diff --git a/BUILD.gn b/BUILD.gn index 1478de7e9fc3f6bf0a1f61baa65ecbc64a8bbdd1..cb3e4211b261cc83a3edd65e91501ddc8f09aecf 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -130,12 +130,99 @@ template("ohos_declaration_template") { } } +# 适配arkui处理noninterop标签的主要api处理template +template("ohos_handle_declaration_template") { + forward_variables_from(invoker, "*") + input_project_dir = invoker.input_project_dir + _module_info_target = "/ohos_sdk_arkui/${sdk_type}/${target_name}_info" + + action_with_pydeps(target_name) { + deps = [ + ":ohos_ets_dynamic", + ":ohos_ets_static" ] + deps += [ ":$_module_info_target" ] + inputs = [] + outputs = [ target_out_dir + "/ohos_sdk_arkui/${target_name}" ] + + script = "//interface/sdk-js/delete_arkui_label.py" + args = [ + "--root-build-dir", + rebase_path("//", root_build_dir), + "--input-interface-sdk", + rebase_path(input_project_dir), + "--output-arkui-interface-sdk", + rebase_path("$target_out_dir/ohos_sdk_arkui/${target_name}"), + "--node-js", + rebase_path(nodejs, root_build_dir) + ] + } + _target_name = target_name + generate_module_info(_module_info_target) { + module_type = "jsdoc" + module_install_name = "" + module_name = _target_name + module_source_dir = + target_out_dir + "/ohos_sdk_arkui/$_target_name" + install_enable = false + } +} + +# 最终打包SDK ets/api执行脚本 +ohos_handle_declaration_template("ohos_build_ets_sdk_api") { + sdk_type = "ets" + input_project_dir = "$ohos_ets_dynamic_path/api" +} + +# 最终打包SDK ets/arkts执行脚本 +ohos_handle_declaration_template("ohos_build_ets_sdk_arkts") { + sdk_type = "ets" + input_project_dir = "$ohos_ets_dynamic_path/arkts" +} + +# 最终打包SDK ets/component执行脚本 +ohos_handle_declaration_template("ohos_build_ets_sdk_component") { + sdk_type = "ets" + input_project_dir = "$ohos_ets_dynamic_path/component" +} + +# 最终打包SDK ets/kits执行脚本 +ohos_handle_declaration_template("ohos_build_ets_sdk_kits") { + sdk_type = "ets" + input_project_dir = "$ohos_ets_dynamic_path/kits" +} + +# 最终打包SDK ets2/api执行脚本 +ohos_handle_declaration_template("ohos_build_ets2_sdk_api") { + sdk_type = "ets2" + input_project_dir = "$ohos_ets_static_path/api" +} + +# 最终打包SDK ets2/arkts执行脚本 +ohos_handle_declaration_template("ohos_build_ets2_sdk_arkts") { + sdk_type = "ets2" + input_project_dir = "$ohos_ets_static_path/arkts" +} + +# 最终打包SDK ets2/kits执行脚本 +ohos_handle_declaration_template("ohos_build_ets2_sdk_kits") { + sdk_type = "ets2" + input_project_dir = "$ohos_ets_static_path/kits" +} + # ets/api执行脚本 ohos_declaration_template("ohos_declaration_ets") { sdk_type = "ets" input_project_dir = interface_sdk_path_ets1 } +ohos_copy("ohos_declaration_ets_api") { + deps = [ ":ohos_declaration_ets" ] + sources = + [ root_out_dir + "/ohos_declaration/${sdk_type}/ohos_declaration_ets" ] + + outputs = [ target_out_dir + "/../api" ] +} + # ets2/api执行脚本 ohos_declaration_template("ohos_declaration_ets2") { sdk_type = "ets2" @@ -149,6 +236,15 @@ ohos_copy_internal("ets_internal_api") { input_project_dir = interface_sdk_path_ets1 } +ohos_prebuilt_etc("ets_internal_api_etc") { + source = "OAT.xml" + deps = [ ":ets_internal_api" ] + install_enable = false + output = string_replace(source, "OAT", "ets_internal_api_etc") + part_name = "sdk" + subsystem_name = "sdk" +} + # ets/arkts执行脚本 ohos_copy_internal("bundle_arkts") { sdk_type = "ets" @@ -156,6 +252,15 @@ ohos_copy_internal("bundle_arkts") { input_project_dir = interface_sdk_path_ets1 } +ohos_prebuilt_etc("bundle_arkts_etc") { + source = "OAT.xml" + deps = [ ":bundle_arkts" ] + install_enable = false + output = string_replace(source, "OAT", "bundle_arkts_etc") + part_name = "sdk" + subsystem_name = "sdk" +} + # ets1.2/arkts执行脚本 ohos_copy_internal("bundle_arkts_ets1.2") { sdk_type = "ets2" @@ -189,6 +294,14 @@ ohos_copy_internal("ets_component") { input_project_dir = interface_sdk_path_ets1 } +ohos_prebuilt_etc("ets_component_etc") { + source = "OAT.xml" + deps = [ ":ets_component" ] + install_enable = false + output = string_replace(source, "OAT", "ets_component_etc") + part_name = "sdk" + subsystem_name = "sdk" +} # ets1.2/arkui/component执行脚本 ohos_copy_internal("ets_component2") { @@ -204,6 +317,14 @@ ohos_copy_internal("bundle_kits") { input_project_dir = interface_sdk_path_ets1 } +ohos_prebuilt_etc("bundle_kits_etc") { + source = "OAT.xml" + deps = [ ":bundle_kits" ] + install_enable = false + output = string_replace(source, "OAT", "ohos_prebuilt_etc") + part_name = "sdk" + subsystem_name = "sdk" +} # ets2/kits执行脚本 ohos_copy_internal("bundle_kits2") { @@ -261,61 +382,9 @@ ohos_copy("syscap_check") { module_install_name = "" } -# ets1.1的执行脚本 -ohos_copy("ohos_build_ets_sdk") { - deps = [ ":handle_ets1.1_arkui_label" ] - sources = [ "$root_build_dir/ohos_dynamic_arkui" ] - outputs=[ target_out_dir+"/${target_name}" ] - module_source_dir = target_out_dir + "/${target_name}" - module_install_name = "" -} - -# ets1.2的执行脚本 -ohos_copy("ohos_build_ets2_sdk") { - deps = [ ":handle_ets1.2_arkui_label" ] - sources = [ "$root_build_dir/ohos_static_arkui" ] - outputs=[ target_out_dir+"/${target_name}" ] - module_source_dir = target_out_dir + "/${target_name}" - module_install_name = "" -} - -# 处理ets1.1的@noninterop标签 -action("handle_ets1.1_arkui_label") { - deps = [ ":ohos_ets_dynamic" ] - script = "delete_arkui_label.py" - args = [ - "--root-build-dir", - rebase_path("//", root_build_dir), - "--input-interface-sdk", - rebase_path(ohos_ets_dynamic_path), - "--output-arkui-interface-sdk", - rebase_path("$root_build_dir/ohos_dynamic_arkui"), - "--node-js", - rebase_path(nodejs, root_build_dir) - ] - outputs=[ "$root_build_dir/ohos_dynamic_arkui" ] -} - -# 处理ets1.2的@noninterop标签 -action("handle_ets1.2_arkui_label") { - deps = [ ":ohos_ets_static" ] - script = "delete_arkui_label.py" - args = [ - "--root-build-dir", - rebase_path("//", root_build_dir), - "--input-interface-sdk", - rebase_path(ohos_ets_static_path), - "--output-arkui-interface-sdk", - rebase_path("$root_build_dir/ohos_static_arkui"), - "--node-js", - rebase_path(nodejs, root_build_dir) - ] - outputs=[ "$root_build_dir/ohos_static_arkui" ] -} - # 处理ets1.1的interop ohos_copy("build_dynamic_sdk_interop") { - deps = [ ":build_sdk_interop1", ":ohos_ets_process_interop" ] + deps = [ ":build_sdk_interop1" ] sources = [ "${interface_sdk_path}/ets1.1interop"] outputs=[ target_out_dir + "/${target_name}" ] module_source_dir = target_out_dir + "/${target_name}" @@ -324,7 +393,7 @@ ohos_copy("build_dynamic_sdk_interop") { # 处理ets1.2 声明文件的interop ohos_copy("build_static_declaration_sdk_interop") { - deps = [ ":build_sdk_interop2", ":ohos_ets_process_interop" ] + deps = [ ":build_sdk_interop2" ] sources = [ "${interface_sdk_path}/ets1.2interop/declaration"] outputs=[ target_out_dir + "/${target_name}" ] module_source_dir = target_out_dir + "/${target_name}" @@ -333,7 +402,7 @@ ohos_copy("build_static_declaration_sdk_interop") { # 处理ets1.2 胶水代码的interop ohos_copy("build_static_bridge_sdk_interop") { - deps = [ ":build_sdk_interop2", ":ohos_ets_process_interop" ] + deps = [ ":build_sdk_interop2" ] sources = [ "${interface_sdk_path}/ets1.2interop/bridge"] outputs=[ target_out_dir + "/${target_name}" ] module_source_dir = target_out_dir + "/${target_name}" @@ -384,14 +453,14 @@ action("build_sdk_interop2") { group("build_ohos_ets") { external_deps = [ ohos_ets_build_system_deps, - ohos_ets_stdlib_deps + ohos_ets_stdlib_deps, + ohos_ets_koala_wrapper_deps ] deps = [ ":ohos_base_split", ":ohos_ets_api", ":ohos_ets_arkts", - ":ohos_ets_kits", - ohos_ets_koala_wrapper_deps, + ":ohos_ets_kits", ohos_ets_ark_link_deps, ohos_ets_es2panda_deps, ohos_ets_libes2panda_public_deps @@ -485,19 +554,23 @@ action("ohos_ets_static_component") { ":ets_component2", ":ohos_ets_static_api_declaration" ] - script = "//interface/sdk-js/arkui_transformer.py" + script = "//interface/sdk-js/process_internal.py" args = [ "--input", rebase_path(interface_sdk_path + "/arkui_transformer_api", root_build_dir), + "--project-dir", + rebase_path(interface_sdk_path, root_build_dir), + "--base-dir", + rebase_path("//interface/sdk-js", root_build_dir), + "--remove", + rebase_path("//interface/sdk-js/remove_list.json", root_build_dir), + "--ispublic", + "${sdk_build_public}", + "--name", + "${target_name}", "--output", - rebase_path(ohos_ets_static_api_path + "/arkui/component", root_build_dir), - "--source_root_dir", - rebase_path("//", root_build_dir), - "--npm-path", - rebase_path(npm, root_build_dir), - "--node-js", - rebase_path(nodejs, root_build_dir), - ] + rebase_path(ohos_ets_static_api_path + "/arkui/component",root_build_dir) + ] outputs = [ ohos_ets_static_api_path + "/arkui/component" ] } @@ -557,20 +630,31 @@ group("ohos_ets_static") { ] } -action("ohos_ets_process_interop") { - deps = [ - ":build_sdk_interop1", - ":build_sdk_interop2" +action("gen_api_check_plugin") { + external_deps = [ + "ace_ets2bundle:ui_plugin" ] - script = "process_label_noninterop.py" + npm_path = "//prebuilts/build-tools/common/nodejs/current/bin/npm" + script = "build_api_check_plugin.py" args = [ - "--intermediates-output", - rebase_path("${interface_sdk_path}", root_build_dir), - "--source-root-dir", - rebase_path("//", root_build_dir), - "--node-js", - rebase_path(nodejs, root_build_dir) + "--source_path", + rebase_path(get_path_info("./build-tools/compile-plugins/api-check-plugin-static", "abspath")), + "--output_path", + rebase_path("$target_gen_dir"), + "--npm", + rebase_path(npm_path), ] + outputs = [ "$target_gen_dir" ] +} - outputs = ["${interface_sdk_path}/arkui_dummy_interop"] +ohos_copy("api_check_plugin") { + deps = [ + ":gen_api_check_plugin" + ] + sources = [ + rebase_path("$target_gen_dir") + ] + outputs = [ target_out_dir + "/$target_name" ] + module_source_dir = target_out_dir + "/$target_name" + module_install_name = "" } \ No newline at end of file diff --git a/api/@internal/component/ets/action_sheet.d.ts b/api/@internal/component/ets/action_sheet.d.ts index 50c6217e9ed028b49d4419613dfaaa0b6ac09062..8c34b13777e9de6b6ecf005da9a75431311e99ba 100644 --- a/api/@internal/component/ets/action_sheet.d.ts +++ b/api/@internal/component/ets/action_sheet.d.ts @@ -18,19 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from '../../global/resource'; -import { - VoidCallback, ResourceStr, ResourceColor, Dimension, BorderRadiuses, LocalizedEdgeColors, EdgeColors, - EdgeWidths, LocalizedEdgeWidths, EdgeStyles, LocalizedBorderRadiuses -} from './units'; -import { Callback, DismissReason, Rectangle, BlurStyle, TransitionEffect, ShadowOptions, HoverModeAreaType, - ShadowStyle, BackgroundBlurStyleOptions, BackgroundEffectOptions } from './common'; -import { DialogButtonStyle, BorderStyle } from './enums'; -import { DialogAlignment } from './alertDialog'; -import { LevelOrder, LevelMode, ImmersiveMode } from '../../@ohos.promptAction'; -/*** endif */ - /** * The information of sheet. * @@ -53,8 +40,7 @@ import { LevelOrder, LevelMode, ImmersiveMode } from '../../@ohos.promptAction'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface SheetInfo { /** @@ -79,8 +65,7 @@ interface SheetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ title: string | Resource; @@ -106,8 +91,7 @@ interface SheetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ icon?: string | Resource; @@ -143,8 +127,7 @@ interface SheetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ action: VoidCallback; } @@ -156,8 +139,7 @@ interface SheetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface DismissDialogAction { /** @@ -170,17 +152,6 @@ declare interface DismissDialogAction { * @since 12 */ dismiss: Callback; - - /** - * Defines dialog dismiss function. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - dismiss(): void; /** * Reason why the dialog box cannot be dismissed. You must specify whether to close the dialog box for each of the @@ -190,8 +161,7 @@ declare interface DismissDialogAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ reason: DismissReason; } @@ -203,8 +173,7 @@ declare interface DismissDialogAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface ActionSheetButtonOptions { /** @@ -234,8 +203,7 @@ interface ActionSheetButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enabled?: boolean; @@ -266,8 +234,7 @@ interface ActionSheetButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ defaultFocus?: boolean; @@ -297,8 +264,7 @@ interface ActionSheetButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ style?: DialogButtonStyle; @@ -334,8 +300,7 @@ interface ActionSheetButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ value: string | Resource; @@ -371,8 +336,7 @@ interface ActionSheetButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ action: VoidCallback; } @@ -384,8 +348,7 @@ interface ActionSheetButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface ActionSheetOffset { /** @@ -396,8 +359,7 @@ interface ActionSheetOffset { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ dx: number | string | Resource; /** @@ -408,8 +370,7 @@ interface ActionSheetOffset { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ dy: number | string | Resource; } @@ -458,8 +419,7 @@ declare type ImmersiveMode = import('../api/@ohos.promptAction').ImmersiveMode; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ActionSheetOptions { @@ -485,8 +445,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ title: string | Resource; @@ -503,8 +462,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ subtitle?: ResourceStr; @@ -530,8 +488,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ message: string | Resource; @@ -568,8 +525,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ confirm?: ActionSheetButtonOptions; @@ -605,8 +561,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ cancel?: VoidCallback; @@ -632,8 +587,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ sheets: Array; @@ -661,8 +615,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ autoCancel?: boolean; @@ -693,8 +646,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignment?: DialogAlignment; @@ -731,8 +683,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ offset?: ActionSheetOffset; @@ -756,8 +707,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maskRect?: Rectangle; @@ -782,8 +732,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ showInSubWindow?: boolean; @@ -802,8 +751,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isModal?: boolean; @@ -828,8 +776,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundColor?: ResourceColor; @@ -855,8 +802,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundBlurStyle?: BlurStyle; @@ -867,8 +813,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -879,8 +824,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -898,8 +842,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillDismiss?: Callback; @@ -917,8 +860,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ transition?: TransitionEffect; @@ -933,8 +875,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ cornerRadius?: Dimension | BorderRadiuses | LocalizedBorderRadiuses; @@ -948,8 +889,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width?: Dimension; @@ -963,8 +903,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height?: Dimension; @@ -979,8 +918,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderWidth?: Dimension | EdgeWidths | LocalizedEdgeWidths; @@ -996,8 +934,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderColor?: ResourceColor | EdgeColors | LocalizedEdgeColors; @@ -1009,8 +946,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderStyle?: BorderStyle | EdgeStyles; @@ -1023,8 +959,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shadow?: ShadowOptions | ShadowStyle; @@ -1036,8 +971,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableHoverMode?: boolean; @@ -1049,8 +983,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ hoverModeArea?: HoverModeAreaType; @@ -1061,8 +994,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onDidAppear?: Callback; @@ -1073,8 +1005,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onDidDisappear?: Callback; @@ -1085,8 +1016,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onWillAppear?: Callback; @@ -1097,8 +1027,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onWillDisappear?: Callback; @@ -1110,8 +1039,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ levelMode?: LevelMode; @@ -1125,8 +1053,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ levelUniqueId?: number; @@ -1138,8 +1065,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ immersiveMode?: ImmersiveMode; @@ -1151,8 +1077,7 @@ interface ActionSheetOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ levelOrder?: LevelOrder; } diff --git a/api/@internal/component/ets/alert_dialog.d.ts b/api/@internal/component/ets/alert_dialog.d.ts index caaf8160a3b90017cbefb0b01808f83e1862a353..9c7ee8c1d04a61a64d5a4ee66e40507161c11518 100644 --- a/api/@internal/component/ets/alert_dialog.d.ts +++ b/api/@internal/component/ets/alert_dialog.d.ts @@ -18,18 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { - ResourceStr, ResourceColor, VoidCallback, Offset, Dimension, BorderRadiuses, LocalizedBorderRadiuses, EdgeWidths, - LocalizedEdgeWidths, EdgeColors, LocalizedEdgeColors, EdgeStyles -} from './units'; -import { WordBreak, DialogButtonStyle, BorderStyle } from './enums'; -import { Rectangle, BlurStyle, Callback, TransitionEffect, ShadowOptions, ShadowStyle, HoverModeAreaType, DismissReason, - BackgroundBlurStyleOptions, BackgroundEffectOptions } from './common'; -import { LevelOrder, ImmersiveMode, LevelMode } from '../../@ohos.promptAction'; -import { DismissDialogAction } from './actionSheet'; -/*** endif */ - /** * The alignment of dialog, * @@ -52,8 +40,7 @@ import { DismissDialogAction } from './actionSheet'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum DialogAlignment { /** @@ -75,8 +62,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Top, @@ -99,8 +85,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Center, @@ -123,8 +108,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Bottom, @@ -147,8 +131,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Default, @@ -171,8 +154,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ TopStart, @@ -195,8 +177,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ TopEnd, @@ -219,8 +200,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CenterStart, @@ -243,8 +223,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CenterEnd, @@ -267,8 +246,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ BottomStart, @@ -291,8 +269,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ BottomEnd, } @@ -312,8 +289,7 @@ declare enum DialogAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice -* @since arkts {'1.1':'11','1.2':'20'} -* @arkts 1.1&1.2 +* @since 11 */ declare enum DialogButtonDirection { /** @@ -329,8 +305,7 @@ declare enum DialogButtonDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ AUTO = 0, @@ -347,8 +322,7 @@ declare enum DialogButtonDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ HORIZONTAL = 1, @@ -365,8 +339,7 @@ declare enum DialogButtonDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ VERTICAL = 2, } @@ -378,8 +351,7 @@ declare enum DialogButtonDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface AlertDialogButtonBaseOptions { /** @@ -410,8 +382,7 @@ declare interface AlertDialogButtonBaseOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enabled?: boolean; @@ -443,8 +414,7 @@ declare interface AlertDialogButtonBaseOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ defaultFocus?: boolean; @@ -476,8 +446,7 @@ declare interface AlertDialogButtonBaseOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ style?: DialogButtonStyle; @@ -506,8 +475,7 @@ declare interface AlertDialogButtonBaseOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ value: ResourceStr; @@ -536,8 +504,7 @@ declare interface AlertDialogButtonBaseOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ fontColor?: ResourceColor; @@ -566,8 +533,7 @@ declare interface AlertDialogButtonBaseOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ backgroundColor?: ResourceColor; @@ -596,8 +562,7 @@ declare interface AlertDialogButtonBaseOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ action: VoidCallback; } @@ -629,8 +594,7 @@ declare interface AlertDialogButtonBaseOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface AlertDialogButtonOptions extends AlertDialogButtonBaseOptions { /** @@ -650,8 +614,7 @@ declare interface AlertDialogButtonOptions extends AlertDialogButtonBaseOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ primary?: boolean; } @@ -678,30 +641,6 @@ declare interface TextStyle { wordBreak?: WordBreak; } -/** - * Defines TextStyle in the AlertDialog. - * - * @interface AlertDialogTextStyleOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare interface AlertDialogTextStyleOptions { - /** - * Set the word break type. - * - * @type { ?WordBreak } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - wordBreak?: WordBreak; -} - /** * Import the LevelOrder type from promptAction. * @@ -735,8 +674,7 @@ declare type LevelOrder = import('../api/@ohos.promptAction').LevelOrder; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface AlertDialogParam { /** @@ -761,8 +699,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ title?: ResourceStr; @@ -779,8 +716,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ subtitle?: ResourceStr; @@ -806,8 +742,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ message: ResourceStr; @@ -833,8 +768,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ autoCancel?: boolean; @@ -870,8 +804,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ cancel?: VoidCallback; @@ -897,8 +830,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignment?: DialogAlignment; @@ -924,8 +856,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset?: Offset; @@ -951,8 +882,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ gridCount?: number; @@ -971,8 +901,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maskRect?: Rectangle; @@ -993,8 +922,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ showInSubWindow?: boolean; @@ -1013,8 +941,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isModal?: boolean; @@ -1035,8 +962,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundColor?: ResourceColor; @@ -1057,8 +983,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundBlurStyle?: BlurStyle; @@ -1069,8 +994,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -1081,8 +1005,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -1093,8 +1016,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillDismiss?: Callback; @@ -1105,8 +1027,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ transition?: TransitionEffect; @@ -1117,8 +1038,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ cornerRadius?: Dimension | BorderRadiuses | LocalizedBorderRadiuses; @@ -1129,8 +1049,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width?: Dimension; @@ -1141,8 +1060,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height?: Dimension; @@ -1153,8 +1071,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderWidth?: Dimension | EdgeWidths | LocalizedEdgeWidths; @@ -1165,8 +1082,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderColor?: ResourceColor | EdgeColors | LocalizedEdgeColors; @@ -1177,8 +1093,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderStyle?: BorderStyle | EdgeStyles; @@ -1189,8 +1104,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shadow?: ShadowOptions | ShadowStyle; @@ -1205,18 +1119,6 @@ declare interface AlertDialogParam { */ textStyle?: TextStyle; - /** - * Set the alertDialog's textStyle. - * - * @type { ?AlertDialogTextStyleOptions } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - textStyle?: AlertDialogTextStyleOptions; - /** * Defines whether to respond to the hover mode. * @@ -1225,8 +1127,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableHoverMode?: boolean; @@ -1238,8 +1139,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ hoverModeArea?: HoverModeAreaType; @@ -1250,8 +1150,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onDidAppear?: Callback; @@ -1262,8 +1161,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onDidDisappear?: Callback; @@ -1274,8 +1172,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onWillAppear?: Callback; @@ -1286,8 +1183,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onWillDisappear?: Callback; @@ -1299,8 +1195,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ levelMode?: LevelMode; @@ -1311,8 +1206,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ levelUniqueId?: number; @@ -1324,8 +1218,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ immersiveMode?: ImmersiveMode; @@ -1337,8 +1230,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ levelOrder?: LevelOrder; } @@ -1368,8 +1260,7 @@ declare interface AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface AlertDialogParamWithConfirm extends AlertDialogParam { /** @@ -1404,8 +1295,7 @@ declare interface AlertDialogParamWithConfirm extends AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ confirm?: AlertDialogButtonBaseOptions; } @@ -1468,8 +1358,7 @@ declare interface DismissDialogAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface AlertDialogParamWithButtons extends AlertDialogParam { /** @@ -1504,8 +1393,7 @@ declare interface AlertDialogParamWithButtons extends AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ primaryButton: AlertDialogButtonBaseOptions; @@ -1541,8 +1429,7 @@ declare interface AlertDialogParamWithButtons extends AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ secondaryButton: AlertDialogButtonBaseOptions; } @@ -1564,8 +1451,7 @@ declare interface AlertDialogParamWithButtons extends AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface AlertDialogParamWithOptions extends AlertDialogParam { /** @@ -1581,8 +1467,7 @@ declare interface AlertDialogParamWithOptions extends AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ buttons: Array; @@ -1601,8 +1486,7 @@ declare interface AlertDialogParamWithOptions extends AlertDialogParam { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ buttonDirection?: DialogButtonDirection; } diff --git a/api/@internal/component/ets/alphabet_indexer.d.ts b/api/@internal/component/ets/alphabet_indexer.d.ts index 8f6c408bf6a5a410c8a0ad4647d6b5dcea7154a3..b947e42ae773e629567d9902b91f49169186defb 100644 --- a/api/@internal/component/ets/alphabet_indexer.d.ts +++ b/api/@internal/component/ets/alphabet_indexer.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod, BlurStyle, Bindable } from './common' -import { ResourceColor, Length, Position } from './units' -import { Font } from './units' -/*** endif */ - /** * indexer align property. * @@ -46,8 +40,7 @@ import { Font } from './units' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum IndexerAlign { /** @@ -69,8 +62,7 @@ declare enum IndexerAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Left, @@ -93,8 +85,7 @@ declare enum IndexerAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Right, @@ -104,8 +95,7 @@ declare enum IndexerAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ START, @@ -115,8 +105,7 @@ declare enum IndexerAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ END, } @@ -128,8 +117,7 @@ declare enum IndexerAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface AlphabetIndexerOptions { /** @@ -164,8 +152,7 @@ interface AlphabetIndexerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ arrayValue: Array; /** @@ -203,17 +190,6 @@ interface AlphabetIndexerOptions { * @since 18 */ selected: number; - /** - * ID of the selected item. - * - * @type { number | Bindable } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected: number | Bindable; } /** @@ -238,8 +214,7 @@ interface AlphabetIndexerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface AlphabetIndexerInterface { /** @@ -282,8 +257,7 @@ interface AlphabetIndexerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options: AlphabetIndexerOptions): AlphabetIndexerAttribute; } @@ -296,8 +270,7 @@ interface AlphabetIndexerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnAlphabetIndexerSelectCallback = (index: number) => void; @@ -309,11 +282,9 @@ declare type OnAlphabetIndexerSelectCallback = (index: number) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnAlphabetIndexerPopupSelectCallback = (index: number) => void; - /** * Defines an AlphabetIndexer callback when onRequestPopupData. * @@ -323,8 +294,7 @@ declare type OnAlphabetIndexerPopupSelectCallback = (index: number) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnAlphabetIndexerRequestPopupDataCallback = (index: number) => Array; @@ -350,8 +320,7 @@ declare type OnAlphabetIndexerRequestPopupDataCallback = (index: number) => Arra * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class AlphabetIndexerAttribute extends CommonMethod { /** @@ -391,8 +360,7 @@ declare class AlphabetIndexerAttribute extends CommonMethod } index - * @returns { AlphabetIndexerAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected(index: number | Bindable): AlphabetIndexerAttribute; /** * Position of the pop-up windows, relative to the midpoint of the top border of the indexer bar. @@ -980,8 +919,7 @@ declare class AlphabetIndexerAttribute extends CommonMethod {} diff --git a/api/@internal/component/ets/blank.d.ts b/api/@internal/component/ets/blank.d.ts index 09487680b7d0fac3f8f2654d49c9929c65a12ed6..19c7cf5a0f0814a37dfe4dc51bb82d7071d3a021 100644 --- a/api/@internal/component/ets/blank.d.ts +++ b/api/@internal/component/ets/blank.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod } from './common'; -import { ResourceColor } from './units'; -/*** endif */ - /** * Create Blank. * @@ -55,8 +50,7 @@ import { ResourceColor } from './units'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface BlankInterface { /** @@ -96,8 +90,7 @@ interface BlankInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (min?: number | string): BlankAttribute; } @@ -134,8 +127,7 @@ interface BlankInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class BlankAttribute extends CommonMethod { /** @@ -175,8 +167,7 @@ declare class BlankAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ color(value: ResourceColor): BlankAttribute; } diff --git a/api/@internal/component/ets/calendar_picker.d.ts b/api/@internal/component/ets/calendar_picker.d.ts index a86fbe7dc893ecf0dd88cd402caf88ad2d179a7c..2ae7c8c787cde6ac58eb41bc6fa7850ffb1c0d2e 100644 --- a/api/@internal/component/ets/calendar_picker.d.ts +++ b/api/@internal/component/ets/calendar_picker.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from '../../global/resource' -import { CommonMethod, PickerTextStyle, Callback, BlurStyle, PickerDialogButtonStyle, ShadowOptions, ShadowStyle, HoverModeAreaType, DateRange, - BackgroundBlurStyleOptions, BackgroundEffectOptions, Optional } from './common' -import { Offset, VoidCallback, ResourceColor } from './units' -/*** endif */ - /** * The type of alignment between entry and calendar. * @enum {number} @@ -38,8 +31,7 @@ import { Offset, VoidCallback, ResourceColor } from './units' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum CalendarAlign { /** @@ -53,8 +45,7 @@ declare enum CalendarAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ START = 0, /** @@ -68,8 +59,7 @@ declare enum CalendarAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CENTER = 1, /** @@ -83,8 +73,7 @@ declare enum CalendarAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ END = 2 } @@ -102,8 +91,7 @@ declare enum CalendarAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CalendarOptions { /** @@ -119,8 +107,7 @@ declare interface CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ hintRadius?: number | Resource; @@ -137,8 +124,7 @@ declare interface CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selected?: Date; @@ -149,8 +135,7 @@ declare interface CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ start?: Date; @@ -161,8 +146,7 @@ declare interface CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ end?: Date; @@ -173,8 +157,7 @@ declare interface CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ disabledDateRange?: DateRange[]; } @@ -192,8 +175,7 @@ declare interface CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface CalendarPickerInterface { /** @@ -211,8 +193,7 @@ interface CalendarPickerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options?: CalendarOptions): CalendarPickerAttribute; } @@ -230,8 +211,7 @@ interface CalendarPickerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CalendarPickerAttribute extends CommonMethod { /** @@ -251,8 +231,7 @@ declare class CalendarPickerAttribute extends CommonMethod, offset?: Offset): CalendarPickerAttribute; @@ -284,8 +262,7 @@ declare class CalendarPickerAttribute extends CommonMethod): CalendarPickerAttribute; @@ -326,8 +302,7 @@ declare class CalendarPickerAttribute extends CommonMethod): CalendarPickerAttribute; @@ -338,8 +313,7 @@ declare class CalendarPickerAttribute extends CommonMethod>): CalendarPickerAttribute; @@ -351,8 +325,7 @@ declare class CalendarPickerAttribute extends CommonMethod; @@ -425,8 +396,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onCancel?: VoidCallback; @@ -452,8 +422,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange?: Callback; @@ -474,8 +443,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundColor?: ResourceColor; @@ -496,8 +464,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundBlurStyle?: BlurStyle; @@ -508,8 +475,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -520,8 +486,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -532,8 +497,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ acceptButtonStyle?: PickerDialogButtonStyle; @@ -544,8 +508,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ cancelButtonStyle?: PickerDialogButtonStyle; @@ -566,8 +529,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDidAppear?: VoidCallback; @@ -588,8 +550,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDidDisappear?: VoidCallback; @@ -610,8 +571,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onWillAppear?: VoidCallback; @@ -632,8 +592,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onWillDisappear?: VoidCallback; @@ -644,8 +603,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shadow?: ShadowOptions | ShadowStyle; @@ -657,8 +615,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableHoverMode?: boolean; @@ -670,8 +627,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ hoverModeArea?: HoverModeAreaType; @@ -683,8 +639,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ markToday?: boolean; } @@ -700,8 +655,7 @@ declare interface CalendarDialogOptions extends CalendarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CalendarPickerDialog { /** @@ -717,8 +671,7 @@ declare class CalendarPickerDialog { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ static show(options?: CalendarDialogOptions): void; } diff --git a/api/@internal/component/ets/canvas.d.ts b/api/@internal/component/ets/canvas.d.ts index 8ac90328238d56767c2a9a482b80edbdc0b62c8f..0fb1acf0152559711df634bd140b204bdac94a8c 100644 --- a/api/@internal/component/ets/canvas.d.ts +++ b/api/@internal/component/ets/canvas.d.ts @@ -18,15 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod, Callback, PixelMap } from './common'; -import { FrameNode } from '../FrameNode'; -import { ImageAIOptions, ImageAnalyzerConfig } from './imageCommon'; -import { Matrix2D } from './matrix2d'; -import { VoidCallback, LengthMetricsUnit, LengthMetrics } from './units'; -import { Size } from '../Graphics' -/*** endif */ - /** * Import the drawing canvas type object for Canvas. * @@ -82,8 +73,7 @@ declare type DrawingCanvas = import('../api/@ohos.graphics.drawing').default.Can * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare type CanvasFillRule = "evenodd" | "nonzero"; @@ -135,8 +125,7 @@ declare type CanvasFillRule = "evenodd" | "nonzero"; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare type CanvasLineCap = "butt" | "round" | "square"; @@ -200,8 +189,7 @@ declare type CanvasLineCap = "butt" | "round" | "square"; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare type CanvasLineJoin = "bevel" | "miter" | "round"; @@ -249,8 +237,7 @@ declare type CanvasLineJoin = "bevel" | "miter" | "round"; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare type CanvasDirection = "inherit" | "ltr" | "rtl"; @@ -314,8 +301,7 @@ declare type CanvasDirection = "inherit" | "ltr" | "rtl"; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare type CanvasTextAlign = "center" | "end" | "left" | "right" | "start"; @@ -383,8 +369,7 @@ declare type CanvasTextAlign = "center" | "end" | "left" | "right" | "start"; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare type CanvasTextBaseline = "alphabetic" | "bottom" | "hanging" | "ideographic" | "middle" | "top"; @@ -432,8 +417,7 @@ declare type CanvasTextBaseline = "alphabetic" | "bottom" | "hanging" | "ideogra * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare type ImageSmoothingQuality = "high" | "low" | "medium"; @@ -476,8 +460,7 @@ declare type FrameNode = import('../api/arkui/FrameNode').FrameNode; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CanvasGradient { /** @@ -520,8 +503,7 @@ declare class CanvasGradient { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ addColorStop(offset: number, color: string): void; @@ -568,8 +550,7 @@ declare class CanvasGradient { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CanvasPath { /** @@ -580,7 +561,7 @@ declare class CanvasPath { * @param { number } radius - Radius of the arc. * @param { number } startAngle - Start point of an arc, which starts to be calculated in the x-axis direction. The unit is radian. * @param { number } endAngle - The end point of the arc, in radians. - * @param { boolean } counterclockwise - If the value is true, the arc is drawn counterclockwise. Otherwise, + * @param { boolean } [counterclockwise] - If the value is true, the arc is drawn counterclockwise. Otherwise, * the arc is drawn clockwise. The default value is false. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 8 @@ -593,7 +574,7 @@ declare class CanvasPath { * @param { number } radius - Radius of the arc. * @param { number } startAngle - Start point of an arc, which starts to be calculated in the x-axis direction. The unit is radian. * @param { number } endAngle - The end point of the arc, in radians. - * @param { boolean } counterclockwise - If the value is true, the arc is drawn counterclockwise. Otherwise, + * @param { boolean } [counterclockwise] - If the value is true, the arc is drawn counterclockwise. Otherwise, * the arc is drawn clockwise. The default value is false. * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -607,7 +588,7 @@ declare class CanvasPath { * @param { number } radius - Radius of the arc. * @param { number } startAngle - Start point of an arc, which starts to be calculated in the x-axis direction. The unit is radian. * @param { number } endAngle - The end point of the arc, in radians. - * @param { boolean } counterclockwise - If the value is true, the arc is drawn counterclockwise. Otherwise, + * @param { boolean } [counterclockwise] - If the value is true, the arc is drawn counterclockwise. Otherwise, * the arc is drawn clockwise. The default value is false. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -622,14 +603,13 @@ declare class CanvasPath { * @param { number } radius - Radius of the arc. * @param { number } startAngle - Start point of an arc, which starts to be calculated in the x-axis direction. The unit is radian. * @param { number } endAngle - The end point of the arc, in radians. - * @param { boolean } counterclockwise - If the value is true, the arc is drawn counterclockwise. Otherwise, + * @param { boolean } [counterclockwise] - If the value is true, the arc is drawn counterclockwise. Otherwise, * the arc is drawn clockwise. The default value is false. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ arc(x: number, y: number, radius: number, startAngle: number, endAngle: number, counterclockwise?: boolean): void; @@ -681,8 +661,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ arcTo(x1: number, y1: number, x2: number, y2: number, radius: number): void; @@ -738,8 +717,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ bezierCurveTo(cp1x: number, cp1y: number, cp2x: number, cp2y: number, x: number, y: number): void; @@ -771,8 +749,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ closePath(): void; @@ -844,8 +821,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ellipse( x: number, @@ -894,8 +870,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lineTo(x: number, y: number): void; @@ -935,8 +910,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ moveTo(x: number, y: number): void; @@ -984,8 +958,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ quadraticCurveTo(cpx: number, cpy: number, x: number, y: number): void; @@ -1033,8 +1006,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rect(x: number, y: number, w: number, h: number): void; @@ -1045,7 +1017,8 @@ declare class CanvasPath { * @param { number } y - The y-axis coordinate of the start point of the rectangle. * @param { number } w - Width of the rectangle. * @param { number } h - Height of the rectangle. - * @param { number | Array } radii - A number or list specifying the radii of the circular arc to be used for the corners of the rectangle. The default value is 0. + * @param { number | Array } [radii] - A number or list specifying the radii of the circular arc to be used for the corners of the rectangle. + * The default value is 0. * @throws { BusinessError } 103701 - Parameter error. Possible causes: *
1. The param radii is a list that has zero or more than four elements. *
2. The param radii contains negative value. @@ -1090,8 +1063,7 @@ declare class CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class Path2D extends CanvasPath { /** @@ -1130,8 +1102,7 @@ declare class Path2D extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ addPath(path: Path2D, transform?: Matrix2D): void; @@ -1163,8 +1134,7 @@ declare class Path2D extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -1176,8 +1146,7 @@ declare class Path2D extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(unit: LengthMetricsUnit); @@ -1213,8 +1182,7 @@ declare class Path2D extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(path: Path2D); @@ -1227,8 +1195,7 @@ declare class Path2D extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(path: Path2D, unit: LengthMetricsUnit); @@ -1264,8 +1231,7 @@ declare class Path2D extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(d: string); @@ -1278,8 +1244,7 @@ declare class Path2D extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(description: string, unit: LengthMetricsUnit); } @@ -1316,8 +1281,7 @@ declare class Path2D extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CanvasPattern { /** @@ -1352,8 +1316,7 @@ declare interface CanvasPattern { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ setTransform(transform?: Matrix2D): void; } @@ -1390,8 +1353,7 @@ declare interface CanvasPattern { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TextMetrics { /** @@ -1434,8 +1396,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly actualBoundingBoxAscent: number; @@ -1479,8 +1440,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly actualBoundingBoxDescent: number; @@ -1524,8 +1484,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly actualBoundingBoxLeft: number; @@ -1569,8 +1528,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly actualBoundingBoxRight: number; @@ -1614,8 +1572,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly alphabeticBaseline: number; @@ -1659,8 +1616,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly emHeightAscent: number; @@ -1704,8 +1660,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly emHeightDescent: number; @@ -1749,8 +1704,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly fontBoundingBoxAscent: number; @@ -1794,8 +1748,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly fontBoundingBoxDescent: number; @@ -1839,8 +1792,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly hangingBaseline: number; @@ -1884,8 +1836,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly ideographicBaseline: number; @@ -1925,8 +1876,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly width: number; @@ -1966,8 +1916,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ readonly height: number; } @@ -2000,8 +1949,7 @@ declare interface TextMetrics { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ImageBitmap { /** @@ -2044,19 +1992,6 @@ declare class ImageBitmap { */ readonly height: number; - /** - * Indicates the height of the CSS pixel unit of ImageData. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get height(): number; - /** * Indicates the width of the CSS pixel unit of ImageData. * @@ -2097,19 +2032,6 @@ declare class ImageBitmap { */ readonly width: number; - /** - * Indicates the width of the CSS pixel unit of ImageData. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get width(): number; - /** * Releases all graphics resources associated with an ImageBitmap. * @@ -2138,8 +2060,7 @@ declare class ImageBitmap { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ close(): void; @@ -2229,19 +2150,6 @@ declare class ImageBitmap { * @since 12 */ constructor(data: PixelMap, unit: LengthMetricsUnit); - - /** - * Create an ImageBitmap object based on the transferred image path or PixelMap object. - * - * @param { PixelMap | string } src - image path or PixelMap object - * @param { LengthMetricsUnit } [unit] - the unit mode - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - constructor(src: PixelMap | string, unit?: LengthMetricsUnit); } /** @@ -2272,8 +2180,7 @@ declare class ImageBitmap { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ImageData { /** @@ -2316,19 +2223,6 @@ declare class ImageData { */ readonly data: Uint8ClampedArray; - /** - * Array containing image pixel data - * - * @return { Uint8ClampedArray } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get data(): Uint8ClampedArray; - /** * Width of the image. * @@ -2369,19 +2263,6 @@ declare class ImageData { */ readonly height: number; - /** - * Height of the image. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get height(): number; - /** * Height of the image. * @@ -2422,19 +2303,6 @@ declare class ImageData { */ readonly width: number; - /** - * Width of the image. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get width(): number; - /** * Create an ImageData object based on the input parameters. * @@ -2490,8 +2358,7 @@ declare class ImageData { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(width: number, height: number, data?: Uint8ClampedArray, unit?: LengthMetricsUnit); } @@ -2524,8 +2391,7 @@ declare class ImageData { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class RenderingContextSettings { /** @@ -2564,32 +2430,6 @@ declare class RenderingContextSettings { */ antialias?: boolean; - /** - * Get the status whether anti-aliasing is enabled for canvas. The default value is false. - * - * @return { boolean | undefined } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get antialias(): boolean | undefined; - - /** - * Set the status whether anti-aliasing is enabled for canvas. The default value is false. - * - * @param { boolean | undefined } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set antialias(antialias: boolean | undefined); - /** * Create an RenderingContextSettings object based on the antialias and alpha. * @@ -2622,8 +2462,7 @@ declare class RenderingContextSettings { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(antialias?: boolean); } @@ -2660,8 +2499,7 @@ declare class RenderingContextSettings { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CanvasRenderer extends CanvasPath { /** @@ -2676,30 +2514,6 @@ declare class CanvasRenderer extends CanvasPath { */ letterSpacing: LengthMetrics | string; - /** - * Get spacing for letter. - * - * @return { LengthMetrics | string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get letterSpacing(): LengthMetrics | string; - - /** - * Set spacing for letter. - * - * @param { LengthMetrics | string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set letterSpacing(letterSpacing: LengthMetrics | string); - /** * Transparency. The value ranges from 0.0 (completely transparent) to 1.0 (completely opaque). * If the value is out of range, the assignment is invalid. @@ -2744,34 +2558,6 @@ declare class CanvasRenderer extends CanvasPath { */ globalAlpha: number; - /** - * Get transparency. The value ranges from 0.0 (completely transparent) to 1.0 (completely opaque). - * If the value is out of range, the assignment is invalid. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get globalAlpha(): number; - - /** - * Set transparency. The value ranges from 0.0 (completely transparent) to 1.0 (completely opaque). - * If the value is out of range, the assignment is invalid. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set globalAlpha(globalAlpha: number); - /** * Type of composition operation applied when drawing a new shape. The following types are supported: * source-over: (Default) Draws a new drawing on top of an existing canvas context. @@ -2868,60 +2654,6 @@ declare class CanvasRenderer extends CanvasPath { */ globalCompositeOperation: string; - /** - * Get the type of composition operation applied when drawing a new shape. The following types are supported: - * source-over: (Default) Draws a new drawing on top of an existing canvas context. - * source-in: The new drawing is drawn only where the new drawing overlaps the target canvas. - * Everything else is transparent. - * source-out: Draws a new drawing where it does not overlap with the existing canvas content. - * source-atop: The new drawing is drawn only where it overlaps the content of the existing canvas. - * destination-over: Draws a new graphic behind the existing canvas content. - * destination-in: Existing canvas content remains where the new drawing overlaps the existing canvas content. - * Everything else is transparent. - * destination-out: Existing content remains where the new drawing does not overlap. - * destination-atop: The existing canvas retains only the part that overlaps with the new drawing, - * which is drawn behind the canvas content. - * lighter: The color of two overlapping shapes is determined by adding the color values. - * copy: Only new graphics are displayed. - * xor: In the image, those overlaps and other places outside of the normal drawing are transparent. - * - * @return { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get globalCompositeOperation(): string; - - /** - * Set the type of composition operation applied when drawing a new shape. The following types are supported: - * source-over: (Default) Draws a new drawing on top of an existing canvas context. - * source-in: The new drawing is drawn only where the new drawing overlaps the target canvas. - * Everything else is transparent. - * source-out: Draws a new drawing where it does not overlap with the existing canvas content. - * source-atop: The new drawing is drawn only where it overlaps the content of the existing canvas. - * destination-over: Draws a new graphic behind the existing canvas content. - * destination-in: Existing canvas content remains where the new drawing overlaps the existing canvas content. - * Everything else is transparent. - * destination-out: Existing content remains where the new drawing does not overlap. - * destination-atop: The existing canvas retains only the part that overlaps with the new drawing, - * which is drawn behind the canvas content. - * lighter: The color of two overlapping shapes is determined by adding the color values. - * copy: Only new graphics are displayed. - * xor: In the image, those overlaps and other places outside of the normal drawing are transparent. - * - * @param { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set globalCompositeOperation(globalCompositeOperation: string); - /** * Draw an image on a canvas * @@ -2962,8 +2694,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ drawImage(image: ImageBitmap | PixelMap, dx: number, dy: number): void; @@ -3015,8 +2746,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ drawImage(image: ImageBitmap | PixelMap, dx: number, dy: number, dw: number, dh: number): void; @@ -3084,8 +2814,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ drawImage( image: ImageBitmap | PixelMap, @@ -3127,8 +2856,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ beginPath(): void; @@ -3164,8 +2892,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ clip(fillRule?: CanvasFillRule): void; @@ -3205,8 +2932,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ clip(path: Path2D, fillRule?: CanvasFillRule): void; @@ -3242,8 +2968,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fill(fillRule?: CanvasFillRule): void; @@ -3283,8 +3008,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fill(path: Path2D, fillRule?: CanvasFillRule): void; @@ -3356,19 +3080,6 @@ declare class CanvasRenderer extends CanvasPath { */ stroke(path: Path2D): void; - /** - * Draws the specified path according to the current stroke style - * - * @param { Path2D } [path] - Specified stroke path object - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - stroke(path?: Path2D): void; - /** * Attributes that describe the fill color and style. The options are as follows: * color: Color String @@ -3423,40 +3134,6 @@ declare class CanvasRenderer extends CanvasPath { */ fillStyle: string | number | CanvasGradient | CanvasPattern; - /** - * Get the attributes specifie the color, gradient, or pattern to use inside shapes. The options are as follows: - * - * @return { string | number | CanvasGradient | CanvasPattern } - * string: Color String. - * number: Indicates the color with number. - * CanvasGradient: Color gradient object. For details, see {@link CanvasGradient}. - * CanvasPattern: Template object. For details, see {@link CanvasPattern}. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get fillStyle(): string | number | CanvasGradient | CanvasPattern; - - /** - * Set the attributes specifie the color, gradient, or pattern to use inside shapes. The options are as follows: - * - * @param { string | number | CanvasGradient | CanvasPattern } - * string: Color String. - * number: Indicates the color with number. - * CanvasGradient: Color gradient object. For details, see {@link CanvasGradient}. - * CanvasPattern: Template object. For details, see {@link CanvasPattern}. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set fillStyle(fillStyle: string | number | CanvasGradient | CanvasPattern); - /** * Attributes of the stroke color and style. The options are as follows: * color: Color String @@ -3512,43 +3189,7 @@ declare class CanvasRenderer extends CanvasPath { strokeStyle: string | number | CanvasGradient | CanvasPattern; /** - * Get the attributes specifie the color, gradient, or pattern to use for the strokes (outlines) around shapes. - * The options are as follows: - * - * @return { string | number | CanvasGradient | CanvasPattern } - * string: Color String. - * number: Indicates the color with number. - * CanvasGradient: Color gradient object. For details, see {@link CanvasGradient}. - * CanvasPattern: Template object. For details, see {@link CanvasPattern}. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get strokeStyle(): string | number | CanvasGradient | CanvasPattern; - - /** - * Set the attributes specifie the color, gradient, or pattern to use for the strokes (outlines) around shapes. - * The options are as follows: - * - * @param { string | number | CanvasGradient | CanvasPattern } - * string: Color String. - * number: Indicates the color with number. - * CanvasGradient: Color gradient object. For details, see {@link CanvasGradient}. - * CanvasPattern: Template object. For details, see {@link CanvasPattern}. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set strokeStyle(strokeStyle: string | number | CanvasGradient | CanvasPattern); - - /** - * Creates a linear gradient object that is specified along the parameter coordinates + * Creates a linear gradient object that is specified along the parameter coordinates * * @param { number } x0 - The x-axis coordinate of the start point. * @param { number } y0 - The y-axis coordinate of the start point. @@ -3595,8 +3236,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ createLinearGradient(x0: number, y0: number, x1: number, y1: number): CanvasGradient; @@ -3660,8 +3300,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ createPattern(image: ImageBitmap, repetition: string | null): CanvasPattern | null; @@ -3721,8 +3360,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ createRadialGradient(x0: number, y0: number, r0: number, x1: number, y1: number, r1: number): CanvasGradient; @@ -3749,8 +3387,7 @@ declare class CanvasRenderer extends CanvasPath { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ createConicGradient( startAngle: number, @@ -3862,64 +3499,6 @@ declare class CanvasRenderer extends CanvasPath { */ filter: string; - /** - * Provides filter effects such as blur and grayscale. You can get the following filter effects: - * blur(): Adds a Gaussian blur effect to the drawing - * brightness(): Provides a linear multiplication for the drawing and adjusts the brightness level. - * contrast(): Adjusts the contrast of the image. When the value is 0%, the image is completely black. - * When the value is 100%, there is no change in the image. - * grayscale(): Converts the image to a gray image. When the value is 100%, the image is completely gray. - * When the value is 0%, there is no change in the image. - * hue-rotate(): Perform color rotation on an image. When the value is 0 degrees, there is no change in the image. - * invert(): Inverted image (representing the effect of a photographic negative). When the value is 100%, - * the image is completely inverted. When the value is 0%, there is no change in the image. - * opacity(): Transparency of the image. At 0%, the image is completely transparent. - * When the value is 100%, there is no change in the image. - * saturate(): Perform saturation processing on the image. At 0%, the image is completely un-saturated. - * When the value is 100%, there is no change in the image. - * sepia(): The image is sepia (nostalgic style). At 100%, the image turns completely sepia. - * When the value is 0%, there is no change in the image. - * none: Turn off filter effects - * - * @return { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get filter(): string; - - /** - * Provides filter effects such as blur and grayscale. You can set the following filter effects: - * blur(): Adds a Gaussian blur effect to the drawing - * brightness(): Provides a linear multiplication for the drawing and adjusts the brightness level. - * contrast(): Adjusts the contrast of the image. When the value is 0%, the image is completely black. - * When the value is 100%, there is no change in the image. - * grayscale(): Converts the image to a gray image. When the value is 100%, the image is completely gray. - * When the value is 0%, there is no change in the image. - * hue-rotate(): Perform color rotation on an image. When the value is 0 degrees, there is no change in the image. - * invert(): Inverted image (representing the effect of a photographic negative). When the value is 100%, - * the image is completely inverted. When the value is 0%, there is no change in the image. - * opacity(): Transparency of the image. At 0%, the image is completely transparent. - * When the value is 100%, there is no change in the image. - * saturate(): Perform saturation processing on the image. At 0%, the image is completely un-saturated. - * When the value is 100%, there is no change in the image. - * sepia(): The image is sepia (nostalgic style). At 100%, the image turns completely sepia. - * When the value is 0%, there is no change in the image. - * none: Turn off filter effects - * - * @param { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set filter(filter: string); - /** * Creates a new, empty ImageData object of the specified size * @@ -3960,8 +3539,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ createImageData(sw: number, sh: number): ImageData; @@ -3969,7 +3547,7 @@ declare class CanvasRenderer extends CanvasPath { * From an existing ImageData object, copy an object with the same width and height as the image. * The image content is not copied. * - * @param { ImageData } imagedata - ImageData object to be copied. + * @param { ImageData } imageData - ImageData object to be copied. * @returns { ImageData } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 8 @@ -3978,7 +3556,7 @@ declare class CanvasRenderer extends CanvasPath { * From an existing ImageData object, copy an object with the same width and height as the image. * The image content is not copied. * - * @param { ImageData } imagedata - ImageData object to be copied. + * @param { ImageData } imageData - ImageData object to be copied. * @returns { ImageData } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -3988,7 +3566,7 @@ declare class CanvasRenderer extends CanvasPath { * From an existing ImageData object, copy an object with the same width and height as the image. * The image content is not copied. * - * @param { ImageData } imagedata - ImageData object to be copied. + * @param { ImageData } imageData - ImageData object to be copied. * @returns { ImageData } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -3999,16 +3577,15 @@ declare class CanvasRenderer extends CanvasPath { * From an existing ImageData object, copy an object with the same width and height as the image. * The image content is not copied. * - * @param { ImageData } imagedata - ImageData object to be copied. + * @param { ImageData } imageData - ImageData object to be copied. * @returns { ImageData } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - createImageData(imagedata: ImageData): ImageData; + createImageData(imageData: ImageData): ImageData; /** * Obtains the pixel data of a specified area on the current canvas. @@ -4058,8 +3635,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getImageData(sx: number, sy: number, sw: number, sh: number): ImageData; @@ -4097,15 +3673,14 @@ declare class CanvasRenderer extends CanvasPath { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getPixelMap(sx: number, sy: number, sw: number, sh: number): PixelMap; /** * Draws the specified ImageData object onto the canvas * - * @param { ImageData } imagedata - ImageData object to be drawn. + * @param { ImageData } imageData - ImageData object to be drawn. * @param { number } dx - Position offset of the source image data in the target canvas (the offset in the x-axis direction). * @param { number } dy - Position offset of the source image data in the target canvas (the offset in the y-axis direction). * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -4114,7 +3689,7 @@ declare class CanvasRenderer extends CanvasPath { /** * Draws the specified ImageData object onto the canvas * - * @param { ImageData } imagedata - ImageData object to be drawn. + * @param { ImageData } imageData - ImageData object to be drawn. * @param { number } dx - Position offset of the source image data in the target canvas (the offset in the x-axis direction). * @param { number } dy - Position offset of the source image data in the target canvas (the offset in the y-axis direction). * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -4124,7 +3699,7 @@ declare class CanvasRenderer extends CanvasPath { /** * Draws the specified ImageData object onto the canvas * - * @param { ImageData } imagedata - ImageData object to be drawn. + * @param { ImageData } imageData - ImageData object to be drawn. * @param { number | string } dx - Position offset of the source image data in the target canvas (the offset in the x-axis direction). * @param { number | string } dy - Position offset of the source image data in the target canvas (the offset in the y-axis direction). * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -4135,22 +3710,21 @@ declare class CanvasRenderer extends CanvasPath { /** * Draws the specified ImageData object onto the canvas * - * @param { ImageData } imagedata - ImageData object to be drawn. + * @param { ImageData } imageData - ImageData object to be drawn. * @param { number | string } dx - Position offset of the source image data in the target canvas (the offset in the x-axis direction). * @param { number | string } dy - Position offset of the source image data in the target canvas (the offset in the y-axis direction). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - putImageData(imagedata: ImageData, dx: number | string, dy: number | string): void; + putImageData(imageData: ImageData, dx: number | string, dy: number | string): void; /** * Draws the specified ImageData object onto the canvas * - * @param { ImageData } imagedata - ImageData object to be drawn. + * @param { ImageData } imageData - ImageData object to be drawn. * @param { number } dx - Position offset of the source image data in the target canvas (the offset in the x-axis direction). * @param { number } dy - Position offset of the source image data in the target canvas (the offset in the y-axis direction). * @param { number } dirtyX - Position of the upper left corner of the rectangular area in the source image data. @@ -4167,7 +3741,7 @@ declare class CanvasRenderer extends CanvasPath { /** * Draws the specified ImageData object onto the canvas * - * @param { ImageData } imagedata - ImageData object to be drawn. + * @param { ImageData } imageData - ImageData object to be drawn. * @param { number } dx - Position offset of the source image data in the target canvas (the offset in the x-axis direction). * @param { number } dy - Position offset of the source image data in the target canvas (the offset in the y-axis direction). * @param { number } dirtyX - Position of the upper left corner of the rectangular area in the source image data. @@ -4185,7 +3759,7 @@ declare class CanvasRenderer extends CanvasPath { /** * Draws the specified ImageData object onto the canvas * - * @param { ImageData } imagedata - ImageData object to be drawn. + * @param { ImageData } imageData - ImageData object to be drawn. * @param { number | string } dx - Position offset of the source image data in the target canvas (the offset in the x-axis direction). * @param { number | string } dy - Position offset of the source image data in the target canvas (the offset in the y-axis direction). * @param { number | string } dirtyX - Position of the upper left corner of the rectangular area in the source image data. @@ -4204,7 +3778,7 @@ declare class CanvasRenderer extends CanvasPath { /** * Draws the specified ImageData object onto the canvas * - * @param { ImageData } imagedata - ImageData object to be drawn. + * @param { ImageData } imageData - ImageData object to be drawn. * @param { number | string } dx - Position offset of the source image data in the target canvas (the offset in the x-axis direction). * @param { number | string } dy - Position offset of the source image data in the target canvas (the offset in the y-axis direction). * @param { number | string } dirtyX - Position of the upper left corner of the rectangular area in the source image data. @@ -4219,11 +3793,10 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ putImageData( - imagedata: ImageData, + imageData: ImageData, dx: number | string, dy: number | string, dirtyX: number | string, @@ -4276,34 +3849,6 @@ declare class CanvasRenderer extends CanvasPath { */ imageSmoothingEnabled: boolean; - /** - * Get the status whether to smooth the image. The value true indicates that the image is smooth. - * The value false indicates that the image is not smooth. - * - * @return { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get imageSmoothingEnabled(): boolean; - - /** - * Set the status whether to smooth the image. The value true indicates that the image is smooth. - * The value false indicates that the image is not smooth. - * - * @param { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set imageSmoothingEnabled(imageSmoothingEnabled: boolean); - /** * Smoothness level of the current image. For details, see {@link ImageSmoothingQuality}. * @@ -4344,32 +3889,6 @@ declare class CanvasRenderer extends CanvasPath { */ imageSmoothingQuality: ImageSmoothingQuality; - /** - * Get the smoothness level of the current image. For details, see {@link ImageSmoothingQuality}. - * - * @return { ImageSmoothingQuality } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get imageSmoothingQuality(): ImageSmoothingQuality; - - /** - * Set the smoothness level of the current image. For details, see {@link ImageSmoothingQuality}. - * - * @param { ImageSmoothingQuality } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set imageSmoothingQuality(imageSmoothingQuality: ImageSmoothingQuality); - /** * Line segment endpoint attribute. For details, see {@link CanvasLineCap}. * @@ -4409,32 +3928,6 @@ declare class CanvasRenderer extends CanvasPath { * @since 11 */ lineCap: CanvasLineCap; - - /** - * Get the line segment endpoint attribute. For details, see {@link CanvasLineCap}. - * - * @return { CanvasLineCap } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get lineCap(): CanvasLineCap; - - /** - * Set the line segment endpoint attribute. For details, see {@link CanvasLineCap}. - * - * @param { CanvasLineCap } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set lineCap(lineCap: CanvasLineCap); /** * Dotted line offset attribute. @@ -4476,32 +3969,6 @@ declare class CanvasRenderer extends CanvasPath { */ lineDashOffset: number; - /** - * Get the dotted line offset attribute. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get lineDashOffset(): number; - - /** - * Set the dotted line offset attribute. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set lineDashOffset(lineDashOffset: number); - /** * Line segment connection point attribute. For details, see {@link CanvasLineJoin}. * @@ -4542,32 +4009,6 @@ declare class CanvasRenderer extends CanvasPath { */ lineJoin: CanvasLineJoin; - /** - * Get the line segment connection point attribute. For details, see {@link CanvasLineJoin}. - * - * @return { CanvasLineJoin } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get lineJoin(): CanvasLineJoin; - - /** - * Set the line segment connection point attribute. For details, see {@link CanvasLineJoin}. - * - * @param { CanvasLineJoin } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set lineJoin(lineJoin: CanvasLineJoin); - /** * Line thickness attribute. The value cannot be 0 or a negative number. * @@ -4608,32 +4049,6 @@ declare class CanvasRenderer extends CanvasPath { */ lineWidth: number; - /** - * Get the line thickness attribute. The value cannot be 0 or a negative number. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get lineWidth(): number; - - /** - * Set the line thickness attribute. The value cannot be 0 or a negative number. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set lineWidth(lineWidth: number); - /** * The value of this parameter cannot be 0 or a negative number. * @@ -4674,32 +4089,6 @@ declare class CanvasRenderer extends CanvasPath { */ miterLimit: number; - /** - * Get the value of this parameter cannot be 0 or a negative number. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get miterLimit(): number; - - /** - * Set the value of this parameter cannot be 0 or a negative number. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set miterLimit(miterLimit: number); - /** * Gets the current segment style. * @@ -4732,8 +4121,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getLineDash(): number[]; @@ -4773,8 +4161,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ setLineDash(segments: number[]): void; @@ -4822,8 +4209,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ clearRect(x: number, y: number, w: number, h: number): void; @@ -4871,8 +4257,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fillRect(x: number, y: number, w: number, h: number): void; @@ -4920,8 +4305,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeRect(x: number, y: number, w: number, h: number): void; @@ -4965,32 +4349,6 @@ declare class CanvasRenderer extends CanvasPath { */ shadowBlur: number; - /** - * Get the shadow blur radius. The value cannot be a negative number. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get shadowBlur(): number; - - /** - * Set the shadow blur radius. The value cannot be a negative number. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set shadowBlur(shadowBlur: number); - /** * Shadow color. * @@ -5031,32 +4389,6 @@ declare class CanvasRenderer extends CanvasPath { */ shadowColor: string; - /** - * Get the shadow color. - * - * @return { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get shadowColor(): string; - - /** - * Set the shadow color. - * - * @param { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set shadowColor(shadowColor: string); - /** * Horizontal offset distance of the shadow. * @@ -5097,32 +4429,6 @@ declare class CanvasRenderer extends CanvasPath { */ shadowOffsetX: number; - /** - * Get the horizontal offset distance of the shadow. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get shadowOffsetX(): number; - - /** - * Set the horizontal offset distance of the shadow. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set shadowOffsetX(shadowOffsetX: number); - /** * Vertical offset distance of the shadow. * @@ -5163,32 +4469,6 @@ declare class CanvasRenderer extends CanvasPath { */ shadowOffsetY: number; - /** - * Get the vertical offset distance of the shadow. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get shadowOffsetY(): number; - - /** - * Set the vertical offset distance of the shadow. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set shadowOffsetY(shadowOffsetY: number); - /** * Top of the stack pop-up state in the drawing state stack * @@ -5217,8 +4497,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ restore(): void; @@ -5250,8 +4529,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ save(): void; @@ -5299,8 +4577,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fillText(text: string, x: number, y: number, maxWidth?: number): void; @@ -5340,8 +4617,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ measureText(text: string): TextMetrics; @@ -5389,8 +4665,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeText(text: string, x: number, y: number, maxWidth?: number): void; @@ -5434,32 +4709,6 @@ declare class CanvasRenderer extends CanvasPath { */ direction: CanvasDirection; - /** - * Get the text drawing direction. For details, see {@link CanvasDirection}. - * - * @return { CanvasDirection } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get direction(): CanvasDirection; - - /** - * Set the text drawing direction. For details, see {@link CanvasDirection}. - * - * @param { CanvasDirection } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set direction(direction: CanvasDirection); - /** * Font style. * @@ -5500,32 +4749,6 @@ declare class CanvasRenderer extends CanvasPath { */ font: string; - /** - * Get the font style. - * - * @return { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get font(): string; - - /** - * Set the font style. - * - * @param { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set font(font: string); - /** * Text alignment mode. For details, see {@link CanvasTextAlign}. * @@ -5566,32 +4789,6 @@ declare class CanvasRenderer extends CanvasPath { */ textAlign: CanvasTextAlign; - /** - * Get the text alignment mode. For details, see {@link CanvasTextAlign}. - * - * @return { CanvasTextAlign } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get textAlign(): CanvasTextAlign; - - /** - * Set the text alignment mode. For details, see {@link CanvasTextAlign}. - * - * @param { CanvasTextAlign } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set textAlign(textAlign: CanvasTextAlign); - /** * Text baseline. For details, see {@link CanvasTextBaseline}. * @@ -5632,32 +4829,6 @@ declare class CanvasRenderer extends CanvasPath { */ textBaseline: CanvasTextBaseline; - /** - * Get the text baseline. For details, see {@link CanvasTextBaseline}. - * - * @return { CanvasTextBaseline } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get textBaseline(): CanvasTextBaseline; - - /** - * Set the text baseline. For details, see {@link CanvasTextBaseline}. - * - * @param { CanvasTextBaseline } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set textBaseline(textBaseline: CanvasTextBaseline); - /** * Obtains the currently applied transformation matrix. * @@ -5690,8 +4861,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getTransform(): Matrix2D; @@ -5723,8 +4893,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ resetTransform(): void; @@ -5764,8 +4933,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rotate(angle: number): void; @@ -5805,8 +4973,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scale(x: number, y: number): void; @@ -5866,8 +5033,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ setTransform(a: number, b: number, c: number, d: number, e: number, f: number): void; @@ -5907,8 +5073,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ setTransform(transform?: Matrix2D): void; @@ -5968,8 +5133,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ transform(a: number, b: number, c: number, d: number, e: number, f: number): void; @@ -6009,8 +5173,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ translate(x: number, y: number): void; @@ -6036,8 +5199,7 @@ declare class CanvasRenderer extends CanvasPath { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ setPixelMap(value?: PixelMap): void; @@ -6073,8 +5235,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ transferFromImageBitmap(bitmap: ImageBitmap): void; @@ -6084,8 +5245,7 @@ declare class CanvasRenderer extends CanvasPath { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ saveLayer(): void; @@ -6095,8 +5255,7 @@ declare class CanvasRenderer extends CanvasPath { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ restoreLayer(): void; @@ -6106,8 +5265,7 @@ declare class CanvasRenderer extends CanvasPath { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ reset(): void; } @@ -6144,8 +5302,7 @@ declare class CanvasRenderer extends CanvasPath { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CanvasRenderingContext2D extends CanvasRenderer { /** @@ -6188,20 +5345,6 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { */ readonly height: number; - /** - * The default value is 0, which is bound to the height of the specified canvas. The value is read-only. - * - * @return { number } - * @readonly - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get height(): number; - /** * The default value is 0, which is bound to the width of the specified canvas. The value is read-only. * @@ -6242,20 +5385,6 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { */ readonly width: number; - /** - * The default value is 0, which is bound to the width of the specified canvas. The value is read-only. - * - * @return { number } - * @readonly - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get width(): number; - /** * Frame node of the canvas. The default value is null. * @@ -6268,18 +5397,6 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { */ readonly canvas: FrameNode; - /** - * Frame node of the canvas. The default value is null. - * - * @return { FrameNode } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get canvas(): FrameNode; - /** * Generate a character string in the data url format. * @@ -6328,22 +5445,6 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { */ toDataURL(type?: string, quality?: any): string; - /** - * Generate a character string in the data url format. - * - * @param { string } [type] - Image format. The default value is image/png. - * @param { number } [quality] - If the image format is image/jpeg or image/webp, you can select the image quality from 0 to 1. - * If the value is out of the range, the default value 0.92 is used. - * @returns { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - toDataURL(type?: string, quality?: number): string; - /** * Start image analyzer. * @@ -6354,8 +5455,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * @throws { BusinessError } 110003 - Image analysis is stopped. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ startImageAnalyzer(config: ImageAnalyzerConfig): Promise; @@ -6363,8 +5463,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * Stop image analyzer. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ stopImageAnalyzer(): void; @@ -6413,8 +5512,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(settings?: RenderingContextSettings, unit?: LengthMetricsUnit); @@ -6430,8 +5528,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ on(type: 'onAttach', callback: Callback): void; @@ -6439,7 +5536,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * Unregister the listener that watches if the canvasrenderingcontext2d attached to the Canvas frameNode. * * @param { 'onAttach' } type Indicates the type of event. - * @param { Callback } callback Indicates the listener. + * @param { Callback } [callback] Indicates the listener. * @throws { BusinessError } 401 - Input parameter error. Possible causes: * 1. Mandatory parameters are left unspecified; * 2. Incorrect parameter types; @@ -6447,8 +5544,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ off(type: 'onAttach', callback?: Callback): void; @@ -6464,8 +5560,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ on(type: 'onDetach', callback: Callback): void; @@ -6473,7 +5568,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * Unregister the listener that watches if the canvasrenderingcontext2d detached from the Canvas frameNode. * * @param { 'onDetach' } type Indicates the type of event. - * @param { Callback } callback Indicates the listener. + * @param { Callback } [callback] Indicates the listener. * @throws { BusinessError } 401 - Input parameter error. Possible causes: * 1. Mandatory parameters are left unspecified; * 2. Incorrect parameter types; @@ -6481,8 +5576,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ off(type: 'onDetach', callback?: Callback): void; } @@ -6519,8 +5613,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class OffscreenCanvasRenderingContext2D extends CanvasRenderer { /** @@ -6571,22 +5664,6 @@ declare class OffscreenCanvasRenderingContext2D extends CanvasRenderer { */ toDataURL(type?: string, quality?: any): string; - /** - * Generate a character string in the data url format. - * - * @param { string } [type] - Image format. The default value is image/png. - * @param { number } [quality] - If the image format is image/jpeg or image/webp, you can select the image quality from 0 to 1. - * If the value is out of the range, the default value 0.92 is used. - * @returns { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - toDataURL(type?: string, quality?: number): string; - /** * transfer the content to ImageBitmap * @@ -6619,8 +5696,7 @@ declare class OffscreenCanvasRenderingContext2D extends CanvasRenderer { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ transferToImageBitmap(): ImageBitmap; @@ -6679,8 +5755,7 @@ declare class OffscreenCanvasRenderingContext2D extends CanvasRenderer { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(width: number, height: number, settings?: RenderingContextSettings, unit?: LengthMetricsUnit); } @@ -6716,8 +5791,7 @@ declare class OffscreenCanvasRenderingContext2D extends CanvasRenderer { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class OffscreenCanvas { /** @@ -6756,32 +5830,6 @@ declare class OffscreenCanvas { */ height: number; - /** - * Get the height of the off-screen canvas. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get height(): number; - - /** - * Set the height of the off-screen canvas. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set height(height: number); - /** * Width of the off-screen canvas. * @@ -6818,32 +5866,6 @@ declare class OffscreenCanvas { */ width: number; - /** - * Get the width of the off-screen canvas. - * - * @return { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - get width(): number; - - /** - * Set the width of the off-screen canvas. - * - * @param { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - set width(width: number); - /** * Exports rendered content as an ImageBitmap object * @@ -6876,8 +5898,7 @@ declare class OffscreenCanvas { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ transferToImageBitmap(): ImageBitmap; @@ -6902,8 +5923,7 @@ declare class OffscreenCanvas { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getContext(contextType: "2d", options?: RenderingContextSettings): OffscreenCanvasRenderingContext2D; @@ -6960,21 +5980,6 @@ declare class OffscreenCanvas { * @since 12 */ constructor(width: number, height: number, unit: LengthMetricsUnit); - - /** - * Constructor of the off-screen canvas, which is used to create an off-screen canvas object. - * - * @param { number } width - Width of the off-screen canvas. - * @param { number } height - Height of the off-screen canvas. - * @param { LengthMetricsUnit } [unit] - the unit mode - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - constructor(width: number, height: number, unit?: LengthMetricsUnit); } /** @@ -7016,8 +6021,7 @@ declare interface Size { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class DrawingRenderingContext { @@ -7028,8 +6032,7 @@ declare class DrawingRenderingContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ get size(): Size; @@ -7050,8 +6053,7 @@ declare class DrawingRenderingContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ invalidate(): void; @@ -7062,8 +6064,7 @@ declare class DrawingRenderingContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(unit?: LengthMetricsUnit); } @@ -7100,8 +6101,7 @@ declare class DrawingRenderingContext { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface CanvasInterface { /** @@ -7151,8 +6151,7 @@ interface CanvasInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ (context?: CanvasRenderingContext2D | DrawingRenderingContext): CanvasAttribute; @@ -7164,8 +6163,7 @@ interface CanvasInterface { * @returns { CanvasAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ (context: CanvasRenderingContext2D | DrawingRenderingContext, imageAIOptions: ImageAIOptions): CanvasAttribute; } @@ -7202,8 +6200,7 @@ interface CanvasInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CanvasAttribute extends CommonMethod { /** @@ -7253,8 +6250,7 @@ declare class CanvasAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onReady(event: VoidCallback): CanvasAttribute; @@ -7265,8 +6261,7 @@ declare class CanvasAttribute extends CommonMethod { * @returns { CanvasAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableAnalyzer(enable: boolean): CanvasAttribute; } diff --git a/api/@internal/component/ets/checkbox.d.ts b/api/@internal/component/ets/checkbox.d.ts index eabf504d46ee1ca6bd632810f2bda67e090c8e1e..a75371bcf8d36b7db43f156a0bc0ace776d105cd 100644 --- a/api/@internal/component/ets/checkbox.d.ts +++ b/api/@internal/component/ets/checkbox.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonConfiguration, Callback, CommonMethod, ContentModifier, Optional, Bindable } from './common'; -import { CustomBuilder } from './builder'; -import { ResourceColor, MarkStyle } from './units'; -import { CheckBoxShape } from './enums'; -/*** endif */ - /** * Defines the options of Checkbox. * @@ -57,8 +50,7 @@ import { CheckBoxShape } from './enums'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CheckboxOptions { /** @@ -93,8 +85,7 @@ declare interface CheckboxOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ name?: string; @@ -130,8 +121,7 @@ declare interface CheckboxOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ group?: string; @@ -142,8 +132,7 @@ declare interface CheckboxOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ indicatorBuilder?: CustomBuilder; } @@ -156,8 +145,7 @@ declare interface CheckboxOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface CheckBoxConfiguration extends CommonConfiguration { /** @@ -167,8 +155,7 @@ declare interface CheckBoxConfiguration extends CommonConfiguration; } @@ -229,8 +214,8 @@ declare interface CheckBoxConfiguration extends CommonConfiguration void; @@ -326,8 +309,8 @@ declare type OnCheckboxChangeCallback = (value: boolean) => void; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class CheckboxAttribute extends CommonMethod { /** @@ -383,20 +366,6 @@ declare class CheckboxAttribute extends CommonMethod { */ select(isSelected: Optional): CheckboxAttribute; - /** - * setting whether checkbox is selected. - * - * @param { boolean | undefined | Bindable } isSelected - * @returns { CheckboxAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - select(isSelected: boolean | undefined | Bindable): CheckboxAttribute; - /** * setting the display color of checkbox. * @@ -433,8 +402,7 @@ declare class CheckboxAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedColor(value: ResourceColor): CheckboxAttribute; @@ -447,8 +415,7 @@ declare class CheckboxAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ selectedColor(resColor: Optional): CheckboxAttribute; @@ -471,8 +438,7 @@ declare class CheckboxAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shape(value: CheckBoxShape): CheckboxAttribute; @@ -485,8 +451,7 @@ declare class CheckboxAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ shape(shape: Optional): CheckboxAttribute; @@ -507,8 +472,7 @@ declare class CheckboxAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ unselectedColor(value: ResourceColor): CheckboxAttribute; @@ -520,8 +484,7 @@ declare class CheckboxAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ unselectedColor(resColor: Optional): CheckboxAttribute; @@ -542,8 +505,7 @@ declare class CheckboxAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ mark(value: MarkStyle): CheckboxAttribute; @@ -555,8 +517,7 @@ declare class CheckboxAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ mark(style: Optional): CheckboxAttribute; @@ -608,8 +569,7 @@ declare class CheckboxAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange(callback: OnCheckboxChangeCallback): CheckboxAttribute; @@ -622,8 +582,7 @@ declare class CheckboxAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange(callback: Optional): CheckboxAttribute; @@ -635,8 +594,7 @@ declare class CheckboxAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentModifier(modifier: ContentModifier): CheckboxAttribute; @@ -648,8 +606,7 @@ declare class CheckboxAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ contentModifier(modifier: Optional>): CheckboxAttribute; } diff --git a/api/@internal/component/ets/checkboxgroup.d.ts b/api/@internal/component/ets/checkboxgroup.d.ts index 60f4eb3d941e73bfcaa6301746350afb6e12d807..c2201583ae692370e41f42d9cc48b060978497aa 100644 --- a/api/@internal/component/ets/checkboxgroup.d.ts +++ b/api/@internal/component/ets/checkboxgroup.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod, Optional, Bindable } from './common'; -import { ResourceColor, MarkStyle } from './units'; -import { CheckBoxShape } from './enums'; -/*** endif */ - /** * CheckboxGroup SelectStatus * @@ -56,8 +50,7 @@ import { CheckBoxShape } from './enums'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SelectStatus { /** @@ -88,8 +81,7 @@ declare enum SelectStatus { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ All, /** @@ -120,8 +112,7 @@ declare enum SelectStatus { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Part, /** @@ -152,8 +143,7 @@ declare enum SelectStatus { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ None, } @@ -190,8 +180,7 @@ declare enum SelectStatus { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CheckboxGroupOptions { /** @@ -226,8 +215,7 @@ declare interface CheckboxGroupOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ group?: string; } @@ -264,8 +252,7 @@ declare interface CheckboxGroupOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CheckboxGroupResult { /** @@ -300,8 +287,7 @@ declare interface CheckboxGroupResult { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ name: Array; /** @@ -336,8 +322,7 @@ declare interface CheckboxGroupResult { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ status: SelectStatus; } @@ -374,8 +359,8 @@ declare interface CheckboxGroupResult { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface CheckboxGroupInterface { /** @@ -414,8 +399,7 @@ interface CheckboxGroupInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options?: CheckboxGroupOptions): CheckboxGroupAttribute; } @@ -430,8 +414,7 @@ interface CheckboxGroupInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnCheckboxGroupChangeCallback = (value: CheckboxGroupResult) => void; @@ -467,8 +450,8 @@ declare type OnCheckboxGroupChangeCallback = (value: CheckboxGroupResult) => voi * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class CheckboxGroupAttribute extends CommonMethod { /** @@ -524,20 +507,6 @@ declare class CheckboxGroupAttribute extends CommonMethod): CheckboxGroupAttribute; - /** - * setting whether all checkbox is selected. - * - * @param { boolean| undefined|Bindable } isAllSelected - * @returns { CheckboxGroupAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selectAll(isAllSelected: boolean | undefined | Bindable): CheckboxGroupAttribute; - /** * setting the display color of checkbox. * @@ -574,8 +543,7 @@ declare class CheckboxGroupAttribute extends CommonMethod): CheckboxGroupAttribute; @@ -610,8 +577,7 @@ declare class CheckboxGroupAttribute extends CommonMethod): CheckboxGroupAttribute; @@ -645,8 +610,7 @@ declare class CheckboxGroupAttribute extends CommonMethod): CheckboxGroupAttribute; @@ -711,8 +674,7 @@ declare class CheckboxGroupAttribute extends CommonMethod): CheckboxGroupAttribute; @@ -739,8 +700,7 @@ declare class CheckboxGroupAttribute extends CommonMethod): CheckboxGroupAttribute; } diff --git a/api/@internal/component/ets/circle.d.ts b/api/@internal/component/ets/circle.d.ts index 845dd4b638feba1c9ddd34cc86374e5927b4b6f4..42e6cc834a3f90dea4e9c7c544bb2a43d7a7b38a 100644 --- a/api/@internal/component/ets/circle.d.ts +++ b/api/@internal/component/ets/circle.d.ts @@ -18,10 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonShapeMethod,CommonMethod } from './common'; -/*** endif */ - /** * Defines circle options for Circle component. * @@ -54,8 +50,7 @@ import { CommonShapeMethod,CommonMethod } from './common'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CircleOptions { /** @@ -299,8 +294,7 @@ interface CircleInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CircleAttribute extends CommonShapeMethod {} @@ -367,30 +361,3 @@ declare const Circle: CircleInterface; * @since 11 */ declare const CircleInstance: CircleAttribute; - -/** - * Defines circle component. - * - * @interface CircleInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface CircleInterface { - /** - * Set the options for circle component. - * - * @param { CircleOptions } [value] - options to create circle component. - * @returns { CircleAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (value?: CircleOptions): CircleAttribute; -} diff --git a/api/@internal/component/ets/column.d.ts b/api/@internal/component/ets/column.d.ts index 96457a9ee06baefc0134795dfdcc5fd43ff59c03..4c7f1e96961c8274b65babb8f5b72d3d024214d5 100644 --- a/api/@internal/component/ets/column.d.ts +++ b/api/@internal/component/ets/column.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { PointLightStyle, Optional, CommonMethod } from './common'; -import { HorizontalAlign, FlexAlign } from './enums'; -import { Resource } from './../../global/resource'; -/*** endif */ - /** * Defines the space property with string, number and resource unit. * @@ -32,8 +26,7 @@ import { Resource } from './../../global/resource'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type SpaceType = string | number | Resource; @@ -45,8 +38,7 @@ declare type SpaceType = string | number | Resource; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface ColumnOptions { /** @@ -81,8 +73,18 @@ interface ColumnOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + */ + /** + * Vertical layout element spacing. + * + * Anonymous Object Rectification + * @type { ?(string | number) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 */ space?: string | number; } @@ -95,8 +97,7 @@ interface ColumnOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface ColumnOptionsV2 { /** @@ -107,8 +108,7 @@ interface ColumnOptionsV2 { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ space?: SpaceType; } @@ -145,8 +145,7 @@ interface ColumnOptionsV2 { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ColumnInterface { /** @@ -198,27 +197,27 @@ interface ColumnInterface { /** * Set the options. * + * Anonymous Object Rectification * @param { ColumnOptions } [options] - column options * @returns { ColumnAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: ColumnOptions): ColumnAttribute; /** * Set the options. * + * Anonymous Object Rectification * @param { ColumnOptions | ColumnOptionsV2 } [options] - column options * @returns { ColumnAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: ColumnOptions | ColumnOptionsV2): ColumnAttribute; } @@ -255,8 +254,7 @@ interface ColumnInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ColumnAttribute extends CommonMethod { /** @@ -295,8 +293,7 @@ declare class ColumnAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignItems(value: HorizontalAlign): ColumnAttribute; @@ -336,8 +333,7 @@ declare class ColumnAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ justifyContent(value: FlexAlign): ColumnAttribute; /** @@ -347,8 +343,7 @@ declare class ColumnAttribute extends CommonMethod { * @returns { ColumnAttribute } The attribute of the column. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pointLight(value: PointLightStyle): ColumnAttribute; /** @@ -360,8 +355,7 @@ declare class ColumnAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ reverse(isReversed: Optional): ColumnAttribute; } diff --git a/api/@internal/component/ets/column_split.d.ts b/api/@internal/component/ets/column_split.d.ts index 4ad3617ad8ed6b196c97a1b150fcbea635c855ec..f76e6cc09da387856ea2096a1079ca28614b94c2 100644 --- a/api/@internal/component/ets/column_split.d.ts +++ b/api/@internal/component/ets/column_split.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Dimension } from './units'; -import { CommonMethod } from './common'; -/*** endif */ - /** * Defines the ColumnSplit component. * @@ -45,8 +40,7 @@ import { CommonMethod } from './common'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ColumnSplitInterface { /** @@ -71,8 +65,7 @@ interface ColumnSplitInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): ColumnSplitAttribute; } @@ -92,8 +85,7 @@ interface ColumnSplitInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ColumnSplitDividerStyle { /** @@ -113,8 +105,7 @@ interface ColumnSplitDividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ startMargin?: Dimension; @@ -135,8 +126,7 @@ interface ColumnSplitDividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ endMargin?: Dimension; } @@ -163,8 +153,7 @@ interface ColumnSplitDividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ColumnSplitAttribute extends CommonMethod { /** @@ -192,8 +181,7 @@ declare class ColumnSplitAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ resizeable(value: boolean): ColumnSplitAttribute; @@ -214,8 +202,7 @@ declare class ColumnSplitAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ divider(value: ColumnSplitDividerStyle | null): ColumnSplitAttribute; } diff --git a/api/@internal/component/ets/common.d.ts b/api/@internal/component/ets/common.d.ts index f11410e0529eab7543019bc85ced42cd3e631f63..daf1b6439e9656d9f245b352a12e9ded57bc5a3e 100644 --- a/api/@internal/component/ets/common.d.ts +++ b/api/@internal/component/ets/common.d.ts @@ -12,10 +12,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + /** * @file * @kit ArkUI */ + /** * Defines the options of Component ClassDecorator. * @@ -79,7 +81,7 @@ declare interface ComponentOptions { */ declare interface InputCounterOptions { /** - * It is the numerator bit of the percentage and used as a threshold. If the number of characters input + * It is the numerator bit of the percentage and used as a threshold. If the number of characters input * reaches the maximum number of characters multiplied by this threshold, the counter is displayed. * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -87,23 +89,8 @@ declare interface InputCounterOptions { * @since 11 */ /** - * It is the numerator bit of the percentage and used as a threshold. If the number of characters input + * It is the numerator bit of the percentage and used as a threshold. If the number of characters input * reaches the maximum number of characters multiplied by this threshold, the counter is displayed. - * - *

NOTE: - *
Threshold percentage for displaying the character counter. - *
The character counter is displayed when the number of characters that have been entered is greater than - * the maximum number of characters multiplied by the threshold percentage value. - *
When displayed, the character counter is in the following format: - *
Number of characters that have been entered/Maximum number of characters allowed. - *
It is visible when the number of characters entered is greater than - * the character limit multiplied by the threshold percentage value. - *
Value range: [1, 100] - *
If the value is not an integer, it is rounded down to the nearest integer. - *
If the value exceeds the valid value range, the character counter is not displayed. - *
If the value is undefined, the character counter is displayed, but this parameter has no effect. - *

- * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -111,7 +98,7 @@ declare interface InputCounterOptions { * @since 12 */ thresholdPercentage?: number; - + /** * If the current input character count reaches the maximum character count and users want to exceed the * normal input, the border will turn red. If this parameter is true, the red border displayed. @@ -124,16 +111,6 @@ declare interface InputCounterOptions { /** * If the current input character count reaches the maximum character count and users want to exceed the * normal input, the border will turn red. If this parameter is true, the red border displayed. - * - *

NOTE: - *
Whether to highlight the text box border and character counter subscript in red. - *
If options is not set, the text box border and character counter subscript turn red - *
when the number of characters entered reaches the limit. - *
If the character counter is displayed and thresholdPercentage is set to a valid value, - * the text box border and character counter subscript turn red when the number of entered characters exceeds the limit. - *
The value true (default) means to highlight the text box border and character counter subscript in red. - *

- * * @type { ?boolean } * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -751,23 +728,23 @@ declare const Provider: (aliasName?: string) => PropertyDecorator; declare const Consume: PropertyDecorator & ((value: string) => PropertyDecorator); /** -* Defining Consumer PropertyDecorator, aliasName is the only matching key and if aliasName is the default, the default attribute name is regarded as aliasName. -* And @Consumer will find the nearest @Provider. -* @syscap SystemCapability.ArkUI.ArkUI.Full -* @crossplatform -* @atomicservice -* @since 12 -*/ + * Defining Consumer PropertyDecorator, aliasName is the only matching key and if aliasName is the default, the default attribute name is regarded as aliasName. + * And @Consumer will find the nearest @Provider. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ declare const Consumer: (aliasName?: string) => PropertyDecorator; /** -* Defining Computed MethodDecorator. -* -* @syscap SystemCapability.ArkUI.ArkUI.Full -* @crossplatform -* @atomicservice -* @since 12 -*/ + * Defining Computed MethodDecorator. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ declare const Computed: MethodDecorator; /** @@ -970,7 +947,7 @@ declare const Extend: MethodDecorator & ((value: any) => MethodDecorator); * @atomicservice * @since 11 */ - declare const AnimatableExtend: MethodDecorator & ((value: Object) => MethodDecorator); +declare const AnimatableExtend: MethodDecorator & ((value: Object) => MethodDecorator); /** * Define Monitor MethodDecorator @@ -1076,13 +1053,7 @@ declare interface IMonitorValue { } /** - * The **AnimatableArithmetic** API defines the animation operation rules for - * non-number data types. To animate non-number data (such as arrays, structs, - * and colors), implement the addition, subtraction, multiplication, and - * equality judgment functions in the **AnimatableArithmetic\** API. - * In this way, the data can be involved in an interpolation operation of the - * animation and identify whether the data changes, that is, the non-number data - * is defined as the types that implement the **AnimatableArithmetic\** API. + * Define AnimatableArithmetic interface * * @interface AnimatableArithmetic * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -1090,13 +1061,7 @@ declare interface IMonitorValue { * @since 10 */ /** - * The **AnimatableArithmetic** API defines the animation operation rules for - * non-number data types. To animate non-number data (such as arrays, structs, - * and colors), implement the addition, subtraction, multiplication, and - * equality judgment functions in the **AnimatableArithmetic\** API. - * In this way, the data can be involved in an interpolation operation of the - * animation and identify whether the data changes, that is, the non-number data - * is defined as the types that implement the **AnimatableArithmetic\** API. + * Define AnimatableArithmetic interface * * @interface AnimatableArithmetic * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -1104,9 +1069,9 @@ declare interface IMonitorValue { * @atomicservice * @since 11 */ - declare interface AnimatableArithmetic { +declare interface AnimatableArithmetic { /** - * Defines the addition rule of the data type. + * Define plus method * * @param { AnimatableArithmetic } rhs - another value * @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface @@ -1115,7 +1080,7 @@ declare interface IMonitorValue { * @since 10 */ /** - * Defines the addition rule of the data type. + * Define plus method * * @param { AnimatableArithmetic } rhs - another value * @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface @@ -1124,10 +1089,10 @@ declare interface IMonitorValue { * @atomicservice * @since 11 */ - plus(rhs: AnimatableArithmetic): AnimatableArithmetic; + plus(rhs: AnimatableArithmetic): AnimatableArithmetic; /** - * Defines the subtraction rule of the data type. + * Define subtract method * * @param { AnimatableArithmetic } rhs - another value * @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface @@ -1136,7 +1101,7 @@ declare interface IMonitorValue { * @since 10 */ /** - * Defines the subtraction rule of the data type. + * Define subtract method * * @param { AnimatableArithmetic } rhs - another value * @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface @@ -1145,10 +1110,10 @@ declare interface IMonitorValue { * @atomicservice * @since 11 */ - subtract(rhs: AnimatableArithmetic): AnimatableArithmetic; + subtract(rhs: AnimatableArithmetic): AnimatableArithmetic; /** - * Defines the multiplication rule of the data type. + * Define multiply method * * @param { number } scale - scale value * @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface @@ -1157,7 +1122,7 @@ declare interface IMonitorValue { * @since 10 */ /** - * Defines the multiplication rule of the data type. + * Define multiply method * * @param { number } scale - scale value * @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface @@ -1166,10 +1131,10 @@ declare interface IMonitorValue { * @atomicservice * @since 11 */ - multiply(scale: number): AnimatableArithmetic; + multiply(scale: number): AnimatableArithmetic; /** - * Defines the equality judgment rule of the data type. + * Define equals method * * @param { AnimatableArithmetic } rhs - another value * @returns { boolean } is equals @@ -1178,7 +1143,7 @@ declare interface IMonitorValue { * @since 10 */ /** - * Defines the equality judgment rule of the data type. + * Define equals method * * @param { AnimatableArithmetic } rhs - another value * @returns { boolean } is equals @@ -1220,7 +1185,7 @@ declare const Concurrent: MethodDecorator; * A function with this decorator is marked as sendable, and the function can be an shareable property of sendable-class object. * A typeAlias with this decorator is marked as sendable, and the typeAlias can be used to declare properties, variables, * and arguments that need to be assigned with sendable-function. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -1304,14 +1269,7 @@ declare const LocalStorageProp: (value: string) => PropertyDecorator; * Obtains the Context object associated with a component on the page. * * @param { Object } component - indicate the component on the page. - * If no component is passed in or the passed-in parameter type is invalid, the default context is returned. - * The default context is the context obtained by tracing the call chain of the API. - * If this API is used in an asynchronous callback or not initially called on the current page, the context of the - * instance may fail to be traced. In this case, undefined is returned. * @returns { Context } - * The context type depends on the ability type. - * For example, if this API is called on a page of the UIAbility, the return value type is UIAbilityContext; - * if this API is called on a page of the ExtensionAbility, the return value type is ExtensionContext. * @syscap SystemCapability.ArkUI.ArkUI.Full * @StageModelOnly * @since 9 @@ -1320,14 +1278,7 @@ declare const LocalStorageProp: (value: string) => PropertyDecorator; * Obtains the Context object associated with a component on the page. * * @param { Object } component - indicate the component on the page. - * If no component is passed in or the passed-in parameter type is invalid, the default context is returned. - * The default context is the context obtained by tracing the call chain of the API. - * If this API is used in an asynchronous callback or not initially called on the current page, the context of the - * instance may fail to be traced. In this case, undefined is returned. * @returns { Context } - * The context type depends on the ability type. - * For example, if this API is called on a page of the UIAbility, the return value type is UIAbilityContext; - * if this API is called on a page of the ExtensionAbility, the return value type is ExtensionContext. * @syscap SystemCapability.ArkUI.ArkUI.Full * @StageModelOnly * @crossplatform @@ -1337,14 +1288,7 @@ declare const LocalStorageProp: (value: string) => PropertyDecorator; * Obtains the Context object associated with a component on the page. * * @param { Object } component - indicate the component on the page. - * If no component is passed in or the passed-in parameter type is invalid, the default context is returned. - * The default context is the context obtained by tracing the call chain of the API. - * If this API is used in an asynchronous callback or not initially called on the current page, the context of the - * instance may fail to be traced. In this case, undefined is returned. * @returns { Context } - * The context type depends on the ability type. - * For example, if this API is called on a page of the UIAbility, the return value type is UIAbilityContext; - * if this API is called on a page of the ExtensionAbility, the return value type is ExtensionContext. * @syscap SystemCapability.ArkUI.ArkUI.Full * @StageModelOnly * @crossplatform @@ -1382,17 +1326,17 @@ declare const Reusable: ClassDecorator; */ declare const ReusableV2: ClassDecorator; - /** - * ReuseId callback type. It is used to compute reuseId. - * - * @typedef { function } ReuseIdCallback - * @returns { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - declare type ReuseIdCallback = () => string; +/** + * ReuseId callback type. It is used to compute reuseId. + * + * @typedef { function } ReuseIdCallback + * @returns { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ +declare type ReuseIdCallback = () => string; /** * Defining the reusable configuration parameters. @@ -1415,6 +1359,7 @@ declare interface ReuseOptions { */ reuseId? : ReuseIdCallback; } + /** * Get context. * @@ -1443,6 +1388,7 @@ declare interface ReuseOptions { * @since 11 */ declare type Context = import('../api/application/Context').default; + /** * Post Card Action. * @@ -1830,7 +1776,7 @@ declare interface ExpectedFrameRateRange { * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 11 - */ + */ /** * The maximum animation drawing FPS. * The maximum value should be greater than or equal to the minimum value. @@ -1838,7 +1784,7 @@ declare interface ExpectedFrameRateRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 - */ + */ /** * The maximum animation drawing FPS. * The maximum value should be greater than or equal to the minimum value. @@ -1857,7 +1803,7 @@ declare interface ExpectedFrameRateRange { * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 11 - */ + */ /** * The expected frame rate of dynamical callback rate range. * The value should be between the minimum and maximum value. @@ -1867,7 +1813,7 @@ declare interface ExpectedFrameRateRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 - */ + */ /** * The expected frame rate of dynamical callback rate range. * The value should be between the minimum and maximum value. @@ -1886,11 +1832,6 @@ declare interface ExpectedFrameRateRange { * global $r function * * @param { string } value - * The value format is 'belonging.type.name'. - * belonging: group to which the resource belongs, which can be 'sys' or 'app'. - * type: resource type, which can be 'boolean', 'color', 'float', 'intarray', 'integer', 'pattern', 'plural', - * 'strarray', 'string', or 'media'. - * name: resource name, which is determined during resource definition. * @param { any[] } params * @returns { Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -1900,11 +1841,6 @@ declare interface ExpectedFrameRateRange { * global $r function * * @param { string } value - * The value format is 'belonging.type.name'. - * belonging: group to which the resource belongs, which can be 'sys' or 'app'. - * type: resource type, which can be 'boolean', 'color', 'float', 'intarray', 'integer', 'pattern', 'plural', - * 'strarray', 'string', or 'media'. - * name: resource name, which is determined during resource definition. * @param { any[] } params * @returns { Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -1915,11 +1851,6 @@ declare interface ExpectedFrameRateRange { * global $r function * * @param { string } value - * The value format is 'belonging.type.name'. - * belonging: group to which the resource belongs, which can be 'sys' or 'app'. - * type: resource type, which can be 'boolean', 'color', 'float', 'intarray', 'integer', 'pattern', 'plural', - * 'strarray', 'string', or 'media'. - * name: resource name, which is determined during resource definition. * @param { any[] } params * @returns { Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -1931,11 +1862,6 @@ declare interface ExpectedFrameRateRange { * global $r function * * @param { string } value - * The value format is 'belonging.type.name'. - * belonging: group to which the resource belongs, which can be 'sys' or 'app'. - * type: resource type, which can be 'boolean', 'color', 'float', 'intarray', 'integer', 'pattern', 'plural', - * 'strarray', 'string', or 'media'. - * name: resource name, which is determined during resource definition. * @param { any[] } params * @returns { Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -1945,14 +1871,11 @@ declare interface ExpectedFrameRateRange { * @since 11 */ declare function $r(value: string, ...params: any[]): Resource; + /** * global $rawfile function * * @param { string } value - * name of the file in the resources/rawfile directory of the project. - * When referencing resources of the Resource type, make sure the data type is the same as that of the attribute method. - * For example, if an attribute method supports the string | Resource types, the data type of the Resource type must be - * string. * @returns { Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 @@ -1961,10 +1884,6 @@ declare function $r(value: string, ...params: any[]): Resource; * global $rawfile function * * @param { string } value - * name of the file in the resources/rawfile directory of the project. - * When referencing resources of the Resource type, make sure the data type is the same as that of the attribute method. - * For example, if an attribute method supports the string | Resource types, the data type of the Resource type must be - * string. * @returns { Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -1974,10 +1893,6 @@ declare function $r(value: string, ...params: any[]): Resource; * global $rawfile function * * @param { string } value - * name of the file in the resources/rawfile directory of the project. - * When referencing resources of the Resource type, make sure the data type is the same as that of the attribute method. - * For example, if an attribute method supports the string | Resource types, the data type of the Resource type must be - * string. * @returns { Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -1988,10 +1903,6 @@ declare function $r(value: string, ...params: any[]): Resource; * global $rawfile function * * @param { string } value - * name of the file in the resources/rawfile directory of the project. - * When referencing resources of the Resource type, make sure the data type is the same as that of the attribute method. - * For example, if an attribute method supports the string | Resource types, the data type of the Resource type must be - * string. * @returns { Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -2011,24 +1922,24 @@ declare function $rawfile(value: string): Resource; */ declare enum AccessibilitySamePageMode { /** - * the first page and root page event is not send.but if application load new page whith navigation,the page event will be sent. - * this mode is to solve skipping focus - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * the first page and root page event is not send.but if application load new page whith navigation,the page event will be sent. + * this mode is to solve skipping focus + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SEMI_SILENT = 0, - /** - * the all page event is not send - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ - FULL_SILENT = 1, + /** + * the all page event is not send + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ + FULL_SILENT = 1 } /** * Enum for accessibility component type @@ -2041,1226 +1952,1143 @@ declare enum AccessibilitySamePageMode { */ declare enum AccessibilityRoleType { /** - * ActionSheet component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * ActionSheet component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ ACTION_SHEET = 0, /** - * AlertDialog component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * AlertDialog component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ ALERT_DIALOG = 1, /** - * AlphabetIndexer component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * AlphabetIndexer component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ INDEXER_COMPONENT = 2, /** - * badge component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * badge component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ BADGE_COMPONENT = 3, /** - * blank component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * blank component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ BLANK = 4, /** - * button component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * button component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ BUTTON = 5, /** - * button component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * button component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ BACK_BUTTON = 6, /** - * sheet drag bar component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * sheet drag bar component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SHEET_DRAG_BAR = 7, /** - * calendar picker component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * calendar picker component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CALENDAR_PICKER = 8, /** - * calendar component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * calendar component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CALENDAR = 9, /** - * canvas component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * canvas component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CANVAS = 10, /** - * canvas gradient component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * canvas gradient component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CANVAS_GRADIENT = 11, /** - * canvas pattern component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * canvas pattern component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CANVAS_PATTERN = 12, /** - * checkbox component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * checkbox component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CHECKBOX = 13, /** - * checkbox group component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * checkbox group component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CHECKBOX_GROUP = 14, /** - * circle component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * circle component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CIRCLE = 15, /** - * column split component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ - COLUMN_SPLIT = 16, - /** - * column component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * column split component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ + COLUMN_SPLIT = 16, + /** + * column component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ COLUMN = 17, /** - * canvas rendering context 2d component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * canvas rendering context 2d component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CANVAS_RENDERING_CONTEXT_2D = 18, /** - * chart component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * chart component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CHART = 19, /** - * counter component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice + * counter component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice * @since 18 - */ + */ COUNTER = 20, /** - * counter modal component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * counter modal component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ CONTAINER_MODAL = 21, /** - * data panel component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * data panel component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ DATA_PANEL = 22, /** - * data picker component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * data picker component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ DATE_PICKER = 23, /** - * dialog component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * dialog component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ DIALOG = 24, /** - * divider component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * divider component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ DIVIDER = 25, /** - * drag bar component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * drag bar component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ DRAG_BAR = 26, /** - * effect component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * effect component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ EFFECT_COMPONENT = 27, /** - * ellipse component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * ellipse component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ ELLIPSE = 28, /** - * flex component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * flex component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ FLEX = 29, /** - * flow item component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * flow item component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ FLOW_ITEM = 30, /** - * form component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * form component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ FORM_COMPONENT = 31, /** - * form link component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * form link component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ FORM_LINK = 32, /** - * gauge component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * gauge component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ GAUGE = 33, /** - * grid component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * grid component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ GRID = 34, /** - * grid col component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * grid col component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ GRID_COL = 35, /** - * grid container component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * grid container component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ GRID_CONTAINER = 36, /** - * grid item component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * grid item component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ GRID_ITEM = 37, /** - * grid row component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * grid row component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ GRID_ROW = 38, /** - * hyperlink component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ - HYPERLINK = 39, - /** - * image component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * hyperlink component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ + HYPERLINK = 39, + /** + * image component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ IMAGE = 40, /** - * image animator component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * image animator component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ IMAGE_ANIMATOR = 41, /** - * image bitmap component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * image bitmap component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ IMAGE_BITMAP = 42, /** - * image data component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * image data component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ IMAGE_DATA = 43, /** - * image span component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * image span component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ IMAGE_SPAN = 44, /** - * label component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * label component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ LABEL = 45, /** - * line component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * line component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ LINE = 46, /** - * list component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * list component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ LIST = 47, /** - * list item component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * list item component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ LIST_ITEM = 48, /** - * list item group component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * list item group component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ LIST_ITEM_GROUP = 49, /** - * loading progress component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * loading progress component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ LOADING_PROGRESS = 50, /** - * marquee component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * marquee component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ MARQUEE = 51, /** - * matrix2d component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * matrix2d component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ MATRIX2D = 52, /** - * menu component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * menu component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ MENU = 53, /** - * menu item component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * menu item component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ MENU_ITEM = 54, /** - * menu item group component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * menu item group component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ MENU_ITEM_GROUP = 55, /** - * navdestination component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * navdestination component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ NAV_DESTINATION = 56, /** - * navrouter component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * navrouter component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ NAV_ROUTER = 57, /** - * navigation component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * navigation component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ NAVIGATION = 58, /** - * navigation bar component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * navigation bar component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ NAVIGATION_BAR = 59, /** - * navigation menu component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * navigation menu component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ NAVIGATION_MENU = 60, /** - * navigator component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * navigator component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ NAVIGATOR = 61, /** - * offscreen canvas component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ - OFFSCREEN_CANVAS = 62, + * offscreen canvas component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ + OFFSCREEN_CANVAS = 62, /** - * offscreen canvas rendering context2d component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * offscreen canvas rendering context2d component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ OFFSCREEN_CANVAS_RENDERING_CONTEXT2D = 63, /** - * option component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * option component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ OPTION = 64, /** - * panel component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * panel component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PANEL = 65, /** - * paper page component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * paper page component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PAPER_PAGE = 66, /** - * path component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * path component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PATH = 67, /** - * path 2d component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * path 2d component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PATH2D = 68, /** - * pattern lock component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * pattern lock component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PATTERN_LOCK = 69, /** - * picker component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * picker component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PICKER = 70, /** - * picker view component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * picker view component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PICKER_VIEW = 71, /** - * plugin component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * plugin component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PLUGIN_COMPONENT = 72, /** - * polygon component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * polygon component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ POLYGON = 73, /** - * polyline component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * polyline component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ POLYLINE = 74, /** - * pop up component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * pop up component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ POPUP = 75, /** - * progress component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * progress component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ PROGRESS = 76, /** - * qr code component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * qr code component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ QRCODE = 77, /** - * radio component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * radio component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ RADIO = 78, /** - * rating component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * rating component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ RATING = 79, /** - * rect component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * rect component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ RECT = 80, /** - * refresh component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * refresh component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ REFRESH = 81, /** - * relative container component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * relative container component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ RELATIVE_CONTAINER = 82, /** - * remote window component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * remote window component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ REMOTE_WINDOW = 83, /** - * rich editor component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * rich editor component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ RICH_EDITOR = 84, /** - * rich text component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ - RICH_TEXT = 85, - /** - * rolepager component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * rich text component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ + RICH_TEXT = 85, + /** + * rolepager component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ ROLE_PAGER = 86, /** - * row component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * row component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ ROW = 87, /** - * row split component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * row split component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ ROW_SPLIT = 88, /** - * scroll component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * scroll component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SCROLL = 89, /** - * scroll bar component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * scroll bar component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SCROLL_BAR = 90, /** - * search component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * search component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SEARCH = 91, /** - * search field component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * search field component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SEARCH_FIELD = 92, /** - * select component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * select component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SELECT = 93, /** - * shape component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * shape component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SHAPE = 94, /** - * sidebar container component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * sidebar container component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SIDEBAR_CONTAINER = 95, /** - * slider component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * slider component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SLIDER = 96, /** - * span component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * span component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SPAN = 97, /** - * stack component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * stack component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ STACK = 98, /** - * stepper component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * stepper component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ STEPPER = 99, /** - * stepper item component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * stepper item component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ STEPPER_ITEM = 100, /** - * swiper component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * swiper component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SWIPER = 101, /** - * swiper indicator component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * swiper indicator component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SWIPER_INDICATOR = 102, /** - * switch component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * switch component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SWITCH = 103, /** - * symbol glyph component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * symbol glyph component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ SYMBOL_GLYPH = 104, /** - * tab content component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * tab content component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TAB_CONTENT = 105, /** - * tab bar component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * tab bar component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TAB_BAR = 106, /** - * tabs component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * tabs component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TABS = 107, /** - * text component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * text component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TEXT = 108, /** - * text clock component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * text clock component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TEXT_CLOCK = 109, /** - * text entry component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * text entry component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TEXT_ENTRY = 110, /** - * text input component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * text input component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TEXT_INPUT = 111, /** - * text picker component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * text picker component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TEXT_PICKER = 112, /** - * text timer component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * text timer component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TEXT_TIMER = 113, /** - * text area component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * text area component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TEXT_AREA = 114, /** - * text field component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * text field component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TEXT_FIELD = 115, /** - * time picker component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * time picker component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TIME_PICKER = 116, /** - * title bar component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * title bar component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TITLE_BAR = 117, /** - * toggler component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * toggler component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ TOGGLER = 118, /** - * uiextensioncomponent component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * uiextensioncomponent component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ UI_EXTENSION_COMPONENT = 119, /** - * video component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * video component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ VIDEO = 120, /** - * water flow component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * water flow component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ WATER_FLOW = 121, /** - * web component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * web component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ WEB = 122, /** - * xcomponent component type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ - XCOMPONENT = 123, - /** - * none component type: screen reader will not broadcast the component type. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ - ROLE_NONE = 124, -} - -/** - * Defines the callback type used in accessibility focus. The value of isFocus indicates whether the current component is focused - * @typedef {function} AccessibilityFocusCallback - * @param {boolean} isFocus - if component is focused,isFocus will be true. else isFocus is false. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ -declare type AccessibilityFocusCallback = (isFocus: boolean) => void; - -/** - * Enum for accessibility action type - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ -declare enum AccessibilityAction { - /** - * undefined action type - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - UNDEFINED_ACTION = 0, - /** - * accessibility click action - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - ACCESSIBILITY_CLICK = 1, -} - -/** - * Enum for the result of accessibility action intercept function - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ -declare enum AccessibilityActionInterceptResult { - /** - * intercept the accessibility action - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - ACTION_INTERCEPT = 0, - /** - * the accessibility action can be continued - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - ACTION_CONTINUE = 1, + * xcomponent component type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ + XCOMPONENT = 123, /** - * the accessibility action need to bubble up for execution - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - ACTION_RISE = 2, + * none component type: screen reader will not broadcast the component type. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ + ROLE_NONE = 124 } /** - * Defines the callback type used in accessibility action intercept. - * The value of action indicates the accessibility action type. - * @typedef { function } AccessibilityActionInterceptCallback - * @param { AccessibilityAction } action - the enum of accessibility action type. - * @returns { AccessibilityActionInterceptResult } the result of continuing to execute the action or interrupting it or bubbling up + * Defines the callback type used in accessibility focus. The value of isFocus indicates whether the current component is focused + * @typedef {function} AccessibilityFocusCallback + * @param {boolean} isFocus - if component is focused,isFocus will be true. else isFocus is false. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice - * @since 20 + * @since 18 */ -declare type AccessibilityActionInterceptCallback = (action: AccessibilityAction) => AccessibilityActionInterceptResult; +declare type AccessibilityFocusCallback = (isFocus: boolean) => void; /** * Enum for FinishCallbackType. @@ -3283,7 +3111,7 @@ declare type AccessibilityActionInterceptCallback = (action: AccessibilityAction */ declare enum FinishCallbackType { /** - * The callback is invoked when the entire animation is removed once it has finished. + * When the entire animation ends and will be removed immediately, the callback is triggered. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -3291,7 +3119,7 @@ declare enum FinishCallbackType { * @since 11 */ /** - * The callback is invoked when the entire animation is removed once it has finished. + * When the entire animation ends and will be removed immediately, the callback is triggered. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -3307,18 +3135,17 @@ declare enum FinishCallbackType { * @crossplatform * @form * @since 11 - */ - /** - * The callback is invoked when the animation logically enters the falling state, - * though it may still be in its long tail state. + */ + /** + * When the animation is logically down but may still be in its long tail, the callback is triggered. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ - LOGICALLY = 1, + */ + LOGICALLY = 1 } /** @@ -3342,62 +3169,60 @@ declare enum FinishCallbackType { */ declare enum TouchTestStrategy { /** - * Do framework touch test. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 11 - */ - /** - * Custom dispatch has no effect; the system distributes events based on the hit status of the current node. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ + * Do framework touch test. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 11 + */ + /** + * Do framework touch test. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 12 + */ DEFAULT = 0, /** - * Specify the component to do touch test and follow the framework touch test - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 11 - */ - /** - * The specified event is forwarded to a particular child node, and the system determines whether to - * distribute the event to other sibling nodes. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ + * Specify the component to do touch test and follow the framework touch test + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 11 + */ + /** + * Specify the component to do touch test and follow the framework touch test + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 12 + */ FORWARD_COMPETITION = 1, /** - * Specify the component to do touch test and not follow the framework touch test - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 11 - */ - /** - * The specified event is forwarded to a particular child node, and the system no longer distributes - * the event to other sibling nodes. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ + * Specify the component to do touch test and not follow the framework touch test + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 11 + */ + /** + * Specify the component to do touch test and not follow the framework touch test + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 12 + */ FORWARD = 2 } @@ -3478,7 +3303,6 @@ declare interface AnimateParam { /** * Animation playback speed. A larger value indicates faster animation playback, and a smaller value indicates slower * animation playback. The value 0 means that there is no animation. - *
Default value: **1.0**. * * @type { ?number } * @default 1.0 @@ -3488,7 +3312,6 @@ declare interface AnimateParam { /** * Animation playback speed. A larger value indicates faster animation playback, and a smaller value indicates slower * animation playback. The value 0 means that there is no animation. - *
Default value: **1.0**. * * @type { ?number } * @default 1.0 @@ -3549,7 +3372,7 @@ declare interface AnimateParam { curve?: Curve | string | ICurve; /** - * Animation delay time, in ms. By default, the animation has no delay. + * Animation plays with delay,when set to a negative number, the animation plays in advance. * * @type { ?number } * @default 0 @@ -3557,7 +3380,7 @@ declare interface AnimateParam { * @since 7 */ /** - * Animation delay time, in ms. By default, the animation has no delay. + * Animation delay time, in ms. * * @type { ?number } * @default 0 @@ -3566,7 +3389,7 @@ declare interface AnimateParam { * @since 10 */ /** - * Animation delay time, in ms. By default, the animation has no delay. + * Animation delay time, in ms. * * @type { ?number } * @default 0 @@ -3578,9 +3401,7 @@ declare interface AnimateParam { delay?: number; /** - * Number of times that the animation is played. By default, the animation is played once. - * The value **-1** indicates that the animation is played for an unlimited number of times. - * The value **0** indicates that there is no animation. + * Animation iterations. When set to -1, the animation playing it repeatedly. The value range is greater than or equal to -1. * * @type { ?number } * @default 1 @@ -3588,9 +3409,7 @@ declare interface AnimateParam { * @since 7 */ /** - * Number of times that the animation is played. By default, the animation is played once. - * The value **-1** indicates that the animation is played for an unlimited number of times. - * The value **0** indicates that there is no animation. + * Animation iterations. When set to -1, the animation playing it repeatedly. The value range is greater than or equal to -1. * * @type { ?number } * @default 1 @@ -3599,9 +3418,7 @@ declare interface AnimateParam { * @since 10 */ /** - * Number of times that the animation is played. By default, the animation is played once. - * The value **-1** indicates that the animation is played for an unlimited number of times. - * The value **0** indicates that there is no animation. + * Animation iterations. When set to -1, the animation playing it repeatedly. The value range is greater than or equal to -1. * * @type { ?number } * @default 1 @@ -3613,7 +3430,7 @@ declare interface AnimateParam { iterations?: number; /** - * Playback mode. By default, the animation is played from the beginning after the playback is complete. + * Animation playback mode. By default, the animation is played from the beginning after the playback is complete. * * @type { ?PlayMode } * @default PlayMode.Normal @@ -3621,7 +3438,7 @@ declare interface AnimateParam { * @since 7 */ /** - * Playback mode. By default, the animation is played from the beginning after the playback is complete. + * Animation playback mode. By default, the animation is played from the beginning after the playback is complete. * * @type { ?PlayMode } * @default PlayMode.Normal @@ -3630,7 +3447,7 @@ declare interface AnimateParam { * @since 9 */ /** - * Playback mode. By default, the animation is played from the beginning after the playback is complete. + * Animation playback mode. By default, the animation is played from the beginning after the playback is complete. * * @type { ?PlayMode } * @default PlayMode.Normal @@ -3640,7 +3457,7 @@ declare interface AnimateParam { * @since 10 */ /** - * Playback mode. By default, the animation is played from the beginning after the playback is complete. + * Animation playback mode. By default, the animation is played from the beginning after the playback is complete. * * @type { ?PlayMode } * @default PlayMode.Normal @@ -3653,14 +3470,14 @@ declare interface AnimateParam { playMode?: PlayMode; /** - * Callback invoked when the animation playback is complete. + * Callback invoked when the animation playback is complete or the ability is about to enter the background. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Callback invoked when the animation playback is complete. + * Callback invoked when the animation playback is complete or the ability is about to enter the background. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -3668,7 +3485,7 @@ declare interface AnimateParam { * @since 9 */ /** - * Callback invoked when the animation playback is complete. + * Callback invoked when the animation playback is complete or the ability is about to enter the background. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -3677,7 +3494,7 @@ declare interface AnimateParam { * @since 10 */ /** - * Callback invoked when the animation playback is complete. + * Callback invoked when the animation playback is complete or the ability is about to enter the background. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -3689,7 +3506,7 @@ declare interface AnimateParam { onFinish?: () => void; /** - * Type of the **onFinish** callback. + * Define the type of onFinish callback in animation. * * @type { ?FinishCallbackType } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -3698,8 +3515,7 @@ declare interface AnimateParam { * @since 11 */ /** - * Type of the **onFinish** callback. - * Default value: FinishCallbackType.REMOVED. + * Define the type of onFinish callback in animation. * * @type { ?FinishCallbackType } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -3711,14 +3527,14 @@ declare interface AnimateParam { finishCallbackType?: FinishCallbackType; /** - * Expected frame rate range of the animation. + * Indicates expectedFrameRateRange including minimum、maximum and expected frame rate. * * @type { ?ExpectedFrameRateRange } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 11 */ /** - * Expected frame rate range of the animation. + * Indicates expectedFrameRateRange including minimum、maximum and expected frame rate. * * @type { ?ExpectedFrameRateRange } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -3757,24 +3573,20 @@ declare interface AnimateParam { */ interface ICurve { /** - * Implements calculation. + * Get curve value by fraction. * - * @param { number } fraction - Current normalized time. Value range: [0, 1]. - *

**NOTE**: - *
A value less than 0 is handed as **0**. A value greater than 1 is handed as **1**. - *

+ * @param { number } fraction - Indicates the current normalized time parameter. Value range: [0, 1]. + * Note: If the value is less than 0, it will be processed as 0. If the value is greater than 1, 1 is used. * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Implements calculation. + * Get curve value by fraction. * - * @param { number } fraction - Current normalized time. Value range: [0, 1]. - *

**NOTE**: - *
A value less than 0 is handed as **0**. A value greater than 1 is handed as **1**. - *

+ * @param { number } fraction - Indicates the current normalized time parameter. Value range: [0, 1]. + * Note: If the value is less than 0, it will be processed as 0. If the value is greater than 1, 1 is used. * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -3782,12 +3594,10 @@ interface ICurve { * @since 10 */ /** - * Implements calculation. + * Get curve value by fraction. * - * @param { number } fraction - Current normalized time. Value range: [0, 1]. - *

**NOTE**: - *
A value less than 0 is handed as **0**. A value greater than 1 is handed as **1**. - *

+ * @param { number } fraction - Indicates the current normalized time parameter. Value range: [0, 1]. + * Note: If the value is less than 0, it will be processed as 0. If the value is greater than 1, 1 is used. * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -3795,8 +3605,9 @@ interface ICurve { * @atomicservice * @since 11 */ - interpolate(fraction: number): number; + interpolate(fraction : number) : number; } + /** * Defines the motion path options. * @@ -3823,22 +3634,14 @@ interface ICurve { */ declare interface MotionPathOptions { /** - * Motion path of the translation animation. - * The **svg** path string is used. - * In the value, **start** and **end** can be used in place of the start point and end point, - * for example, **'Mstart.x start.y L50 50 Lend.x end.y Z'**. - * If this parameter is set to an empty string, the path animation is not set. + * The path info. * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Motion path of the translation animation. - * The **svg** path string is used. - * In the value, **start** and **end** can be used in place of the start point and end point, - * for example, **'Mstart.x start.y L50 50 Lend.x end.y Z'**. - * If this parameter is set to an empty string, the path animation is not set. + * The path info. * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -3846,11 +3649,7 @@ declare interface MotionPathOptions { * @since 10 */ /** - * Motion path of the translation animation. - * The **svg** path string is used. - * In the value, **start** and **end** can be used in place of the start point and end point, - * for example, **'Mstart.x start.y L50 50 Lend.x end.y Z'**. - * If this parameter is set to an empty string, the path animation is not set. + * The path info. * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -3861,9 +3660,7 @@ declare interface MotionPathOptions { path: string; /** - * Start point of the motion path. - * Value range: [0, 1]. - * A value less than 0 or greater than 1 evaluates to the default value **0**. + * The origin point info in range [0,1). * * @type { ?number } * @default 0.0 @@ -3871,9 +3668,7 @@ declare interface MotionPathOptions { * @since 7 */ /** - * Start point of the motion path. - * Value range: [0, 1]. - * A value less than 0 or greater than 1 evaluates to the default value **0**. + * The origin point info in range [0,1). * * @type { ?number } * @default 0.0 @@ -3882,9 +3677,7 @@ declare interface MotionPathOptions { * @since 10 */ /** - * Start point of the motion path. - * Value range: [0, 1]. - * A value less than 0 or greater than 1 evaluates to the default value **0**. + * The origin point info in range [0,1). * * @type { ?number } * @default 0.0 @@ -3896,10 +3689,7 @@ declare interface MotionPathOptions { from?: number; /** - * End point of the motion path. - * Value range: [0, 1]. - * A value less than 0 or greater than 1 evaluates to the default value **1**, - * provided that the value of **to** is greater than or equal to the value of **from**. + * he distance point info in range (0,1]. * * @type { ?number } * @default 1.0 @@ -3907,10 +3697,7 @@ declare interface MotionPathOptions { * @since 7 */ /** - * End point of the motion path. - * Value range: [0, 1]. - * A value less than 0 or greater than 1 evaluates to the default value **1**, - * provided that the value of **to** is greater than or equal to the value of **from**. + * he distance point info in range (0,1]. * * @type { ?number } * @default 1.0 @@ -3919,10 +3706,7 @@ declare interface MotionPathOptions { * @since 10 */ /** - * End point of the motion path. - * Value range: [0, 1]. - * A value less than 0 or greater than 1 evaluates to the default value **1**, - * provided that the value of **to** is greater than or equal to the value of **from**. + * The distance point info in range (0,1]. * * @type { ?number } * @default 1.0 @@ -3934,7 +3718,7 @@ declare interface MotionPathOptions { to?: number; /** - * Whether to rotate along the path. + * The rotate info. * * @type { ?boolean } * @default false @@ -3942,7 +3726,7 @@ declare interface MotionPathOptions { * @since 7 */ /** - * Whether to rotate along the path. + * The rotate info. * * @type { ?boolean } * @default false @@ -3951,7 +3735,7 @@ declare interface MotionPathOptions { * @since 10 */ /** - * Whether to rotate along the path. + * The rotate info. * * @type { ?boolean } * @default false @@ -3997,10 +3781,7 @@ declare interface sharedTransitionOptions { * @since 7 */ /** - * Animation duration. - *
Default value: **1000**. - *
Unit: ms. - *
Value range: [0, +∞). + * Animation duration, in ms. * * @type { ?number } * @default 1000 @@ -4009,10 +3790,7 @@ declare interface sharedTransitionOptions { * @since 10 */ /** - * Animation duration. - *
Default value: **1000**. - *
Unit: ms. - *
Value range: [0, +∞). + * Animation duration, in ms. * * @type { ?number } * @default 1000 @@ -4024,7 +3802,7 @@ declare interface sharedTransitionOptions { duration?: number; /** - * Animation curve.
You are advised to specify the curve using the Curve or ICurve type. + * Animation duration, in ms. * * @type { ?(Curve | string | ICurve) } * @default 1000 @@ -4032,11 +3810,7 @@ declare interface sharedTransitionOptions { * @since 7 */ /** - * Animation curve.
You are advised to specify the curve using the **Curve** or - * ** ICurve** type.
For the string type, this parameter indicates an animation - * interpolation curve. For available values, see the **curve** parameter in - * AnimateParam. - *
Default value: **Curve.Linear**. + * Animation curve. * * @type { ?(Curve | string | ICurve) } * @default 1000 @@ -4045,11 +3819,7 @@ declare interface sharedTransitionOptions { * @since 10 */ /** - * Animation curve.
You are advised to specify the curve using the **Curve** or - * ** ICurve** type.
For the string type, this parameter indicates an animation - * interpolation curve. For available values, see the **curve** parameter in - * AnimateParam. - *
Default value: **Curve.Linear**. + * Animation curve. * * @type { ?(Curve | string | ICurve) } * @default 1000 @@ -4211,7 +3981,7 @@ declare interface GeometryTransitionOptions { follow?: boolean; /** * Defines movement strategy of source and target in the hierarchy during geometry transition. - * + * * @type { ?TransitionHierarchyStrategy } * @default TransitionHierarchyStrategy.ADAPTIVE * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -4221,14 +3991,14 @@ declare interface GeometryTransitionOptions { */ /** * Defines movement strategy of source and target in the hierarchy during geometry transition. - * + * * @type { ?TransitionHierarchyStrategy } * @default TransitionHierarchyStrategy.ADAPTIVE * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi * @since 13 */ - hierarchyStrategy?: TransitionHierarchyStrategy + hierarchyStrategy?: TransitionHierarchyStrategy; } /** @@ -4772,18 +4542,6 @@ declare interface SweepGradientOptions { * @since 18 */ colors: Array<[ResourceColor, number]>; - - /** - * Defines color description in ColorMetrics format for gradients. - * This parameter takes precedence over colors parameter. - * - * @type { ?Array<[ColorMetrics, number]> } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - metricsColors?: Array<[ColorMetrics, number]>; /** * repeating:repeating. The default value is false @@ -4842,6 +4600,18 @@ declare interface SweepGradientOptions { * @since 18 */ repeating?: boolean; + + /** + * Defines color description in ColorMetrics format for gradients. + * This parameter takes precedence over colors parameter. + * + * @type { ?Array<[ColorMetrics, number]> } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + metricsColors?: Array<[ColorMetrics, number]>; } /** @@ -5147,7 +4917,7 @@ declare enum TransitionHierarchyStrategy { * @systemapi * @since 13 */ - ADAPTIVE = 1, + ADAPTIVE = 1 } /** @@ -5186,18 +4956,14 @@ declare enum TransitionHierarchyStrategy { */ declare interface TranslateOptions { /** - * Translation distance along the x-axis. - * For the number type, the unit is VP, and the value range is (-∞, +∞). - * For the string type, the value follows the format of Length string type. + * The param of x direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Translation distance along the x-axis. - * For the number type, the unit is VP, and the value range is (-∞, +∞). - * For the string type, the value follows the format of Length string type. + * The param of x direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5205,9 +4971,7 @@ declare interface TranslateOptions { * @since 9 */ /** - * Translation distance along the x-axis. - * For the number type, the unit is VP, and the value range is (-∞, +∞). - * For the string type, the value follows the format of Length string type. + * The param of x direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5216,9 +4980,7 @@ declare interface TranslateOptions { * @since 10 */ /** - * Translation distance along the x-axis. - * For the number type, the unit is VP, and the value range is (-∞, +∞). - * For the string type, the value follows the format of length string type. + * The param of x direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5230,18 +4992,14 @@ declare interface TranslateOptions { x?: number | string; /** - * Translation distance along the y-axis. - * For the number type, the unit is VP, and the value range is (-∞, +∞). - * For the string type, the value follows the format of length string type. + * The param of y direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Translation distance along the y-axis. - * For the number type, the unit is VP, and the value range is (-∞, +∞). - * For the string type, the value follows the format of length string type. + * The param of y direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5249,9 +5007,7 @@ declare interface TranslateOptions { * @since 9 */ /** - * Translation distance along the y-axis. - * For the number type, the unit is VP, and the value range is (-∞, +∞). - * For the string type, the value follows the format of length string type. + * The param of y direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5260,9 +5016,7 @@ declare interface TranslateOptions { * @since 10 */ /** - * Translation distance along the y-axis. - * For the number type, the unit is VP, and the value range is (-∞, +∞). - * For the string type, the value follows the format of length string type. + * The param of y direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5274,16 +5028,14 @@ declare interface TranslateOptions { y?: number | string; /** - * Distance to translate along the z-axis. The value is a floating - * point number, the default value is 0.0, and the unit is px. + * The param of z direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Distance to translate along the z-axis. The value is a floating - * point number, the default value is 0.0, and the unit is px. + * The param of z direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5291,8 +5043,7 @@ declare interface TranslateOptions { * @since 9 */ /** - * Distance to translate along the z-axis. The value is a floating - * point number, the default value is 0.0, and the unit is px. + * The param of z direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5301,8 +5052,7 @@ declare interface TranslateOptions { * @since 10 */ /** - * Distance to translate along the z-axis. The value is a floating - * point number, the default value is 0.0, and the unit is px. + * The param of z direction. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5350,20 +5100,14 @@ declare interface TranslateOptions { */ declare interface ScaleOptions { /** - * Scale ratio along the x-axis. - * x > 1: The component is scaled up along the x-axis. - * 0 < x < 1: The component is scaled down along the x-axis. - * x < 0: The component is scaled in the reverse direction of the x-axis. + * The param of x direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Scale ratio along the x-axis. - * x > 1: The component is scaled up along the x-axis. - * 0 < x < 1: The component is scaled down along the x-axis. - * x < 0: The component is scaled in the reverse direction of the x-axis. + * The param of x direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5371,10 +5115,7 @@ declare interface ScaleOptions { * @since 9 */ /** - * Scale ratio along the x-axis. - * x > 1: The component is scaled up along the x-axis. - * 0 < x < 1: The component is scaled down along the x-axis. - * x < 0: The component is scaled in the reverse direction of the x-axis. + * The param of x direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5383,10 +5124,7 @@ declare interface ScaleOptions { * @since 10 */ /** - * Scale ratio along the x-axis. - * x > 1: The component is scaled up along the x-axis. - * 0 < x < 1: The component is scaled down along the x-axis. - * x < 0: The component is scaled in the reverse direction of the x-axis. + * The param of x direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5398,20 +5136,14 @@ declare interface ScaleOptions { x?: number; /** - * Scale ratio along the y-axis. - * y > 1: The component is scaled up along the y-axis. - * 0 < y < 1: The component is scaled down along the y-axis. - * y < 0: The component is scaled in the reverse direction of the y-axis. + * The param of y direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Scale ratio along the y-axis. - * y > 1: The component is scaled up along the y-axis. - * 0 < y < 1: The component is scaled down along the y-axis. - * y < 0: The component is scaled in the reverse direction of the y-axis. + * The param of y direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5419,10 +5151,7 @@ declare interface ScaleOptions { * @since 9 */ /** - * Scale ratio along the y-axis. - * y > 1: The component is scaled up along the y-axis. - * 0 < y < 1: The component is scaled down along the y-axis. - * y < 0: The component is scaled in the reverse direction of the y-axis. + * The param of y direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5431,10 +5160,7 @@ declare interface ScaleOptions { * @since 10 */ /** - * Scale ratio along the y-axis. - * y > 1: The component is scaled up along the y-axis. - * 0 < y < 1: The component is scaled down along the y-axis. - * y < 0: The component is scaled in the reverse direction of the y-axis. + * The param of y direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5446,18 +5172,14 @@ declare interface ScaleOptions { y?: number; /** - * Scale ratio along the z-axis. z > 1: The component is scaled up along the z-axis. - *
0 < z < 1: The component is scaled down along the z-axis. - *
z < 0: The component is scaled in the reverse direction of the z-axis. + * The param of z direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Scale ratio along the z-axis. z > 1: The component is scaled up along the z-axis. - *
0 < z < 1: The component is scaled down along the z-axis. - *
z < 0: The component is scaled in the reverse direction of the z-axis. + * The param of z direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5465,9 +5187,7 @@ declare interface ScaleOptions { * @since 9 */ /** - * Scale ratio along the z-axis. z > 1: The component is scaled up along the z-axis. - *
0 < z < 1: The component is scaled down along the z-axis. - *
z < 0: The component is scaled in the reverse direction of the z-axis. + * The param of z direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5476,9 +5196,7 @@ declare interface ScaleOptions { * @since 10 */ /** - * Scale ratio along the z-axis. z > 1: The component is scaled up along the z-axis. - *
0 < z < 1: The component is scaled down along the z-axis. - *
z < 0: The component is scaled in the reverse direction of the z-axis. + * The param of z direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5490,14 +5208,14 @@ declare interface ScaleOptions { z?: number; /** - * X coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of x. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * X coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of x. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5505,7 +5223,7 @@ declare interface ScaleOptions { * @since 9 */ /** - * X coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of x. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5514,7 +5232,7 @@ declare interface ScaleOptions { * @since 10 */ /** - * X coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of x. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5526,14 +5244,14 @@ declare interface ScaleOptions { centerX?: number | string; /** - * Y coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of y. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Y coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of y. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5541,7 +5259,7 @@ declare interface ScaleOptions { * @since 9 */ /** - * Y coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of y. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5550,7 +5268,7 @@ declare interface ScaleOptions { * @since 10 */ /** - * Y coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of y. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5607,9 +5325,7 @@ declare interface AlignRuleOption { * @since 10 */ /** - * Left alignment. - *
anchor: ID of the component that functions as the anchor point. - *
align: alignment mode relative to the anchor component. + * The param of left align. * * @type { ?object } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5638,9 +5354,7 @@ declare interface AlignRuleOption { * @since 10 */ /** - * Right alignment. - *
anchor: ID of the component that functions as the anchor point. - *
align: alignment mode relative to the anchor component. + * The param of right align. * * @type { ?object } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5669,9 +5383,7 @@ declare interface AlignRuleOption { * @since 10 */ /** - * Horizontal center alignment. - *
anchor: ID of the component that functions as the anchor point. - *
align: alignment mode relative to the anchor component. + * The param of middle align. * * @type { ?object } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5700,9 +5412,7 @@ declare interface AlignRuleOption { * @since 10 */ /** - * Top alignment. - *
anchor: ID of the component that functions as the anchor point. - *
align: alignment mode relative to the anchor component. + * The param of top align. * * @type { ?object } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5730,9 +5440,7 @@ declare interface AlignRuleOption { * @since 10 */ /** - * Bottom alignment. - *
anchor: ID of the component that functions as the anchor point. - *
align: alignment mode relative to the anchor component. + * The param of bottom align. * * @type { ?object } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5760,9 +5468,7 @@ declare interface AlignRuleOption { * @since 10 */ /** - * Vertical center alignment. - *
anchor: ID of the component that functions as the anchor point. - *
align: alignment mode relative to the anchor component. + * The param of center align. * * @type { ?object } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5784,8 +5490,7 @@ declare interface AlignRuleOption { * @since 11 */ /** - * Offset of the component under the anchor constraints. - *
The value is the ratio of the distance to the left/upper anchor to the total distance between anchors. + * Defines the bias ratio in horizontal and vertical direction. * * @type { ?Bias } * @default {horizontal:0.5,vertical:0.5} @@ -5809,7 +5514,7 @@ declare interface AlignRuleOption { */ declare interface LocalizedHorizontalAlignParam { /** - * ID of the component that serves as the anchor. + * The anchor of localized align param. * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5820,7 +5525,7 @@ declare interface LocalizedHorizontalAlignParam { anchor: string; /** - * Horizontal alignment mode relative to the anchor component. + * The align of localized align param. * * @type { HorizontalAlign } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5842,7 +5547,7 @@ declare interface LocalizedHorizontalAlignParam { */ declare interface LocalizedVerticalAlignParam { /** - * ID of the component that serves as the anchor. + * The anchor of localized align param. * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5853,7 +5558,7 @@ declare interface LocalizedVerticalAlignParam { anchor: string; /** - * Vertical alignment mode relative to the anchor component. + * The align of localized align param. * * @type { VerticalAlign } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5875,7 +5580,7 @@ declare interface LocalizedVerticalAlignParam { */ declare interface LocalizedAlignRuleOptions { /** - * Left alignment with left-to-right scripts and right alignment with right-to-left scripts in the horizontal direction. + * The param of start align. * * @type { ?LocalizedHorizontalAlignParam } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5886,7 +5591,7 @@ declare interface LocalizedAlignRuleOptions { start?: LocalizedHorizontalAlignParam; /** - * Right alignment with left-to-right scripts and left alignment with right-to-left scripts in the horizontal direction. + * The param of end align. * * @type { ?LocalizedHorizontalAlignParam } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5897,7 +5602,7 @@ declare interface LocalizedAlignRuleOptions { end?: LocalizedHorizontalAlignParam; /** - * Center alignment in the horizontal direction. + * The param of middle align. * * @type { ?LocalizedHorizontalAlignParam } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5908,7 +5613,7 @@ declare interface LocalizedAlignRuleOptions { middle?: LocalizedHorizontalAlignParam; /** - * Top alignment in the vertical direction. + * The param of top align. * * @type { ?LocalizedVerticalAlignParam } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5919,7 +5624,7 @@ declare interface LocalizedAlignRuleOptions { top?: LocalizedVerticalAlignParam; /** - * Bottom alignment in the vertical direction. + * The param of bottom align. * * @type { ?LocalizedVerticalAlignParam } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5930,7 +5635,7 @@ declare interface LocalizedAlignRuleOptions { bottom?: LocalizedVerticalAlignParam; /** - * Center alignment in the vertical direction. + * The param of center align. * * @type { ?LocalizedVerticalAlignParam } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5941,8 +5646,7 @@ declare interface LocalizedAlignRuleOptions { center?: LocalizedVerticalAlignParam; /** - * Offset of the component under the anchor constraints. - *
The value is the ratio of the distance to the left/upper anchor to the total distance between anchors. + * Defines the bias ratio in horizontal and vertical direction. * * @type { ?Bias } * @default {horizontal:0.5,vertical:0.5} @@ -5955,7 +5659,7 @@ declare interface LocalizedAlignRuleOptions { } /** - * Enumerates the chain styles in relative container. + * Defines the style of the chain in relative container. * * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -5965,34 +5669,34 @@ declare interface LocalizedAlignRuleOptions { */ declare enum ChainStyle { /** - * Child components are evenly distributed among constraint anchors. + * Elements of the chain will be spread out. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - SPREAD, + SPREAD = 0, /** - * All child components except the first and last ones are evenly distributed among constraint anchors. + * Elements except chain's head and tail will be spread out. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - SPREAD_INSIDE, + SPREAD_INSIDE = 1, /** - * There is no gap between child components in the chain. + * Elements of the chain will be packed together. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - PACKED, + PACKED = 2 } /** @@ -6031,14 +5735,14 @@ declare enum ChainStyle { */ declare interface RotateOptions { /** - * X coordinate of the rotation axis vector. + * The param of x direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * X coordinate of the rotation axis vector. + * The param of x direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6046,7 +5750,7 @@ declare interface RotateOptions { * @since 9 */ /** - * X coordinate of the rotation axis vector. + * The param of x direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6055,7 +5759,7 @@ declare interface RotateOptions { * @since 10 */ /** - * X coordinate of the rotation axis vector. + * The param of x direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6067,14 +5771,14 @@ declare interface RotateOptions { x?: number; /** - * Y coordinate of the rotation axis vector. + * The param of y direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Y coordinate of the rotation axis vector. + * The param of y direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6082,7 +5786,7 @@ declare interface RotateOptions { * @since 9 */ /** - * Y coordinate of the rotation axis vector. + * The param of y direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6091,7 +5795,7 @@ declare interface RotateOptions { * @since 10 */ /** - * Y coordinate of the rotation axis vector. + * The param of y direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6103,14 +5807,14 @@ declare interface RotateOptions { y?: number; /** - * Z coordinate of the rotation axis vector. + * The param of z direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Z coordinate of the rotation axis vector. + * The param of z direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6118,7 +5822,7 @@ declare interface RotateOptions { * @since 9 */ /** - * Z coordinate of the rotation axis vector. + * The param of z direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6127,7 +5831,7 @@ declare interface RotateOptions { * @since 10 */ /** - * Z coordinate of the rotation axis vector. + * The param of z direction. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6139,14 +5843,14 @@ declare interface RotateOptions { z?: number; /** - * X coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of x. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * X coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of x. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6154,7 +5858,7 @@ declare interface RotateOptions { * @since 9 */ /** - * X coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of x. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6163,7 +5867,7 @@ declare interface RotateOptions { * @since 10 */ /** - * X coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of x. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6175,21 +5879,21 @@ declare interface RotateOptions { centerX?: number | string; /** - * Y coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of y. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Y coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of y. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 9 */ /** - * Y coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of y. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6198,7 +5902,7 @@ declare interface RotateOptions { * @since 10 */ /** - * Y coordinate of the transformation center point (anchor). Unit is vp. + * The param of center point of y. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6210,7 +5914,7 @@ declare interface RotateOptions { centerY?: number | string; /** - * Z-axis anchor, that is, the z-component of the 3D rotation center point. + * The param of center point of z. * * @type { ?number } * @default 0 @@ -6220,7 +5924,7 @@ declare interface RotateOptions { * @since 10 */ /** - * Z-axis anchor, that is, the z-component of the 3D rotation center point. + * The param of center point of z. * * @type { ?number } * @default 0 @@ -6233,10 +5937,7 @@ declare interface RotateOptions { centerZ?: number; /** - * Distance from the user to the z=0 plane. - * The axis and center of rotation are set based on the coordinate system, - * which remains where it is when the component is moved. - * + * The param of camera distance, value range (-∞, ∞). * @type { ?number } * @default 0 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6245,10 +5946,7 @@ declare interface RotateOptions { * @since 10 */ /** - * Distance from the user to the z=0 plane. - * The axis and center of rotation are set based on the coordinate system, - * which remains where it is when the component is moved. - * + * The param of camera distance, value range (-∞, ∞). * @type { ?number } * @default 0 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6297,7 +5995,7 @@ declare interface RotateOptions { } /** - * The param of rotate about angle. + * The rotation parameters containing multi-axis angle information. * * @interface RotateAngleOptions * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6319,7 +6017,7 @@ declare interface RotateAngleOptions { * @since 20 */ angleX?: number | string; - + /** * the angle of the y-axis direction. * @@ -6332,7 +6030,7 @@ declare interface RotateAngleOptions { * @since 20 */ angleY?: number | string; - + /** * the angle of the z-axis direction. * @@ -6345,7 +6043,7 @@ declare interface RotateAngleOptions { * @since 20 */ angleZ?: number | string; - + /** * The param of center point of x. * @@ -6358,7 +6056,7 @@ declare interface RotateAngleOptions { * @since 20 */ centerX?: number | string; - + /** * The param of center point of y. * @@ -6371,7 +6069,7 @@ declare interface RotateAngleOptions { * @since 20 */ centerY?: number | string; - + /** * The param of center point of z. * @@ -6384,7 +6082,7 @@ declare interface RotateAngleOptions { * @since 20 */ centerZ?: number; - + /** * The param of camera distance, value range (-∞, ∞). * @type { ?number } @@ -6409,10 +6107,7 @@ declare interface RotateAngleOptions { */ declare interface TransitionOptions { /** - * Transition type.
- * Default value: **TransitionType.All**. - *
**NOTE**
If **type** is not specified, the default value **TransitionType.All** - * is used, which means that the transition effect works for both component addition and deletion. + * Defines the param of type. * * @type { ?TransitionType } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6421,11 +6116,7 @@ declare interface TransitionOptions { */ type?: TransitionType; /** - * Opacity of the component during transition, which is the value of the - * start point of insertion and the end point of deletion. - *
Value range: [0, 1]. - *
**NOTE**
If the value specified is less than 0, the value **0** is used. - * If the value specified is greater than 1, the value **1** is used. + * Defines the param of opacity. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6434,11 +6125,7 @@ declare interface TransitionOptions { */ opacity?: number; /** - * Translation of the component during transition, - * which is the value of the start point of insertion and the end point of deletion. - * **x**: distance to translate along the x-axis. - * **y**: distance to translate along the y-axis. - * **z**: distance to translate along the z-axis. + * Defines the param of translate. * * @type { ?TranslateOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6447,15 +6134,7 @@ declare interface TransitionOptions { */ translate?: TranslateOptions; /** - * Scaling of the component during transition, which is the value of the start point of insertion and the end point - * of deletion. **x**: scale factor along the x-axis. **y**: scale factor along the y-axis. **z**: scale factor along - * the z-axis (not effective for the current 2D graphics). **centerX** and **centerY**: scale center point. The - * default values are both **"50%"**, indicating the center point of the page. If the center point is (0, 0), it - * refers to the upper left corner of the component. - *

**NOTE**: - *
If **centerX** or **centerY** is set to an invalid string (for example, **"illegalString"**), - * the default value **"0"** is used. - *

+ * Defines the param of scale. * * @type { ?ScaleOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6464,11 +6143,7 @@ declare interface TransitionOptions { */ scale?: ScaleOptions; /** - * Rotation of the component during transition, which is the value of the start point of insertion and the end point - * of deletion. **x**: X-component of the rotation vector. **y**: Y-component of the rotation vector. **z**: - * Z-component of the rotation vector. **centerX** and **centerY**: rotation center point. The default values are - * both **"50%"**, indicating the center point of the page.If the center point is (0, 0), it refers to the upper left - * corner of the component. + * Defines the param of rotate. * * @type { ?RotateOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -6515,10 +6190,10 @@ declare enum TransitionEdge { * @atomicservice * @since 11 */ - TOP, + TOP = 0, /** - * Bottom edge of the window. + * Bottom edge * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6526,7 +6201,7 @@ declare enum TransitionEdge { * @since 10 */ /** - * Bottom edge of the window. + * Bottom edge * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6534,11 +6209,10 @@ declare enum TransitionEdge { * @atomicservice * @since 11 */ - BOTTOM, + BOTTOM = 1, /** - * Start edge of the window, which is the left edge for left-to-right - * scripts and the right edge for right-to-left scripts. + * Start edge * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6546,8 +6220,7 @@ declare enum TransitionEdge { * @since 10 */ /** - * Start edge of the window, which is the left edge for left-to-right - * scripts and the right edge for right-to-left scripts. + * Start edge * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6555,11 +6228,10 @@ declare enum TransitionEdge { * @atomicservice * @since 11 */ - START, + START = 2, /** - * End edge of the window, which is the right edge for left-to-right scripts - * and the left edge for right-to-left scripts. + * End edge * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6567,8 +6239,7 @@ declare enum TransitionEdge { * @since 10 */ /** - * End edge of the window, which is the right edge for left-to-right scripts - * and the left edge for right-to-left scripts. + * End edge * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6576,7 +6247,7 @@ declare enum TransitionEdge { * @atomicservice * @since 11 */ - END + END = 3 } /** @@ -6614,8 +6285,7 @@ declare type TransitionEffects = { /** * Defined the draw modifier of node. Provides draw callbacks for the associated Node. - * Each DrawModifier instance can be set for only one component. Repeated setting is not allowed. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -6632,6 +6302,7 @@ declare class DrawModifier { * @since 12 */ drawBehind?(drawContext: DrawContext): void; + /** * drawContent Method. Executed when associated Node is drawing, the default drawContent method will be replaced * if this method is set. @@ -6643,6 +6314,7 @@ declare class DrawModifier { * @since 12 */ drawContent?(drawContext: DrawContext): void; + /** * drawFront Method. Executed after drawing associated Node. * @@ -6653,7 +6325,6 @@ declare class DrawModifier { * @since 12 */ drawFront?(drawContext: DrawContext): void; - /** * drawforeground Method. Executed after drawing associated Node and its children. * @param { DrawContext } drawContext - The drawContext used to draw @@ -6663,10 +6334,9 @@ declare class DrawModifier { * @since 20 */ drawForeground?(drawContext: DrawContext): void; - + /** * Invalidate the component, which will cause a re-render of the component. - * No overloading is allowed or needed. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6723,8 +6393,7 @@ declare class TransitionEffect< static readonly IDENTITY: TransitionEffect<"identity">; /** - * Applies a transition effect with the opacity changing from 0 to 1 when the component appears - * And from 1 to 0 when the component disappears. This is equivalent to **TransitionEffect.opacity(0)** + * Specifies a transition effect with transparency of 0, which is equivalent to TransitionEffect.opacity(0). * * @type { TransitionEffect<"opacity"> } * @readonly @@ -6735,8 +6404,7 @@ declare class TransitionEffect< * @since 10 */ /** - * Applies a transition effect with the opacity changing from 0 to 1 when the component appears - * And from 1 to 0 when the component disappears. This is equivalent to **TransitionEffect.opacity(0)** + * Specifies a transition effect with transparency of 0, which is equivalent to TransitionEffect.opacity(0). * * @type { TransitionEffect<"opacity"> } * @readonly @@ -6750,13 +6418,7 @@ declare class TransitionEffect< static readonly OPACITY: TransitionEffect<"opacity">; /** - * Applies a transition effect of sliding in from the start edge when the component - * appears and sliding out from the end edge when the component disappears. - * This means sliding in from the left edge and sliding out from the right edge for - * left-to-right scripts, and sliding in from the right edge and sliding out from - * the left edge for right-to-left scripts. This is equivalent to - * TransitionEffect.asymmetric(TransitionEffect.move(TransitionEdge.START), - * TransitionEffect.move(TransitionEdge.END)). + * Defines a slide transition effect * * @type { TransitionEffect< * "asymmetric", @@ -6771,13 +6433,7 @@ declare class TransitionEffect< * @since 10 */ /** - * Applies a transition effect of sliding in from the start edge when the component - * appears and sliding out from the end edge when the component disappears. - * This means sliding in from the left edge and sliding out from the right edge for - * left-to-right scripts, and sliding in from the right edge and sliding out from - * the left edge for right-to-left scripts. This is equivalent to - * TransitionEffect.asymmetric(TransitionEffect.move(TransitionEdge.START), - * TransitionEffect.move(TransitionEdge.END)). + * Defines a slide transition effect * * @type { TransitionEffect< * "asymmetric", @@ -6801,13 +6457,11 @@ declare class TransitionEffect< >; /** - * Applies a transition effect of sliding in from the right with first scaling down and then scaling up - * when the component appears and sliding out from the right - * with first scaling down and then scaling up when the component disappears. - * This transition effect comes with its own animation parameters, which can also be overridden. - * The default animation duration is 600 milliseconds, - * with a specified animation curve of cubicBezierCurve(0.24, 0.0, 0.50, 1.0) and a minimum scale factor of 0.8. - * + * Specify a transition effect where the element enters by shrinking first and then expanding as it slides in from the right, + * and exits by shrinking first and then expanding as it slides out to the left, with a minimum scale ratio of 0.8. + * It comes with default animation parameters, which can also be overridden. + * The default animation duration is set to 600ms, and the specified animation curve is cubicBezierCurve(0.24, 0.0, 0.50, 1.0). + * * @type { TransitionEffect<"slideSwitch"> } * @readonly * @static @@ -6817,13 +6471,11 @@ declare class TransitionEffect< * @since 10 */ /** - * Applies a transition effect of sliding in from the right with first scaling down and then scaling up - * when the component appears and sliding out from the right - * with first scaling down and then scaling up when the component disappears. - * This transition effect comes with its own animation parameters, which can also be overridden. - * The default animation duration is 600 milliseconds, - * with a specified animation curve of cubicBezierCurve(0.24, 0.0, 0.50, 1.0) and a minimum scale factor of 0.8. - * + * Specify a transition effect where the element enters by shrinking first and then expanding as it slides in from the right, + * and exits by shrinking first and then expanding as it slides out to the left, with a minimum scale ratio of 0.8. + * It comes with default animation parameters, which can also be overridden. + * The default animation duration is set to 600ms, and the specified animation curve is cubicBezierCurve(0.24, 0.0, 0.50, 1.0). + * * @type { TransitionEffect<"slideSwitch"> } * @readonly * @static @@ -6836,13 +6488,9 @@ declare class TransitionEffect< static readonly SLIDE_SWITCH: TransitionEffect<"slideSwitch">; /** - * Translation of the component during transition, which is the value of the start point - * of insertion and the end point of deletion. + * Creates a translate transition effect * - * @param { TranslateOptions } options - translate options. - *
-**x**: distance to translate along the x-axis. Unit is vp. - *
-**y**: distance to translate along the y-axis. Unit is vp. - *
-**z**: distance to translate along the z-axis. Unit is vp. + * @param { TranslateOptions } options - translate options * @returns { TransitionEffect<"translate"> } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6850,13 +6498,9 @@ declare class TransitionEffect< * @since 10 */ /** - * Translation of the component during transition, which is the value of the start point - * of insertion and the end point of deletion. + * Creates a translate transition effect * - * @param { TranslateOptions } options - translate options. - *
-**x**: distance to translate along the x-axis. Unit is vp. - *
-**y**: distance to translate along the y-axis. Unit is vp. - *
-**z**: distance to translate along the z-axis. Unit is vp. + * @param { TranslateOptions } options - translate options * @returns { TransitionEffect<"translate"> } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6867,20 +6511,19 @@ declare class TransitionEffect< static translate(options: TranslateOptions): TransitionEffect<"translate">; /** - * Rotation of the component during transition, which is the value of the start - * point of insertion and the end point of deletion. - *
- **x**: X-component of the rotation vector. - *
- **y**: Y-component of the rotation vector. - *
- **z**: Z-component of the rotation vector. - *
- **centerX** and **centerY**: rotation center point. The default values - * are both **"50%"**, indicating the center point of the page. - *
- If the center point is (0, 0), it refers to the upper left corner of the component. - *
- **centerZ**: z-axis anchor point, that is, the z-component of the 3D rotation - * center point. The default value is **0**. - *
- **perspective**: viewing distance. It is not supported for use in transition animations. - *
**Widget capability**: This API can be used in ArkTS widgets since API version 10. - * - * @param { RotateOptions } options - Rotate options. + * Creates a rotation transition effect + * + * @param { RotateOptions } options - rotate options + * Set the rotation effect for component transitions when inserting and deleting. + * The value represents the starting rotation point for the inserting animation and the ending rotation point for the deleting animation. + * -x: Horizontal component of the rotational vector. + * -y: Vertical component of the rotational vector. + * -z: Vertical component of the rotational vector. + * -centerX, centerY specify the rotation center point, with default values of "50%", + * meaning that the default rotation center point is the center point of the component. + * -The center point of (0, 0) represents the upper-left corner of the component. + * -centerZ refers to the Z-axis anchor point. The default value of centerZ is 0. + * -perspective indicates the visual distance. The perspective property does not support transition animation. * @returns { TransitionEffect<"rotate"> } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6888,20 +6531,19 @@ declare class TransitionEffect< * @since 10 */ /** - * Rotation of the component during transition, which is the value of the start - * point of insertion and the end point of deletion. - *
- **x**: X-component of the rotation vector. - *
- **y**: Y-component of the rotation vector. - *
- **z**: Z-component of the rotation vector. - *
- **centerX** and **centerY**: rotation center point. The default values - * are both **"50%"**, indicating the center point of the page. - *
- If the center point is (0, 0), it refers to the upper left corner of the component. - *
- **centerZ**: z-axis anchor point, that is, the z-component of the 3D rotation - * center point. The default value is **0**. - *
- **perspective**: viewing distance. It is not supported for use in transition animations. - *
**Widget capability**: This API can be used in ArkTS widgets since API version 10. + * Creates a rotation transition effect * - * @param { RotateOptions } options - Rotate options. + * @param { RotateOptions } options - rotate options + * Set the rotation effect for component transitions when inserting and deleting. + * The value represents the starting rotation point for the inserting animation and the ending rotation point for the deleting animation. + * -x: Horizontal component of the rotational vector. + * -y: Vertical component of the rotational vector. + * -z: Vertical component of the rotational vector. + * -centerX, centerY specify the rotation center point, with default values of "50%", + * meaning that the default rotation center point is the center point of the component. + * -The center point of (0, 0) represents the upper-left corner of the component. + * -centerZ refers to the Z-axis anchor point. The default value of centerZ is 0. + * -perspective indicates the visual distance. The perspective property does not support transition animation. * @returns { TransitionEffect<"rotate"> } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -6912,8 +6554,7 @@ declare class TransitionEffect< static rotate(options: RotateOptions): TransitionEffect<"rotate">; /** - * Scaling of the component during transition, which is the value of the start point of insertion and - * the end point of deletion. + * Creates a scale transition effect * * @param { ScaleOptions } options - scale options * @returns { TransitionEffect<"scale"> } @@ -6923,8 +6564,7 @@ declare class TransitionEffect< * @since 10 */ /** - * Scaling of the component during transition, which is the value of the start point of insertion and - * the end point of deletion. + * Creates a scale transition effect * * @param { ScaleOptions } options - scale options * @returns { TransitionEffect<"scale"> } @@ -6972,9 +6612,7 @@ declare class TransitionEffect< static opacity(alpha: number): TransitionEffect<"opacity">; /** - * Slide-in and slide-out of the component from the screen edge during transition. - * It is essentially a translation effect, which is the value of the start point of insertion - * and the end point of deletion. + * Creates a move transition effect * * @param { TransitionEdge } edge - the edge that component will move to * @returns { TransitionEffect<"move"> } @@ -6984,9 +6622,7 @@ declare class TransitionEffect< * @since 10 */ /** - * Slide-in and slide-out of the component from the screen edge during transition. - * It is essentially a translation effect, which is the value of the start point of insertion - * and the end point of deletion. + * Creates a move transition effect * * @param { TransitionEdge } edge - the edge that component will move to * @returns { TransitionEffect<"move"> } @@ -7073,7 +6709,7 @@ declare class TransitionEffect< animation(value: AnimateParam): TransitionEffect; /** - * Combination of transition effects. + * Combines another transition effect * * @param { TransitionEffect } transitionEffect - transition effect which is be combined * @returns { TransitionEffect } combined transition effect @@ -7083,7 +6719,7 @@ declare class TransitionEffect< * @since 10 */ /** - * Combination of transition effects. + * Combines another transition effect * * @param { TransitionEffect } transitionEffect - transition effect which is be combined * @returns { TransitionEffect } combined transition effect @@ -7095,6 +6731,7 @@ declare class TransitionEffect< */ combine(transitionEffect: TransitionEffect): TransitionEffect; } + /** * Define Preview property * @@ -7392,7 +7029,7 @@ declare enum EffectType { * @atomicservice * @since 14 */ - WINDOW_EFFECT = 1, + WINDOW_EFFECT = 1 } /** @@ -7474,7 +7111,7 @@ declare enum PreDragStatus { * @atomicservice * @since 18 */ - PREPARING_FOR_DRAG_DETECTION = 7, + PREPARING_FOR_DRAG_DETECTION = 7 } /** @@ -7624,9 +7261,7 @@ declare interface DragItemInfo { declare function animateTo(value: AnimateParam, event: () => void): void; /** - * Implements immediate delivery of an explicit animation through a **UIContext** object. - * When multiple property animations are loaded at once, you can call this API to immediately - * execute the transition animation for state changes caused by the specified closure function. + * Define animation functions for immediate distribution. * * @param { AnimateParam } value - Set animation effect parameters. * @param { function } event - Specify the closure function that displays dynamic effects, @@ -7639,38 +7274,26 @@ declare function animateToImmediately(value: AnimateParam, event: () => void): v /** * Converts a value in vp units to a value in px. - * By default, the virtual pixel ratio of the screen where the current UI instance is located is used for conversion. - * If no UI instance is available, the virtual pixel ratio of the default screen is used instead. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** * Converts a value in vp units to a value in px. - * By default, the virtual pixel ratio of the screen where the current UI instance is located is used for conversion. - * If no UI instance is available, the virtual pixel ratio of the default screen is used instead. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** * Converts a value in vp units to a value in px. - * By default, the virtual pixel ratio of the screen where the current UI instance is located is used for conversion. - * If no UI instance is available, the virtual pixel ratio of the default screen is used instead. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7678,13 +7301,9 @@ declare function animateToImmediately(value: AnimateParam, event: () => void): v */ /** * Converts a value in vp units to a value in px. - * By default, the virtual pixel ratio of the screen where the current UI instance is located is used for conversion. - * If no UI instance is available, the virtual pixel ratio of the default screen is used instead. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7697,38 +7316,26 @@ declare function vp2px(value: number): number; /** * Converts a number in units of px to a number in units of vp. - * By default, the virtual pixel ratio of the screen where the current UI instance is located is used for conversion. - * If no UI instance is available, the virtual pixel ratio of the default screen is used instead. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** * Converts a number in units of px to a number in units of vp. - * By default, the virtual pixel ratio of the screen where the current UI instance is located is used for conversion. - * If no UI instance is available, the virtual pixel ratio of the default screen is used instead. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** * Converts a number in units of px to a number in units of vp. - * By default, the virtual pixel ratio of the screen where the current UI instance is located is used for conversion. - * If no UI instance is available, the virtual pixel ratio of the default screen is used instead. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7736,13 +7343,9 @@ declare function vp2px(value: number): number; */ /** * Converts a number in units of px to a number in units of vp. - * By default, the virtual pixel ratio of the screen where the current UI instance is located is used for conversion. - * If no UI instance is available, the virtual pixel ratio of the default screen is used instead. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7757,9 +7360,7 @@ declare function px2vp(value: number): number; * Converts a number in fp units to a number in px. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ @@ -7767,9 +7368,7 @@ declare function px2vp(value: number): number; * Converts a number in fp units to a number in px. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 @@ -7778,9 +7377,7 @@ declare function px2vp(value: number): number; * Converts a number in fp units to a number in px. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7790,9 +7387,7 @@ declare function px2vp(value: number): number; * Converts a number in fp units to a number in px. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7807,9 +7402,7 @@ declare function fp2px(value: number): number; * Converts a number in units of px to a number in units of fp. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ @@ -7817,9 +7410,7 @@ declare function fp2px(value: number): number; * Converts a number in units of px to a number in units of fp. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 @@ -7828,9 +7419,7 @@ declare function fp2px(value: number): number; * Converts a number in units of px to a number in units of fp. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7840,9 +7429,7 @@ declare function fp2px(value: number): number; * Converts a number in units of px to a number in units of fp. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7857,9 +7444,7 @@ declare function px2fp(value: number): number; * Converts a number in units of lpx to a number in units of px. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ @@ -7867,9 +7452,7 @@ declare function px2fp(value: number): number; * Converts a number in units of lpx to a number in units of px. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 @@ -7878,9 +7461,7 @@ declare function px2fp(value: number): number; * Converts a number in units of lpx to a number in units of px. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7890,9 +7471,7 @@ declare function px2fp(value: number): number; * Converts a number in units of lpx to a number in units of px. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7907,9 +7486,7 @@ declare function lpx2px(value: number): number; * Converts a number in units of px to a number in units of lpx. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ @@ -7917,9 +7494,7 @@ declare function lpx2px(value: number): number; * Converts a number in units of px to a number in units of lpx. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 @@ -7928,9 +7503,7 @@ declare function lpx2px(value: number): number; * Converts a number in units of px to a number in units of lpx. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -7940,9 +7513,7 @@ declare function lpx2px(value: number): number; * Converts a number in units of px to a number in units of lpx. * * @param { number } value - * Value range of value: (-∞, +∞). * @returns { number } - * Value range of the return value: (-∞, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -8019,6 +7590,7 @@ declare namespace focusControl { * @since 12 */ declare type PointerStyle = import('../api/@ohos.multimodalInput.pointer').default.PointerStyle; + /** * CursorControl * @@ -8047,7 +7619,7 @@ declare namespace cursorControl { /** * Change the mouse cursor style by param: 'PointerStyle'. * - * @param { PointerStyle } value - Cursor style. + * @param { PointerStyle } value * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -8133,7 +7705,7 @@ declare interface EventTarget { * @since 10 */ /** - * Area information of the target element. + * Area of current target. * * @type { Area } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -8354,7 +7926,7 @@ declare enum SourceTool { * @atomicservice * @since 12 */ - MOUSE, + MOUSE = 3, /** * The touchpad type. @@ -8364,7 +7936,7 @@ declare enum SourceTool { * @atomicservice * @since 12 */ - TOUCHPAD, + TOUCHPAD = 4, /** * The joystick type. @@ -8374,7 +7946,7 @@ declare enum SourceTool { * @atomicservice * @since 12 */ - JOYSTICK, + JOYSTICK = 5 } /** @@ -8473,7 +8045,7 @@ declare enum RepeatMode { * @since 10 */ /** - * The source image's slices are tiled to fill the border box. Tiles may be compressed when needed. + * Round mode. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8498,7 +8070,7 @@ declare enum RepeatMode { * @form * @since 10 */ - /** + /** * The source image's slices are tiled to fill the border box. Extra space will be distributed in between tiles. * * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -8617,14 +8189,14 @@ declare enum BlurStyle { Thick, /** - * Material that creates the minimum depth of field effect. + * Defines the thin background material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Material that creates the minimum depth of field effect. + * Defines the thin background material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8632,17 +8204,17 @@ declare enum BlurStyle { * @atomicservice * @since 11 */ - BACKGROUND_THIN, + BACKGROUND_THIN = 3, /** - * Material that creates a medium shallow depth of field effect. + * Defines the thin regular material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Material that creates a medium shallow depth of field effect. + * Defines the thin regular material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8650,17 +8222,17 @@ declare enum BlurStyle { * @atomicservice * @since 11 */ - BACKGROUND_REGULAR, + BACKGROUND_REGULAR = 4, /** - * Material that creates a high shallow depth of field effect. + * Defines the thin thick material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Material that creates a high shallow depth of field effect. + * Defines the thin thick material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8668,17 +8240,17 @@ declare enum BlurStyle { * @atomicservice * @since 11 */ - BACKGROUND_THICK, + BACKGROUND_THICK = 5, /** - * Material that creates the maximum depth of field effect. + * Defines the thin ultra thick material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Material that creates the maximum depth of field effect. + * Defines the thin ultra thick material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8686,10 +8258,10 @@ declare enum BlurStyle { * @atomicservice * @since 11 */ - BACKGROUND_ULTRA_THICK, + BACKGROUND_ULTRA_THICK = 6, /** - * No blur. + * Defines none material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8697,7 +8269,7 @@ declare enum BlurStyle { * @since 10 */ /** - * No blur. + * Defines none material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8705,10 +8277,10 @@ declare enum BlurStyle { * @atomicservice * @since 11 */ - NONE, + NONE = 7, /** - * Component ultra-thin material. + * Defines the ultra thin component material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8716,7 +8288,7 @@ declare enum BlurStyle { * @since 11 */ /** - * Component ultra-thin material. + * Defines the ultra thin component material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8735,7 +8307,7 @@ declare enum BlurStyle { * @since 11 */ /** - * Component thin material. + * Defines the thin component material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8754,7 +8326,7 @@ declare enum BlurStyle { * @since 11 */ /** - * Component regular material. + * Defines the regular component material. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -8800,7 +8372,7 @@ declare enum BlurStyle { * @atomicservice * @since 12 */ - COMPONENT_ULTRA_THICK = 12, + COMPONENT_ULTRA_THICK = 12 } /** @@ -8841,7 +8413,7 @@ declare enum BlurStyleActivePolicy { * @atomicservice * @since 14 */ - ALWAYS_INACTIVE = 2, + ALWAYS_INACTIVE = 2 } /** @@ -8877,7 +8449,7 @@ declare enum ThemeColorMode { * @atomicservice * @since 11 */ - SYSTEM, + SYSTEM = 0, /** * Defines the light mode. @@ -8894,7 +8466,7 @@ declare enum ThemeColorMode { * @atomicservice * @since 11 */ - LIGHT, + LIGHT = 1, /** * Defines the dark mode. @@ -8911,7 +8483,7 @@ declare enum ThemeColorMode { * @atomicservice * @since 11 */ - DARK, + DARK = 2 } /** @@ -8933,40 +8505,38 @@ declare enum ThemeColorMode { */ declare enum AdaptiveColor { /** - * Adaptive color mode is not used. - * The default color is used as the mask color. Using a mode other than **DEFAULT** can be more time-consuming. + * Defines the fixed value color adaptive mode. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Adaptive color mode is not used. - * The default color is used as the mask color. Using a mode other than **DEFAULT** can be more time-consuming. + * Defines the fixed value color adaptive mode. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - DEFAULT, + DEFAULT = 0, /** - * Adaptive color mode is used. The average color value of the color picking area is used as the mask color. + * Defines the background average color adaptive mode. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Adaptive color mode is used. The average color value of the color picking area is used as the mask color. + * Defines the background average color adaptive mode. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - AVERAGE, + AVERAGE = 1 } /** @@ -8988,55 +8558,57 @@ declare enum AdaptiveColor { */ declare enum ModalTransition { /** - * Slide-up and slide-down animation for the modal. + * Use default animation. + * Upward animation when entering and downward animation when exiting. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Slide-up and slide-down animation for the modal. + * Use default animation. + * Upward animation when entering and downward animation when exiting. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - DEFAULT, + DEFAULT = 0, /** - * No transition animation for the modal. + * Use none animation. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * No transition animation for the modal. + * Use none animation. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - NONE, + NONE = 1, /** - * Opacity gradient animation for the modal. + * Use alpha animation. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Opacity gradient animation for the modal. + * Use alpha animation. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - ALPHA, + ALPHA = 2 } /** @@ -9185,8 +8757,7 @@ declare interface SystemAdaptiveOptions { */ declare interface BlurStyleOptions { /** - * Color mode used for the foreground blur. - *
Default value: **ThemeColorMode.SYSTEM**. + * color mode * * @type { ?ThemeColorMode } * @default ThemeColorMode.SYSTEM @@ -9194,8 +8765,7 @@ declare interface BlurStyleOptions { * @since 10 */ /** - * Color mode used for the foreground blur. - *
Default value: **ThemeColorMode.SYSTEM**. + * color mode * * @type { ?ThemeColorMode } * @default ThemeColorMode.SYSTEM @@ -9207,8 +8777,7 @@ declare interface BlurStyleOptions { colorMode?: ThemeColorMode; /** - * Adaptive color mode. - *
Default value: **AdaptiveColor.DEFAULT**. + * adaptive color * * @type { ?AdaptiveColor } * @default AdaptiveColor.DEFAULT @@ -9216,8 +8785,7 @@ declare interface BlurStyleOptions { * @since 10 */ /** - * Adaptive color mode. - *
Default value: **AdaptiveColor.DEFAULT**. + * adaptive color * * @type { ?AdaptiveColor } * @default AdaptiveColor.DEFAULT @@ -9229,9 +8797,9 @@ declare interface BlurStyleOptions { adaptiveColor?: AdaptiveColor; /** - * Foreground blur scale. - *
Default value: **1.0**. - *
Value range: [0.0, 1.0]. + * Define the scale of blur effect. + * The range of value is [0, 1]. The larger the value, the more obvious the blurring effect. + * A value of 0 indicates no blur effect and a value of 1 indicates a complete blur effect. * * @type { ?number } * @default 1.0 @@ -9283,9 +8851,7 @@ declare interface BlurStyleOptions { declare interface BackgroundEffectOptions { /** - * Blur radius. - * Value range: [0, +∞). - * Default value: **0**. + * Define the radius size of BackgroundEffect.The range of this value is [0, ∞) * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9293,9 +8859,7 @@ declare interface BackgroundEffectOptions { * @since 11 */ /** - * Blur radius. - * Value range: [0, +∞). - * Default value: **0**. + * Define the radius size of BackgroundEffect.The range of this value is [0, ∞) * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9306,9 +8870,7 @@ declare interface BackgroundEffectOptions { radius: number; /** - * Saturation. - * Value range: [0, +∞). - * Recommended value range: [0, 50]. + * Define the saturation of BackgroundEffect. Value range [0, ∞) * * @type { ?number } * @default 1 @@ -9317,9 +8879,7 @@ declare interface BackgroundEffectOptions { * @since 11 */ /** - * Saturation. - * Value range: [0, +∞). - * Recommended value range: [0, 50]. + * Define the saturation of BackgroundEffect. Value range [0, ∞) * * @type { ?number } * @default 1 @@ -9331,10 +8891,8 @@ declare interface BackgroundEffectOptions { saturation?: number; /** - * Brightness. - *
Value range: [0, +∞). - *
Default value: **1** Recommended value range: [0, 2]. - * + * Define the brightness of BackgroundEffect. Value range [0, ∞) + * The input parameter is the highlight proportion. 0 indicates no highlight effect, and 1 indicates the maximum highlight proportion. * @type { ?number } * @default 1 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9342,10 +8900,8 @@ declare interface BackgroundEffectOptions { * @since 11 */ /** - * Brightness. - *
Value range: [0, +∞). - *
Default value: **1** Recommended value range: [0, 2]. - * + * Define the brightness of BackgroundEffect. Value range [0, ∞) + * The input parameter is the highlight proportion. 0 indicates no highlight effect, and 1 indicates the maximum highlight proportion. * @type { ?number } * @default 1 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9356,7 +8912,7 @@ declare interface BackgroundEffectOptions { brightness?: number; /** - * Color. + * color the brightness of BackgroundEffect. * * @type { ?ResourceColor } * @default Color.Transparent @@ -9365,7 +8921,7 @@ declare interface BackgroundEffectOptions { * @since 11 */ /** - * Color. + * color the brightness of BackgroundEffect. * * @type { ?ResourceColor } * @default Color.Transparent @@ -9406,7 +8962,7 @@ declare interface BackgroundEffectOptions { * @crossplatform * @since 11 */ - /** + /** * Define the blurOptions of BackgroundEffect. * * @type { ?BlurOptions } @@ -9453,7 +9009,7 @@ declare interface BackgroundEffectOptions { * @since 12 */ declare interface ForegroundEffectOptions { - + /** * Define the radius size of ForegroundEffect.The range of this value is [0, ∞) * @@ -9463,7 +9019,7 @@ declare interface ForegroundEffectOptions { * @atomicservice * @since 12 */ - radius: number; + radius: number; } /** @@ -9493,7 +9049,7 @@ declare interface PickerTextStyle { * @since 10 */ /** - * Font color. + * Define the text color of picker. * * @type { ?ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9513,7 +9069,8 @@ declare interface PickerTextStyle { * @since 10 */ /** - * Text style. + * Define the text font of picker. + * Only support size and weight. * * @type { ?Font } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9689,24 +9246,24 @@ declare enum ShadowType { * @atomicservice * @since 11 */ - COLOR, + COLOR = 0, /** - * Blur. + * Define a blur type of shadow * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Blur. + * Define a blur type of shadow * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - BLUR, + BLUR = 1 } /** @@ -9745,14 +9302,14 @@ declare enum ShadowType { */ declare interface ShadowOptions { /** - * Blur radius of the shadow. + * Define the radius size of shadow * * @type { number | Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Blur radius of the shadow. + * Define the radius size of shadow * * @type { number | Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9760,7 +9317,7 @@ declare interface ShadowOptions { * @since 9 */ /** - * Blur radius of the shadow. + * Define the radius size of shadow * * @type { number | Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9769,7 +9326,7 @@ declare interface ShadowOptions { * @since 10 */ /** - * Blur radius of the shadow. + * Define the radius size of shadow * * @type { number | Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9781,8 +9338,7 @@ declare interface ShadowOptions { radius: number | Resource; /** - * Shadow type. - *
Default value: **COLOR**. + * Define the type of shadow * * @type { ?ShadowType } * @default ShadowType.COLOR @@ -9791,8 +9347,7 @@ declare interface ShadowOptions { * @since 10 */ /** - * Shadow type. - *
Default value: **COLOR**. + * Define the type of shadow * * @type { ?ShadowType } * @default ShadowType.COLOR @@ -9804,14 +9359,14 @@ declare interface ShadowOptions { type?: ShadowType; /** - * Color of the shadow. Default value: **Black** + * Define the color of shadow * * @type { ?(Color | string | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Color of the shadow. Default value: **Black** + * Define the color of shadow * * @type { ?(Color | string | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9819,7 +9374,7 @@ declare interface ShadowOptions { * @since 9 */ /** - * Color of the shadow. Default value: **Black** + * Define the color of shadow * * @type { ?(Color | string | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9828,7 +9383,7 @@ declare interface ShadowOptions { * @since 10 */ /** - * Color of the shadow. Default value: **Black** + * Define the color or the color strategy of shadow * * @type { ?(Color | string | Resource| ColoringStrategy) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9840,14 +9395,14 @@ declare interface ShadowOptions { color?: Color | string | Resource | ColoringStrategy; /** - * Offset of the shadow along the x-axis. Unit is px. Default value is 0. + * Define the horizontal offset size of shadow * * @type { ?(number | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Offset of the shadow along the x-axis. Unit is px. Default value is 0. + * Define the horizontal offset size of shadow * * @type { ?(number | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9855,7 +9410,7 @@ declare interface ShadowOptions { * @since 9 */ /** - * Offset of the shadow along the x-axis. Unit is px. Default value is 0. + * Define the horizontal offset size of shadow * * @type { ?(number | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9864,7 +9419,7 @@ declare interface ShadowOptions { * @since 10 */ /** - * Offset of the shadow along the x-axis. Unit is px. Default value is 0. + * Define the horizontal offset size of shadow * * @type { ?(number | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9876,14 +9431,14 @@ declare interface ShadowOptions { offsetX?: number | Resource; /** - * Offset of the shadow along the y-axis. Unit is px. Default value is 0. + * Define the vertical offset size of shadow * * @type { ?(number | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Offset of the shadow along the y-axis. Unit is px. Default value is 0. + * Define the vertical offset size of shadow * * @type { ?(number | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9891,7 +9446,7 @@ declare interface ShadowOptions { * @since 9 */ /** - * Offset of the shadow along the y-axis. Unit is px. Default value is 0. + * Define the vertical offset size of shadow * * @type { ?(number | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9900,7 +9455,7 @@ declare interface ShadowOptions { * @since 10 */ /** - * Offset of the shadow along the y-axis. Unit is px. Default value is 0. + * Define the vertical offset size of shadow * * @type { ?(number | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -9912,11 +9467,7 @@ declare interface ShadowOptions { offsetY?: number | Resource; /** - * Whether to fill the inside of the component with shadow. **true**: Fill - * the inside of the component with shadow. - *
**false**: Do not fill the inside of the component with shadow. - *
The default value is **false**. - *
**NOTE**
This attribute does not take effect in textShadow. + * Define whether the shadow should fill the area * * @type { ?boolean } * @default false @@ -9925,11 +9476,7 @@ declare interface ShadowOptions { * @since 11 */ /** - * Whether to fill the inside of the component with shadow. **true**: Fill - * the inside of the component with shadow. - *
**false**: Do not fill the inside of the component with shadow. - *
The default value is **false**. - *
**NOTE**
This attribute does not take effect in textShadow. + * Define whether the shadow should fill the area * * @type { ?boolean } * @default false @@ -9974,7 +9521,7 @@ declare enum ShadowStyle { * @atomicservice * @since 11 */ - OUTER_DEFAULT_XS, + OUTER_DEFAULT_XS = 0, /** * Defines the small default shadow style. @@ -9991,58 +9538,58 @@ declare enum ShadowStyle { * @atomicservice * @since 11 */ - OUTER_DEFAULT_SM, + OUTER_DEFAULT_SM = 1, /** - * Medium shadow. + * Defines the medium default shadow style. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Medium shadow. + * Defines the medium default shadow style. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - OUTER_DEFAULT_MD, + OUTER_DEFAULT_MD = 2, /** - * Large shadow. + * Defines the large default shadow style. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Large shadow. + * Defines the large default shadow style. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - OUTER_DEFAULT_LG, + OUTER_DEFAULT_LG = 3, /** - * Floating medium shadow. + * Defines the small floating shadow style. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Floating medium shadow. + * Defines the small floating shadow style. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - OUTER_FLOATING_SM, + OUTER_FLOATING_SM = 4, /** * Defines the medium floating shadow style. @@ -10052,14 +9599,14 @@ declare enum ShadowStyle { * @since 10 */ /** - * Floating medium shadow. + * Defines the medium floating shadow style. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - OUTER_FLOATING_MD, + OUTER_FLOATING_MD = 5 } /** @@ -10081,12 +9628,8 @@ declare enum ShadowStyle { */ declare interface MultiShadowOptions { /** - * Shadow blur radius. - * Unit: vp. - *

**NOTE**: - *
A value less than or equal to 0 is handled as the default value. - *

- * + * Current shadow radius. + * * @type { ?(number | Resource) } * @default 5 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10094,12 +9637,8 @@ declare interface MultiShadowOptions { * @since 10 */ /** - * Shadow blur radius. - * Unit: vp. - *

**NOTE**: - *
A value less than or equal to 0 is handled as the default value. - *

- * + * Current shadow radius. + * * @type { ?(number | Resource) } * @default 20 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10110,9 +9649,8 @@ declare interface MultiShadowOptions { radius?: number | Resource; /** - * Offset on the x-axis. - * Unit: vp. - * + * Current shadow offsetX. + * * @type { ?(number | Resource) } * @default 5 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10120,9 +9658,8 @@ declare interface MultiShadowOptions { * @since 10 */ /** - * Offset on the x-axis. - * Unit: vp. - * + * Current shadow offsetX. + * * @type { ?(number | Resource) } * @default 5 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10133,9 +9670,8 @@ declare interface MultiShadowOptions { offsetX?: number | Resource; /** - * Offset on the y-axis. - * Unit: vp. - * + * Current shadow offsetY + * * @type { ?(number | Resource) } * @default 5 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10143,9 +9679,8 @@ declare interface MultiShadowOptions { * @since 10 */ /** - * Offset on the y-axis. - * Unit: vp. - * + * Current shadow offsetY + * * @type { ?(number | Resource) } * @default 5 * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10164,7 +9699,7 @@ declare interface MultiShadowOptions { * @since 10 */ /** - * The types of expanded safe areas. + * Enumerates the safe area types. * * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10180,14 +9715,14 @@ declare enum SafeAreaType { * @since 10 */ /** - * Default non-safe area of the system, including the status bar and navigation bar. + * Default area of the system, including the status bar and navigation bar. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - SYSTEM, + SYSTEM = 0, /** * Notch or punch hole. @@ -10196,14 +9731,14 @@ declare enum SafeAreaType { * @since 10 */ /** - * Non-safe area of the device like Notch or punch hole. + * Notch or punch hole. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - CUTOUT, + CUTOUT = 1, /** * Soft keyboard area. @@ -10219,7 +9754,7 @@ declare enum SafeAreaType { * @atomicservice * @since 11 */ - KEYBOARD + KEYBOARD = 2 } /** @@ -10246,14 +9781,14 @@ declare enum SafeAreaEdge { * @since 10 */ /** - * Top edge. + * Top edge of the safe area. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - TOP, + TOP = 0, /** * Bottom edge of the safe area. @@ -10262,14 +9797,14 @@ declare enum SafeAreaEdge { * @since 10 */ /** - * Bottom edge. + * Bottom edge of the safe area. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - BOTTOM, + BOTTOM = 1, /** * Start edge of the safe area. @@ -10278,14 +9813,14 @@ declare enum SafeAreaEdge { * @since 10 */ /** - * Start edge. + * Start edge of the safe area. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - START, + START = 2, /** * End edge of the safe area. @@ -10294,18 +9829,18 @@ declare enum SafeAreaEdge { * @since 10 */ /** - * End edge. + * End edge of the safe area. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - END + END = 3 } /** - * Describe the types for expanding the safe area in layout. + * Enumerates the safe area types can be ignored. * * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10315,7 +9850,7 @@ declare enum SafeAreaEdge { */ declare enum LayoutSafeAreaType { /** - * Default non-safe area of the system, including the status bar and navigation bar. + * Default area of the system, including the status bar and navigation bar. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -10326,7 +9861,7 @@ declare enum LayoutSafeAreaType { } /** - * Define the edges for expanding the safe area in layout. + * Enumerates the safe area edges can be ignored. * * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10336,7 +9871,7 @@ declare enum LayoutSafeAreaType { */ declare enum LayoutSafeAreaEdge { /** - * Top edge. + * Top edge of the safe area. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -10346,7 +9881,7 @@ declare enum LayoutSafeAreaEdge { TOP = 0, /** - * Bottom edge. + * Bottom edge of the safe area. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -10425,56 +9960,57 @@ declare enum LayoutSafeAreaEdge { */ declare enum SheetSize { /** - * The sheet height is half of the screen height. + * Defines the sheet size medium height type. The height is half the screen height * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * The sheet height is half of the screen height. + * Defines the sheet size medium height type. The height is half the screen height * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - MEDIUM, + MEDIUM = 0, /** - * The sheet height is almost the screen height. + * Defines the sheet size large height type. The height is almost screen height. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * The sheet height is almost the screen height. + * Defines the sheet size large height type. The height is almost screen height. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - LARGE, + LARGE = 1, /** - * The sheet height automatically adapts to the content. + * Defines the sheet size fit content height type. The height fit content. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 */ /** - * The sheet height automatically adapts to the content. + * Defines the sheet size fit content height type. The height fit content. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - FIT_CONTENT = 2, + FIT_CONTENT = 2 } + /** * Defines the base event. * @@ -10535,7 +10071,7 @@ declare interface BaseEvent { * @since 10 */ /** - * Display area of the element that triggers the gesture event. + * Defines the current target which fires this event. * * @type { EventTarget } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10571,7 +10107,7 @@ declare interface BaseEvent { * @since 10 */ /** - * Timestamp of the event. + * Event timestamp. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10607,7 +10143,7 @@ declare interface BaseEvent { * @since 10 */ /** - * Event input device. + * the event source info. * * @type { SourceType } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10628,7 +10164,7 @@ declare interface BaseEvent { * @atomicservice * @since 12 */ - axisHorizontal?: number; + axisHorizontal ?: number; /** * the Vertical axis coordinate. @@ -10640,7 +10176,7 @@ declare interface BaseEvent { * @atomicservice * @since 12 */ - axisVertical?: number; + axisVertical ?: number; /** * Touch pressure. @@ -10660,7 +10196,7 @@ declare interface BaseEvent { * @since 10 */ /** - * Press pressure. + * Touch pressure. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10689,7 +10225,7 @@ declare interface BaseEvent { * @since 10 */ /** - * Angle between the projection of the stylus on the device plane and the x-axis. + * The angle between pencil projection on plane-X-Y and axis-Z. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10718,7 +10254,7 @@ declare interface BaseEvent { * @since 10 */ /** - * Angle between the projection of the stylus on the device plane and the y-axis. + * The angle between pencil projection on plane-Y-Z and axis-Z. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10759,7 +10295,7 @@ declare interface BaseEvent { * @since 10 */ /** - * Event input source. + * The event tool type info. * * @type { SourceTool } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10782,6 +10318,7 @@ declare interface BaseEvent { * @since 12 */ getModifierKeyState?(keys: Array): boolean; + /** * Indicates the ID of the input device that triggers the current event. * @@ -10861,11 +10398,9 @@ declare interface BorderImageOption { * @since 11 */ /** - * Slice width of the upper left corner, upper right corner, lower left corner, - * and lower right corner of the border image. + * Border image slice * * @type { ?(Length | EdgeWidths | LocalizedEdgeWidths) } - * @default 0 * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -10892,10 +10427,9 @@ declare interface BorderImageOption { * @since 10 */ /** - * Repeat mode of the source image's slices on the border. + * Border image repeat * * @type { ?RepeatMode } - * @default RepeatMode.Stretch * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -10922,13 +10456,7 @@ declare interface BorderImageOption { * @since 10 */ /** - * Source or gradient color of the border image. - * When the type is string, this parameter sets the border image source. - * For details about how to reference image resources, see Loading Image Resources. - * - *

NOTE: - *
The border image source applies only to container components, such as Row, Column, and Flex. - *

+ * Border image source * * @type { ?(string | Resource | LinearGradient) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10938,6 +10466,7 @@ declare interface BorderImageOption { * @since 11 */ source?: string | Resource | LinearGradient, + /** * Border image width * @@ -10966,10 +10495,9 @@ declare interface BorderImageOption { * @since 11 */ /** - * Width of the border image. + * Border image width * * @type { ?(Length | EdgeWidths | LocalizedEdgeWidths) } - * @default 0 * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -11006,10 +10534,9 @@ declare interface BorderImageOption { * @since 11 */ /** - * Amount by which the border image is extended beyond the border box. + * Border image outset * * @type { ?(Length | EdgeWidths | LocalizedEdgeWidths) } - * @default 0 * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -11036,19 +10563,16 @@ declare interface BorderImageOption { * @since 10 */ /** - * Whether to fill the center of the border image. - * true: Fill the center of the border image. - * false: Do not fill the center of the border image. + * Border image center fill * * @type { ?boolean } - * @default false * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 11 */ - fill?: boolean + fill?: boolean; } /** @@ -11074,6 +10598,7 @@ declare class LayoutPolicy { * @since 15 */ static readonly matchParent: LayoutPolicy; + /** * The component fills its content which means its size is as large as its children but it is constained by its parent. * @@ -11083,10 +10608,11 @@ declare class LayoutPolicy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form - * @atomicservice + * @atomicservice * @since 20 */ static readonly wrapContent: LayoutPolicy; + /** * The component fills its content which means its size is as large as its children. * @@ -11096,7 +10622,7 @@ declare class LayoutPolicy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form - * @atomicservice + * @atomicservice * @since 20 */ static readonly fixAtIdealSize: LayoutPolicy; @@ -11172,7 +10698,7 @@ declare interface ClickEvent extends BaseEvent { * @since 10 */ /** - * X coordinate of the click relative to the upper left corner of the application screen. + * X coordinate of the click point relative to the left edge of the device screen. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11191,7 +10717,7 @@ declare interface ClickEvent extends BaseEvent { * @since 10 */ /** - * Y coordinate of the click relative to the upper left corner of the application screen. + * Y coordinate of the click point relative to the upper edge of the device screen. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11210,7 +10736,7 @@ declare interface ClickEvent extends BaseEvent { * @since 10 */ /** - * X coordinate of the click relative to the upper left corner of the application window. + * X coordinate of the click point relative to the left edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11229,7 +10755,7 @@ declare interface ClickEvent extends BaseEvent { * @since 10 */ /** - * Y coordinate of the click relative to the upper left corner of the application window. + * Y coordinate of the click point relative to the upper edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11240,7 +10766,7 @@ declare interface ClickEvent extends BaseEvent { windowY: number; /** - * X coordinate of the click relative to the upper left corner of the application window. + * X coordinate of the click point relative to the left edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11251,7 +10777,7 @@ declare interface ClickEvent extends BaseEvent { screenX: number; /** - * Y coordinate of the click relative to the upper left corner of the application window. + * Y coordinate of the click point relative to the upper edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11334,7 +10860,7 @@ declare interface ClickEvent extends BaseEvent { y: number; /** - * Whether the event is triggered by a left-hand or right-hand tap. + * Type of the touch hand. * * @type { InteractionHand } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11553,7 +11079,7 @@ declare interface MouseEvent extends BaseEvent { * @since 10 */ /** - * X coordinate of the mouse pointer relative to the upper left corner of the application screen. + * X coordinate of the mouse point relative to the left edge of the device screen. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11570,7 +11096,7 @@ declare interface MouseEvent extends BaseEvent { * @since 10 */ /** - * Y coordinate of the mouse pointer relative to the upper left corner of the application screen. + * Y coordinate of the mouse point relative to the upper edge of the device screen. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11587,7 +11113,7 @@ declare interface MouseEvent extends BaseEvent { * @since 10 */ /** - * X coordinate of the mouse pointer relative to the upper left corner of the application window. + * X coordinate of the mouse point relative to the left edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11604,7 +11130,7 @@ declare interface MouseEvent extends BaseEvent { * @since 10 */ /** - * Y coordinate of the mouse pointer relative to the upper left corner of the application window. + * Y coordinate of the mouse point relative to the upper edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11614,7 +11140,7 @@ declare interface MouseEvent extends BaseEvent { windowY: number; /** - * X coordinate of the mouse pointer relative to the upper left corner of the application window. + * X coordinate of the mouse point relative to the left edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11625,7 +11151,7 @@ declare interface MouseEvent extends BaseEvent { screenX: number; /** - * Y coordinate of the mouse pointer relative to the upper left corner of the application window. + * Y coordinate of the mouse point relative to the upper edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11643,7 +11169,7 @@ declare interface MouseEvent extends BaseEvent { * @since 8 */ /** - * X coordinate of the mouse pointer relative to the upper left corner of the component being clicked. + * X coordinate of the mouse point relative to the left edge of the mouse hit element. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11660,7 +11186,7 @@ declare interface MouseEvent extends BaseEvent { * @since 8 */ /** - * Y coordinate of the mouse pointer relative to the upper left corner of the component being clicked. + * Y coordinate of the mouse point relative to the upper edge of the mouse hit element. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11677,7 +11203,7 @@ declare interface MouseEvent extends BaseEvent { * @since 8 */ /** - * Stops the event from bubbling upwards or downwards. + * The blocking event pops up. * * @type { function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11707,9 +11233,9 @@ declare interface MouseEvent extends BaseEvent { * @since 15 */ rawDeltaY?: number; - + /** - * Array of all mouse buttons that are currently pressed. + * The pressed buttons of the mouse event. * * @type { ?MouseButton[] } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11887,7 +11413,7 @@ declare interface TouchObject { * @since 10 */ /** - * Unique identifier of a finger. + * Finger unique identifier. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11928,7 +11454,7 @@ declare interface TouchObject { * @since 10 */ /** - * X coordinate of the touch point relative to the upper left corner of the application screen. + * X coordinate of the touch point relative to the left edge of the device screen. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11947,7 +11473,7 @@ declare interface TouchObject { * @since 10 */ /** - * Y coordinate of the touch point relative to the upper left corner of the application screen. + * Y coordinate of the touch point relative to the upper edge of the device screen. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11966,7 +11492,7 @@ declare interface TouchObject { * @since 10 */ /** - * X coordinate of the touch point relative to the upper left corner of the application window. + * X coordinate of the touch point relative to the left edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11985,7 +11511,7 @@ declare interface TouchObject { * @since 10 */ /** - * Y coordinate of the touch point relative to the upper left corner of the application window. + * Y coordinate of the touch point relative to the upper edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -11996,7 +11522,7 @@ declare interface TouchObject { windowY: number; /** - * X coordinate of the touch point relative to the upper left corner of the application window. + * X coordinate of the touch point relative to the left edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12007,7 +11533,7 @@ declare interface TouchObject { screenX: number; /** - * Y coordinate of the touch point relative to the upper left corner of the application window. + * Y coordinate of the touch point relative to the upper edge of the current window. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12033,7 +11559,7 @@ declare interface TouchObject { * @since 10 */ /** - * X coordinate of the touch point relative to the upper left corner of the event responding component. + * X coordinate of the touch point relative to the left edge of the touched element. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12059,7 +11585,7 @@ declare interface TouchObject { * @since 10 */ /** - * Y coordinate of the touch point relative to the upper left corner of the event responding component. + * Y coordinate of the touch point relative to the upper edge of the touched element. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12070,7 +11596,7 @@ declare interface TouchObject { y: number; /** - * Whether the event is triggered by a left-hand or right-hand tap. + * Type of the touch hand. * * @type { InteractionHand } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12078,10 +11604,10 @@ declare interface TouchObject { * @atomicservice * @since 15 */ - hand?: InteractionHand; + hand?: InteractionHand; /** - * Time when the finger is pressed. + * Time stamp when the touch point is pressed. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12091,18 +11617,18 @@ declare interface TouchObject { */ pressedTime?: number; /** - * Pressure value of the finger press. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 15 - */ + * Pressure of a specific touch point. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 15 + */ pressure?: number; /** - * Width of the area pressed by the finger. + * Width of the contact area when touch is pressed of a specific touch point. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12113,7 +11639,7 @@ declare interface TouchObject { width?: number; /** - * Height of the area pressed by the finger. + * Height of the contact area when touch is pressed of a specific touch point. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12315,7 +11841,7 @@ declare interface TouchEvent extends BaseEvent { * @since 10 */ /** - * Finger information changed. + * Indicates the current changed finger information. * * @type { TouchObject[] } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12341,7 +11867,7 @@ declare interface TouchEvent extends BaseEvent { * @since 10 */ /** - * Stops the event from bubbling upwards or downwards. + * The blocking event pops up. * * @type { function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12360,7 +11886,7 @@ declare interface TouchEvent extends BaseEvent { * @since 10 */ /** - * Obtains all historical points of the current frame. + * Get the historical points. * * @returns { Array } - return all historical points. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12371,7 +11897,7 @@ declare interface TouchEvent extends BaseEvent { getHistoricalPoints(): Array; /** - * Blocks the default event. + * Prevent the default function. * * @type { function } * @throws { BusinessError } 100017 - Component does not support prevent function. @@ -12526,8 +12052,8 @@ declare interface AxisEvent extends BaseEvent { /** * Defines the callback type used in onSizeChange. - *
oldValue - the width and height of the component before the change. - *
newValue - the width and height of the component after the change. + * The value of oldValue is last size of the component. + * The value of newValue is new size of the component. * * @typedef { function } SizeChangeCallback * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12558,14 +12084,15 @@ declare type SizeChangeCallback = (oldValue: SizeOptions, newValue: SizeOptions) * @param { BaseGestureEvent } event - the event information * @param { GestureRecognizer } current - the current gesture recognizer of the component * @param { Array } recognizers - the gesture recognizers of the component on the response chain - * @param { Array } touchRecognizers - the touch recognizers of the component on the response chain + * @param { Array } [touchRecognizers] - the touch recognizers of the component on the response chain * @returns { GestureJudgeResult } the gesture judge result * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 20 */ -declare type GestureRecognizerJudgeBeginCallback = (event: BaseGestureEvent, current: GestureRecognizer, recognizers: Array, touchRecognizers?: Array) => GestureJudgeResult; +declare type GestureRecognizerJudgeBeginCallback = (event: BaseGestureEvent, current: GestureRecognizer, recognizers: Array, + touchRecognizers?: Array) => GestureJudgeResult; /** * Defines the callback type used in shouldBuiltInRecognizerParallelWith. @@ -12633,6 +12160,7 @@ declare type TouchTestDoneCallback = (event: BaseGestureEvent, recognizers: Arra * @since 11 */ declare type PixelMap = import('../api/@ohos.multimedia.image').default.PixelMap; + /** * pixelmap object with release function. * @@ -12669,10 +12197,6 @@ declare interface PixelMapMock { */ /** * Enum for Drag Behavior. - * - * NOTE:
- * DragBehavior serves to inform you about the intended method of data handling, - * whether it's a copy or a move, but it does not actually dictate the real processing of the data. * * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -12702,7 +12226,7 @@ declare enum DragBehavior { * @atomicservice * @since 18 */ - COPY, + COPY = 0, /** * If drag use move event, then set DragBehavior.MOVE. * @@ -12724,7 +12248,7 @@ declare enum DragBehavior { * @atomicservice * @since 18 */ - MOVE + MOVE = 1 } /** @@ -12745,6 +12269,7 @@ declare enum DragBehavior { * @since 11 */ declare type UnifiedData = import('../api/@ohos.data.unifiedDataChannel').default.UnifiedData; + /** * Import the Summary type object for ui component. * @@ -12848,6 +12373,15 @@ declare type DataLoadParams = import('../api/@ohos.data.unifiedDataChannel').def * @since 14 */ declare enum DragResult { + /** + * If the drag is not finished and the result is not set by receiver, return DragResult.UNKNOWN. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + UNKNOWN = -1, /** * If the drag is successful, return DragResult.DRAG_SUCCESSFUL. * @@ -12938,7 +12472,7 @@ declare enum DragResult { /** * Enum for BlendMode. - * Blend modes for compositing current component + * Blend modes for compositing current component * with overlapping content. Use overlapping content * as dst, current component as src. * @@ -12963,7 +12497,7 @@ declare enum DragResult { */ declare enum BlendMode { /** - * The top image is superimposed on the bottom image without any blending. + * Hybrid mode does not take effect * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -12971,7 +12505,7 @@ declare enum BlendMode { * @since 11 */ /** - * The top image is superimposed on the bottom image without any blending. + * Hybrid mode does not take effect * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -12981,7 +12515,7 @@ declare enum BlendMode { */ NONE = 0, /** - * The target pixels covered by the source pixels are erased by being turned to completely transparent. + * Clear destination color covered by the source to 0. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -12989,7 +12523,7 @@ declare enum BlendMode { * @since 11 */ /** - * The target pixels covered by the source pixels are erased by being turned to completely transparent. + * Clear destination color covered by the source to 0. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -12999,22 +12533,22 @@ declare enum BlendMode { */ CLEAR = 1, /** - * r = s: Only the source pixels are displayed. + * r = s * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 11 - */ + */ /** - * r = s: Only the source pixels are displayed. + * r = s * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ SRC = 2, /** * r = d @@ -13023,7 +12557,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * r = d * @@ -13032,10 +12566,10 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ DST = 3, /** - * r = s + (1 - sa) * d: The source pixels are blended based on opacity and cover the target pixels. + * r = s + (1 - sa) * d * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -13043,7 +12577,7 @@ declare enum BlendMode { * @since 11 */ /** - * r = s + (1 - sa) * d: The source pixels are blended based on opacity and cover the target pixels. + * r = s + (1 - sa) * d * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -13053,25 +12587,25 @@ declare enum BlendMode { */ SRC_OVER = 4, /** - * r = d + (1 - da) * s: The target pixels are blended based on opacity and cover on the source pixels. + * r = d + (1 - da) * s * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 11 - */ + */ /** - * r = d + (1 - da) * s: The target pixels are blended based on opacity and cover on the source pixels. + * r = d + (1 - da) * s * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ DST_OVER = 5, /** - * r = s * da: Only the part of the source pixels that overlap with the target pixels is displayed. + * r = s * da * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -13079,7 +12613,7 @@ declare enum BlendMode { * @since 11 */ /** - * r = s * da: Only the part of the source pixels that overlap with the target pixels is displayed. + * r = s * da * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -13089,22 +12623,22 @@ declare enum BlendMode { */ SRC_IN = 6, /** - * r = d * sa: Only the part of the target pixels that overlap with the source pixels is displayed. + * r = d * sa * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 11 - */ + */ /** - * r = d * sa: Only the part of the target pixels that overlap with the source pixels is displayed. + * r = d * sa * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ DST_IN = 7, /** * r = s * (1 - da) @@ -13113,7 +12647,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * r = s * (1 - da) * @@ -13122,7 +12656,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ SRC_OUT = 8, /** * r = d * (1 - sa) @@ -13131,36 +12665,34 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** - * r = d * (1 - sa), retains the parts of the destination pixels that do not overlap with the source. + * r = d * (1 - sa) * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ DST_OUT = 9, /** - * r = s * da + d * (1 - sa): The part of the source pixels that overlap with the target pixels is displayed - * and the part of the target pixels that do not overlap with the source pixels are displayed. + * r = s * da + d * (1 - sa) * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 11 - */ + */ /** - * r = s * da + d * (1 - sa): The part of the source pixels that overlap with the target pixels is displayed - * and the part of the target pixels that do not overlap with the source pixels are displayed. + * r = s * da + d * (1 - sa) * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ SRC_ATOP = 10, /** * r = d * sa + s * (1 - da) @@ -13169,17 +12701,16 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** - * r = d * sa + s * (1 - da): The part of the target pixels that overlap with the source pixels - * and the part of the source pixels that do not overlap with the target pixels are displayed. + * r = d * sa + s * (1 - da) * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ DST_ATOP = 11, /** * r = s * (1 - da) + d * (1 - sa) @@ -13188,7 +12719,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * r = s * (1 - da) + d * (1 - sa) * @@ -13197,7 +12728,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ XOR = 12, /** * r = min(s + d, 1) @@ -13206,17 +12737,16 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** - * r = min(s + d, 1): - * New pixels resulting from adding the source pixels to the target pixels are displayed. + * r = min(s + d, 1) * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ PLUS = 13, /** * r = s * d @@ -13225,7 +12755,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * r = s * d * @@ -13234,7 +12764,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ MODULATE = 14, /** * r = s + d - s * d @@ -13243,7 +12773,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * r = s + d - s * d * @@ -13252,7 +12782,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ SCREEN = 15, /** * multiply or screen, depending on destination @@ -13261,7 +12791,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * multiply or screen, depending on destination * @@ -13270,7 +12800,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ OVERLAY = 16, /** * rc = s + d - max(s * da, d * sa), ra = kSrcOver @@ -13279,7 +12809,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * rc = s + d - max(s * da, d * sa), ra = kSrcOver * @@ -13288,7 +12818,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ DARKEN = 17, /** * rc = s + d - min(s * da, d * sa), ra = kSrcOver @@ -13297,7 +12827,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * rc = s + d - min(s * da, d * sa), ra = kSrcOver * @@ -13306,7 +12836,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ LIGHTEN = 18, /** * brighten destination to reflect source @@ -13315,7 +12845,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * brighten destination to reflect source * @@ -13324,7 +12854,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ COLOR_DODGE = 19, /** * darken destination to reflect source @@ -13333,7 +12863,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * darken destination to reflect source * @@ -13342,7 +12872,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ COLOR_BURN = 20, /** * multiply or screen, depending on source @@ -13351,7 +12881,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * multiply or screen, depending on source * @@ -13360,25 +12890,25 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ HARD_LIGHT = 21, /** - * The LIGHTEN or DARKEN mode is used, depending on the source pixels. + * lighten or darken, depending on source * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 11 - */ + */ /** - * The LIGHTEN or DARKEN mode is used, depending on the source pixels. + * lighten or darken, depending on source * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ SOFT_LIGHT = 22, /** * rc = s + d - 2 * (min(s * da, d * sa)), ra = kSrcOver @@ -13387,17 +12917,16 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** - * rc = s + d - 2 * (min(s * da, d * sa)), ra = kSrcOver: The final pixel is the result of subtracting - * the darker of the two pixels (source and target) from the lighter one. + * rc = s + d - 2 * (min(s * da, d * sa)), ra = kSrcOver * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ DIFFERENCE = 23, /** * rc = s + d - two(s * d), ra = kSrcOver @@ -13406,7 +12935,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * rc = s + d - two(s * d), ra = kSrcOver * @@ -13415,27 +12944,25 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ EXCLUSION = 24, /** - * r = s * (1 - da) + d * (1 - sa) + s * d: - * The final pixel is the result of multiplying the source pixel by the target pixel. + * r = s * (1 - da) + d * (1 - sa) + s * d * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 11 - */ + */ /** - * r = s * (1 - da) + d * (1 - sa) + s * d: - * The final pixel is the result of multiplying the source pixel by the target pixel. + * r = s * (1 - da) + d * (1 - sa) + s * d * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @atomicservice * @since 12 - */ + */ MULTIPLY = 25, /** * hue of source with saturation and luminosity of destination @@ -13444,7 +12971,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * hue of source with saturation and luminosity of destination * @@ -13453,7 +12980,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ HUE = 26, /** * saturation of source with hue and luminosity of destination @@ -13462,7 +12989,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * saturation of source with hue and luminosity of destination * @@ -13471,7 +12998,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ SATURATION = 27, /** * hue and saturation of source with luminosity of destination @@ -13480,7 +13007,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * hue and saturation of source with luminosity of destination * @@ -13489,7 +13016,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ COLOR = 28, /** * luminosity of source with hue and saturation of destination @@ -13498,7 +13025,7 @@ declare enum BlendMode { * @crossplatform * @form * @since 11 - */ + */ /** * luminosity of source with hue and saturation of destination * @@ -13507,7 +13034,7 @@ declare enum BlendMode { * @form * @atomicservice * @since 12 - */ + */ LUMINOSITY = 29 } @@ -13536,7 +13063,7 @@ declare enum BlendMode { */ declare enum BlendApplyType { /** - * The content of the view is blended in sequence on the target image. + * Blend view's content in sequence over dst * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -13544,7 +13071,7 @@ declare enum BlendApplyType { * @since 11 */ /** - * The content of the view is blended in sequence on the target image. + * Blend view's content in sequence over dst * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -13555,8 +13082,8 @@ declare enum BlendApplyType { FAST = 0, /** - * The content of the component and its child components are drawn on the - * offscreen canvas, and then blended with the existing content on the canvas. + * Composite this views's contents into an + * offscreen image and then blend over dst * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -13564,8 +13091,8 @@ declare enum BlendApplyType { * @since 11 */ /** - * The content of the component and its child components are drawn on the - * offscreen canvas, and then blended with the existing content on the canvas. + * Composite this views's contents into an + * offscreen image and then blend over dst * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -13573,7 +13100,7 @@ declare enum BlendApplyType { * @atomicservice * @since 12 */ - OFFSCREEN = 1, + OFFSCREEN = 1 } /** @@ -13748,29 +13275,29 @@ declare interface DragEvent { getY(): number; /** - * If copy is COPY, this DragEvent is a copy event. - * @type { DragBehavior } Operation, if use copy then set COPY, else set MOVE. - * @default COPY - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ + * If copy is COPY, this DragEvent is a copy event. + * @type { DragBehavior } Operation, if use copy then set COPY, else set MOVE. + * @default COPY + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ /** - * If copy is COPY, this DragEvent is a copy event. - * @type { DragBehavior } Operation, if use copy then set COPY, else set MOVE. - * @default COPY - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ + * If copy is COPY, this DragEvent is a copy event. + * @type { DragBehavior } Operation, if use copy then set COPY, else set MOVE. + * @default COPY + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 11 + */ /** - * If copy is COPY, this DragEvent is a copy event. - * @type { DragBehavior } Operation, if use copy then set COPY, else set MOVE. - * @default COPY - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ + * If copy is COPY, this DragEvent is a copy event. + * @type { DragBehavior } Operation, if use copy then set COPY, else set MOVE. + * @default COPY + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ dragBehavior: DragBehavior; /** @@ -13987,7 +13514,7 @@ declare interface DragEvent { getVelocity(): number; /** - * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift' + * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift'|'fn' * * @param { Array } keys - indicate the keys of the ModifierKey. * @returns { boolean } @@ -13997,7 +13524,7 @@ declare interface DragEvent { * @since 12 */ /** - * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift' + * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift'|'fn' * * @param { Array } keys - indicate the keys of the ModifierKey. * @returns { boolean } @@ -14032,7 +13559,7 @@ declare interface DragEvent { * @param { DataSyncOptions } options - the data sync options. * @returns { string } The data key returned by system, which can be used as the identify of the request. * @throws { BusinessError } 401 - Parameter error. - * @throws { BusinessError } 190003 - Operation not allowed for current pharse. + * @throws { BusinessError } 190003 - Operation not allowed for current phase. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 15 @@ -14418,7 +13945,7 @@ declare interface KeyEvent { intentionCode: IntentionCode; /** - * Get the modifier keys press state, support 'ctrl'|'alt'|'shift' + * Get the modifier keys press state, support 'ctrl'|'alt'|'shift'|'fn' * * @param { Array } keys - indicate the modifier keys. * @returns { boolean } @@ -14428,7 +13955,7 @@ declare interface KeyEvent { * @since 12 */ /** - * Get the modifier keys press state, support 'ctrl'|'alt'|'shift' + * Get the modifier keys press state, support 'ctrl'|'alt'|'shift'|'fn' * * @param { Array } keys - indicate the modifier keys. * @returns { boolean } @@ -14591,8 +14118,7 @@ declare interface CrownEvent { */ declare interface BindOptions { /** - * Background color of the sheet. - *
Default value: **Color.White**. + * Defines the background color * * @type { ?ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -14600,8 +14126,7 @@ declare interface BindOptions { * @since 10 */ /** - * Background color of the sheet. - *
Default value: **Color.White**. + * Defines the background color * * @type { ?ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -14612,7 +14137,7 @@ declare interface BindOptions { backgroundColor?: ResourceColor; /** - * Callback for when the sheet is displayed (after the animation ends). + * Callback function when overlay interface appears * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -14620,7 +14145,7 @@ declare interface BindOptions { * @since 10 */ /** - * Callback for when the sheet is displayed (after the animation ends). + * Callback function when overlay interface appears * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -14631,7 +14156,7 @@ declare interface BindOptions { onAppear?: () => void; /** - * Callback for when the sheet disappears (after the animation ends). + * Callback function when overlay interface exits * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -14639,7 +14164,7 @@ declare interface BindOptions { * @since 10 */ /** - * Callback for when the sheet disappears (after the animation ends). + * Callback function when overlay interface exits * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -14650,7 +14175,7 @@ declare interface BindOptions { onDisappear?: () => void; /** - * Callback for when the sheet is about to be displayed (before the animation starts). + * Callback function before overlay animation starts. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -14704,6 +14229,7 @@ declare interface DismissContentCoverAction { */ reason: DismissReason; } + /** * Component content cover options * @@ -14743,7 +14269,7 @@ declare interface ContentCoverOptions extends BindOptions { * @atomicservice * @since 11 */ - modalTransition?: ModalTransition, + modalTransition?: ModalTransition; /** * Callback function when the content cover interactive dismiss @@ -14856,14 +14382,14 @@ declare interface SheetTitleOptions { */ declare enum SheetType { /** - * Bottom sheet. + * Defines bottom sheet type. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 */ /** - * Bottom sheet. + * Defines bottom sheet type. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -14873,14 +14399,14 @@ declare enum SheetType { BOTTOM = 0, /** - * Center sheet. + * Defines center sheet type. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 */ /** - * Center sheet. + * Defines center sheet type. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -14890,14 +14416,14 @@ declare enum SheetType { CENTER = 1, /** - * Popup sheet. The popup sheet cannot be dismissed with a pull-down gesture. + * Defines popup sheet type. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 */ /** - * Popup sheet. The popup sheet cannot be dismissed with a pull-down gesture. + * Defines popup sheet type. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -14928,8 +14454,7 @@ declare enum SheetType { */ declare enum SheetMode { /** - * The sheet is displayed at the top of the window corresponding to the current **UIContext** instance, - * above all pages. It is displayed at the same level as dialog boxes. + * Sheet displays above all page levels. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -14939,23 +14464,14 @@ declare enum SheetMode { OVERLAY = 0, /** - * The sheet is displayed at the top of the current page. - *
**NOTE**
Currently, the sheet can only be mounted on a **Page** - * or **NavDestination** node, with priority given to the **NavDestination** - * node if it is present. This means that, the sheet can only be displayed at - * the top of these two types of pages.
In this mode, new pages can overlay - * the sheet, and when the user returns to the previous page, the sheet remains - * present without losing its content.
In this mode, you must ensure that - * the target page node, such as the **Page** node, has been attached to the tree - * before bringing up the sheet; otherwise, the sheet will not be able to be - * attached to the corresponding page node. + * Sheet displays within the current page. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - EMBEDDED = 1, + EMBEDDED = 1 } /** @@ -14986,7 +14502,7 @@ declare enum ScrollSizeMode { * @atomicservice * @since 12 */ - CONTINUOUS = 1, + CONTINUOUS = 1 } /** @@ -15049,7 +14565,7 @@ declare enum SheetKeyboardAvoidMode { * @atomicservice * @since 20 */ - POPUP_SHEET = 4, + POPUP_SHEET = 4 } /** @@ -15188,9 +14704,7 @@ declare interface SheetOptions extends BindOptions { height?: SheetSize | Length; /** - * Whether to display the drag bar. - *
**NOTE**
By default, the drag bar is displayed only when the sheet's - * **detents** attribute is set to multiple heights and the settings take effect. + * Defines whether the control bar is displayed. * * @type { ?boolean } * @default true @@ -15199,9 +14713,7 @@ declare interface SheetOptions extends BindOptions { * @since 10 */ /** - * Whether to display the drag bar. - *
**NOTE**
By default, the drag bar is displayed only when the sheet's - * **detents** attribute is set to multiple heights and the settings take effect. + * Defines whether the control bar is displayed. * * @type { ?boolean } * @default true @@ -15233,8 +14745,8 @@ declare interface SheetOptions extends BindOptions { * @since 10 */ /** - * Mask color of the sheet. - * + * Defines sheet maskColor + * * @type { ?ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -15245,28 +14757,14 @@ declare interface SheetOptions extends BindOptions { /** * Defines sheet detents + * * @type { ?[(SheetSize | Length), (SheetSize | Length)?, (SheetSize | Length)?] } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 */ /** - * Array of heights where the sheet can rest. - *

**NOTE**: - *
Since API version 12, this attribute takes effect for a bottom sheet in landscape mode. - *
In earlier versions, this attribute takes effect only for the bottom sheet in portrait mode. - *
The first height in the tuple is the initial height. - *
The sheet can switch between heights by dragging. - *
After the sheet is dragged and released, it switches to the target height or remains at the current height, - * depending on the velocity and distance. - *
If the velocity exceeds the threshold, the sheet switches to the target height in the same direction as the - * velocity. - *
If the velocity is less than the threshold, the displacement distance is used for judgement. - *
If the displacement distance is greater than 1/2 of the distance between the current and target positions, - * the sheet switches to the target height in the same direction as the velocity; otherwise, the sheet remains at the - * current height. - *
Velocity threshold: 1000; Distance threshold: 50%. - *

+ * Defines sheet detents * * @type { ?[(SheetSize | Length), (SheetSize | Length)?, (SheetSize | Length)?] } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15277,8 +14775,8 @@ declare interface SheetOptions extends BindOptions { detents?: [(SheetSize | Length), (SheetSize | Length)?, (SheetSize | Length)?]; /** - * Background blur of the sheet. By default, there is no background blur. - * + * Defines sheet background blur Style + * * @type { ?BlurStyle } * @default BlurStyle.NONE * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15286,8 +14784,8 @@ declare interface SheetOptions extends BindOptions { * @since 11 */ /** - * Background blur of the sheet. By default, there is no background blur. - * + * Defines sheet background blur Style + * * @type { ?BlurStyle } * @default BlurStyle.NONE * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15319,23 +14817,15 @@ declare interface SheetOptions extends BindOptions { showClose?: boolean | Resource; /** - * Type of the sheet. - *
**NOTE**
The types supported by the sheet vary by window. - *
1. Width < 600 vp: bottom. - *
2. 600 vp <= Width: bottom, center, and popup (default). - *
3. Width >= 840 vp: bottom, center, and popup (default). + * Defines the sheet prefer type * * @type { ?(SheetType.CENTER | SheetType.POPUP) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 */ - /** - * Type of the sheet. - *
**NOTE**
The types supported by the sheet vary by window. - *
1. Width < 600 vp: bottom. - *
2. 600 vp <= Width: bottom, center, and popup (default). - *
3. Width >= 840 vp: bottom, center, and popup (default). + /** + * Defines the sheet prefer type * * @type { ?SheetType } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15346,7 +14836,7 @@ declare interface SheetOptions extends BindOptions { preferType?: SheetType; /** - * Title of the sheet. + * Defines the sheet title * * @type { ?(SheetTitleOptions | CustomBuilder) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15354,7 +14844,7 @@ declare interface SheetOptions extends BindOptions { * @since 11 */ /** - * Title of the sheet. + * Defines the sheet title * * @type { ?(SheetTitleOptions | CustomBuilder) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15365,12 +14855,7 @@ declare interface SheetOptions extends BindOptions { title?: SheetTitleOptions | CustomBuilder; /** - * Callback invoked when the user performs an interactive dismiss operation: pulling down or clicking - * the back button, the mask, or the close icon.
**NOTE**
If this callback is registered, the - * sheet is not dismissed immediately when the user performs the above operations. To dismiss the sheet, - * you must call **shouldDismiss.dismiss()** in the callback.
If this callback is not registered, the - * sheet is dismissed immediately when the user performs the above operations, without any additional - * behavior.
It is recommended that this API be used in scenarios where a secondary confirmation is required. + * Callback function when the sheet interactive dismiss * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15378,12 +14863,7 @@ declare interface SheetOptions extends BindOptions { * @since 11 */ /** - * Callback invoked when the user performs an interactive dismiss operation: pulling down or clicking - * the back button, the mask, or the close icon.
**NOTE**
If this callback is registered, the - * sheet is not dismissed immediately when the user performs the above operations. To dismiss the sheet, - * you must call **shouldDismiss.dismiss()** in the callback.
If this callback is not registered, the - * sheet is dismissed immediately when the user performs the above operations, without any additional - * behavior.
It is recommended that this API be used in scenarios where a secondary confirmation is required. + * Callback function when the sheet interactive dismiss * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15394,18 +14874,7 @@ declare interface SheetOptions extends BindOptions { shouldDismiss?: (sheetDismiss: SheetDismiss) => void; /** - * Callback invoked when the user performs an interactive dismiss operation: - * pulling down or clicking the back button, the mask, or the close icon, - * to obtain the type of dismiss operation and decide whether to dismiss the sheet. - *

**NOTE**: - *
If this callback is registered, the sheet is not dismissed immediately when the user performs the above - * operations. - *
Instead, you can use the DismissSheetAction parameter in the callback to determine the type of - * dismiss operation and decide whether to dismiss the sheet. - *
If this callback is not registered, the sheet is dismissed immediately when the user performs the above - * operations, without any additional behavior. - *
No further interception with onWillDismiss is allowed in an onWillDismiss callback. - *

+ * Callback function when the sheet will dismiss * * @type { ?Callback } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15415,17 +14884,9 @@ declare interface SheetOptions extends BindOptions { */ onWillDismiss?: Callback; - /** - * Callback invoked when the user performs a pull-down-to-dismiss gesture, to control the bounce effect. - *

**NOTE**: - *
If this callback is registered along with **shouldDismiss** or **onWillDismiss** you can control whether the - * sheet bounces back during the pull-down-to-dismiss operation by calling **springBack** in the callback. - *
If this callback is not registered but **shouldDismiss** or **onWillDismiss** is registered, the sheet will - * bounce back before remaining open or being dismissed based on the callback behavior. - *
If neither this callback nor **shouldDismiss** or **onWillDismiss** is registered, the sheet is dismissed by - * default during the pull-down-to-dismiss operation. - *

- * + /** + * Sheet springs back callback when dismiss + * * @type { ?Callback } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -15435,12 +14896,7 @@ declare interface SheetOptions extends BindOptions { onWillSpringBackWhenDismiss?: Callback; /** - * Whether to allow users to interact with the page pertaining to the sheet. - *
**NOTE**
The value **true** means that interactions are allowed, in which - * case no mask is not displayed. The value **false** means that interactions are not - * allowed, in which case a mask is displayed. If this parameter is not set, interactions - * are allowed for the popup sheet, but not for bottom and center sheets. If this parameter - * is set to **true**, the setting of **maskColor** does not take effect. + * Set whether interaction is allowed outside the sheet * * @type { ?boolean } * @default false @@ -15449,12 +14905,7 @@ declare interface SheetOptions extends BindOptions { * @since 11 */ /** - * Whether to allow users to interact with the page pertaining to the sheet. - *
**NOTE**
The value **true** means that interactions are allowed, in which - * case no mask is not displayed. The value **false** means that interactions are not - * allowed, in which case a mask is displayed. If this parameter is not set, interactions - * are allowed for the popup sheet, but not for bottom and center sheets. If this parameter - * is set to **true**, the setting of **maskColor** does not take effect. + * Set whether interaction is allowed outside the sheet * * @type { ?boolean } * @default false @@ -15466,8 +14917,7 @@ declare interface SheetOptions extends BindOptions { enableOutsideInteractive?: boolean; /** - * Width of the sheet. - * Percentage parameter method: Set the width of the sheet as a percentage of the width of the parent element. + * Defines the sheet's width. * * @type { ?Dimension } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15478,16 +14928,7 @@ declare interface SheetOptions extends BindOptions { width?: Dimension; /** - * Border width of the sheet. - * You can set the width for all four sides or set separate widths for individual sides. - * Default value: **0**. - * Percentage parameter method: - * Set the border width of the sheet as a percentage of the width of the parent element. - * If the left and right border widths of the sheet are greater than the width of the sheet, and the top - * and bottom border widths are greater than the height of the sheet, the display may not appear as expected. - *

**Note**: - *
For bottom sheets, the bottom border width setting is ineffective. - *

+ * Defines the sheet's border width. * * @type { ?(Dimension | EdgeWidths | LocalizedEdgeWidths) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15498,14 +14939,9 @@ declare interface SheetOptions extends BindOptions { borderWidth?: Dimension | EdgeWidths | LocalizedEdgeWidths; /** - * Border color of the sheet. - * **borderColor** must be used with **borderWidth** in pairs. - *

**NOTE**: - *
For bottom sheets, the bottom border color setting is ineffective. - *

- * + * Defines the sheet's border color. + * * @type { ?(ResourceColor | EdgeColors | LocalizedEdgeColors) } - * @default Color.Black * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -15525,8 +14961,7 @@ declare interface SheetOptions extends BindOptions { borderStyle?: BorderStyle | EdgeStyles; /** - * Shadow of the sheet. - * Default value for 2-in-1 devices: **ShadowStyle.OUTER_FLOATING_SM**. + * Defines the sheet's shadow. * * @type { ?(ShadowOptions | ShadowStyle) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15537,14 +14972,7 @@ declare interface SheetOptions extends BindOptions { shadow?: ShadowOptions | ShadowStyle; /** - * Callback for changes in the height of the sheet. - *

**Note**: - *
For a bottom sheet, the height of each frame is only returned when there are changes in detents or during drag - * actions. - *
When the sheet is pulled up or making space for the soft keyboard, only the final height is returned. - *
For other types of sheets, the final height is only returned when the sheet is pulled up. - *
The return value is in px. - *

+ * Called when height of the sheet is changed * * @type { ?Callback } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -15555,7 +14983,7 @@ declare interface SheetOptions extends BindOptions { onHeightDidChange?: Callback; /** - * Determine the level sheet shows, whether sheet should be displayed within the page. + * Determine the level sheet shows, whether sheet should be displayed within the page * * @type { ?SheetMode } * @default SheetMode.OVERLAY @@ -15567,7 +14995,7 @@ declare interface SheetOptions extends BindOptions { mode?: SheetMode; /** - * Content update mode of the sheet when it is scrolled. + * Determine sheet scroll size mode. * * @type { ?ScrollSizeMode } * @default ScrollSizeMode.FELLOW_DETEND @@ -15576,16 +15004,12 @@ declare interface SheetOptions extends BindOptions { * @atomicservice * @since 12 */ - scrollSizeMode?: ScrollSizeMode; + scrollSizeMode?: ScrollSizeMode; /** - * Callback for changes in the detents of the sheet. - *

**NOTE**: - *
For a bottom sheet, the final height is returned when there are changes in detents. - *
The return value is in px. - *

+ * Called when detents of the sheet changed + * * @type { ?Callback } - * @default false * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -15670,23 +15094,23 @@ declare interface SheetOptions extends BindOptions { * @systemapi * @since 14 */ - offset?: Position + offset?: Position; - /** - * Sets whether the sheet edge has spring effect. - * - * @type { ?number } - * @default 3 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - effectEdge?: number + /** + * Sets whether the sheet edge has spring effect. + * + * @type { ?number } + * @default 3 + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ + effectEdge?: number; /** * Defines sheet radius - * + * * @type { ?(LengthMetrics | BorderRadiuses | LocalizedBorderRadiuses) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -15735,7 +15159,7 @@ declare interface SheetOptions extends BindOptions { /** * placement On target node * - * @type { ?boolean } + * @type { ?boolean } * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -16048,61 +15472,58 @@ declare interface PopupMessageOptions { * @atomicservice * @since 12 */ -declare enum DismissReason { +declare enum DismissReason { /** - * Touching the Back button, swiping left or right on the screen, or pressing the Esc key. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ + * Press back + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ PRESS_BACK = 0, /** - * Touching the mask. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ + * Touch component outside + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ TOUCH_OUTSIDE = 1, /** - * Touching the Close button. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ + * Close button + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ CLOSE_BUTTON = 2, /** - * Slide down - *

NOTE: - *
This API is effective only in sheet transition. - *

- * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ + * Slide down + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ SLIDE_DOWN = 3, /** - * Slide, not slide down. - * Default means slide right, after mirroring it means slide left. - * Choosing to slide left or slide right is not supported. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - SLIDE = 4, + * Slide, not slide down. + * Default means slide right, after mirroring it means slide left. + * Choosing to slide left or slide right is not supported. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + SLIDE = 4 } /** @@ -16290,7 +15711,7 @@ declare interface PopupCommonOptions { /** * on State Change * - * @type { ?function } + * @type { ?PopupStateChangeCallback } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -16469,7 +15890,7 @@ declare interface PopupCommonOptions { * @crossplatform * @atomicservice * @since 18 - */ + */ onWillDismiss?: boolean | Callback; /** @@ -16516,7 +15937,7 @@ declare interface PopupCommonOptions { * @crossplatform * @atomicservice * @since 20 - */ + */ outlineWidth?: Dimension; /** @@ -16708,7 +16129,7 @@ declare interface PopupOptions { * @since 10 */ /** - * Content of the popup message. + * Information in the pop-up window. * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -17037,7 +16458,7 @@ declare interface PopupOptions { * @since 10 */ /** - * Parameters of the popup message. + * Sets the options of popup message. * * @type { ?PopupMessageOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -17045,7 +16466,7 @@ declare interface PopupOptions { * @atomicservice * @since 11 */ - messageOptions?: PopupMessageOptions + messageOptions?: PopupMessageOptions; /** * Sets the space of between the popup and target. @@ -17064,7 +16485,7 @@ declare interface PopupOptions { * @atomicservice * @since 11 */ - targetSpace?: Length + targetSpace?: Length; /** * whether show arrow @@ -17102,7 +16523,7 @@ declare interface PopupOptions { * @atomicservice * @since 11 */ - offset?: Position + offset?: Position; /** * Set the background color of the popup. @@ -17182,7 +16603,7 @@ declare interface PopupOptions { */ arrowPointPosition?: ArrowPointPosition; - /** + /** * The width of the arrow. * * @type { ?Dimension } @@ -17308,7 +16729,7 @@ declare interface PopupOptions { * @since 12 */ onWillDismiss?: boolean | Callback; - + /** * Determine if it is compatible popup's half folded. * @@ -17365,7 +16786,7 @@ declare interface PopupOptions { * @crossplatform * @atomicservice * @since 20 - */ + */ outlineWidth?: Dimension; /** @@ -17378,7 +16799,7 @@ declare interface PopupOptions { * @since 20 */ borderWidth?: Dimension; - + /** * The LinearGradient of popup's outline. * @@ -17443,15 +16864,7 @@ declare interface CustomPopupOptions { * @since 10 */ /** - * Popup builder. - *

NOTE: - *
The popup attribute is a universal attribute. A custom popup does not support display of another popup. - *
The position attribute cannot be used for the first-layer container in the builder. - *
If the position attribute is used, the popup will not be displayed. - *
If a custom component is used in the builder, the aboutToAppear and aboutToDisappear lifecycle callbacks - * of the custom component are irrelevant to the visibility of the popup. As such, the lifecycle of the - * custom component cannot be used to determine whether the popup is displayed or not. - *

+ * builder of popup * * @type { CustomBuilder } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -17477,11 +16890,9 @@ declare interface CustomPopupOptions { * @since 10 */ /** - * Preferred position of the popup. If the set position is insufficient for holding the popup, - * it will be automatically adjusted. + * placement of popup * * @type { ?Placement } - * @default Placement.Bottom * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -17511,16 +16922,14 @@ declare interface CustomPopupOptions { * background color of popup * * @type { ?(Color | string | Resource | number) } - * @default '#4d4d4d' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Color of the popup. To remove the background blur, set backgroundBlurStyle to BlurStyle.NONE. + * background color of popup * * @type { ?(Color | string | Resource | number) } - * @default TRANSPARENT plus COMPONENT_ULTRA_THICK * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -17547,7 +16956,6 @@ declare interface CustomPopupOptions { * whether show arrow * * @type { ?boolean } - * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -17571,15 +16979,9 @@ declare interface CustomPopupOptions { * @since 10 */ /** - * Whether to automatically dismiss the popup when an operation is performed on the page. - *

NOTE: - *
To enable the popup to disappear upon a click on it, place a layout component in the builder place the - * component in the layout component, and modify the value of the bindPopup variable (show: boolean) - * in the onClick event of the layout component. - *

+ * whether hide popup when click mask * * @type { ?boolean } - * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -17603,7 +17005,7 @@ declare interface CustomPopupOptions { * @since 10 */ /** - * Callback for the popup status change event. + * on State Change * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -17650,13 +17052,6 @@ declare interface CustomPopupOptions { /** * The offset of the sharp corner of popup. * - * Offset of the popup arrow relative to the popup. When the arrow is at the top or bottom of the popup: - *
The value 0 indicates that the arrow is located on the leftmost, and any other value indicates the distance - * from the arrow to the leftmost; the arrow is centered by default. When the arrow is on the left or right - * side of the popup: The value indicates the distance from the arrow to the top; the arrow is centered by - * default. When the popup is displayed on either edge of the screen, it will automatically deviate leftward - * or rightward to stay within the safe area. When the value is 0, the arrow always points to the bound component. - * * @type { ?Length } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -17684,7 +17079,6 @@ declare interface CustomPopupOptions { * Whether to display in the sub window. * * @type { ?boolean } - * @default false * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -17703,9 +17097,9 @@ declare interface CustomPopupOptions { * @since 10 */ /** - * Whether to apply a mask to the popup. - *
The value true means to apply a transparent mask to the popup, false means not to apply a mask to the popup, - * and a color value means to apply a mask in the corresponding color to the popup. + * The mask to block gesture events of popup. + * When mask is set false, gesture events are not blocked. + * When mask is set true, gesture events are blocked and mask color is transparent. * * @type { ?(boolean | { color: ResourceColor }) } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -17732,7 +17126,7 @@ declare interface CustomPopupOptions { * @atomicservice * @since 11 */ - targetSpace?: Length + targetSpace?: Length; /** * Sets the position offset of the popup. @@ -17751,7 +17145,7 @@ declare interface CustomPopupOptions { * @atomicservice * @since 11 */ - offset?: Position + offset?: Position; /** * Set the width of the popup. @@ -17762,7 +17156,7 @@ declare interface CustomPopupOptions { * @since 11 */ /** - * Width of the popup. + * Set the width of the popup. * * @type { ?Dimension } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -17781,8 +17175,7 @@ declare interface CustomPopupOptions { * @since 11 */ /** - * Position of the popup arrow relative to its parent component. Available positions are Start, Center, and End, - * in both vertical and horizontal directions. All these positions are within the parent component area. + * The position of the sharp corner of popup. * * @type { ?ArrowPointPosition } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -17802,15 +17195,10 @@ declare interface CustomPopupOptions { * @since 11 */ /** - * Arrow thickness. If the arrow thickness exceeds the length of the edge minus twice the size of the popup - * rounded corner, the arrow is not drawn. + * The width of the arrow. * * @type { ?Dimension } * @default 16.0_vp. - *

NOTE: - *
This parameter cannot be set in percentage. - *

- * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -17832,10 +17220,6 @@ declare interface CustomPopupOptions { * * @type { ?Dimension } * @default 8.0_vp. - *

NOTE: - *
This parameter cannot be set in percentage. - *

- * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -17853,7 +17237,7 @@ declare interface CustomPopupOptions { * @since 11 */ /** - * Rounded corner radius of the popup. + * The round corners of the popup. * * @type { ?Dimension } * @default 20.0_vp. @@ -17874,7 +17258,7 @@ declare interface CustomPopupOptions { * @since 11 */ /** - * Popup shadow. + * The style of popup Shadow. * * @type { ?(ShadowOptions | ShadowStyle) } * @default ShadowStyle.OUTER_DEFAULT_MD. @@ -17895,7 +17279,7 @@ declare interface CustomPopupOptions { * @since 11 */ /** - * Background blur style of the popup. + * Defines popup background blur Style * * @type { ?BlurStyle } * @default BlurStyle.COMPONENT_ULTRA_THICK @@ -17939,27 +17323,17 @@ declare interface CustomPopupOptions { transition?: TransitionEffect; /** - * Whether to perform dismissal event interception and interception callback. - * 1. If this parameter is set to false, the system does not respond to the dismissal event initiated by - * touching the Back button, swiping left or right on the screen, or pressing the Esc key; and the system - * dismisses the popup only when show is set to false. If this parameter is set to true, the system responds - * to the dismissal event as expected. - * 2. If this parameter is set to a function, the dismissal event is intercepted and the callback function - * is executed. - *

NOTE: - *
No more onWillDismiss callback is allowed in an onWillDismiss callback. - *

+ * Callback function when the popup interactive dismiss * * @type { ?(boolean | Callback) } - * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 - */ + */ onWillDismiss?: boolean | Callback; - /** + /** * Determine if it is compatible popup's half folded. * * @type { ?boolean } @@ -18015,7 +17389,7 @@ declare interface CustomPopupOptions { * @crossplatform * @atomicservice * @since 20 - */ + */ outlineWidth?: Dimension; /** @@ -18028,7 +17402,7 @@ declare interface CustomPopupOptions { * @since 20 */ borderWidth?: Dimension; - + /** * The LinearGradient of popup's outline. * @@ -18094,7 +17468,7 @@ declare enum MenuPreviewMode { * @since 11 */ /** - * The preview is a screenshot of the component on which a long-press triggers the context menu. + * Defines image type preview content. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -18183,12 +17557,11 @@ interface ContextMenuAnimationOptions { * @since 12 */ hoverScale?: AnimationRange; - + /** * Sets whether support to interrupt the process of hover scale. * * @type { ?boolean } - * @default false * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -18198,14 +17571,14 @@ interface ContextMenuAnimationOptions { } /** - * Defines the type of border radius. - * - * @typedef { Length | BorderRadiuses | LocalizedBorderRadiuses } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 19 - */ + * Defines the type of border radius. + * + * @typedef { Length | BorderRadiuses | LocalizedBorderRadiuses } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 19 + */ type BorderRadiusType = Length | BorderRadiuses | LocalizedBorderRadiuses; /** @@ -18237,54 +17610,137 @@ declare enum HapticFeedbackMode { */ ENABLED = 1, /** - * Defines menu automatically haptic feedback. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - AUTO = 2 + * Defines menu automatically haptic feedback. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ + AUTO = 2 +} + +/** + * Define the modal mode of menu. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ +declare enum ModalMode { + /** + * Modal modal automatically. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + AUTO = 0, + /** + * Operation takes effect around menu. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + NONE = 1, + /** + * Operation takes no effect around menu in target window. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + TARGET_WINDOW = 2 +} + +/** + * Enum for accessibility action type + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ +declare enum AccessibilityAction { + /** + * undefined action type + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ + UNDEFINED_ACTION = 0, + /** + * accessibility click action + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ + ACCESSIBILITY_CLICK = 1, +} + +/** + * Enum for the result of accessibility action intercept function + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ +declare enum AccessibilityActionInterceptResult { + /** + * intercept the accessibility action + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ + ACTION_INTERCEPT = 0, + /** + * the accessibility action can be continued + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ + ACTION_CONTINUE = 1, + /** + * the accessibility action need to bubble up for execution + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ + ACTION_RISE = 2, } /** - * Define the modal mode of menu. - * - * @enum { number } + * Defines the callback type used in accessibility action intercept. + * The value of action indicates the accessibility action type. + * @typedef { function } AccessibilityActionInterceptCallback + * @param { AccessibilityAction } action - the enum of accessibility action type. + * @returns { AccessibilityActionInterceptResult } the result of continuing to execute the action or interrupting it or bubbling up * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform + * @form * @atomicservice * @since 20 */ -declare enum ModalMode { - /** - * Modal modal automatically. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - AUTO = 0, - /** - * Operation takes effect around menu. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - NONE = 1, - /** - * Operation takes no effect around menu in target window. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - TARGET_WINDOW = 2 -} +declare type AccessibilityActionInterceptCallback = (action: AccessibilityAction) => AccessibilityActionInterceptResult; /** * Menu mask type @@ -18410,26 +17866,10 @@ declare interface ContextMenuOptions { * @since 10 */ /** - * Offset for showing the context menu, which should not cause the menu to extend beyond the screen. - *

NOTE: - *
When the menu is displayed relative to the parent component area, the width or height of the area is - * automatically counted into the offset based on the placement attribute of the menu. When the menu is - * displayed above the parent component (that is, placement is set to Placement.TopLeft, Placement.Top, or - * Placement.TopRight), a positive value of x indicates rightward movement relative to the parent component, - * and a positive value of y indicates upward movement. When the menu is displayed below the parent component - * (that is, placement is set to Placement.BottomLeft, Placement.Bottom, or Placement.BottomRight), a positive - * value of x indicates rightward movement relative to the parent component, and a positive value of y indicates - * downward movement. When the menu is displayed on the left of the parent component (that is, placement is set - * to Placement.LeftTop, Placement.Left, or Placement.LeftBottom), a positive value of x indicates leftward - * movement relative to the parent component, and a positive value of y indicates downward movement. When the - * menu is displayed on the right of the parent component (that is, placement is set to Placement.RightTop, - * Placement.Right, or Placement.RightBottom), a positive value of x indicates rightward movement relative to - * the parent component, and a positive value of y indicates downward movement. If the display position of the - * menu is adjusted (different from the main direction of the initial placement value), the offset value is invalid. - *

+ * Sets the position offset of the context menu window. * * @type { ?Position } - * @default {x:0,y:0} - Percentage values are not supported. + * @default - * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -18447,15 +17887,10 @@ declare interface ContextMenuOptions { * @since 10 */ /** - * Preferred position of the context menu. If the set position is insufficient for holding the component, it will be - * automatically adjusted. - *

NOTE: - *
If a menu is displayed by pressing and holding or right-clicking, the menu is displayed at the clicked - * position. - *

+ * Sets the placement of the context menu window. * * @type { ?Placement } - * @default Placement.BottomLeft + * @default - * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -18464,7 +17899,7 @@ declare interface ContextMenuOptions { placement?: Placement; /** - * whether show arrow belong to the menu. + * whether show arrow belong to the menu, default: false, not show arrow * * @type { ?boolean } * @default false @@ -18472,14 +17907,7 @@ declare interface ContextMenuOptions { * @since 10 */ /** - * whether show arrow belong to the menu. - *

NOTE: - *
When enableArrow is true, an arrow is displayed in the position specified by placement. - *
If placement is not set or its value is invalid, the arrow is displayed above the target. - *
If the position is insufficient for holding the arrow, it is automatically adjusted. - *
When enableArrow is undefined, no arrow is displayed. - *
This API is supported in bindContextMenu since API version 10 and bindMenu since API version 12. - *

+ * whether show arrow belong to the menu, default: false, not show arrow * * @type { ?boolean } * @default false @@ -18494,46 +17922,25 @@ declare interface ContextMenuOptions { * The horizontal offset to the left of menu or vertical offset to the top of menu * * @type { ?Length } - * @default 0vp + * @default 0 * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 */ /** - * Offset of the arrow relative to the context menu. The offset settings take effect only when the value is valid, - * can be converted to a number greater than 0, and does not cause the arrow to extend beyond the safe area of - * the context menu. - *

NOTE: - *
The safe distance of the arrow from the four sides of the menu is the sum of the menu's corner radius and - * half the width of the arrow. The value of placement determines whether the offset is horizontal or vertical. - * When the arrow is in the horizontal direction of the menu, the offset is the distance from the arrow to the - * leftmost arrow's safe distance. When the arrow is in the vertical direction of the menu, the offset is the - * distance from the arrow to the topmost arrow's safe distance. The default position where the arrow is - * displayed varies with the value of placement: Without any avoidance by the menu, when placement is set to - * Placement.Top or Placement.Bottom, the arrow is displayed horizontally and is centered by default; when - * placement is set to Placement.Left or Placement.Right, the arrow is displayed vertically and is centered by - * default; when placement is set to Placement.TopLeft or Placement.BottomLeft, the arrow is displayed - * horizontally by default, and the distance from the arrow to the left edge of the menu is the arrow's safe - * distance; when placement is set to Placement.TopRight or Placement.BottomRight, the arrow is displayed - * horizontally by default, and the distance from the arrow to the right edge of the menu is the arrow's safe - * distance; when placement is set to Placement.LeftTop or Placement.RightTop, the arrow is displayed vertically - * by default, and the distance from the arrow to the top edge of the menu is the arrow's safe distance; when - * placement is set to Placement.LeftBottom or Placement.RightBottom, the arrow is displayed vertically by - * default, and the distance from the arrow to the bottom edge of the menu is the arrow's safe distance. - *
This API is supported in bindContextMenu since API version 10 and bindMenu since API version 12. - *

+ * The horizontal offset to the left of menu or vertical offset to the top of menu * * @type { ?Length } - * @default 0vp + * @default 0 * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ arrowOffset?: Length; - + /** * The preview content of context menu. - * + * * @type { ?(MenuPreviewMode | CustomBuilder) } * @default MenuPreviewMode.NONE * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -18541,14 +17948,7 @@ declare interface ContextMenuOptions { * @since 11 */ /** - * Preview displayed when the context menu is triggered by a long-press or use the isShown variable of - * bindContextMenu to display the preview content style of the menu. - *

NOTE: - *
This parameter has no effect when responseType is set to ResponseType.RightClick. - *
If preview is set to MenuPreviewMode.NONE or is not set, the enableArrow parameter is effective. - *
If preview is set to MenuPreviewMode.IMAGE or CustomBuilder, no arrow will be displayed even when - * enableArrow is true. - *

+ * The preview content of context menu. * * @type { ?(MenuPreviewMode | CustomBuilder) } * @default MenuPreviewMode.NONE @@ -18571,16 +17971,9 @@ declare interface ContextMenuOptions { previewBorderRadius?: BorderRadiusType; /** - * Border radius of the menu. - *

NOTE: - *
The value can be in percentage. - *
If the sum of the two maximum corner radii in the horizontal direction exceeds the menu's width, or if the sum - * of the two maximum corner radii in the vertical direction exceeds the menu's height, the default corner radius of - * the menu will be used. - *

+ * Defines the border radius of menu. * * @type { ?(Length | BorderRadiuses | LocalizedBorderRadiuses) } - * @default 8vp for 2-in-1 devices and 20vp for other devices * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -18597,7 +17990,7 @@ declare interface ContextMenuOptions { * @since 10 */ /** - * Callback triggered when the menu is displayed. + * Callback function when the context menu appears. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -18608,7 +18001,7 @@ declare interface ContextMenuOptions { onAppear?: () => void; /** - * Callback triggered when the menu is hidden. + * Callback function when the context menu disappear. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -18635,7 +18028,7 @@ declare interface ContextMenuOptions { * @since 11 */ /** - * Callback triggered when the menu is about to appear. + * Callback function before the context menu animation starts. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -18654,7 +18047,7 @@ declare interface ContextMenuOptions { * @since 11 */ /** - * Callback triggered when the menu is about to disappear. + * Callback function before the context menu popAnimation starts. * * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -18663,7 +18056,7 @@ declare interface ContextMenuOptions { * @since 12 */ aboutToDisappear?: () => void; - + /** * The margin of menu's layoutRegion. * @@ -18674,7 +18067,7 @@ declare interface ContextMenuOptions { * @since 13 */ layoutRegionMargin?: Margin; - + /** * The preview animator options. * @@ -18704,7 +18097,7 @@ declare interface ContextMenuOptions { * @since 11 */ /** - * Background color of the menu. + * Defines the menu's background color * * @type { ?ResourceColor } * @default Color.Transparent @@ -18725,7 +18118,7 @@ declare interface ContextMenuOptions { * @since 11 */ /** - * Background blur style of the menu. + * Defines menu background blur Style * * @type { ?BlurStyle } * @default BlurStyle.COMPONENT_ULTRA_THICK @@ -18770,15 +18163,15 @@ declare interface ContextMenuOptions { transition?: TransitionEffect; /** - * Determine if it is compatible menu's half folded. - * - * @type { ?boolean } - * @default false - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ + * Determine if it is compatible menu's half folded. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ enableHoverMode?: boolean; /** @@ -18793,14 +18186,14 @@ declare interface ContextMenuOptions { outlineColor?: ResourceColor | EdgeColors; /** - * The width of menu's outer border. - * - * @type { ?(Dimension | EdgeOutlineWidths) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ + * The width of menu's outer border. + * + * @type { ?(Dimension | EdgeOutlineWidths) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ outlineWidth?: Dimension | EdgeOutlineWidths; /** @@ -18968,7 +18361,6 @@ declare interface MenuOptions extends ContextMenuOptions { * Whether to display in the sub window. * * @type { ?boolean } - * @default true for 2-in-1 devices and false for other devices * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -18985,7 +18377,7 @@ declare interface MenuOptions extends ContextMenuOptions { * @since 10 */ /** - * Implements a ProgressMask object to set the progress, maximum value, and color of the mask. + * Defines the ProgressMask class. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19006,9 +18398,9 @@ declare class ProgressMask { /** * constructor. * - * @param { number } value - Current value of the progress mask. Value range: [0.0, +∞). - * @param { number } total - Maximum value of the progress mask. Value range: [0.0, +∞). - * @param { ResourceColor } color - Color of the progress mask. + * @param { number } value - indicates the current value of the progress. + * @param { number } total - indicates the total value of the progress. + * @param { ResourceColor } color - indicates the color of the mask. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -19025,9 +18417,9 @@ declare class ProgressMask { * @since 10 */ /** - * Updates the progress value of the progress mask. + * Update the current value of the progress. * - * @param { number } value - Current value of the progress mask. + * @param { number } value - indicates the current value of the progress. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -19046,14 +18438,14 @@ declare class ProgressMask { /** * Update the color of the mask. * - * @param { ResourceColor } value - Color of the progress mask. + * @param { ResourceColor } value - indicates the color of the mask. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ updateColor(value: ResourceColor): void; - + /** * Enable the breathe animation of mask. * @@ -19451,14 +18843,7 @@ declare interface ClickEffect { /** * Set scale number. * This default scale is same as the scale of click effect level. - * - *

NOTE: - *
This parameter works based on the setting of ClickEffectLevel. - *
If level is set to ClickEffectLevel.LIGHT, the default value is 0.90. - *
If level is set to ClickEffectLevel.MIDDLE or ClickEffectLevel.HEAVY, the default value is 0.95. - *
If level is set to undefined or null (both of which evaluate to ClickEffectLevel.LIGHT), the default value is 0.90. - *
If scale is set to undefined or null, the default zoom ratio for the set level will be used. - *

+ * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -19684,7 +19069,7 @@ declare interface MenuElement { /** * Defines the attribute modifier. - * + * * @interface AttributeModifier * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19692,7 +19077,7 @@ declare interface MenuElement { */ /** * Defines the attribute modifier. - * + * * @interface AttributeModifier * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19703,7 +19088,7 @@ declare interface AttributeModifier { /** * Defines the normal update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19711,7 +19096,7 @@ declare interface AttributeModifier { */ /** * Defines the normal update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19722,7 +19107,7 @@ declare interface AttributeModifier { /** * Defines the pressed update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19730,7 +19115,7 @@ declare interface AttributeModifier { */ /** * Defines the pressed update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19741,7 +19126,7 @@ declare interface AttributeModifier { /** * Defines the focused update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19749,7 +19134,7 @@ declare interface AttributeModifier { */ /** * Defines the focused update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19760,7 +19145,7 @@ declare interface AttributeModifier { /** * Defines the disabled update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19768,7 +19153,7 @@ declare interface AttributeModifier { */ /** * Defines the disabled update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19779,7 +19164,7 @@ declare interface AttributeModifier { /** * Defines the selected update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19787,7 +19172,7 @@ declare interface AttributeModifier { */ /** * Defines the selected update attribute function. - * + * * @param { T } instance * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19799,7 +19184,7 @@ declare interface AttributeModifier { /** * Defines the content modifier. - * + * * @interface ContentModifier * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19810,22 +19195,19 @@ declare interface ContentModifier { /** * Defining applyContent function. - * + * * @returns { WrappedBuilder<[T]> } - * Component attribute class, which is used to distinguish different information required by different components - * after content areas are customized, for example, ButtonConfiguration for the Button component and - * CheckBoxConfiguration of the Checkbox component. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - applyContent(): WrappedBuilder<[T]> + applyContent(): WrappedBuilder<[T]>; } /** * Defines the common configuration. - * + * * @interface CommonConfiguration * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19833,7 +19215,7 @@ declare interface ContentModifier { * @since 12 */ declare interface CommonConfiguration { - + /** * If the value is true, the contentModifier is available and can respond to operations such as triggerChange. * If it is set to false, triggerChange operations are not responded. @@ -19848,14 +19230,14 @@ declare interface CommonConfiguration { /** * Obtains the contentModifier instance object - * + * * @type { ContentModifier } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - contentModifier: ContentModifier + contentModifier: ContentModifier; } /** @@ -19879,7 +19261,7 @@ declare interface CommonConfiguration { */ declare enum OutlineStyle { /** - * Solid border. + * Shows as a solid line. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19887,7 +19269,7 @@ declare enum OutlineStyle { * @since 11 */ /** - * Solid border. + * Shows as a solid line. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19898,7 +19280,7 @@ declare enum OutlineStyle { SOLID = 0, /** - * Dashed border. + * Shows as a series of short square dashed lines. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19906,7 +19288,7 @@ declare enum OutlineStyle { * @since 11 */ /** - * Dashed border. + * Shows as a series of short square dashed lines. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19925,7 +19307,7 @@ declare enum OutlineStyle { * @since 11 */ /** - * Dotted border. The radius of a dot is half of **outlineWidth**. + * Displays as a series of dots with a radius of half the borderWidth. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -19933,7 +19315,7 @@ declare enum OutlineStyle { * @atomicservice * @since 12 */ - DOTTED = 2, + DOTTED = 2 } /** @@ -20053,6 +19435,7 @@ declare enum DragPreviewMode { * @since 18 */ ENABLE_MULTI_TILE_EFFECT = 6, + /** * Enable the touch point calculation position based on final preview rect. * @@ -20121,7 +19504,7 @@ declare enum MenuPolicy { DEFAULT = 0, /** - * The menu is always hidden. + * Hide pop up menu. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20131,14 +19514,14 @@ declare enum MenuPolicy { HIDE = 1, /** - * The menu is always displayed. + * Show pop up menu. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - SHOW = 2, + SHOW = 2 } /** @@ -20197,80 +19580,77 @@ declare type SymbolGlyphModifier = import('../api/arkui/SymbolGlyphModifier').Sy */ declare interface DragPreviewOptions { /** - * Drag preview mode. - * - * @type { ?DragPreviewMode } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Drag preview mode. - * - * @type { ?(DragPreviewMode | Array) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - /** - * Drag preview mode. - * - * @type { ?(DragPreviewMode | Array) } - * @default DragPreviewMode.AUTO - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ + * Drag preview mode. + * + * @type { ?DragPreviewMode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 11 + */ + /** + * Drag preview mode. + * + * @type { ?(DragPreviewMode | Array) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 12 + */ + /** + * Drag preview mode. + * + * @type { ?(DragPreviewMode | Array) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ mode?: DragPreviewMode | Array; /** - * Drag preview modifier. - * - * @type { ?ImageModifier } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - /** - * Drag preview modifier. - * - * @type { ?ImageModifier } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ + * Drag preview modifier. + * + * @type { ?ImageModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 12 + */ + /** + * Drag preview modifier. + * + * @type { ?ImageModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ modifier?: ImageModifier; /** - * The flag for number showing. - * - * @type { ?(boolean | number) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - /** - * The flag for number showing. - * - * @type { ?(boolean | number) } - * @default true - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ + * The flag for number showing. + * + * @type { ?(boolean | number) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 12 + */ + /** + * The flag for number showing. + * + * @type { ?(boolean | number) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ numberBadge?: boolean | number; /** - * Drag start animation effect from drag preview to the handle drag image. - * - * @type { ?DraggingSizeChangeEffect } - * @default DraggingSizeChangeEffect.DEFAULT - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 19 - */ + * Drag start animation effect from drag preview to the handle drag image. + * + * @type { ?DraggingSizeChangeEffect } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 19 + */ sizeChangeEffect?: DraggingSizeChangeEffect; } @@ -20284,58 +19664,54 @@ declare interface DragPreviewOptions { */ declare interface DragInteractionOptions { /** - * Define whether to gather selected nodes in grid or list. - * - * @type { ?boolean } - * @default false - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ + * Define whether to gather selected nodes in grid or list. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 12 + */ isMultiSelectionEnabled?: boolean; - + /** - * Define whether to execute animation before preview floating. - * - * @type { ?boolean } - * @default false - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ + * Define whether to execute animation before preview floating. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 12 + */ defaultAnimationBeforeLifting?: boolean; /** - * Config if auto scrolling should be triggered when the drag hovered on a scrollable controller's edge. - * - * @type { ?boolean } - * @default true - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 18 - */ + * Config if auto scrolling should be triggered when the drag hovered on a scrollable controller's edge. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 18 + */ enableEdgeAutoScroll?: boolean; /** - * Define whether to enable the haptic feedback when dragging, the default value is false. - * - * @type { ?boolean } - * @default false - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 18 - */ + * Define whether to enable the haptic feedback when dragging, the default value is false. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 18 + */ enableHapticFeedback?: boolean; /** - * Define whether to lifting trigger drag by finger. - * - * @type { ?boolean } - * @default false - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 15 - */ + * Define whether to lifting trigger drag by finger. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 15 + */ isLiftingDisabled?: boolean; } @@ -20349,25 +19725,25 @@ declare interface DragInteractionOptions { */ declare interface PreviewConfiguration { /** - * Define whether to only use for lifting. - * - * @type { ?boolean } - * @default false - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 15 - */ + * Define whether to only use for lifting. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 15 + */ onlyForLifting?: boolean; /** - * Define whether to delay create builder. - * - * @type { ?boolean } - * @default false - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 15 - */ + * Define whether to delay create builder. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 15 + */ delayCreating?: boolean; } @@ -20390,7 +19766,7 @@ declare interface InvertOptions { /** * Defines the low value of threshold - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20398,7 +19774,7 @@ declare interface InvertOptions { */ /** * Defines the low value of threshold - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20408,27 +19784,27 @@ declare interface InvertOptions { low: number; /** - * Defines the high value of threshold - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ - /** - * Defines the high value of threshold - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ + * Defines the high value of threshold + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 11 + */ + /** + * Defines the high value of threshold + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ high: number; /** * Defines the threshold - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20436,7 +19812,7 @@ declare interface InvertOptions { */ /** * Defines the threshold - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20444,10 +19820,10 @@ declare interface InvertOptions { * @since 12 */ threshold: number; - + /** *Defines the threshold range - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20455,7 +19831,7 @@ declare interface InvertOptions { */ /** *Defines the threshold range - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20467,7 +19843,7 @@ declare interface InvertOptions { /** * Import the CircleShape type object for common method. - * + * * @typedef { import('../api/@ohos.arkui.shape').CircleShape } CircleShape * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20479,7 +19855,7 @@ declare type CircleShape = import('../api/@ohos.arkui.shape').CircleShape; /** * Import the EllipseShape type object for common method. - * + * * @typedef { import('../api/@ohos.arkui.shape').EllipseShape } EllipseShape * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20491,7 +19867,7 @@ declare type EllipseShape = import('../api/@ohos.arkui.shape').EllipseShape; /** * Import the PathShape type object for common method. - * + * * @typedef { import('../api/@ohos.arkui.shape').PathShape } PathShape * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20503,7 +19879,7 @@ declare type PathShape = import('../api/@ohos.arkui.shape').PathShape; /** * Import the RectShape type object for common method. - * + * * @typedef { import('../api/@ohos.arkui.shape').RectShape } RectShape * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20624,10 +20000,12 @@ declare interface BackgroundOptions { * @since 20 */ align?: Alignment; + /** - * The set of edges for which to ignore layout safe area. The default value is LayoutSafeAreaEdge.ALL. To respect safe area insets on all edges, explicitly pass empty edge set. + * The set of edges for which to ignore layout safe area. To respect safe area insets on all edges, explicitly pass empty edge set. + * * @type { ?Array } - * @default LayoutSafeAreaEdge.ALL + * @default The default value is LayoutSafeAreaEdge.ALL when background is ResourceColor, otherwise it is an empty array []. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 20 @@ -20711,9 +20089,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the width of the component. By default, the width required to fully hold the - * component content is used.If the width of the component is greater than that of - * the parent container, the component will be drawn beyond the parent container scope. + * Sets the width of the current component. * * @param { Length } value * @returns { T } @@ -20725,10 +20101,7 @@ declare class CommonMethod { */ width(value: Length): T; /** - * Sets the width of the component or its horizontal layout policy. By default, the - * component uses the width required for its content. If the width of the component is - * greater than that of the parent container, the component will be drawn beyond the - * parent container scope. + * Sets the width of the current component. * * @param { Length | LayoutPolicy } widthValue * @returns { T } @@ -20768,9 +20141,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the height of the component. By default, the height required to fully hold the - * component content is used. If the height of the component is greater than that of - * the parent container, the component will be drawn beyond the parent container scope. + * Sets the height of the current component. * * @param { Length } value * @returns { T } @@ -20782,10 +20153,7 @@ declare class CommonMethod { */ height(value: Length): T; /** - * Sets the height of the component or its vertical layout policy. By default, the - * component uses the height required for its content. If the height of the component - * is greater than that of the parent container, the component will be drawn beyond - * the parent container scope. + * Sets the height of the current component. * * @param { Length | LayoutPolicy } heightValue * @returns { T } @@ -20796,13 +20164,11 @@ declare class CommonMethod { * @since 15 */ height(heightValue: Length | LayoutPolicy): T; - + /** * Sets the drawModifier of the current component. * * @param { DrawModifier | undefined } modifier - drawModifier used to draw, or undefined if it is not available. - * Default value: undefined - * A custom modifier applies only to the FrameNode of the currently bound component, not to its subnodes. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -20813,7 +20179,6 @@ declare class CommonMethod { /** * Sets the custom property of the current component. - * This API does not work for custom components. * * @param { string } name - the name of the custom property. * @param { Optional } value - the value of the custom property. @@ -20836,9 +20201,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the safe area to be expanded to. - *
default:{types: [SafeAreaType.SYSTEM, SafeAreaType.CUTOUT, SafeAreaType.KEYBOARD], - * edges: [SafeAreaEdge.TOP, SafeAreaEdge.BOTTOM, SafeAreaEdge.START, SafeAreaEdge.END]} + * Expands the safe area. * * @param { Array } types - Indicates the types of the safe area. * @param { Array } edges - Indicates the edges of the safe area. @@ -20952,7 +20315,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the size of the component. + * The size of the current component. * * @param { SizeOptions } value * @returns { T } @@ -20995,8 +20358,8 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the constraint size of the component, which is used to limit the size range during component layout. - * Default value: **{minWidth: 0, maxWidth: Infinity, minHeight: 0, maxHeight: Infinity}**. + * constraint Size: + * minWidth: minimum Width, maxWidth: maximum Width, minHeight: minimum Height, maxHeight: maximum Height. * * @param { ConstraintSizeOptions } value * @returns { T } @@ -21038,11 +20401,9 @@ declare class CommonMethod { * @since 10 */ /** - * Sets how the component behaves during hit testing. + * Defines the component's hit test behavior in touch events. * * @param { HitTestMode } value - the hit test mode. - * @default HitTestMode.default - Both the node and its child nodes respond to the hit test of a touch event, - * but its sibling nodes are blocked from the hit test. The hit test for ancestor nodes is not affected. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21061,7 +20422,7 @@ declare class CommonMethod { * @since 11 */ /** - * Called to specify how to perform the touch test on the children of this component. + * Defines the pre-touch test of sub component in touch events. * * @param { function } event * @returns { T } @@ -21100,9 +20461,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the weight of the component during layout. A component with this attribute is allocated space - * along the main axis of its parent container (Row, Column, or Flex) based on its specified weight. - * Default value: **0**. + * Defines the weight of the component, according to which the remain part of main-axis is allocated self-adaptively * * @param { number | string } value * @returns { T } @@ -21115,8 +20474,7 @@ declare class CommonMethod { layoutWeight(value: number | string): T; /** - * Sets the weight of the component in a chain, which is used to re-lay out components that form the chain. - *
This API has effect only when the parent container is RelativeContainer. + * chain Weight * * @param { ChainWeightOptions } chainWeight * @returns { T } @@ -21166,8 +20524,7 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the padding of the component. - * Default value: **0**. + * Inner margin. * * @param { Padding | Length | LocalizedPadding } value * @returns { T } @@ -21180,9 +20537,7 @@ declare class CommonMethod { padding(value: Padding | Length | LocalizedPadding): T; /** - * Sets the safe area padding. It enables a container to add a component-level - * safe area for child components to expand into. - * Default value: **LengthMetrics.vp(0)** + * Inner safeArea padding. * * @param { Padding | LengthMetrics | LocalizedPadding } paddingValue - Indicates safeArea padding values * @returns { T } @@ -21193,7 +20548,7 @@ declare class CommonMethod { * @since 14 */ safeAreaPadding(paddingValue: Padding | LengthMetrics | LocalizedPadding): T; - + /** * Outer Margin. * @@ -21233,8 +20588,7 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the margin of the component. - * Default value: **0**. + * Outer Margin. * * @param { Margin | Length | LocalizedMargin } value * @returns { T } @@ -21278,7 +20632,7 @@ declare class CommonMethod { * * Anonymous Object Rectification. * @param { CustomBuilder | ResourceColor } content - * @param { BackgroundOptions } options + * @param { BackgroundOptions } [options] * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21354,10 +20708,9 @@ declare class CommonMethod { backgroundColor(color: Optional): T; /** - * Sets the pixel rounding policy for the current component in the specified direction. - *
If a direction is not set, the pixels are rounded to the nearest whole number in that direction. + * PixelRound * - * @param { PixelRoundPolicy } value - indicates the rounding policy for the bounds of the component. + * @param { PixelRoundPolicy } value - indicates the pixel round policy. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21441,7 +20794,7 @@ declare class CommonMethod { * @since 18 */ backgroundImage(src: ResourceStr | PixelMap, options?: BackgroundImageOptions): T; - + /** * Background image size * @@ -21472,7 +20825,7 @@ declare class CommonMethod { /** * Background image size * - * @param { SizeOptions | ImageSize } value - The width and height of the background image. + * @param { SizeOptions | ImageSize } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21527,40 +20880,35 @@ declare class CommonMethod { backgroundImagePosition(value: Position | Alignment): T; /** - * Defines the blur style to apply between the background and content of a component. - * It encapsulates various blur radius, mask color, mask opacity, saturation. - * And brightness values through enum values. + * Background blur style. + * blurStyle:Blur style type. * - * @param { BlurStyle } value - Settings of the background blur style - *
including the blur radius, mask color, mask opacity, saturation, and brightness. - * @param { BackgroundBlurStyleOptions } options - Background blur options. + * @param { BlurStyle } value + * @param { BackgroundBlurStyleOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Defines the blur style to apply between the background and content of a component. - * It encapsulates various blur radius, mask color, mask opacity, saturation. - * And brightness values through enum values. + * Background blur style. + * blurStyle:Blur style type. * - * @param { BlurStyle } value - Settings of the background blur style - *
including the blur radius, mask color, mask opacity, saturation, and brightness. - * @param { BackgroundBlurStyleOptions } options - Background blur options. + * @param { BlurStyle } value + * @param { BackgroundBlurStyleOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 10 */ + /** - * Defines the blur style to apply between the background and content of a component. - * It encapsulates various blur radius, mask color, mask opacity, saturation. - * And brightness values through enum values. + * Background blur style. + * blurStyle:Blur style type. * - * @param { BlurStyle } value - Settings of the background blur style - *
including the blur radius, mask color, mask opacity, saturation, and brightness. - * @param { BackgroundBlurStyleOptions } options - Background blur options. + * @param { BlurStyle } value + * @param { BackgroundBlurStyleOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21612,9 +20960,9 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the background effect of the component, including the blur radius, brightness, saturation, and color. + * options:background effect options. * - * @param { BackgroundEffectOptions } options - Background effect, including saturation, brightness, and color. + * @param { BackgroundEffectOptions } options - options indicates the effect options. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21680,8 +21028,9 @@ declare class CommonMethod { */ foregroundEffect(options: ForegroundEffectOptions): T; + /** - * Sets a visual effect that is not a filter effect. + * Unified visual effect interface. * * @param { VisualEffect } effect - Visual effect parameters. * @returns { T } @@ -21693,7 +21042,7 @@ declare class CommonMethod { visualEffect(effect: VisualEffect): T; /** - * Sets the visual effect of the background filter. + * Filter applied to the background layer of the component. * * @param { Filter } filter - Filter effect parameters. * @returns { T } @@ -21705,7 +21054,7 @@ declare class CommonMethod { backgroundFilter(filter: Filter): T; /** - * Sets the visual effect of the foreground (content) filter. + * Filter applied to the foreground layer of the component. * * @param { Filter } filter - Filter effect parameters. * @returns { T } @@ -21717,7 +21066,7 @@ declare class CommonMethod { foregroundFilter(filter: Filter): T; /** - * Sets the visual effect of the compositing filter. + * Filter applied to the compositing layer of the component. * * @param { Filter } filter - Filter effect parameters. * @returns { T } @@ -21729,20 +21078,22 @@ declare class CommonMethod { compositingFilter(filter: Filter): T; /** - * Applies a foreground blur style to the component. + * Foreground blur style. + * blurStyle:Blur style type. * - * @param { BlurStyle } value - Settings of the foreground blur style. - * @param { ForegroundBlurStyleOptions } options - Foreground blur options. + * @param { BlurStyle } value + * @param { ForegroundBlurStyleOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Applies a foreground blur style to the component. + * Foreground blur style. + * blurStyle:Blur style type. * - * @param { BlurStyle } value - Settings of the foreground blur style. - * @param { ForegroundBlurStyleOptions } options - Foreground blur options. + * @param { BlurStyle } value + * @param { ForegroundBlurStyleOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21784,24 +21135,24 @@ declare class CommonMethod { /** * Sets the opacity of the component. * - * @param { number | Resource } value - Opacity of the component. The value ranges from 0 to 1. + * @param { number | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the opacity of the component. + * Opacity * - * @param { number | Resource } value - Opacity of the component. The value ranges from 0 to 1. + * @param { number | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the opacity of the component. + * Opacity * - * @param { number | Resource } value - Opacity of the component. The value ranges from 0 to 1. + * @param { number | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21809,9 +21160,9 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the opacity of the component. + * Opacity * - * @param { number | Resource } value - Opacity of the component. The value ranges from 0 to 1. + * @param { number | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21822,9 +21173,9 @@ declare class CommonMethod { opacity(value: number | Resource): T; /** - * Sets the opacity of the component. + * Opacity * - * @param { Optional } opacity - Opacity of the component. The value ranges from 0 to 1. + * @param { Optional } opacity * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -21865,7 +21216,8 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the border. + * Border + * width:Border width;color:Border color;radius:Border radius; * * @param { BorderOptions } value * @returns { T } @@ -21905,8 +21257,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the border style. - * Default value: **BorderStyle.Solid**. + * Border style * * @param { BorderStyle | EdgeStyles } value * @returns { T } @@ -21957,8 +21308,7 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the border width. - * Percentage values are not supported. + * Border width * * @param { Length | EdgeWidths | LocalizedEdgeWidths } value * @returns { T } @@ -22009,8 +21359,8 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the border color. - * Default value: **Color.Black**. + * Border color + * * @param { ResourceColor | EdgeColors | LocalizedEdgeColors } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -22060,8 +21410,7 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the radius of the border rounded corners. - *
The radius is restricted by the component size. The maximum value is half of the component width or height. + * Border radius * * @param { Length | BorderRadiuses | LocalizedBorderRadiuses } value * @returns { T } @@ -22093,9 +21442,9 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the border image of the component. + * Border image * - * @param { BorderImageOption } value - Border image or border gradient. + * @param { BorderImageOption } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22106,9 +21455,10 @@ declare class CommonMethod { borderImage(value: BorderImageOption): T; /** - * Sets the outline attributes in one declaration. + * Outline + * width:Outline width;color:Outline color;radius:Outline radius;style:Outline style; * - * @param { OutlineOptions } value - Outline attributes. + * @param { OutlineOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22116,9 +21466,10 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the outline attributes in one declaration. + * Outline + * width:Outline width;color:Outline color;radius:Outline radius;style:Outline style; * - * @param { OutlineOptions } value - Outline attributes. + * @param { OutlineOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22129,11 +21480,10 @@ declare class CommonMethod { outline(value: OutlineOptions): T; /** - * Sets the outline attributes in one declaration. Compared to outline, - * this API supports the **undefined** type for the **options** parameter. + * Outline + * width:Outline width;color:Outline color;radius:Outline radius;style:Outline style; * - * @param { Optional } options - Outline attributes.
If **options** is **undefined**, - * the component reverts to its original style with no outline. + * @param { Optional } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22144,10 +21494,10 @@ declare class CommonMethod { outline(options: Optional): T; /** - * Sets the style of the outline. + * Outline style + * The input parameter default value is OutlineStyle.SOLID * - * @param { OutlineStyle | EdgeOutlineStyles } value - Outline style. - *
Default value: **OutlineStyle.SOLID**. + * @param { OutlineStyle | EdgeOutlineStyles } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22155,10 +21505,9 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the style of the outline. + * Outline style * - * @param { OutlineStyle | EdgeOutlineStyles } value - Outline style. - *
Default value: **OutlineStyle.SOLID**. + * @param { OutlineStyle | EdgeOutlineStyles } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22169,13 +21518,9 @@ declare class CommonMethod { outlineStyle(value: OutlineStyle | EdgeOutlineStyles): T; /** - * Sets the style of the outline. Compared to outlineStyle, - * this API supports the **undefined** type for the **style** parameter. + * Outline style * - * @param { Optional } style - Outline style. - *
Default value: **OutlineStyle.SOLID**. - *
If **style** is **undefined**, the component reverts to its original - * style with no outline. + * @param { Optional } style * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22186,11 +21531,10 @@ declare class CommonMethod { outlineStyle(style: Optional): T; /** - * Sets the thickness of the outline. + * Outline width + * The input parameter default value is 0 * - * @param { Dimension | EdgeOutlineWidths } value - Outline thickness. Percentage values are not supported. - *
Default value: **0**Outline thickness. Percentage values are not supported. - *
Default value: **0**. + * @param { Dimension | EdgeOutlineWidths } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22198,11 +21542,9 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the thickness of the outline. + * Outline width * - * @param { Dimension | EdgeOutlineWidths } value - Outline thickness. Percentage values are not supported. - *
Default value: **0**Outline thickness. Percentage values are not supported. - *
Default value: **0**. + * @param { Dimension | EdgeOutlineWidths } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22213,12 +21555,9 @@ declare class CommonMethod { outlineWidth(value: Dimension | EdgeOutlineWidths): T; /** - * Sets the thickness of the outline. Compared to outlineWidth, - * this API supports the **undefined** type for the **width** parameter. + * Outline width * - * @param { Optional } width - Outline thickness. Percentage values are not supported. - *
Default value: **0**. - *
If **width** is **undefined**, the component reverts to its original style with no outline width. + * @param { Optional } width * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22229,10 +21568,10 @@ declare class CommonMethod { outlineWidth(width: Optional): T; /** - * Sets the color of the outline. + * Outline color + * The input parameter default value is Color.Black * - * @param { ResourceColor | EdgeColors } value - Outline color. - *
Default value: **Color.Black**. + * @param { ResourceColor | EdgeColors } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22240,10 +21579,9 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the color of the outline. + * Outline color * - * @param { ResourceColor | EdgeColors | LocalizedEdgeColors } value - Outline color. - *
Default value: **Color.Black**. + * @param { ResourceColor | EdgeColors | LocalizedEdgeColors } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22254,13 +21592,9 @@ declare class CommonMethod { outlineColor(value: ResourceColor | EdgeColors | LocalizedEdgeColors): T; /** - * Sets the color of the outline. Compared to outlineColor, - * this API supports the **undefined** type for the **color** parameter. + * Outline color * - * @param { Optional } color - Outline color. - *
Default value: **Color.Black**. - *
If **color** is **undefined**, the component reverts to its original style with the - * outline color of **Color.Black**. + * @param { Optional } color * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22271,12 +21605,10 @@ declare class CommonMethod { outlineColor(color: Optional): T; /** - * Sets the radius of the outline corners. + * Outline radius + * The input parameter default value is 0 * - * @param { Dimension | OutlineRadiuses } value - adius of the outline corners. Percentage - * values are not supported. - *
Default value: **0**. - *
Maximum effective value: Component width/2 + outlineWidth or component height/2 + outlineWidth. + * @param { Dimension | OutlineRadiuses } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22284,12 +21616,9 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the radius of the outline corners. + * Outline radius * - * @param { Dimension | OutlineRadiuses } value - adius of the outline corners. Percentage - * values are not supported. - *
Default value: **0**. - *
Maximum effective value: Component width/2 + outlineWidth or component height/2 + outlineWidth. + * @param { Dimension | OutlineRadiuses } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22300,15 +21629,9 @@ declare class CommonMethod { outlineRadius(value: Dimension | OutlineRadiuses): T; /** - * Sets the radius of the outline corners. Compared to outlineRadius, this API - * supports the **undefined** type for the **radius** parameter. + * Outline radius * - * @param { Optional } radius - Radius of the outline corners. Percentage - * values are not supported. - *
Default value: **0**. - *
Maximum effective value: Component width/2 + outlineWidth or component height/2 + outlineWidth. - *
If **radius** is **undefined**, the component reverts to its original style with the - * outline corner radius of 0. + * @param { Optional } radius * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22319,22 +21642,20 @@ declare class CommonMethod { outlineRadius(radius: Optional): T; /** - * Sets the foreground color of the component. - * If the component does not have a foreground color set, it inherits the color from its parent component by default. + * Provides the general foreground color capability of UI components, and assigns color values + * according to the characteristics of components. * - * @param { ResourceColor | ColoringStrategy } value - Foreground color. - *
The value can be a specific color or a coloring strategy. Property animations are supported. + * @param { ResourceColor | ColoringStrategy } value - indicates the color or color selection strategy * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Sets the foreground color of the component. - * If the component does not have a foreground color set, it inherits the color from its parent component by default. + * Provides the general foreground color capability of UI components, and assigns color values + * according to the characteristics of components. * - * @param { ResourceColor | ColoringStrategy } value - Foreground color. - *
The value can be a specific color or a coloring strategy. Property animations are supported. + * @param { ResourceColor | ColoringStrategy } value - indicates the color or color selection strategy * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22344,13 +21665,10 @@ declare class CommonMethod { foregroundColor(value: ResourceColor | ColoringStrategy): T; /** - * Sets the foreground color of the component. - * If the component does not have a foreground color set, it inherits the color from its parent component by default. - * Compared to {@link foregroundColor}, this API supports the **undefined** type for the **color** parameter. + * Provides the general foreground color capability of UI components, and assigns color values + * according to the characteristics of components. * - * @param { Optional } color -Foreground color. - *
The value can be a specific color or a coloring strategy. Property animations are supported. - *
If **color** is set to **undefined**, the previous value is retained. + * @param { Optional } color - indicates the color or color selection strategy * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22387,13 +21705,8 @@ declare class CommonMethod { * @since 10 */ /** - * Called when a click event occurs. + * Trigger a click event when a click is clicked. * - *

NOTE: - *
Since API version 9, the following constraints apply when this API is used in service widgets: - *
Click events cannot be triggered if the finger is pressed for more than 800 ms. - *
Click events cannot be triggered if the finger moves more than 20 px after pressing down. - *

* @param { function } event * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -22405,17 +21718,10 @@ declare class CommonMethod { onClick(event: (event: ClickEvent) => void): T; /** - * Trigger a click event when a click is clicked, move distance should smaller than distanceThreshold. + * Trigger a click event when a click is clicked, move distance should smaller than distanceThreshold. * - *

NOTE: - *
If the distanceThreshold value specified is less than or equal to 0 vp, it will be converted to the default value. - *
Since API version 9, the following constraints apply when this API is used in service widgets: - *
Click events cannot be triggered if the finger is pressed for more than 800 ms. - *
Click events cannot be triggered if the finger moves more than 20 px after pressing down. - *

* @param { function } event - this function callback executed when the click action is recognized * @param { number } distanceThreshold - the distance threshold of finger's movement when detecting a click action - * @default (2^31-1)vp * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22472,7 +21778,7 @@ declare class CommonMethod { /** * prompt for current component and descendants unable to handle accessibility hover event * - * @param { AccessibilityTransparentCallback } callback - A callback instance used when current component and + * @param { AccessibilityTransparentCallback } callback - A callback instance used when current component and * descendants not handled accessibility hover event * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -22481,7 +21787,7 @@ declare class CommonMethod { * @since 20 */ onAccessibilityHoverTransparent(callback: AccessibilityTransparentCallback): T; - + /** * Set hover effect. * @@ -22502,7 +21808,7 @@ declare class CommonMethod { /** * Set hover effect. * - * @param { HoverEffect } value - Hover effect of the component in hover state. + * @param { HoverEffect } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22520,7 +21826,7 @@ declare class CommonMethod { * @since 8 */ /** - * Triggered when the component is clicked by a mouse button or the mouse pointer moves on the component. + * Trigger a mouse event. * * @param { function } event * @returns { T } @@ -22548,7 +21854,7 @@ declare class CommonMethod { * @since 10 */ /** - * Invoked when a touch event is triggered. + * Trigger a touch event when touched. * * @param { function } event * @returns { T } @@ -22591,7 +21897,7 @@ declare class CommonMethod { /** * Keyboard input * - * @param { Callback } event - Callback for handling the key event. + * @param { Callback } event * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22614,7 +21920,7 @@ declare class CommonMethod { /** * Handle keyboard events before input method events. * - * @param { Callback } event - Callback for handling the key event. + * @param { Callback } event * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22676,10 +21982,7 @@ declare class CommonMethod { */ /** * Set focusable. - * Components that have default interaction logic, such as Button and TextInput, are focusable by default. Other - * components, such as Text and Image, are not focusable by default. Only focusable components can trigger a focus - * event. - * + * * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -22712,7 +22015,7 @@ declare class CommonMethod { * @since 14 */ tabStop(isTabStop: boolean): T; - + /** * Trigger a event when got focus. * @@ -22743,7 +22046,7 @@ declare class CommonMethod { onFocus(event: () => void): T; /** - * Triggered when the current component loses focus. + * Trigger a event when lose focus. * * @param { function } event * @returns { T } @@ -22751,7 +22054,7 @@ declare class CommonMethod { * @since 8 */ /** - * Triggered when the current component loses focus. + * Trigger a event when lose focus. * * @param { function } event * @returns { T } @@ -22760,7 +22063,7 @@ declare class CommonMethod { * @since 10 */ /** - * Triggered when the current component loses focus. + * Trigger a event when lose focus. * * @param { function } event * @returns { T } @@ -22790,7 +22093,7 @@ declare class CommonMethod { */ /** * Set focus index by key tab. - * The tabIndex and focusScopeId cannot be used together. + * * @param { number } index * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -22820,7 +22123,7 @@ declare class CommonMethod { /** * Set default focused component when a page create. * - * @param { boolean } value - True means to set the component as the default focus, and the value false has no effect. + * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22849,8 +22152,7 @@ declare class CommonMethod { /** * Set default focused component when focus on a focus group. * - * @param { boolean } value - True means the component is the default focus of the parent container, and - * false means the component is not the default focus of the parent container. + * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22879,7 +22181,7 @@ declare class CommonMethod { /** * Set a component focused when the component be touched. * - * @param { boolean } value - True means the component is focusable on touch, false means the component is not focusable on touch. + * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22891,7 +22193,7 @@ declare class CommonMethod { /** * Set the component's focusBox style. * - * @param { FocusBoxStyle } style - Component's focusBox style. + * @param { FocusBoxStyle } style * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -22901,44 +22203,44 @@ declare class CommonMethod { focusBox(style: FocusBoxStyle): T; /** - * Set container as a focus group with a specific identifier. - * - * @param { string } id - focus scope identifier. - * @param { boolean } [isGroup] - whether this scope is a focus group, the default value is false - * @returns { T } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - focusScopeId(id: string, isGroup?: boolean): T; + * Set container as a focus group with a specific identifier. + * + * @param { string } id - focus scope identifier. + * @param { boolean } [isGroup] - whether this scope is a focus group, the default value is false + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + focusScopeId(id: string, isGroup?: boolean): T; /** - * Set container as a focus group with a specific identifier. - * - * @param { string } id - focus scope identifier. - * @param { boolean } [isGroup] - whether this scope is a focus group, the default value is false. - * @param { boolean } [arrowStepOut] - whether the arrow keys can move focus from inside the focus group to outside, - * only effective when isGroup is true, the default value is true. - * @returns { T } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - focusScopeId(id: string, isGroup?: boolean, arrowStepOut?: boolean): T; + * Set container as a focus group with a specific identifier. + * + * @param { string } id - focus scope identifier. + * @param { boolean } [isGroup] - whether this scope is a focus group, the default value is false. + * @param { boolean } [arrowStepOut] - whether the arrow keys can move focus from inside the focus group to outside, + * only effective when isGroup is true, the default value is true. + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + focusScopeId(id: string, isGroup?: boolean, arrowStepOut?: boolean): T; /** - * Set the focus priority of component in a specific focus scope. - * - * @param { string } scopeId - * @param { FocusPriority } [priority] - the default value is AUTO - * @returns { T } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - focusScopePriority(scopeId: string, priority?: FocusPriority): T; + * Set the focus priority of component in a specific focus scope. + * + * @param { string } scopeId + * @param { FocusPriority } [priority] - the default value is AUTO + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + focusScopePriority(scopeId: string, priority?: FocusPriority): T; /** * animation @@ -22981,27 +22283,24 @@ declare class CommonMethod { animation(value: AnimateParam): T; /** - * Transition effects for when the component is inserted to show and removed to hide - * as well as the callback for the end of the transition animation. + * Transition parameter * - * @param { TransitionOptions | TransitionEffect } value - transition options or transition effect + * @param { TransitionOptions | TransitionEffect } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Transition effects for when the component is inserted to show and removed to hide - * as well as the callback for the end of the transition animation. + * Transition parameter * - * @param { TransitionOptions | TransitionEffect } value - transition options or transition effect + * @param { TransitionOptions | TransitionEffect } value - transition options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Transition effects for when the component is inserted to show and removed to hide - * as well as the callback for the end of the transition animation. + * Transition parameter * * @param { TransitionOptions | TransitionEffect } value - transition options or transition effect * @returns { T } @@ -23011,8 +22310,7 @@ declare class CommonMethod { * @since 10 */ /** - * Transition effects for when the component is inserted to show and removed to hide - * as well as the callback for the end of the transition animation. + * Transition parameter * * @param { TransitionOptions | TransitionEffect } value - transition options or transition effect * @returns { T } @@ -23158,7 +22456,7 @@ declare class CommonMethod { * The larger the blurring radius, the more blurring the content. * If the value is 0, the content blurring effect is not blurring. * - * @param { number } value - value indicates radius of backdrop blur. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -23169,7 +22467,7 @@ declare class CommonMethod { * The larger the blurring radius, the more blurring the content. * If the value is 0, the content blurring effect is not blurring. * - * @param { number } value - value indicates radius of backdrop blur. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23239,7 +22537,7 @@ declare class CommonMethod { linearGradientBlur(value: number, options: LinearGradientBlurOptions): T; /** - * Applies a linear gradient foreground blur effect to the component. + * Adds the content linear gradient blurring effect for the current component. The input parameter is the blurring radius. * * @param { Optional } blurRadius - the blurring radius. * The larger the blurring radius, the more blurring the content, and if the value is 0, the content blurring effect is not blurring. @@ -23252,21 +22550,9 @@ declare class CommonMethod { linearGradientBlur(blurRadius: Optional, options: Optional): T; /** - * Apply a motion blur effect to the component being scaled or moved. - * 1.Do not use this API in intra-component transitions, shared element transitions, - * implicit element transitions, or particle animations. Doing so may cause unexpected results. - * 2.The **radius** parameter of **motionBlur** must be set to **0** for the initial state. - * Otherwise, there may be unexpected results during a cold start. - * 3.This API must be used together with the **onFinish** parameter of **AnimateParam**. - * Its **radius** parameter must be set to **0** when the animation ends; otherwise, there may be unexpected results. - * 4.When using this API, do not frequently change the blur radius of the same component; - * otherwise, there may be unexpected results. - * For example, if you frequently click the image in the example, the blur effect may not work sometimes. - * 5.To avoid unexpected results, make sure the coordinates of - * the motion blur anchor point are the same as those of the animation scaling anchor point. - * 6.To avoid unexpected results, set the blur radius to a value less than 1. - * - * @param { MotionBlurOptions } value - Motion blur options. + * Component motion blur interface. + * + * @param { MotionBlurOptions } value - the attributes of motion blur. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23288,47 +22574,32 @@ declare class CommonMethod { motionBlur(motionBlur: Optional):T; /** - * Applies a brightness effect to the component. + * Adds a highlight effect to the current component. + * The input parameter is the highlight proportion. 0 indicates no highlight effect, and 1 indicates the maximum highlight proportion. + * The component is displayed as all white (percentage). * - * @param { number } value - Brightness of the component. The value **1** indicates no effects. - * The value **0** indicates the complete darkness. If the value is less than **1**, the brightness - * decreases. If the value is greater than **1**, the brightness increases. A larger value indicates - * a higher brightness. A brightness of 2 turns the component completely white. - *
Default value: **1.0**
Recommended value range: [0, 2]. - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. - *
**Widget capability**: This API can be used in ArkTS widgets since API version 9. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Applies a brightness effect to the component. + * Adds a highlight effect to the current component. + * The input parameter is the highlight proportion. 0 indicates no highlight effect, and 1 indicates the maximum highlight proportion. + * The component is displayed as all white (percentage). * - * @param { number } value - Brightness of the component. The value **1** indicates no effects. - * The value **0** indicates the complete darkness. If the value is less than **1**, the brightness - * decreases. If the value is greater than **1**, the brightness increases. A larger value indicates - * a higher brightness. A brightness of 2 turns the component completely white. - *
Default value: **1.0**
Recommended value range: [0, 2]. - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. - *
**Widget capability**: This API can be used in ArkTS widgets since API version 9. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Applies a brightness effect to the component. + * Adds a highlight effect to the current component. + * The input parameter is the highlight proportion. 0 indicates no highlight effect, and 1 indicates the maximum highlight proportion. + * The component is displayed as all white (percentage). * - * @param { number } value - Brightness of the component. The value **1** indicates no effects. - * The value **0** indicates the complete darkness. If the value is less than **1**, the brightness - * decreases. If the value is greater than **1**, the brightness increases. A larger value indicates - * a higher brightness. A brightness of 2 turns the component completely white. - *
Default value: **1.0**
Recommended value range: [0, 2]. - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. - *
**Widget capability**: This API can be used in ArkTS widgets since API version 9. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23336,16 +22607,11 @@ declare class CommonMethod { * @since 10 */ /** - * Applies a brightness effect to the component. + * Adds a highlight effect to the current component. + * The input parameter is the highlight proportion. 0 indicates no highlight effect, and 1 indicates the maximum highlight proportion. + * The component is displayed as all white (percentage). * - * @param { number } value - Brightness of the component. The value **1** indicates no effects. - * The value **0** indicates the complete darkness. If the value is less than **1**, the brightness - * decreases. If the value is greater than **1**, the brightness increases. A larger value indicates - * a higher brightness. A brightness of 2 turns the component completely white. - *
Default value: **1.0**
Recommended value range: [0, 2]. - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. - *
**Widget capability**: This API can be used in ArkTS widgets since API version 9. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23356,19 +22622,11 @@ declare class CommonMethod { brightness(value: number): T; /** - * Applies a brightness effect to the component. Compared to brightness, this - * API supports the **undefined** type for the **brightness** parameter. + * Adds a highlight effect to the current component. + * The input parameter is the highlight proportion. 0 indicates no highlight effect, and 1 indicates the maximum highlight proportion. + * The component is displayed as all white (percentage). * - * @param { Optional } brightness - Brightness of the component. The value **1** indicates - * no effects. The value **0** indicates the complete darkness. If the value is less than **1**, - * the brightness decreases. If the value is greater than **1**, the brightness increases. A larger - * value indicates a higher brightness. A brightness of 2 turns the component completely white. - *
Default value: **1.0**. - *
Recommended value range: [0, 2]. - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. - *
**Widget capability**: This API can be used in ArkTS widgets since API version 16. - *
If **brightness** is **undefined**, the brightness level is reset to **0**. + * @param { Optional } brightness * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23379,50 +22637,29 @@ declare class CommonMethod { brightness(brightness: Optional): T; /** - * Applies a contrast effect to the component. + * Adds a contrast effect to the current component. The input parameter is the contrast value. + * A larger contrast value indicates a sharper image. When the contrast value is 0, the image becomes gray. (%) * - * @param { number } value - Contrast of the component. The input parameter is a - * contrast value. If the value is **1**, the source image is displayed. If the - * value is greater than 1, a larger value indicates a higher contrast and a clearer - * image. If the value is less than 1, a smaller value indicates a lower contrast is. - * If the value is **0**, the image becomes all gray. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 10). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Applies a contrast effect to the component. + * Adds a contrast effect to the current component. The input parameter is the contrast value. + * A larger contrast value indicates a sharper image. When the contrast value is 0, the image becomes gray. (%) * - * @param { number } value - Contrast of the component. The input parameter is a - * contrast value. If the value is **1**, the source image is displayed. If the - * value is greater than 1, a larger value indicates a higher contrast and a clearer - * image. If the value is less than 1, a smaller value indicates a lower contrast is. - * If the value is **0**, the image becomes all gray. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 10). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Applies a contrast effect to the component. + * Adds a contrast effect to the current component. The input parameter is the contrast value. + * A larger contrast value indicates a sharper image. When the contrast value is 0, the image becomes gray. (%) * - * @param { number } value - Contrast of the component. The input parameter is a - * contrast value. If the value is **1**, the source image is displayed. If the - * value is greater than 1, a larger value indicates a higher contrast and a clearer - * image. If the value is less than 1, a smaller value indicates a lower contrast is. - * If the value is **0**, the image becomes all gray. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 10). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23430,17 +22667,10 @@ declare class CommonMethod { * @since 10 */ /** - * Applies a contrast effect to the component. + * Adds a contrast effect to the current component. The input parameter is the contrast value. + * A larger contrast value indicates a sharper image. When the contrast value is 0, the image becomes gray. (%) * - * @param { number } value - Contrast of the component. The input parameter is a - * contrast value. If the value is **1**, the source image is displayed. If the - * value is greater than 1, a larger value indicates a higher contrast and a clearer - * image. If the value is less than 1, a smaller value indicates a lower contrast is. - * If the value is **0**, the image becomes all gray. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 10). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23451,19 +22681,10 @@ declare class CommonMethod { contrast(value: number): T; /** - * Applies a contrast effect to the component. Compared to contrast, - * this API supports the **undefined** type for the **contrast** parameter. + * Adds a contrast effect to the current component. The input parameter is the contrast value. + * A larger contrast value indicates a sharper image. When the contrast value is 0, the image becomes gray. (%) * - * @param { Optional } contrast - Contrast of the component. The input parameter - * is a contrast value. If the value is **1**, the source image is displayed. If the value - * is greater than 1, a larger value indicates a higher contrast and a clearer image. If the - * value is less than 1, a smaller value indicates a lower contrast is. If the value is **0**, - * the image becomes all gray. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 10). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. - *
If **contrast** is **undefined**, the contrast effect is reset to **1.0**. + * @param { Optional } contrast * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23474,53 +22695,32 @@ declare class CommonMethod { contrast(contrast: Optional): T; /** - * Applies a grayscale effect to the component. - * - * @param { number } value - Grayscale conversion ratio of the component. - *
If the value is **1.0**, the component is completely converted to grayscale. - *
If the value is **0.0**, the component remains unchanged. Between **0** and **1**, - * the value applies a linear multiplier on the grayscale effect. The unit is percentage. - *
Default value: **0.0**. - *
Value range: [0.0, 1.0]. - *

**NOTE**: - *
A value less than **0.0** evaluates to the value **0.0**. - *
A value greater than **1.0** evaluates to the value **1.0**. - *

+ * Adds a grayscale effect to the current component. + * The value is the gray scale conversion ratio. If the input parameter is 1.0, the gray scale image is completely converted to the gray scale image. If the input parameter is 0.0, the image does not change. + * If the input parameter is between 0.0 and 1.0, the effect changes. (Percentage) + * + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Applies a grayscale effect to the component. - * - * @param { number } value - Grayscale conversion ratio of the component. - *
If the value is **1.0**, the component is completely converted to grayscale. - *
If the value is **0.0**, the component remains unchanged. Between **0** and **1**, - * the value applies a linear multiplier on the grayscale effect. The unit is percentage. - *
Default value: **0.0**. - *
Value range: [0.0, 1.0]. - *

**NOTE**: - *
A value less than **0.0** evaluates to the value **0.0**. - *
A value greater than **1.0** evaluates to the value **1.0**. - *

+ * Adds a grayscale effect to the current component. + * The value is the gray scale conversion ratio. If the input parameter is 1.0, the gray scale image is completely converted to the gray scale image. If the input parameter is 0.0, the image does not change. + * If the input parameter is between 0.0 and 1.0, the effect changes. (Percentage) + * + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Applies a grayscale effect to the component. - * - * @param { number } value - Grayscale conversion ratio of the component. - *
If the value is **1.0**, the component is completely converted to grayscale. - *
If the value is **0.0**, the component remains unchanged. Between **0** and **1**, - * the value applies a linear multiplier on the grayscale effect. The unit is percentage. - *
Default value: **0.0**. - *
Value range: [0.0, 1.0]. - *

**NOTE**: - *
A value less than **0.0** evaluates to the value **0.0**. - *
A value greater than **1.0** evaluates to the value **1.0**. - *

+ * Adds a grayscale effect to the current component. + * The value is the gray scale conversion ratio. If the input parameter is 1.0, the gray scale image is completely converted to the gray scale image. If the input parameter is 0.0, the image does not change. + * If the input parameter is between 0.0 and 1.0, the effect changes. (Percentage) + * + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23528,18 +22728,11 @@ declare class CommonMethod { * @since 10 */ /** - * Applies a grayscale effect to the component. - * - * @param { number } value - Grayscale conversion ratio of the component. - *
If the value is **1.0**, the component is completely converted to grayscale. - *
If the value is **0.0**, the component remains unchanged. Between **0** and **1**, - *
the value applies a linear multiplier on the grayscale effect. The unit is percentage. - *
Default value: **0.0**. - *
Value range: [0.0, 1.0]. - *

**NOTE**: - *
A value less than **0.0** evaluates to the value **0.0**. - *
A value greater than **1.0** evaluates to the value **1.0**. - *

+ * Adds a grayscale effect to the current component. + * The value is the gray scale conversion ratio. If the input parameter is 1.0, the gray scale image is completely converted to the gray scale image. If the input parameter is 0.0, the image does not change. + * If the input parameter is between 0.0 and 1.0, the effect changes. (Percentage) + * + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23550,19 +22743,11 @@ declare class CommonMethod { grayscale(value: number): T; /** - * Applies a grayscale effect to the component. - * Compared to grayscale, this API supports the **undefined** type for the **grayscale** parameter. + * Adds a grayscale effect to the current component. + * The value is the gray scale conversion ratio. If the input parameter is 1.0, the gray scale image is completely converted to the gray scale image. If the input parameter is 0.0, the image does not change. + * If the input parameter is between 0.0 and 1.0, the effect changes. (Percentage) * - * @param { Optional } grayscale - Grayscale conversion ratio of the component. - *
If the value is **1.0**, the component is completely converted to grayscale. - *
If the value is **0.0**, the component remains unchanged. Between **0** and **1**, - *
the value applies a linear multiplier on the grayscale effect. The unit is percentage. - *
Default value: **0.0**. - *
Value range: [0.0, 1.0]. - *

**NOTE** - *
A value less than **0.0** evaluates to the value **0.0**. - *
A value greater than **1.0** evaluates to the value **1.0**. - *

+ * @param { Optional } grayscale * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23573,26 +22758,26 @@ declare class CommonMethod { grayscale(grayscale: Optional): T; /** - * Applies a color blend effect to the component. + * Adds a color overlay effect for the current component. The input parameter is the superimposed color. * - * @param { Color | string | Resource } value - Color to blend with the component. + * @param { Color | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Applies a color blend effect to the component. + * Adds a color overlay effect for the current component. The input parameter is the superimposed color. * - * @param { Color | string | Resource } value - Color to blend with the component. + * @param { Color | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Applies a color blend effect to the component. + * Adds a color overlay effect for the current component. The input parameter is the superimposed color. * - * @param { Color | string | Resource } value - Color to blend with the component. + * @param { Color | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23600,9 +22785,9 @@ declare class CommonMethod { * @since 10 */ /** - * Applies a color blend effect to the component. + * Adds a color overlay effect for the current component. The input parameter is the superimposed color. * - * @param { Color | string | Resource } value - Color to blend with the component. + * @param { Color | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23613,11 +22798,9 @@ declare class CommonMethod { colorBlend(value: Color | string | Resource): T; /** - * Applies a color blend effect to the component. - * Compared to {@link colorBlend}, this API supports the **undefined** type for the **color** parameter. + * Adds a color overlay effect for the current component. The input parameter is the superimposed color. * - * @param { Optional } color - Color to blend with the component. - *
If **color** is **undefined**, the component reverts to its original effect with no color blending. + * @param { Optional } color * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23628,50 +22811,35 @@ declare class CommonMethod { colorBlend(color: Optional): T; /** - * Applies a saturation effect to the component. + * Adds a saturation effect to the current component. + * The saturation is the ratio of the color-containing component to the achromatic component (gray). + * The larger the color-containing component, the greater the saturation. + * The larger the achromatic component, the smaller the saturation. (Percentage) * - * @param { number } value - Saturation of the component. The saturation is the ratio of the - * chromatic component to the achromatic component (gray) in a color. If the value is **1**, - * the original image is displayed. If the value is greater than **1**, a higher percentage of - * the chromatic component indicates a higher saturation. If the value is less than **1**, a higher - * percentage of the achromatic component indicates a lower saturation. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 50). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Applies a saturation effect to the component. + * Adds a saturation effect to the current component. + * The saturation is the ratio of the color-containing component to the achromatic component (gray). + * The larger the color-containing component, the greater the saturation. + * The larger the achromatic component, the smaller the saturation. (Percentage) * - * @param { number } value - Saturation of the component. The saturation is the ratio of the - * chromatic component to the achromatic component (gray) in a color. If the value is **1**, - * the original image is displayed. If the value is greater than **1**, a higher percentage of - * the chromatic component indicates a higher saturation. If the value is less than **1**, a higher - * percentage of the achromatic component indicates a lower saturation. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 50). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Applies a saturation effect to the component. + * Adds a saturation effect to the current component. + * The saturation is the ratio of the color-containing component to the achromatic component (gray). + * The larger the color-containing component, the greater the saturation. + * The larger the achromatic component, the smaller the saturation. (Percentage) * - * @param { number } value - Saturation of the component. The saturation is the ratio of the - * chromatic component to the achromatic component (gray) in a color. If the value is **1**, - * the original image is displayed. If the value is greater than **1**, a higher percentage of - * the chromatic component indicates a higher saturation. If the value is less than **1**, a higher - * percentage of the achromatic component indicates a lower saturation. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 50). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23679,17 +22847,12 @@ declare class CommonMethod { * @since 10 */ /** - * Applies a saturation effect to the component. + * Adds a saturation effect to the current component. + * The saturation is the ratio of the color-containing component to the achromatic component (gray). + * The larger the color-containing component, the greater the saturation. + * The larger the achromatic component, the smaller the saturation. (Percentage) * - * @param { number } value - Saturation of the component. The saturation is the ratio of the - * chromatic component to the achromatic component (gray) in a color. If the value is **1**, - * the original image is displayed. If the value is greater than **1**, a higher percentage of - * the chromatic component indicates a higher saturation. If the value is less than **1**, a higher - * percentage of the achromatic component indicates a lower saturation. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 50). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23700,19 +22863,12 @@ declare class CommonMethod { saturate(value: number): T; /** - * Applies a saturation effect to the component. Compared to saturate, this API supports - * the **undefined** type for the **saturate** parameter. + * Adds a saturation effect to the current component. + * The saturation is the ratio of the color-containing component to the achromatic component (gray). + * The larger the color-containing component, the greater the saturation. + * The larger the achromatic component, the smaller the saturation. (Percentage) * - * @param { Optional } saturate - Saturation of the component. The saturation is the ratio of - * the chromatic component to the achromatic component (gray) in a color. If the value is **1**, the - * original image is displayed. If the value is greater than **1**, a higher percentage of the chromatic - * component indicates a higher saturation. If the value is less than **1**, a higher percentage of the - * achromatic component indicates a lower saturation. The unit is percentage. - *
Default value: **1.0**. - *
Recommended value range: [0, 50). - *
**NOTE** - *
A value less than 0 evaluates to the value **0**. - *
If **saturate** is **undefined**, the saturation effect is reset to **1.0**. + * @param { Optional } saturate * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23723,32 +22879,29 @@ declare class CommonMethod { saturate(saturate: Optional): T; /** - * Sepia conversion ratio of the component. + * Converts the image to sepia. Value defines the scale of the conversion. + * A value of 1 is completely sepia, and a value of 0 does not change the image. (Percentage) * - * @param { number } value - Sepia conversion ratio of the component. If the value is **1**, the image - * is completely sepia. If the value is **0**, the component remains unchanged. The unit is percentage. - *
Value range: [0, +∞). + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sepia conversion ratio of the component. + * Converts the image to sepia. Value defines the scale of the conversion. + * A value of 1 is completely sepia, and a value of 0 does not change the image. (Percentage) * - * @param { number } value - Sepia conversion ratio of the component. If the value is **1**, the image - * is completely sepia. If the value is **0**, the component remains unchanged. The unit is percentage. - *
Value range: [0, +∞). + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sepia conversion ratio of the component. + * Converts the image to sepia. Value defines the scale of the conversion. + * A value of 1 is completely sepia, and a value of 0 does not change the image. (Percentage) * - * @param { number } value - Sepia conversion ratio of the component. If the value is **1**, the image - * is completely sepia. If the value is **0**, the component remains unchanged. The unit is percentage. - *
Value range: [0, +∞). + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23756,11 +22909,10 @@ declare class CommonMethod { * @since 10 */ /** - * Sepia conversion ratio of the component. + * Converts the image to sepia. Value defines the scale of the conversion. + * A value of 1 is completely sepia, and a value of 0 does not change the image. (Percentage) * - * @param { number } value - Sepia conversion ratio of the component. If the value is **1**, the image - * is completely sepia. If the value is **0**, the component remains unchanged. The unit is percentage. - *
Value range: [0, +∞). + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23771,13 +22923,10 @@ declare class CommonMethod { sepia(value: number): T; /** - * Sepia conversion ratio of the component. Compared to sepia, - * this API supports the **undefined** type for the **sepia** parameter. + * Converts the image to sepia. Value defines the scale of the conversion. + * A value of 1 is completely sepia, and a value of 0 does not change the image. (Percentage) * - * @param { Optional } sepia - Sepia conversion ratio of the component. If the value is **1**, the - * image is completely sepia. If the value is **0**, the component remains unchanged. The unit is percentage. - *
If **sepia** is **undefined**, the component reverts to its original effect. - *
Value range: [0, +∞). + * @param { Optional } sepia * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23832,20 +22981,10 @@ declare class CommonMethod { invert(value: number | InvertOptions): T; /** - * Inverts the image. Compared to invert, - * this API supports the **undefined** type for the **options** parameter. + * Invert the input image. Value defines the scale of the conversion. 100% of the value is a complete reversal. + * A value of 0% does not change the image. (Percentage) * - * @param { Optional } options - How the image is inverted. - *
If the value is of the number type, - *
it indicates the inversion ratio. If the value is **1**, - *
the image is completely inverted. If the value is **0**, the image remains unchanged. - *
The unit is percentage.
Value range: [0, 1]
A value less than 0 evaluates to the value **0**. - *
If the value is of the InvertOptions type, the grayscale value of the background color is compared - *
with the threshold range. If the grayscale value is greater than the upper bound of the threshold range, - *
the **high** value is used. If the grayscale value is less than the lower bound of the threshold range, - *
the **low** value is used. If the grayscale value is within the threshold range, - *
the background color changes linearly from high to low.
If **options** is **undefined**, - *
the component reverts to its original effect. + * @param { Optional } options - value indicates the scale of the conversion or the options of invert. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23856,7 +22995,7 @@ declare class CommonMethod { invert(options: Optional): T; /** - * Applies a system bar effect to the component, which means to invert colors based on the background and add a blur. + * Sets system bar effect to the component. * * @returns { T } return the component attribute. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -23866,35 +23005,32 @@ declare class CommonMethod { systemBarEffect(): T; /** - * Rotates the hue of the component. + * Adds the hue rotation effect to the current component. + * The input parameter is the rotation angle. When the input parameter is 0deg, the image does not change (the default value is 0deg), and the input parameter does not have a maximum value. + * If the value exceeds 360deg, the image is circled again. * - * @param { number | string } value - Hue rotation angle of the component. - *
A rotation of 360 degrees leaves the color unchanged. - *
A rotation of 180 degrees and then -180 degrees also leaves the color unchanged. - *
When the data type is number, the value **90** is equivalent to **'90deg'**. + * @param { number | string } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Rotates the hue of the component. + * Adds the hue rotation effect to the current component. + * The input parameter is the rotation angle. When the input parameter is 0deg, the image does not change (the default value is 0deg), and the input parameter does not have a maximum value. + * If the value exceeds 360deg, the image is circled again. * - * @param { number | string } value - Hue rotation angle of the component. - *
A rotation of 360 degrees leaves the color unchanged. - *
A rotation of 180 degrees and then -180 degrees also leaves the color unchanged. - *
When the data type is number, the value **90** is equivalent to **'90deg'**. + * @param { number | string } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Rotates the hue of the component. + * Adds the hue rotation effect to the current component. + * The input parameter is the rotation angle. When the input parameter is 0deg, the image does not change (the default value is 0deg), and the input parameter does not have a maximum value. + * If the value exceeds 360deg, the image is circled again. * - * @param { number | string } value - Hue rotation angle of the component. - *
A rotation of 360 degrees leaves the color unchanged. - *
A rotation of 180 degrees and then -180 degrees also leaves the color unchanged. - *
When the data type is number, the value **90** is equivalent to **'90deg'**. + * @param { number | string } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23902,12 +23038,11 @@ declare class CommonMethod { * @since 10 */ /** - * Rotates the hue of the component. + * Adds the hue rotation effect to the current component. + * The input parameter is the rotation angle. When the input parameter is 0deg, the image does not change (the default value is 0deg), and the input parameter does not have a maximum value. + * If the value exceeds 360deg, the image is circled again. * - * @param { number | string } value - Hue rotation angle of the component. - *
A rotation of 360 degrees leaves the color unchanged. - *
A rotation of 180 degrees and then -180 degrees also leaves the color unchanged. - *
When the data type is number, the value **90** is equivalent to **'90deg'**. + * @param { number | string } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23918,8 +23053,9 @@ declare class CommonMethod { hueRotate(value: number | string): T; /** - * Rotates the hue of the component. Compared to hueRotate, - * this API supports the **undefined** type for the **rotation** parameter. + * Adds the hue rotation effect to the current component. + * The input parameter is the rotation angle. When the input parameter is 0deg, the image does not change (the default value is 0deg), and the input parameter does not have a maximum value. + * If the value exceeds 360deg, the image is circled again. * * @param { Optional } rotation * @returns { T } @@ -23932,18 +23068,9 @@ declare class CommonMethod { hueRotate(rotation: Optional): T; /** - * Sets whether to draw shadows of child nodes in the component at the same layer, - * so that the shadows of elements at the same layer overlap. + * Add an attribute to control whether the shadows of the child nodes overlap each other. * - * @param { boolean } value - Whether to draw shadows of child nodes in the component - * at the same layer, so that the shadows of elements at the same layer overlap. - *
Default value: **false**. - *
**NOTE** - *
1. When this feature is disabled (default), if the shadow radius of a child node - * is large, the shadows of the child nodes may overlap. This overlap issue does not occur - * when the feature is enabled. - *
2. Avoid nesting **useShadowBatching**. When used in nested mode, **useShadowBatching** - * takes effect for the current child node only and cannot be recursively used. + * @param { boolean } value - true means the shadows of the child nodes overlap each other effect and drawn in batches. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23951,18 +23078,9 @@ declare class CommonMethod { * @since 11 */ /** - * Sets whether to draw shadows of child nodes in the component at the same layer, - * so that the shadows of elements at the same layer overlap. + * Add an attribute to control whether the shadows of the child nodes overlap each other. * - * @param { boolean } value - Whether to draw shadows of child nodes in the component - * at the same layer, so that the shadows of elements at the same layer overlap. - *
Default value: **false**. - *
**NOTE** - *
1. When this feature is disabled (default), if the shadow radius of a child node - * is large, the shadows of the child nodes may overlap. This overlap issue does not occur - * when the feature is enabled. - *
2. Avoid nesting **useShadowBatching**. When used in nested mode, **useShadowBatching** - * takes effect for the current child node only and cannot be recursively used. + * @param { boolean } value - true means the shadows of the child nodes overlap each other effect and drawn in batches. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23973,21 +23091,9 @@ declare class CommonMethod { useShadowBatching(value: boolean): T; /** - * Sets whether to draw shadows of child nodes in the component at the same layer, - * so that the shadows of elements at the same layer overlap. Compared to - * useShadowBatching11+, this API supports the - * **undefined** type for the **use** parameter. + * Add an attribute to control whether the shadows of the child nodes overlap each other. * - * @param { Optional } use - Whether to draw shadows of child nodes in the - * component at the same layer, so that the shadows of elements at the same layer overlap. - *
Default value: **false**. - *
**NOTE** - *
1. When this feature is disabled (default), if the shadow radius of a child node is large, - * the shadows of the child nodes may overlap. This overlap issue does not occur when the feature - * is enabled.
2. Avoid nesting **useShadowBatching**. When used in nested mode, - * **useShadowBatching** takes effect for the current child node only and cannot be recursively used. - *
If **use** is **undefined**, the component reverts to its original effect of not using - * shadow overlapping. + * @param { Optional } use - true means the shadows of the child nodes overlap each other effect and drawn in batches. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -23997,18 +23103,13 @@ declare class CommonMethod { */ useShadowBatching(use: Optional): T; - /** - * Specifies whether to apply the effect defined by the parent - * [EffectComponent](ts-container-effectcomponent-sys.md) or the window. - * - * @param { Optional } useEffect - Whether to apply the effect defined by the parent - * **EffectComponent** or the window. - *
The value **true** means to apply the effect defined by the parent **EffectComponent** - * or the window. - *
Default value: **false**. - * @param { EffectType } [effectType] - Type of effect to apply to the component, which is defined by - * the parent **EffectComponent** or the window. - *
Default value: **EffectType.DEFAULT**. + /** + * Sets whether the component should apply the effects template defined by the parent effectComponent or window. + * If multiple parent effectComponents are found, the nearest one will be used. + * If no parent effectComponent is found, this method has no effect. + * + * @param { boolean } useEffect - true means the component should apply the effects template defined by the parent effectComponent or window. + * @param { EffectType } effectType - the effect type of the effects template, defined by the parent effectComponent or window. * @returns { T } return the component attribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -24017,20 +23118,12 @@ declare class CommonMethod { useEffect(useEffect: boolean, effectType: EffectType): T; /** - * Specifies whether to apply the effect defined by the parent - * EffectComponent or - * the window. Compared to useEffect14+, - * this API supports the **undefined** type for the **useEffect** parameter. - * - * @param { Optional } useEffect - Whether to apply the effect defined by - * the parent **EffectComponent** or the window. - *
The value **true** means to apply the effect defined by the parent - * **EffectComponent** or the window. - *
Default value: **false**. - *
If **useEffect** is set to **undefined**, the previous value is retained. - * @param { EffectType } [effectType] - Type of effect to apply to the component, which - * is defined by the parent **EffectComponent** or the window. - *
Default value: **EffectType.DEFAULT**. + * Sets whether the component should apply the effects template defined by the parent effectComponent or window. + * If multiple parent effectComponents are found, the nearest one will be used. + * If no parent effectComponent is found, this method has no effect. + * + * @param { Optional } useEffect - true means the component should apply the effects template defined by the parent effectComponent or window. + * @param { EffectType } [effectType] - the effect type of the effects template, defined by the parent effectComponent or window. * @returns { T } return the component attribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -24039,12 +23132,11 @@ declare class CommonMethod { useEffect(useEffect: Optional, effectType?: EffectType): T; /** - * Specifies whether to combine the drawing of special effects, such as background blur. + * Sets whether the component should apply the effects template defined by the parent effectComponent. + * If multiple parent effectComponents are found, the nearest one will be used. + * If no parent effectComponent is found, this method has no effect. * - * @param { boolean } value - Whether the component inherits the special effect settings of the - * **EffectComponent** component.
The value **true** means that the component inherits the - * special effect settings of the **EffectComponent** component, and **false** means the opposite. - *
Default value: **false**. + * @param { boolean } value - true means the component should apply the effects template. * @returns { T } return the component attribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -24053,32 +23145,29 @@ declare class CommonMethod { useEffect(value: boolean): T; /** - * Applies a background blur effect to the component. You can customize the blur radius and grayscale parameters. + * Adds the background blur effect for the current component. The input parameter is the blur radius. + * The larger the blur radius, the more blurred the background. If the value is 0, the background blur is not blurred. * - * @param { number } value - Background blur effect to apply to the component. - *
The input parameter is the blur radius. The larger the radius is, the more blurred the background is. - *
If the value is **0**, the background is not blurred. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Applies a background blur effect to the component. You can customize the blur radius and grayscale parameters. + * Adds the background blur effect for the current component. The input parameter is the blur radius. + * The larger the blur radius, the more blurred the background. If the value is 0, the background blur is not blurred. * - * @param { number } value - Background blur effect to apply to the component. - *
The input parameter is the blur radius. The larger the radius is, the more blurred the background is. - *
If the value is **0**, the background is not blurred. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Applies a background blur effect to the component. You can customize the blur radius and grayscale parameters. + * Adds the background blur effect for the current component. The input parameter is the blur radius. + * The larger the blur radius, the more blurred the background. If the value is 0, the background blur is not blurred. * - * @param { number } value - Background blur effect to apply to the component. - *
The input parameter is the blur radius. The larger the radius is, the more blurred the background is. - *
If the value is **0**, the background is not blurred. + * @param { number } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24086,12 +23175,11 @@ declare class CommonMethod { * @since 10 */ /** - * Applies a background blur effect to the component. You can customize the blur radius and grayscale parameters. + * Adds the background blur effect for the current component. The input parameter is the blur radius. + * The larger the blur radius, the more blurred the background. If the value is 0, the background blur is not blurred. * - * @param { number } value - Background blur effect to apply to the component. - *
The input parameter is the blur radius. The larger the radius is, the more blurred the background is. - *
If the value is **0**, the background is not blurred. - * @param { BlurOptions } [options] - Grayscale parameters. + * @param { number } value - value indicates radius of backdrop blur. + * @param { BlurOptions } [options] - options indicates the backdrop blur options. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24116,7 +23204,7 @@ declare class CommonMethod { */ backdropBlur(radius: Optional, options?: BlurOptions): T; - /** + /** * Adds the background blur effect for the current component. The input parameter is the blur radius. * The larger the blur radius, the more blurred the background. If the value is 0, the background blur is not blurred. * @@ -24133,30 +23221,18 @@ declare class CommonMethod { backdropBlur(radius: Optional, options?: BlurOptions, sysOptions?: SystemAdaptiveOptions): T; /** - * Sets whether the component and its child components are rendered off - * the screen as a whole before being blended with its parent. + * Composite the contents of this view and its children into an offscreen cache before display in the screen. * - * @param { boolean } value - Whether the component and its child components are rendered - * off the screen as a whole before being blended with its parent. If the opacity of the - * component is not 1, the drawing effect may vary depending on the value. - *
Default value: **false**. - *
The value **true** means the component and its child components are rendered off - * the screen as a whole, and **false** means the opposite. + * @param { boolean } value - if this view and its children need to composite into an offscreen cache. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Sets whether the component and its child components are rendered off - * the screen as a whole before being blended with its parent. + * Composite the contents of this view and its children into an offscreen cache before display in the screen. * - * @param { boolean } value - Whether the component and its child components are rendered - * off the screen as a whole before being blended with its parent. If the opacity of the - * component is not 1, the drawing effect may vary depending on the value. - *
Default value: **false**. - *
The value **true** means the component and its child components are rendered off - * the screen as a whole, and **false** means the opposite. + * @param { boolean } value - if this view and its children need to composite into an offscreen cache. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24164,15 +23240,9 @@ declare class CommonMethod { * @since 11 */ /** - * Sets whether the component and its child components are rendered off - * the screen as a whole before being blended with its parent. + * Composite the contents of this view and its children into an offscreen cache before display in the screen. * - * @param { boolean } value - Whether the component and its child components are rendered - * off the screen as a whole before being blended with its parent. If the opacity of the - * component is not 1, the drawing effect may vary depending on the value. - *
Default value: **false**. - *
The value **true** means the component and its child components are rendered off - * the screen as a whole, and **false** means the opposite. + * @param { boolean } value - if this view and its children need to composite into an offscreen cache. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24183,16 +23253,9 @@ declare class CommonMethod { renderGroup(value: boolean): T; /** - * Sets whether the component and its child components are rendered off the screen as a whole - * before being blended with its parent. Compared to renderGroup10+, - * this API supports the **undefined** type for the **isGroup** parameter. + * Composite the contents of this view and its children into an offscreen cache before display in the screen. * - * @param { Optional } isGroup - Whether the component and its child components are rendered - * off the screen as a whole before being blended with its parent. If the opacity of the component is - * not 1, the drawing effect may vary depending on the value. - *
Default value: **false**. - *
If **isGroup** is **undefined**, the component reverts to its original effect of not enabling - * offscreen rendering as a whole before blending with the parent component. + * @param { Optional } isGroup - if this view and its children need to composite into an offscreen cache. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24203,15 +23266,10 @@ declare class CommonMethod { renderGroup(isGroup: Optional): T; /** - * Sets whether to freeze the component. When frozen, the component and its children are cached for - * repeated drawing after offscreen rendering, without updating internal attributes. + * Sets whether the component should remain stationary, reusing the results of the current frame's off-screen rendering. + * If the input parameter is true, the component and subcomponent changes do not affect the display. * - * @param { boolean } value - Whether to freeze the component. When frozen, the component and its children - * are cached for repeated drawing after offscreen rendering, without updating internal attributes. If the - * opacity of the component is not 1, the drawing effect may vary depending on the value. - *
Default value: **false**. - *
**true**: Freeze the component. - *
**false**: Do not freeze the component. + * @param { boolean } value - true means the component should remain stationary. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -24220,17 +23278,10 @@ declare class CommonMethod { freeze(value: boolean): T; /** - * Sets whether to freeze the component. When frozen, the component and its children are cached for repeated - * drawing after offscreen rendering, without updating internal attributes. Compared to freeze, - * this API supports the **undefined** type for the **freeze** parameter. + * Sets whether the component should remain stationary, reusing the results of the current frame's off-screen rendering. + * If the input parameter is true, the component and subcomponent changes do not affect the display. * - * @param { Optional } freeze - Whether to freeze the component. When frozen, the component and its - * children are cached for repeated drawing after offscreen rendering, without updating internal attributes. - * If the opacity of the component is not 1, the drawing effect may vary depending on the value. - *
Default value: **false**. - *
**true**: Freeze the component. - *
**false**: Do not freeze the component. - *
If **freeze** is set to **undefined**, the previous value is retained. + * @param { Optional } freeze - true means the component should remain stationary. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -24239,29 +23290,32 @@ declare class CommonMethod { freeze(freeze: Optional): T; /** - * Sets the translation effect for page transitions. + * Sets the translation effect during page transition. + * The value is the start point of entry and end point of exit. + * When this parameter is set together with slide, slide takes effect by default. * - * @param { TranslateOptions } value - Translation effect for page transitions - *
specifying the start value for entrance and the end value for exit. default:{x:0,y:0,z:0} + * @param { TranslateOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the translation effect for page transitions. + * Sets the translation effect during page transition. + * The value is the start point of entry and end point of exit. + * When this parameter is set together with slide, slide takes effect by default. * - * @param { TranslateOptions } value - Translation effect for page transitions - *
specifying the start value for entrance and the end value for exit. default:{x:0,y:0,z:0} + * @param { TranslateOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the translation effect for page transitions. + * Sets the translation effect during page transition. + * The value is the start point of entry and end point of exit. + * When this parameter is set together with slide, slide takes effect by default. * - * @param { TranslateOptions } value - Translation effect for page transitions - *
specifying the start value for entrance and the end value for exit. default:{x:0,y:0,z:0} + * @param { TranslateOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24269,10 +23323,9 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the translation effect for page transitions. + * Set component translation. * - * @param { TranslateOptions } value - Translation effect for page transitions - *
specifying the start value for entrance and the end value for exit. default:{x:0,y:0,z:0} + * @param { TranslateOptions } value default:{x:0,y:0,z:0} * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24283,14 +23336,9 @@ declare class CommonMethod { translate(value: TranslateOptions): T; /** - * Translates the component. - * Compared to {@link translate}, this API supports the **undefined** type for the **translate** parameter. - + * Set component translation. * - * @param { Optional } translate - How the component is translated in the coordinate - *
system (as shown below) with the upper left corner of the component as the coordinate origin. - *
Values of **x**, **y**, and **z** indicate the translation distance along the respective axis. - *
default:{x:0,y:0,z:0} + * @param { Optional } translate default:{x:0,y:0,z:0} * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24303,9 +23351,7 @@ declare class CommonMethod { /** * Sets the zoom effect during page transition. The value is the start point of entry and end point of exit. * - * @param { ScaleOptions } value - Scale ratio along the x-, y-, and z-axis. The default value is **1**. - *
**centerX** and **centerY** are used to set the scale center point. - *
default:{x:1,y:1,z:1,centerX:'50%',centerY:'50%'} + * @param { ScaleOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 @@ -24313,9 +23359,7 @@ declare class CommonMethod { /** * Sets the zoom effect during page transition. The value is the start point of entry and end point of exit. * - * @param { ScaleOptions } value - Scale ratio along the x-, y-, and z-axis. The default value is **1**. - *
**centerX** and **centerY** are used to set the scale center point. - *
default:{x:1,y:1,z:1,centerX:'50%',centerY:'50%'} + * @param { ScaleOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -24324,9 +23368,7 @@ declare class CommonMethod { /** * Sets the zoom effect during page transition. The value is the start point of entry and end point of exit. * - * @param { ScaleOptions } value - Scale ratio along the x-, y-, and z-axis. The default value is **1**. - *
**centerX** and **centerY** are used to set the scale center point. - *
default:{x:1,y:1,z:1,centerX:'50%',centerY:'50%'} + * @param { ScaleOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24334,11 +23376,9 @@ declare class CommonMethod { * @since 10 */ /** - * Scales the component. + * Set component scaling. * - * @param { ScaleOptions } value - Scale ratio along the x-, y-, and z-axis. The default value is **1**. - *
**centerX** and **centerY** are used to set the scale center point. - *
default:{x:1,y:1,z:1,centerX:'50%',centerY:'50%'} + * @param { ScaleOptions } value default:{x:1,y:1,z:1,centerX:'50%',centerY:'50%'} * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24349,13 +23389,9 @@ declare class CommonMethod { scale(value: ScaleOptions): T; /** - * Scales the component. - * Compared to {@link scale} , this API supports the **undefined** type for the **options** parameter. + * Set component scaling. * - * @param { Optional } options - Scale ratio along the x-, y-, and z-axis. - *
The default value is **1**. **centerX** and **centerY** are used to set the scale center point. - *
default:{x:1,y:1,z:1,centerX:'50%',centerY:'50%'} - *
If **options** is **undefined**, the component reverts to its original state with no scaling. + * @param { Optional } options default:{x:1,y:1,z:1,centerX:'50%',centerY:'50%'} * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24474,7 +23510,7 @@ declare class CommonMethod { rotate(value: RotateOptions): T; /** - * Rotates the component. This API supports the **undefined** type for the **options** parameter. + * Set component rotation. * * @param { Optional } options default:{x:0,y:0,z:0,centerX:'50%',centerY:'50%',centerZ:0,perspective:0} * @returns { T } @@ -24499,27 +23535,28 @@ declare class CommonMethod { */ rotate(options: Optional): T; + /** - * Sets the transformation matrix of the component. + * Sets the transformation matrix for the current component. * - * @param { object } value - Transformation matrix of the component. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the transformation matrix of the component. + * Sets the transformation matrix for the current component. * - * @param { object } value - Transformation matrix of the component. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Sets the transformation matrix of the component. + * Sets the transformation matrix for the current component. * - * @param { object } value - Transformation matrix of the component. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24529,11 +23566,9 @@ declare class CommonMethod { transform(value: object): T; /** - * Sets the transformation matrix of the component. - * Compared to {@link transform}, this API supports the **undefined** type for the **transform** parameter. + * Sets the transformation matrix for the current component. * - * @param { Optional } transform - How the component is translated in the coordinate - *
system (as shown below) with the upper left corner of the component as the coordinate origin. + * @param { Optional } transform * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24718,7 +23753,7 @@ declare class CommonMethod { /** * Controls the display or hide of the current component. * - * @param { Visibility } value - Whether the component is visible. + * @param { Visibility } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24756,8 +23791,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the percentage of the parent container's remaining space that is allocated to the component. - * Default value: **0**. + * The percentage of the remaining space of the Flex container allocated to the component on which this property resides. * * @param { number } value * @returns { T } @@ -24797,8 +23831,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the percentage of the parent container's shrink size that is allocated to the component. - * Default value: 0 when the parent container is Column or Row, 1 when the parent container is Flex.. + * The proportion of the Flex container compression size assigned to the component on which this attribute resides. * * @param { number } value * @returns { T } @@ -24838,8 +23871,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the base size of the component in the main axis of the parent container. - * Default value: **'auto'**. + * The base dimension of the assembly on which this attribute is located in the direction of the principal axis in the Flex container. * * @param { number | string } value * @returns { T } @@ -24879,8 +23911,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the alignment mode of the child components along the cross axis of the parent container. - * Default value: **ItemAlign.Auto**. + * Overrides the default configuration of alignItems in the Flex Layout container. * * @param { ItemAlign } value * @returns { T } @@ -24895,7 +23926,7 @@ declare class CommonMethod { /** * Defines the align rules of child component in Stack container. * - * @param { LocalizedAlignment} alignment + * @param { LocalizedAlignment } alignment * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -24933,8 +23964,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the display priority for the component in the layout container. - *
This parameter is only effective in Row, Column, and Flex (single-line) container components. + * Sets the current component and displays the priority in the layout container. This parameter is valid only in Row, Column, and Flex single-row layouts. * * @param { number } value * @returns { T } @@ -24987,47 +24017,29 @@ declare class CommonMethod { zIndex(value: number): T; /** - * If the components of the two pages are configured with the same ID. - * The shared element transition is performed during transition. - * If the parameter is set to an empty string, the shared element transition does not occur. - * For details about the options parameter, see the options parameter description. + * If the components of the two pages are configured with the same ID, the shared element transition is performed during transition. If the parameter is set to an empty string, the shared element transition does not occur. For details about the options parameter, see the options parameter description. * - * @param { string } id - Transition of the shared element. - *
If the same **id** value is configured for a component on the two pages, - *
this component is considered as a shared element of the pages. - *
If the **id** value is an empty string, no transition will be applied to the component. - * @param { sharedTransitionOptions } options - Parameters of the shared element transition animation. + * @param { string } id + * @param { sharedTransitionOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * If the components of the two pages are configured with the same ID. - * The shared element transition is performed during transition. - * If the parameter is set to an empty string, the shared element transition does not occur. - * For details about the options parameter, see the options parameter description. + * If the components of the two pages are configured with the same ID, the shared element transition is performed during transition. If the parameter is set to an empty string, the shared element transition does not occur. For details about the options parameter, see the options parameter description. * - * @param { string } id - Transition of the shared element. - *
If the same **id** value is configured for a component on the two pages, - *
this component is considered as a shared element of the pages. - *
If the **id** value is an empty string, no transition will be applied to the component. - * @param { sharedTransitionOptions } options - Parameters of the shared element transition animation. + * @param { string } id + * @param { sharedTransitionOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * If the components of the two pages are configured with the same ID. - * The shared element transition is performed during transition. - * If the parameter is set to an empty string, the shared element transition does not occur. - * For details about the options parameter, see the options parameter description. + * If the components of the two pages are configured with the same ID, the shared element transition is performed during transition. If the parameter is set to an empty string, the shared element transition does not occur. For details about the options parameter, see the options parameter description. * - * @param { string } id - Transition of the shared element. - *
If the same **id** value is configured for a component on the two pages, - *
this component is considered as a shared element of the pages. - *
If the **id** value is an empty string, no transition will be applied to the component. - * @param { sharedTransitionOptions } options - Parameters of the shared element transition animation. + * @param { string } id + * @param { sharedTransitionOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -25064,8 +24076,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets how elements are laid out along the main axis of the container. - * Default value: **Direction.Auto**. + * Sets the sliding direction. The enumerated value supports logical AND (&) and logical OR (|). * * @param { Direction } value * @returns { T } @@ -25105,8 +24116,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the alignment mode of the component content in the drawing area. - * Default value: **Alignment.Center**. + * align * * @param { Alignment } value * @returns { T } @@ -25118,7 +24128,7 @@ declare class CommonMethod { */ align(value: Alignment): T; - /** + /** * align * * @param { Alignment | LocalizedAlignment } alignment @@ -25183,8 +24193,7 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the absolute position of the component relative to the position of the parent component. - *
The attribute is not available for a layout container whose width and height are zero. + * position * * @param { Position | Edges | LocalizedEdges } value * @returns { T } @@ -25235,8 +24244,7 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the anchor for locating the component, which is used to move the component - * further away from the position specified by position or offset. + * Sets the anchor point of the element when it is positioned. The base point is offset from the top start point of the element. * * @param { Position | LocalizedPosition} value * @returns { T } @@ -25291,9 +24299,8 @@ declare class CommonMethod { * @since 11 */ /** - * Sets the offset of the component relative to its original position. - *
The offset attribute does not affect the layout of the parent container. - * It adjusts the component position only during drawing. + * Coordinate offset relative to the layout completion position. + * Setting this attribute does not affect the layout of the parent container. The position is adjusted only during drawing. * * @param { Position | Edges | LocalizedEdges } value * @returns { T } @@ -25307,7 +24314,7 @@ declare class CommonMethod { /** * If the value is true, the component is available and can respond to operations such as clicking. - * If it is set to false, click operations are not responded. + * If it is set to false, click operations are not responded. * * @param { boolean } value * @returns { T } @@ -25316,7 +24323,7 @@ declare class CommonMethod { */ /** * If the value is true, the component is available and can respond to operations such as clicking. - * If it is set to false, click operations are not responded. + * If it is set to false, click operations are not responded. * * @param { boolean } value * @returns { T } @@ -25326,7 +24333,7 @@ declare class CommonMethod { */ /** * If the value is true, the component is available and can respond to operations such as clicking. - * If it is set to false, click operations are not responded. + * If it is set to false, click operations are not responded. * * @param { boolean } value * @returns { T } @@ -25337,7 +24344,7 @@ declare class CommonMethod { */ /** * If the value is true, the component is available and can respond to operations such as clicking. - * If it is set to false, click operations are not responded. + * If it is set to false, click operations are not responded. * * @param { boolean } value * @returns { T } @@ -25386,8 +24393,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the alignment rules in the relative container. - * This API is valid only when the container is RelativeContainer. + * Specifies the alignRules of relative container * * @param { AlignRuleOption } value * @returns { T } @@ -25400,11 +24406,7 @@ declare class CommonMethod { alignRules(value: AlignRuleOption): T; /** - * Sets the alignment rules in the relative container. - *
This API is valid only when the container is RelativeContainer. - *
This API takes the right-to-left scripts into account, using start and end instead of - * left and right for alignment in the horizontal direction. Prioritize this API in aligning - * child components in the relative container. + * Specifies the localized alignRules of relative container * * @param { LocalizedAlignRuleOptions } alignRule * @returns { T } @@ -25417,11 +24419,7 @@ declare class CommonMethod { alignRules(alignRule: LocalizedAlignRuleOptions): T; /** - * Sets the parameters of the chain in which the component is the head. - *
This parameter has effect only when the parent container is RelativeContainer. - *
The chain head is the first component in the chain that satisfies the chain formation rules. - * In a horizontal layout, it starts from the left (or from the right in a mirrored language - * layout). In a vertical layout, it starts from the top. + * Specifies the direction and style of chain in relative container * * @param { Axis } direction - indicates direction of the chain * @param { ChainStyle } style - indicates style of the chain @@ -25461,12 +24459,7 @@ declare class CommonMethod { * @since 10 */ /** - * Sets the aspect ratio of the component, which can be obtained using the following formula: width/height. - *
If only width and aspectRatio are set, the height is calculated using the following formula: width/aspectRatio. - *
If only height and aspectRatio are set, the width is calculated using the following formula: height x aspectRatio. - *
If width, height, and aspectRatio are all set, the explicitly set height is ignored, and the effective height is - * calculated using the following formula: width/aspectRatio. - *
This parameter takes effect only when a valid value greater than 0 is specified. + * Specifies the aspect ratio of the current component. * * @param { number } value * @returns { T } @@ -25533,9 +24526,6 @@ declare class CommonMethod { /** * After a listener is bound, the component can be dragged. After the drag occurs, a callback is triggered. * (To be triggered, press and hold for 170 milliseconds (ms)) - * - * NOTE:
- * The global builder is not supported. * * @param { function } event * @returns { T } @@ -25708,36 +24698,6 @@ declare class CommonMethod { */ onDragEnd(event: (event: DragEvent, extraParams?: string) => void): T; - /** - * Enables the component as a drag-and-drop target with spring loading functionality. - * - * When a dragged object hovers over the target, it triggers a callback notification. Spring Loading is an enhanced - * feature for drag-and-drop operations, allowing users to automatically trigger view transitions during dragging - * by hovering (hover) without needing to use another hand. - * This feature is primarily designed to enhance the smoothness and efficiency of drag-and-drop operations. Below are - * some common scenarios suitable for supporting this feature: - * - In a file manager, when dragging a file and hovering over a folder, the folder is automatically opened. - * - On a desktop launcher, when dragging a file and hovering over an application icon, the application is - * automatically opened. - * - * Please note: - * 1. Registering spring-loaded or drag-and-drop events (onDragEnter/Move/Leave/Drop) on a component makes it a - * drag-and-drop target. Only one target can be the responder at the same time when user drags and hovers on, and - * child components always have higher priority. - * 2. Once a complete spring loading is triggered on a component, new spring loading detection will only occur after the - * dragged object leaves and re-enters the component's range. - * - * @param { Callback | null } callback Registers the callback for spring loading response, or - * sets it to null to disable the support for spring loading. - * @param { DragSpringLoadingConfiguration } [configuration] The initialized spring loading configuration which is - * only used when the entire spring detecting. - * @returns { T } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - */ - onDragSpringLoading(callback: Callback | null, configuration?: DragSpringLoadingConfiguration): T; - /** * Allowed drop uniformData type for this node. * @@ -25781,7 +24741,6 @@ declare class CommonMethod { * Enable the selectable area can be dragged. * * @param { boolean } value - true means the area can be dragged, false means the area can't be dragged. - * The default value is false. * @returns { T } property value of type T. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -25908,7 +24867,7 @@ declare class CommonMethod { */ overlay(value: string | CustomBuilder | ComponentContent, options?: OverlayOptions): T; - /** + /** * Config toolbar for current component. * * @param { CustomBuilder } value @@ -25926,7 +24885,7 @@ declare class CommonMethod { * colors: Color description for gradients. * repeating: repeating. The default value is false * - * @param { object } value - Linear gradient. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 @@ -25938,7 +24897,7 @@ declare class CommonMethod { * colors: Color description for gradients. * repeating: repeating. The default value is false * - * @param { object } value - Linear gradient. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -25951,7 +24910,7 @@ declare class CommonMethod { * colors: Color description for gradients. * repeating: repeating. The default value is false * - * @param { object } value - Linear gradient. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -25965,7 +24924,7 @@ declare class CommonMethod { * colors: Color description for gradients. * repeating: repeating. The default value is false * - * @param { object } value - Linear gradient. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -25975,12 +24934,9 @@ declare class CommonMethod { */ /** * Linear Gradient - * angle: Angle of Linear Gradient. The default value is 180; - * direction: Direction of Linear Gradient. The default value is GradientDirection.Bottom; - * colors: Color description for gradients. - * repeating: repeating. The default value is false + * angle: Angle of Linear Gradient; direction:Direction of Linear Gradient; colors:Color description for gradients,repeating:repeating. * - * @param { object } value - Linear gradient. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -25995,8 +24951,8 @@ declare class CommonMethod { * colors: Color description for gradients. * repeating: repeating. The default value is false * - * @param { object } value - Linear gradient. - *
If **options** is **undefined**, the linear gradient is disabled. + * Anonymous Object Rectification. + * @param { LinearGradientOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26013,8 +24969,7 @@ declare class CommonMethod { * colors: Color description for gradients. * repeating: repeating. The default value is false * - * @param { Optional } options - Linear gradient. - *
If **options** is **undefined**, the linear gradient is disabled. + * @param { Optional } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26025,80 +24980,47 @@ declare class CommonMethod { linearGradient(options: Optional): T; /** - * Creates a sweep gradient. - * - * @param { SweepGradientOptions } value - Sweep gradient, which can sweep around the specified - * center point in the 0–360 degree range. If the rotation angle exceeds the range, a monochrome - * color instead of a gradient will be drawn.
- **center**: center of the sweep gradient, that - * is, the coordinates relative to the upper left corner of the current component. - *
- **start**: start angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **end**: end angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **rotation**: rotation angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- colors: array of color stops, - * each of which consists of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. - *
**NOTE** - *
A value less than 0 is treated as **0**. A value greater than 360 is treated as **360**. - *
When **start**, **end**, or **rotation** is specified with a string, the string must be a number - * or a number followed by one of the following units: deg, rad, grad, and turn. Valid value examples - * are "90", "90deg", and "1.57rad". + * Angle Gradient + * center:is the center point of the angle gradient + * start:Start point of angle gradient. The default value is 0 + * end:End point of angle gradient. The default value is 0 + * number:number + * rotating:rotating. The default value is 0 + * colors:Color description for gradients + * repeating:repeating. The default value is false + * + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Creates a sweep gradient. + * Angle Gradient + * center:is the center point of the angle gradient + * start:Start point of angle gradient. The default value is 0 + * end:End point of angle gradient. The default value is 0 + * number:number + * rotating:rotating. The default value is 0 + * colors:Color description for gradients + * repeating:repeating. The default value is false * - * @param { SweepGradientOptions } value - Sweep gradient, which can sweep around the specified - * center point in the 0–360 degree range. If the rotation angle exceeds the range, a monochrome - * color instead of a gradient will be drawn.
- **center**: center of the sweep gradient, that - * is, the coordinates relative to the upper left corner of the current component. - *
- **start**: start angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **end**: end angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **rotation**: rotation angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- colors: array of color stops, - * each of which consists of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. - *
**NOTE** - *
A value less than 0 is treated as **0**. A value greater than 360 is treated as **360**. - *
When **start**, **end**, or **rotation** is specified with a string, the string must be a number - * or a number followed by one of the following units: deg, rad, grad, and turn. Valid value examples - * are "90", "90deg", and "1.57rad". + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Creates a sweep gradient. + * Angle Gradient + * center:is the center point of the angle gradient + * start:Start point of angle gradient. The default value is 0 + * end:End point of angle gradient. The default value is 0 + * number:number + * rotating:rotating. The default value is 0 + * colors:Color description for gradients + * repeating:repeating. The default value is false * - * @param { SweepGradientOptions } value - Sweep gradient, which can sweep around the specified - * center point in the 0–360 degree range. If the rotation angle exceeds the range, a monochrome - * color instead of a gradient will be drawn.
- **center**: center of the sweep gradient, that - * is, the coordinates relative to the upper left corner of the current component. - *
- **start**: start angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **end**: end angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **rotation**: rotation angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- colors: array of color stops, - * each of which consists of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. - *
**NOTE** - *
A value less than 0 is treated as **0**. A value greater than 360 is treated as **360**. - *
When **start**, **end**, or **rotation** is specified with a string, the string must be a number - * or a number followed by one of the following units: deg, rad, grad, and turn. Valid value examples - * are "90", "90deg", and "1.57rad". + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26106,27 +25028,16 @@ declare class CommonMethod { * @since 10 */ /** - * Creates a sweep gradient. + * Angle Gradient + * center:is the center point of the angle gradient + * start:Start point of angle gradient. The default value is 0 + * end:End point of angle gradient. The default value is 0 + * number:number + * rotating:rotating. The default value is 0 + * colors:Color description for gradients + * repeating:repeating. The default value is false * - * @param { SweepGradientOptions } value - Sweep gradient, which can sweep around the specified - * center point in the 0–360 degree range. If the rotation angle exceeds the range, a monochrome - * color instead of a gradient will be drawn.
- **center**: center of the sweep gradient, that - * is, the coordinates relative to the upper left corner of the current component. - *
- **start**: start angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **end**: end angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **rotation**: rotation angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- colors: array of color stops, - * each of which consists of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. - *
**NOTE** - *
A value less than 0 is treated as **0**. A value greater than 360 is treated as **360**. - *
When **start**, **end**, or **rotation** is specified with a string, the string must be a number - * or a number followed by one of the following units: deg, rad, grad, and turn. Valid value examples - * are "90", "90deg", and "1.57rad". + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26135,27 +25046,16 @@ declare class CommonMethod { * @since 11 */ /** - * Creates a sweep gradient. + * Angle Gradient + * center:is the center point of the angle gradient + * start:Start point of angle gradient + * end:End point of angle gradient + * number:number + * rotating:rotating + * colors:Color description for gradients + * repeating:repeating * - * @param { SweepGradientOptions } value - Sweep gradient, which can sweep around the specified - * center point in the 0–360 degree range. If the rotation angle exceeds the range, a monochrome - * color instead of a gradient will be drawn.
- **center**: center of the sweep gradient, that - * is, the coordinates relative to the upper left corner of the current component. - *
- **start**: start angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **end**: end angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **rotation**: rotation angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- colors: array of color stops, - * each of which consists of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. - *
**NOTE** - *
A value less than 0 is treated as **0**. A value greater than 360 is treated as **360**. - *
When **start**, **end**, or **rotation** is specified with a string, the string must be a number - * or a number followed by one of the following units: deg, rad, grad, and turn. Valid value examples - * are "90", "90deg", and "1.57rad". + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26164,27 +25064,16 @@ declare class CommonMethod { * @since 12 */ /** - * Creates a sweep gradient. + * Angle Gradient + * center:is the center point of the angle gradient + * start:Start point of angle gradient. The default value is 0 + * end:End point of angle gradient. The default value is 0 + * rotating:rotating. The default value is 0 + * colors:Color description for gradients + * repeating:repeating. The default value is false * - * @param { SweepGradientOptions } value - Sweep gradient, which can sweep around the specified - * center point in the 0–360 degree range. If the rotation angle exceeds the range, a monochrome - * color instead of a gradient will be drawn.
- **center**: center of the sweep gradient, that - * is, the coordinates relative to the upper left corner of the current component. - *
- **start**: start angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **end**: end angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- **rotation**: rotation angle of the sweep gradient. - *
Default value: **0**
If the angle is specified with a string, only the deg, grad, rad, - * and turn types are supported.
- colors: array of color stops, - * each of which consists of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. - *
**NOTE** - *
A value less than 0 is treated as **0**. A value greater than 360 is treated as **360**. - *
When **start**, **end**, or **rotation** is specified with a string, the string must be a number - * or a number followed by one of the following units: deg, rad, grad, and turn. Valid value examples - * are "90", "90deg", and "1.57rad". + * Anonymous Object Rectification. + * @param { SweepGradientOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26195,11 +25084,15 @@ declare class CommonMethod { sweepGradient(value: SweepGradientOptions): T; /** - * Creates a sweep gradient. Compared to sweepGradient, - * this API supports the **undefined** type for the **options** parameter. + * Angle Gradient + * center:is the center point of the angle gradient + * start:Start point of angle gradient. The default value is 0 + * end:End point of angle gradient. The default value is 0 + * rotating:rotating. The default value is 0 + * colors:Color description for gradients + * repeating:repeating. The default value is false * - * @param { Optional } options - Sweep gradient. - *
If **options** is **undefined**, the sweep gradient is disabled. + * @param { Optional } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26210,56 +25103,38 @@ declare class CommonMethod { sweepGradient(options: Optional): T; /** - * Creates a radial gradient. + * Radial Gradient + * center:Center point of radial gradient + * radius:Radius of Radial Gradient. value range [0, +∞) + * colors:Color description for gradients + * repeating: Refill. The default value is false * - * @param { object } value - Radial gradient. - *
- **center**: center of the radial gradient, that is, the coordinates relative - * to the upper left corner of the current component. - *
- **radius**: radius of the radial gradient. - *
Value range: [0, +∞). - *
**NOTE** - *
A value less than 0 is treated as **0**. - *
- colors: array of color stops, each of which consists - * of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Creates a radial gradient. + * Radial Gradient + * center:Center point of radial gradient + * radius:Radius of Radial Gradient. value range [0, +∞) + * colors:Color description for gradients + * repeating: Refill. The default value is false * - * @param { object } value - Radial gradient. - *
- **center**: center of the radial gradient, that is, the coordinates relative - * to the upper left corner of the current component. - *
- **radius**: radius of the radial gradient. - *
Value range: [0, +∞). - *
**NOTE** - *
A value less than 0 is treated as **0**. - *
- colors: array of color stops, each of which consists - * of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Creates a radial gradient. + * Radial Gradient + * center:Center point of radial gradient + * radius:Radius of Radial Gradient. value range [0, +∞) + * colors:Color description for gradients + * repeating: Refill. The default value is false * - * @param { object } value - Radial gradient. - *
- **center**: center of the radial gradient, that is, the coordinates relative - * to the upper left corner of the current component. - *
- **radius**: radius of the radial gradient. - *
Value range: [0, +∞). - *
**NOTE** - *
A value less than 0 is treated as **0**. - *
- colors: array of color stops, each of which consists - * of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26267,19 +25142,13 @@ declare class CommonMethod { * @since 10 */ /** - * Creates a radial gradient. + * Radial Gradient + * center:Center point of radial gradient + * radius:Radius of Radial Gradient. value range [0, +∞) + * colors:Color description for gradients + * repeating: Refill. The default value is false * - * @param { object } value - Radial gradient. - *
- **center**: center of the radial gradient, that is, the coordinates relative - * to the upper left corner of the current component. - *
- **radius**: radius of the radial gradient. - *
Value range: [0, +∞). - *
**NOTE** - *
A value less than 0 is treated as **0**. - *
- colors: array of color stops, each of which consists - * of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26288,19 +25157,13 @@ declare class CommonMethod { * @since 11 */ /** - * Creates a radial gradient. + * Radial Gradient + * center:Center point of radial gradient + * radius:Radius of Radial Gradient + * colors:Color description for gradients + * repeating: Refill * - * @param { object } value - Radial gradient. - *
- **center**: center of the radial gradient, that is, the coordinates relative - * to the upper left corner of the current component. - *
- **radius**: radius of the radial gradient. - *
Value range: [0, +∞). - *
**NOTE** - *
A value less than 0 is treated as **0**. - *
- colors: array of color stops, each of which consists - * of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. + * @param { object } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26309,20 +25172,14 @@ declare class CommonMethod { * @since 12 */ /** - * Creates a radial gradient. + * Radial Gradient + * center:Center point of radial gradient + * radius:Radius of Radial Gradient. value range [0, +∞) + * colors:Color description for gradients + * repeating: Refill. The default value is false * * Anonymous Object Rectification. - * @param { RadialGradientOptions } value - Radial gradient. - *
- **center**: center of the radial gradient, that is, the coordinates relative - * to the upper left corner of the current component. - *
- **radius**: radius of the radial gradient. - *
Value range: [0, +∞). - *
**NOTE** - *
A value less than 0 is treated as **0**. - *
- colors: array of color stops, each of which consists - * of a color and its stop position. Invalid colors are automatically skipped. - *
- **repeating**: whether the colors are repeated. - *
Default value: **false**. + * @param { RadialGradientOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26333,11 +25190,13 @@ declare class CommonMethod { radialGradient(value: RadialGradientOptions): T; /** - * Creates a radial gradient. Compared to radialGradient, - * this API supports the **undefined** type for the **options** parameter. + * Radial Gradient + * center:Center point of radial gradient + * radius:Radius of Radial Gradient. value range [0, +∞) + * colors:Color description for gradients + * repeating: Refill. The default value is false * - * @param { Optional } options - Radial gradient. - *
If **options** is **undefined**, the radial gradient is disabled. + * @param { Optional } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26348,26 +25207,38 @@ declare class CommonMethod { radialGradient(options: Optional): T; /** - * Set the motion path of the component. + * Set the motion path of the component + * path:Motion path for displacement animation, using the svg path string. + * from:Start point of the motion path. The default value is 0.0. + * to:End point of the motion path. The default value is 1.0. + * rotatable:Whether to follow the path for rotation. * - * @param { MotionPathOptions } value - Motion path of the component. + * @param { MotionPathOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Set the motion path of the component. + * Set the motion path of the component + * path:Motion path for displacement animation, using the svg path string. + * from:Start point of the motion path. The default value is 0.0. + * to:End point of the motion path. The default value is 1.0. + * rotatable:Whether to follow the path for rotation. * - * @param { MotionPathOptions } value - Motion path of the component. + * @param { MotionPathOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Set the motion path of the component. + * Set the motion path of the component + * path:Motion path for displacement animation, using the svg path string. + * from:Start point of the motion path. The default value is 0.0. + * to:End point of the motion path. The default value is 1.0. + * rotatable:Whether to follow the path for rotation. * - * @param { MotionPathOptions } value - Motion path of the component. + * @param { MotionPathOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26377,33 +25248,26 @@ declare class CommonMethod { motionPath(value: MotionPathOptions): T; /** - * Applies a shadow effect to the component. + * Add a shadow effect to the current component * - * @param { ShadowOptions } value - Shadow of the component. - *
When the value type is **ShadowOptions**, the blur radius, shadow color, - * and offset along the x-axis and y-axis can be specified. + * @param { ShadowOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Applies a shadow effect to the component. + * Add a shadow effect to the current component * - * @param { ShadowOptions } value - Shadow of the component. - *
When the value type is **ShadowOptions**, the blur radius, shadow color, - * and offset along the x-axis and y-axis can be specified. + * @param { ShadowOptions } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Applies a shadow effect to the component. + * Add a shadow effect to the current component * - * @param { ShadowOptions | ShadowStyle } value - Shadow of the component. - *
When the value type is **ShadowOptions**, the blur radius, shadow color, - * and offset along the x-axis and y-axis can be specified. - *
When the value type is **ShadowStyle**, the shadow style can be specified. + * @param { ShadowOptions | ShadowStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26411,12 +25275,9 @@ declare class CommonMethod { * @since 10 */ /** - * Applies a shadow effect to the component. + * Add a shadow effect to the current component * - * @param { ShadowOptions | ShadowStyle } value - Shadow of the component. - *
When the value type is **ShadowOptions**, the blur radius, shadow color, - * and offset along the x-axis and y-axis can be specified. - *
When the value type is **ShadowStyle**, the shadow style can be specified. + * @param { ShadowOptions | ShadowStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26427,14 +25288,9 @@ declare class CommonMethod { shadow(value: ShadowOptions | ShadowStyle): T; /** - * Applies a shadow effect to the component. - * Compared to {@link shadow}, this API supports the **undefined** type for the **options** parameter. + * Add a shadow effect to the current component * - * @param { Optional } options - Shadow of the component. - *
When the value type is **ShadowOptions**, the blur radius, shadow color, - * and offset along the x-axis and y-axis can be specified. - *
When the value type is **ShadowStyle**, the shadow style can be specified. - *
If **options** is **undefined**, the component reverts to its original effect with no shadow. + * @param { Optional } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26445,23 +25301,10 @@ declare class CommonMethod { shadow(options: Optional): T; /** - * Defines how the component's content (including the content of it child components) - * is blended with the existing content on the canvas (possibly offscreen canvas) below. + * Add a blendMode effect to the current component * - * @param { BlendMode } value - Blend mode. - *
Default value: **BlendMode.NONE**. - *
**NOTE** - *
When **BlendMode.NONE** is used, the blend effect is **BlendMode.SRC_OVER** - * by default, and **BlendApplyType** does not take effect. - * @param { BlendApplyType } [type] - Whether the blend mode is implemented offscreen. - *
Default value: **BlendApplyType.FAST**. - *
**NOTE** - *
1. **BlendApplyType.FAST**: The blend mode is not implemented offscreen. - *
2. **BlendApplyType.OFFSCREEN**: An offscreen canvas of the size of the current component - * is created. The content of the current component (including child components) is then drawn - * onto the offscreen canvas, and blended with the existing content on the canvas below using - * the specified blend mode. This approach may cause issues with screen capture for APIs such - * as linearGradientBlur12+, backgroundEffect, and brightness. + * @param { BlendMode } value - Different hybrid modes + * @param { BlendApplyType } [type] - Different blend apply type * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26469,23 +25312,10 @@ declare class CommonMethod { * @since 11 */ /** - * Defines how the component's content (including the content of it child components) - * is blended with the existing content on the canvas (possibly offscreen canvas) below. + * Add a blendMode effect to the current component * - * @param { BlendMode } value - Blend mode. - *
Default value: **BlendMode.NONE**. - *
**NOTE** - *
When **BlendMode.NONE** is used, the blend effect is **BlendMode.SRC_OVER** - * by default, and **BlendApplyType** does not take effect. - * @param { BlendApplyType } [type] - Whether the blend mode is implemented offscreen. - *
Default value: **BlendApplyType.FAST**. - *
**NOTE** - *
1. **BlendApplyType.FAST**: The blend mode is not implemented offscreen. - *
2. **BlendApplyType.OFFSCREEN**: An offscreen canvas of the size of the current component - * is created. The content of the current component (including child components) is then drawn - * onto the offscreen canvas, and blended with the existing content on the canvas below using - * the specified blend mode. This approach may cause issues with screen capture for APIs such - * as linearGradientBlur12+, backgroundEffect, and brightness. + * @param { BlendMode } value - Different hybrid modes + * @param { BlendApplyType } [type] - Different blend apply type * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26496,27 +25326,10 @@ declare class CommonMethod { blendMode(value: BlendMode, type?: BlendApplyType): T; /** - * Defines how the component's content (including the content of it child components) is - * blended with the existing content on the canvas (possibly offscreen canvas) below. - * Compared to blendMode11+, this API supports the **undefined** - * type for the **mode** parameter. + * Add a blendMode effect to the current component * - * @param { Optional } mode - Blend mode. - *
Default value: **BlendMode.NONE**. - *
If **mode** is **undefined**, the component reverts to its original effect of not - * enabling offscreen rendering as a whole before blending with the parent component. - *
**NOTE** - *
When **BlendMode.NONE** is used, the blend effect is **BlendMode.SRC_OVER** - * by default, and **BlendApplyType** does not take effect. - * @param { BlendApplyType } [type] - Whether the blend mode is implemented offscreen. - *
Default value: **BlendApplyType.FAST**. - *
**NOTE** - *
1. **BlendApplyType.FAST**: The blend mode is not implemented offscreen. - *
2. **BlendApplyType.OFFSCREEN**: An offscreen canvas of the size of the current component - * is created. The content of the current component (including child components) is then drawn - * onto the offscreen canvas, and blended with the existing content on the canvas below using - * the specified blend mode. This approach may cause issues with screen capture for APIs such - * as linearGradientBlur12+, backgroundEffect, and brightness. + * @param { Optional } mode - Different hybrid modes + * @param { BlendApplyType } [type] - Different blend apply type * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26528,7 +25341,7 @@ declare class CommonMethod { /** * Add a blendMode effect to the current component.Cannot be used together with the blendMode interface. - * + * * @param { BlendMode | Blender } effect - When the effect type is BlendMode type, define Different hybrid modes. * When the effect type is Blender type, Define the corresponding blending effect. * @param { BlendApplyType } [type] - Different blend apply type @@ -26541,14 +25354,9 @@ declare class CommonMethod { advancedBlendMode(effect: BlendMode | Blender, type?: BlendApplyType): T; /** - * Sets whether to clip the areas of child components that extend beyond this component's boundaries, - * That is, whether to perform clipping based on the edge contour of the parent container. + * Whether to crop the sub components beyond the current component range. * - * @param { boolean } value - Whether to perform clipping based on the edge contour of the parent container. - *
Default value: **false**. - *
**true**: Perform clipping. **false**: Do not perform clipping. - *
If this parameter is set to **true**. - *
child components exceeding the current component's bounds will not respond to bound gesture events. + * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26559,15 +25367,9 @@ declare class CommonMethod { clip(value: boolean): T; /** - * Sets whether to clip the areas of child components that extend beyond this component's boundaries, - * That is, whether to perform clipping based on the edge contour of the parent container. - * This API supports the **undefined** type for the **clip** parameter. + * Whether to crop the sub components beyond the current component range. * - * @param { Optional } clip - Whether to perform clipping based on the edge contour of the parent container. - *
Default value: **false**. - *
If this parameter is set to **true**, - * child components exceeding the current component's bounds will not respond to bound gesture events. - *
If **clip** is set to **undefined**, clipping is disabled, and child components are not clipped. + * @param { Optional } clip * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26581,13 +25383,7 @@ declare class CommonMethod { * When the parameter is of the Shape type, the current component is cropped according to the specified shape. * When the parameter is of the boolean type, this parameter specifies whether to crop based on the edge contour. * - * @param { boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute } value - Clip mode. - *
If the value is a shape attribute, the component is clipped based on the specified shape. - *
If the value is of the Boolean type, - * it specifies whether to clip the component based on the boundaries of the parent container. - *
Default value: **false**. - *
If the value is a shape attribute, the clipped area can still respond to bound gesture events. - *
If the value is of the Boolean type, the clipped area will not respond to bound gesture events. + * @param { boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 @@ -26596,13 +25392,7 @@ declare class CommonMethod { * When the parameter is of the Shape type, the current component is cropped according to the specified shape. * When the parameter is of the boolean type, this parameter specifies whether to crop based on the edge contour. * - * @param { boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute } value - Clip mode. - *
If the value is a shape attribute, the component is clipped based on the specified shape. - *
If the value is of the Boolean type, - * it specifies whether to clip the component based on the boundaries of the parent container. - *
Default value: **false**. - *
If the value is a shape attribute, the clipped area can still respond to bound gesture events. - *
If the value is of the Boolean type, the clipped area will not respond to bound gesture events. + * @param { boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -26612,13 +25402,7 @@ declare class CommonMethod { * When the parameter is of the Shape type, the current component is cropped according to the specified shape. * When the parameter is of the boolean type, this parameter specifies whether to crop based on the edge contour. * - * @param { boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute } value - Clip mode. - *
If the value is a shape attribute, the component is clipped based on the specified shape. - *
If the value is of the Boolean type, - * it specifies whether to clip the component based on the boundaries of the parent container. - *
Default value: **false**. - *
If the value is a shape attribute, the clipped area can still respond to bound gesture events. - *
If the value is of the Boolean type, the clipped area will not respond to bound gesture events. + * @param { boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26629,13 +25413,7 @@ declare class CommonMethod { * When the parameter is of the Shape type, the current component is cropped according to the specified shape. * When the parameter is of the boolean type, this parameter specifies whether to crop based on the edge contour. * - * @param { boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute } value - Clip mode. - *
If the value is a shape attribute, the component is clipped based on the specified shape. - *
If the value is of the Boolean type, - * it specifies whether to clip the component based on the boundaries of the parent container. - *
Default value: **false**. - *
If the value is a shape attribute, the clipped area can still respond to bound gesture events. - *
If the value is of the Boolean type, the clipped area will not respond to bound gesture events. + * @param { boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26648,41 +25426,35 @@ declare class CommonMethod { clip(value: boolean | CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute): T; /** - * Clips this component based on the given shape. - * - * @param { CircleShape | EllipseShape | PathShape | RectShape } value - Shape that the component to be clipped into. - *
The clipped area remains responsive to bound gesture events. - * @returns { T } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ + * The current component is cropped according to the specified shape. + * + * @param { CircleShape | EllipseShape | PathShape | RectShape } value - indicates the shape of the clip. + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 12 + */ clipShape(value: CircleShape | EllipseShape | PathShape | RectShape): T; /** - * Sets whether to clip this component based on the given shape. - * Compared to {@link clipShape}, this API supports the **undefined** type for the **shape** parameter. - * - * @param { Optional } shape - Shape that the component to - *
be clipped into. - *
The clipped area remains responsive to bound gesture events. - *
If **shape** is set to **undefined**, the previous value is retained. - * @returns { T } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 18 - */ + * The current component is cropped according to the specified shape. + * + * @param { Optional } shape - indicates the shape of the clip. + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ clipShape(shape: Optional): T; /** - * Adds a mask to the component to indicate the progress. + * Sets the mask of the current component. * - * @param { ProgressMask } value - Mask to add to the component, which allows for dynamic - * adjustment of progress, maximum value, and color settings. + * @param { ProgressMask } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26692,12 +25464,9 @@ declare class CommonMethod { mask(value: ProgressMask): T; /** - * Adds a mask to the component to indicate the progress. Compared to mask12+, - * this API supports the **undefined** type for the **mask** parameter. + * Sets the mask of the current component. * - * @param { Optional } mask - Mask to add to the component, which allows for dynamic - * adjustment of progress, maximum value, and color settings.
If **mask** is set to **undefined**, - * the component to revert to its original effect without the mask to indicate the progress. + * @param { Optional } mask * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26749,10 +25518,9 @@ declare class CommonMethod { mask(value: CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute | ProgressMask): T; /** - * Adds a mask of the specified shape to the component. + * Applies a mask of the specified shape to the current assembly. * - * @param { CircleShape | EllipseShape | PathShape | RectShape } value - Mask of the specified - * shape to add to the component. + * @param { CircleShape | EllipseShape | PathShape | RectShape } value - indicates the shape of the mask. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26763,11 +25531,9 @@ declare class CommonMethod { maskShape(value: CircleShape | EllipseShape | PathShape | RectShape): T; /** - * Adds a mask of the specified shape to the component. Compared to maskShape12+, - * this API supports the **undefined** type for the **shape** parameter. + * Applies a mask of the specified shape to the current assembly. * - * @param { Optional } shape - Mask of the specified shape to - * add to the component.
If **shape** is set to **undefined**, the previous value is retained. + * @param { Optional } shape - indicates the shape of the mask. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -26913,12 +25679,8 @@ declare class CommonMethod { */ /** * Popup control - *

NOTE: - *
The popup can be displayed only after the entire page is fully constructed. Therefore, to avoid incorrect - * display positions and shapes, do not set this parameter to true while the page is still being constructed. - *

* - * @param { boolean } show - Whether to show the popup, default is false. + * @param { boolean } show * @param { PopupOptions | CustomPopupOptions } popup * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -26976,7 +25738,7 @@ declare class CommonMethod { /** * Menu control * - * @param { boolean } isShow true means display menu, false means hide menu, default is false. + * @param { boolean } isShow true means display menu, false means hide menu. * @param { Array | CustomBuilder } content - Indicates the content of menu. * @param { MenuOptions } options - Indicates the options of menu. * @returns { T } @@ -27009,12 +25771,10 @@ declare class CommonMethod { * @since 10 */ /** - * Binds a context menu to this component, which is displayed when the user long-presses or right-clicks the - * component. Only custom menu items are supported. + * ContextMenu control * * @param { CustomBuilder } content - Indicates the content of context menu. - * @param { ResponseType } responseType - Indicates response type of context menu, Long pressing with a mouse device - * is not supported. + * @param { ResponseType } responseType - Indicates response type of context menu. * @param { ContextMenuOptions } options - Indicates the options of context menu. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -27025,15 +25785,9 @@ declare class CommonMethod { bindContextMenu(content: CustomBuilder, responseType: ResponseType, options?: ContextMenuOptions): T; /** - * Binds a context menu to the component, whose visibility is subject to the isShown settings. - * - * @param { boolean } isShown - true means display content, false means hide content, default is false. - *

NOTE: - *
The menu can be displayed properly only when the related page has been constructed. If this parameter is set - * to true before the construction is complete, display issues, such as misplacement, distortion, or failure to pop - * up, may occur. To trigger dragging by long presses is not supported. - *

+ * ContextMenu control * + * @param { boolean } isShown - true means display content, false means hide content. * @param { CustomBuilder } content - Indicates the content of context menu. * @param { ContextMenuOptions } [options] - Indicates the options of context menu. * @returns { T } @@ -27045,7 +25799,7 @@ declare class CommonMethod { bindContextMenu(isShown: boolean, content: CustomBuilder, options?: ContextMenuOptions): T; /** - * Binds a modal page to the component, whose visibility is subject to the isShow settings. + * Bind content cover * * @param { boolean } isShow - true means display content, false means hide content. * @param { CustomBuilder } builder - the content to be displayed. @@ -27056,7 +25810,7 @@ declare class CommonMethod { * @since 10 */ /** - * Binds a modal page to the component, whose visibility is subject to the isShow settings. + * Bind content cover * * @param { boolean } isShow - true means display content, false means hide content. * @param { CustomBuilder } builder - the content to be displayed. @@ -27081,7 +25835,7 @@ declare class CommonMethod { * @since 10 */ /** - * Binds a modal page to the component, whose visibility is subject to the isShow settings. + * Bind content cover * * @param { boolean } isShow - true means display content, false means hide content. * @param { CustomBuilder } builder - the content to be displayed. @@ -27092,10 +25846,10 @@ declare class CommonMethod { * @atomicservice * @since 11 */ - bindContentCover(isShow: boolean , builder: CustomBuilder, options?: ContentCoverOptions): T; + bindContentCover(isShow: boolean, builder: CustomBuilder, options?: ContentCoverOptions): T; /** - * Binds a sheet page to the component, whose visibility is subject to the isShow settings. + * Bind sheet * * @param { boolean } isShow - true means display sheet, false means hide sheet. * @param { CustomBuilder } builder - the sheet to be displayed. @@ -27106,7 +25860,7 @@ declare class CommonMethod { * @since 10 */ /** - * Binds a sheet page to the component, whose visibility is subject to the isShow settings. + * Bind sheet * * @param { boolean } isShow - true means display sheet, false means hide sheet. * @param { CustomBuilder } builder - the sheet to be displayed. @@ -27212,9 +25966,8 @@ declare class CommonMethod { /** * Trigger a visible area change event. * - * @param { Array } ratios - Threshold array. Each threshold represents a ratio of the component's visible area to the component's total area. - * The value range of the threshold is [0.0, 1.0]. - * @param { VisibleAreaChangeCallback } event - Callback for visible area changes of the component. + * @param { Array } ratios + * @param { VisibleAreaChangeCallback } event * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27223,7 +25976,6 @@ declare class CommonMethod { */ onVisibleAreaChange(ratios: Array, event: VisibleAreaChangeCallback): T; - /** * Set or reset the callback which is triggered when the visibleArea of component changed. * The interval between two visible area change callbacks will not be less than the expected update interval. @@ -27239,19 +25991,10 @@ declare class CommonMethod { onVisibleAreaApproximateChange(options: VisibleAreaEventOptions, event: VisibleAreaChangeCallback | undefined): void; /** - * Applies a spherical effect to the component. + * Set the spherical effect of the component. * - * @param { number } value - Spherical degree of the component. - *
The value ranges from 0 to 1. - *

**NOTE**: - *
1. If the value is **0**, the component remains unchanged. If the value is 1, the component is completely - * spherical. Between **0** and **1**, a larger value indicates a higher spherical degree. A value less than 0 is - * handled as the value **0**. A value greater than 1 is handled as the value **1**. - *
2. The component's shadow and outer stroke do not support spherical effects. - *
3. If the value is greater than 0, the component is frozen and not updated, and its content is drawn to the - * transparent offscreen buffer. To update the component attributes, set the value to **0**. - *

- * + * @param { number } value - set the degree of spherical effect, value range [0, 1]. + * If the value is 0, the component keep same, else the value is 1, component are fully spherical. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27263,17 +26006,8 @@ declare class CommonMethod { /** * Set the spherical effect of the component. * - * @param { Optional } effect - The value ranges from 0 to 1. - *

**NOTE**: - *
1. If the value is **0**, the component remains unchanged. If the value is 1, the component is completely - * spherical. Between **0** and **1**, a larger value indicates a higher spherical degree.A value less than 0 is - * handled as the value **0**. A value greater than 1 is handled as the value **1**. - *
2. The component's shadow and outer stroke do not support spherical effects. - *
3. If the value is greater than 0, the component is frozen and not updated, and its content is drawn to the - * transparent offscreen buffer. To update the component attributes, set the value to **0**. If **effect** is - * **undefined**, the spherical degree reverts to **0**. - *

- * + * @param { Optional } effect - set the degree of spherical effect, value range [0, 1]. + * If the value is 0, the component keep same, else the value is 1, component are fully spherical. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27283,14 +26017,10 @@ declare class CommonMethod { sphericalEffect(effect: Optional): T; /** - * Applies a light up effect to the component. + * Set the light up effect of the component * - * @param { number } value - Light up degree of the component. - *
The value ranges from 0 to 1. - *
If the value is **0**, the component is dark. If the value is **1**, the component is fully illuminated. - *
Between **0** and **1**, a larger value indicates higher luminance. - *
A value less than 0 is handled as the value **0**. - *
A value greater than 1 is handled as the value **1**. + * @param { number } value - set the degree to which the component lights up, value range [0, 1]. + * The color brightness in the component rendering content area is greater than the value and can be displayed, otherwise it will not be displayed. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27300,16 +26030,10 @@ declare class CommonMethod { lightUpEffect(value: number): T; /** - * Applies a light up effect to the component. Compared to lightUpEffect, - * this API supports the **undefined** type for the **degree** parameter. + * Set the light up effect of the component * - * @param { Optional } degree - Light up degree of the component. - *
The value ranges from 0 to 1. - *
If the value is **0**, the component is dark. If the value is **1**, the component is fully illuminated. - *
Between **0** and **1**, a larger value indicates higher luminance. - *
A value less than 0 is handled as the value **0**. - *
A value greater than 1 is handled as the value **1**. - *
If **degree** is **undefined**, the light up degree reverts to **1**. + * @param { Optional } degree - set the degree to which the component lights up, value range [0, 1]. + * The color brightness in the component rendering content area is greater than the value and can be displayed, otherwise it will not be displayed. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27319,26 +26043,9 @@ declare class CommonMethod { lightUpEffect(degree: Optional): T; /** - * Applies a pixel stretch effect to the component. - * - * @param { PixelStretchEffectOptions } options - Pixel stretch effect options. - *
The value includes the length by which a pixel is stretched toward the four edges. - *

**NOTE**: - *
1. If the length is a positive value, the original image is stretched, and the image size increases. The edge - * pixels grow by the set length toward the top, bottom, left, and right edges. - *
2. If the length is a negative value, the original image shrinks as follows, but the image size remains - * unchanged: - *
Shrinking mode: - *
(1) The image shrinks from the four edges by the absolute value of length set through **options**. - *
(2) The image is stretched back to the original size with edge pixels. - *
3. Constraints on **options**: - *
(1) The length values for the four edges must be all positive or all negative. That is, the four edges are - * stretched or shrink at the same time in the same direction. - *
(2) The length values must all be a percentage or a specific value. Combined use of the percentage and - * specific value is not allowed. - *
(3) If the input value is invalid, the image is displayed as {0, 0, 0, 0}, that is, the image is the same as - * the original image. - *

+ * Set the edge pixel stretch effect of the Component. + * + * @param { PixelStretchEffectOptions } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27348,27 +26055,9 @@ declare class CommonMethod { pixelStretchEffect(options: PixelStretchEffectOptions): T; /** - * Applies a pixel stretch effect to the component. Compared to pixelStretchEffect, - * this API supports the **undefined** type for the **options** parameter. + * Set the edge pixel stretch effect of the Component. * - * @param { Optional } options - Pixel stretch effect options. - *
The value includes the length by which a pixel is stretched toward the four edges. - *

**NOTE**: - *
1. If the length is a positive value, the original image is stretched, and the image size increases. The edge - * pixels grow by the set length toward the top, bottom, left, and right edges. - *
2. If the length is a negative value, the original image shrinks as follows, but the image size remains - * unchanged: - *
Shrinking mode: - *
(1) The image shrinks from the four edges by the absolute value of length set through **options**. - *
(2) The image is stretched back to the original size with edge pixels. - *
3. Constraints on **options**: - *
(1) The length values for the four edges must be all positive or all negative. That is, the four edges are - * stretched or shrink at the same time in the same direction. - *
(2) The length values must all be a percentage or a specific value. Combined use of the percentage and - * specific value is not allowed. - *
(3) If the input value is invalid, the image is displayed as {0, 0, 0, 0}, that is, the image is the same as - * the original image. - *

+ * @param { Optional } options * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27497,7 +26186,7 @@ declare class CommonMethod { * @since 12 */ accessibilityText(value: string): T; - + /** * Sets accessibility next focus id * @param { string } nextId - set component next accessibility focus id @@ -27509,7 +26198,7 @@ declare class CommonMethod { * @since 18 */ accessibilityNextFocusId(nextId: string): T; - + /** * Sets the accessibility default foucs flag * @param { boolean } focus - if the component is accessibility default focus,focus set true @@ -27521,7 +26210,7 @@ declare class CommonMethod { * @since 18 */ accessibilityDefaultFocus(focus: boolean): T; - + /** * Sets accessibility same page mode * @param { AccessibilitySamePageMode } pageMode - accessibility same page mode @@ -27563,7 +26252,7 @@ declare class CommonMethod { * @since 12 */ accessibilityText(text: Resource): T; - + /** * Sets accessibility role,role indicates the custom type of the component * @param { AccessibilityRoleType } role - set accessibility component type @@ -27807,7 +26496,7 @@ declare class CommonMethod { */ reuseId(id: string): T; - /** + /** * Reuse id is used for identify the reuse type of each @ComponentV2 custom component, which can give user control of sub-component recycle and reuse. * * @param { ReuseOptions } options - The configuration parameter for reusable custom component. @@ -27817,25 +26506,21 @@ declare class CommonMethod { * @atomicservice * @since 18 */ - reuse(options: ReuseOptions): T; + reuse(options: ReuseOptions): T; /** - * How the final state of the component's content is rendered during its width and height animation process. + * Sets how content is drawn within nodes duration animation * - * @param { RenderFit } fitMode - How the final state of the component's content is rendered during. - *
its width and height animation process. - *
If **renderFit** is not set, the default value **RenderFit.TOP_LEFT** is used. + * @param { RenderFit } fitMode - The render fit mode of content. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * How the final state of the component's content is rendered during its width and height animation process. + * Sets how content is drawn within nodes duration animation * - * @param { RenderFit } fitMode - How the final state of the component's content is rendered during. - *
its width and height animation process. - *
If **renderFit** is not set, the default value **RenderFit.TOP_LEFT** is used. + * @param { RenderFit } fitMode - The render fit mode of content. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27843,11 +26528,9 @@ declare class CommonMethod { * @since 11 */ /** - * How the final state of the component's content is rendered during its width and height animation process. + * Sets how content is drawn within nodes duration animation * - * @param { RenderFit } fitMode - How the final state of the component's content is rendered during. - *
its width and height animation process. - *
If **renderFit** is not set, the default value **RenderFit.TOP_LEFT** is used. + * @param { RenderFit } fitMode - The render fit mode of content. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27858,13 +26541,9 @@ declare class CommonMethod { renderFit(fitMode: RenderFit): T; /** - * How the final state of the component's content is rendered during its width and height animation process. - * Compared to {@link renderFit}, this API supports the **undefined** type for the **fitMode** parameter. + * Sets how content is drawn within nodes during animation * - * @param { Optional } fitMode - How the final state of the component's content is rendered during. - *
its width and height animation process. - *
If **fitMode** is set to **undefined**, the default value is used, - * which is equivalent to **RenderFit.TOP_LEFT**. + * @param { Optional } fitMode - The render fit mode of content. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27887,8 +26566,6 @@ declare class CommonMethod { * Sets the attribute modifier. * * @param { AttributeModifier } modifier - * The if/else syntax is supported. - * You need a custom class to implement the AttributeModifier API. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -27910,9 +26587,9 @@ declare class CommonMethod { gestureModifier(modifier: GestureModifier): T; /** - * Sets the background brightness of the component. + * Adds a background dynamic light up effect to the current component. * - * @param { BackgroundBrightnessOptions } params - Parameters for setting the background brightness. + * @param { BackgroundBrightnessOptions } params - params indicates BackgroundBrightnessOptions * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -27921,11 +26598,9 @@ declare class CommonMethod { backgroundBrightness(params: BackgroundBrightnessOptions): T; /** - * Sets the background brightness of the component. Compared to backgroundBrightness12+, - * this API supports the **undefined** type for the **options** parameter. + * Adds a background dynamic light up effect to the current component. * - * @param { Optional } options - Parameters for setting the background brightness. - *
If **options** is **undefined**, the background reverts to its default state with no brightness effect. + * @param { Optional } options - params indicates BackgroundBrightnessOptions * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -27955,7 +26630,7 @@ declare class CommonMethod { onGestureJudgeBegin(callback: (gestureInfo: GestureInfo, event: BaseGestureEvent) => GestureJudgeResult): T; /** - * Binds a custom gesture recognizer judgment callback to the component. + * When a gesture bound to this component will be accepted, a user-defined callback is triggered to get the result * * @param { GestureRecognizerJudgeBeginCallback } callback - A callback instance used when a gesture bound to this component will be accepted. * @returns { T } @@ -27967,28 +26642,21 @@ declare class CommonMethod { onGestureRecognizerJudgeBegin(callback: GestureRecognizerJudgeBeginCallback): T; /** - * Binds a custom gesture recognizer judgment callback to the component. - * - *

NOTE: - *
For a composite component, setting exposeInnerGesture to true exposes the internal gesture recognizer of the - *
composite component in the current parameter callback. Currently, only the Tabs component is supported. - * - *
Do not set exposeInnerGesture for other components. When exposeInnerGesture is set to false, this API provides the same functionality - *
as the onGestureRecognizerJudgeBegin API. - *

+ * When a gesture bound to this component will be accepted, a user-defined callback is triggered to get the result + * * @param { GestureRecognizerJudgeBeginCallback } callback - A callback instance used when a gesture bound to this component will be accepted. * @param { boolean } exposeInnerGesture - This parameter is a flag. This flag determines whether to expose internal gestures. - * @default false * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice + * * @since 13 */ onGestureRecognizerJudgeBegin(callback: GestureRecognizerJudgeBeginCallback, exposeInnerGesture: boolean): T; /** - * Provides a callback to set the parallel relationship between built-in gestures and gestures of other components in the response chain. + * In the touch test phase, the recognizer is selected to form a parallel relationship with other recognizers on the response chain. * * @param { ShouldBuiltInRecognizerParallelWithCallback } callback - A callback instance used when a component is doing touch test. * @returns { T } @@ -28009,11 +26677,9 @@ declare class CommonMethod { * @since 11 */ /** - * Sets whether the component exclusively handles events. - * true: The component exclusively handles events. false: The component does not exclusively handle events. + * Events are monopolized by components. * * @param { boolean } monopolize - indicate the monopoly of events - * @default false * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28035,8 +26701,7 @@ declare class CommonMethod { onTouchIntercept(callback: Callback): T; /** - * This callback is triggered when the component size changes due to layout updates. - * This event is not triggered for render attribute changes caused by re-rendering. + * This callback is triggered when the size of this component change finished. * * @param { SizeChangeCallback } event - event callback. * @returns { T } @@ -28075,6 +26740,36 @@ declare class CommonMethod { * @since 20 */ onTouchTestDone(callback: TouchTestDoneCallback): T; + + /** + * Enables the component as a drag-and-drop target with spring loading functionality. + * + * When a dragged object hovers over the target, it triggers a callback notification. Spring Loading is an enhanced + * feature for drag-and-drop operations, allowing users to automatically trigger view transitions during dragging + * by hovering (hover) without needing to use another hand. + * This feature is primarily designed to enhance the smoothness and efficiency of drag-and-drop operations. Below are + * some common scenarios suitable for supporting this feature: + * - In a file manager, when dragging a file and hovering over a folder, the folder is automatically opened. + * - On a desktop launcher, when dragging a file and hovering over an application icon, the application is + * automatically opened. + * + * Please note: + * 1. Registering spring-loaded or drag-and-drop events (onDragEnter/Move/Leave/Drop) on a component makes it a + * drag-and-drop target. Only one target can be the responder at the same time when user drags and hovers on, and + * child components always have higher priority. + * 2. Once a complete spring loading is triggered on a component, new spring loading detection will only occur after the + * dragged object leaves and re-enters the component's range. + * + * @param { Callback | null } callback Registers the callback for spring loading response, or + * sets it to null to disable the support for spring loading. + * @param { DragSpringLoadingConfiguration } [configuration] The initialized spring loading configuration which is + * only used when the entire spring detecting. + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 20 + */ + onDragSpringLoading(callback: Callback | null, configuration?: DragSpringLoadingConfiguration): T; } /** @@ -28157,7 +26852,7 @@ interface CommonInterface { */ /** * Constructor - * + * * @returns { CommonAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -28174,7 +26869,7 @@ interface CommonInterface { */ /** * Constructor - * + * * @returns { CommonAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28287,10 +26982,6 @@ declare type CustomBuilder = (() => any) | void; /** * Defines the OverlayOptions interface. - * - * NOTE:
- * When both align and offset are set, the effects are combined. - * The overlay is first aligned relative to the component and then offset from its current upper left corner. * * @typedef OverlayOptions * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -28328,7 +27019,6 @@ declare interface OverlayOptions { * Defines align type. * * @type { ?Alignment } - * @default TopStart * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -28336,7 +27026,7 @@ declare interface OverlayOptions { * @since 11 */ align?: Alignment; - + /** * Defines offset type. * @@ -28365,7 +27055,6 @@ declare interface OverlayOptions { * Defines offset type. * * @type { ?OverlayOffset } - * @default - the overlay is in the upper left corner of the component. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -28525,32 +27214,26 @@ declare class CommonShapeMethod extends CommonMethod { constructor(); /** - * Sets the stroke color. - * If this attribute is not set, the component does not have any stroke. - * If the value is invalid, no stroke will be drawn. + * border Color * - * @param { ResourceColor } value - Stroke color. + * @param { ResourceColor } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the stroke color. - * If this attribute is not set, the component does not have any stroke. - * If the value is invalid, no stroke will be drawn. + * border Color * - * @param { ResourceColor } value - Stroke color. + * @param { ResourceColor } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the stroke color. - * If this attribute is not set, the component does not have any stroke. - * If the value is invalid, no stroke will be drawn. + * border Color * - * @param { ResourceColor } value - Stroke color. + * @param { ResourceColor } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28558,11 +27241,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets the stroke color. - * If this attribute is not set, the component does not have any stroke. - * If the value is invalid, no stroke will be drawn. + * border Color * - * @param { ResourceColor } value - Stroke color. + * @param { ResourceColor } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28573,32 +27254,26 @@ declare class CommonShapeMethod extends CommonMethod { stroke(value: ResourceColor): T; /** - * Sets the color of the fill area. - * An invalid value is handled as the default value. - * If this attribute and the universal attribute foregroundColor are both set, whichever is set later takes effect. + * Fill color. * - * @param { ResourceColor } value - Color of the fill area. Default value: Color.Black. + * @param { ResourceColor } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the color of the fill area. - * An invalid value is handled as the default value. - * If this attribute and the universal attribute foregroundColor are both set, whichever is set later takes effect. + * Fill color. * - * @param { ResourceColor } value - Color of the fill area. Default value: Color.Black. + * @param { ResourceColor } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the color of the fill area. - * An invalid value is handled as the default value. - * If this attribute and the universal attribute foregroundColor are both set, whichever is set later takes effect. + * Fill color. * - * @param { ResourceColor } value - Color of the fill area. Default value: Color.Black. + * @param { ResourceColor } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28606,11 +27281,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets the color of the fill area. - * An invalid value is handled as the default value. - * If this attribute and the universal attribute foregroundColor are both set, whichever is set later takes effect. + * Fill color. * - * @param { ResourceColor } value - Color of the fill area. Default value: Color.Black. + * @param { ResourceColor } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28621,35 +27294,26 @@ declare class CommonShapeMethod extends CommonMethod { fill(value: ResourceColor): T; /** - * Sets the offset of the start point for drawing the stroke. - * An invalid value is handled as the default value. + * Offset from the start point of the border drawing. * - * @param { number | string } value - Offset of the start point for drawing the stroke. - * Default value: 0 - * Default unit: vp + * @param { number | string } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the offset of the start point for drawing the stroke. - * An invalid value is handled as the default value. + * Offset from the start point of the border drawing. * - * @param { number | string } value - Offset of the start point for drawing the stroke. - * Default value: 0 - * Default unit: vp + * @param { number | string } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the offset of the start point for drawing the stroke. - * An invalid value is handled as the default value. + * Offset from the start point of the border drawing. * - * @param { number | string } value - Offset of the start point for drawing the stroke. - * Default value: 0 - * Default unit: vp + * @param { number | string } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28657,12 +27321,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets the offset of the start point for drawing the stroke. - * An invalid value is handled as the default value. + * Offset from the start point of the border drawing. * - * @param { number | string } value - Offset of the start point for drawing the stroke. - * Default value: 0 - * Default unit: vp + * @param { number | string } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28673,26 +27334,26 @@ declare class CommonShapeMethod extends CommonMethod { strokeDashOffset(value: number | string): T; /** - * Sets the cap style of the stroke. + * Path endpoint drawing style. * - * @param { LineCapStyle } value - Cap style of the stroke. Default value: LineCapStyle.Butt + * @param { LineCapStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the cap style of the stroke. + * Path endpoint drawing style. * - * @param { LineCapStyle } value - Cap style of the stroke. Default value: LineCapStyle.Butt + * @param { LineCapStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the cap style of the stroke. + * Path endpoint drawing style. * - * @param { LineCapStyle } value - Cap style of the stroke. Default value: LineCapStyle.Butt + * @param { LineCapStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28700,9 +27361,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets the cap style of the stroke. + * Path endpoint drawing style. * - * @param { LineCapStyle } value - Cap style of the stroke. Default value: LineCapStyle.Butt + * @param { LineCapStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28713,29 +27374,26 @@ declare class CommonShapeMethod extends CommonMethod { strokeLineCap(value: LineCapStyle): T; /** - * Sets the join style of the stroke. - * This attribute does not work for the Circle component, which does not have corners. + * Border corner drawing style. * - * @param { LineJoinStyle } value - Join style of the stroke. Default value: LineJoinStyle.Miter + * @param { LineJoinStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the join style of the stroke. - * This attribute does not work for the Circle component, which does not have corners. + * Border corner drawing style. * - * @param { LineJoinStyle } value - Join style of the stroke. Default value: LineJoinStyle.Miter + * @param { LineJoinStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the join style of the stroke. - * This attribute does not work for the Circle component, which does not have corners. + * Border corner drawing style. * - * @param { LineJoinStyle } value - Join style of the stroke. Default value: LineJoinStyle.Miter + * @param { LineJoinStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28743,10 +27401,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets the join style of the stroke. - * This attribute does not work for the Circle component, which does not have corners. + * Border corner drawing style. * - * @param { LineJoinStyle } value - Join style of the stroke. Default value: LineJoinStyle.Miter + * @param { LineJoinStyle } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28797,35 +27454,26 @@ declare class CommonShapeMethod extends CommonMethod { strokeMiterLimit(value: number | string): T; /** - * Sets the stroke opacity. - * The value range is [0.0, 1.0]. - * A value less than 0.0 evaluates to the value 0.0. A value greater than 1.0 evaluates to the value 1.0. - * Any other value evaluates to the value 1.0. + * Sets the opacity of the border. * - * @param { number | string | Resource } value - Stroke opacity. Default value: 1 + * @param { number | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the stroke opacity. - * The value range is [0.0, 1.0]. - * A value less than 0.0 evaluates to the value 0.0. A value greater than 1.0 evaluates to the value 1.0. - * Any other value evaluates to the value 1.0. + * Sets the opacity of the border. * - * @param { number | string | Resource } value - Stroke opacity. Default value: 1 + * @param { number | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the stroke opacity. - * The value range is [0.0, 1.0]. - * A value less than 0.0 evaluates to the value 0.0. A value greater than 1.0 evaluates to the value 1.0. - * Any other value evaluates to the value 1.0. + * Sets the opacity of the border. * - * @param { number | string | Resource } value - Stroke opacity. Default value: 1 + * @param { number | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28833,12 +27481,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets the stroke opacity. - * The value range is [0.0, 1.0]. - * A value less than 0.0 evaluates to the value 0.0. A value greater than 1.0 evaluates to the value 1.0. - * Any other value evaluates to the value 1.0. + * Sets the opacity of the border. * - * @param { number | string | Resource } value - Stroke opacity. Default value: 1 + * @param { number | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28849,35 +27494,26 @@ declare class CommonShapeMethod extends CommonMethod { strokeOpacity(value: number | string | Resource): T; /** - * Sets the opacity of the fill area. - * The value range is [0.0, 1.0]. - * A value less than 0.0 evaluates to the value 0.0. A value greater than 1.0 evaluates to the value 1.0. - * Any other value evaluates to the value 1.0. + * fill Opacity * - * @param { number | string | Resource } value - Opacity of the fill area. Default value: 1 + * @param { number | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the opacity of the fill area. - * The value range is [0.0, 1.0]. - * A value less than 0.0 evaluates to the value 0.0. A value greater than 1.0 evaluates to the value 1.0. - * Any other value evaluates to the value 1.0. + * fill Opacity * - * @param { number | string | Resource } value - Opacity of the fill area. Default value: 1 + * @param { number | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the opacity of the fill area. - * The value range is [0.0, 1.0]. - * A value less than 0.0 evaluates to the value 0.0. A value greater than 1.0 evaluates to the value 1.0. - * Any other value evaluates to the value 1.0. + * fill Opacity * - * @param { number | string | Resource } value - Opacity of the fill area. Default value: 1 + * @param { number | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28885,12 +27521,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets the opacity of the fill area. - * The value range is [0.0, 1.0]. - * A value less than 0.0 evaluates to the value 0.0. A value greater than 1.0 evaluates to the value 1.0. - * Any other value evaluates to the value 1.0. + * fill Opacity * - * @param { number | string | Resource } value - Opacity of the fill area. Default value: 1 + * @param { number | string | Resource } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28901,41 +27534,26 @@ declare class CommonShapeMethod extends CommonMethod { fillOpacity(value: number | string | Resource): T; /** - * Sets the stroke width. - * If this attribute is of the string type, percentage values are not supported and will be treated as 1 px. + * Sets the width of the dividing line. * - * @param { Length } value - Stroke width. - * The value must be greater than or equal to 0. - * Default value: 1. - * Default unit: vp. - * An invalid value is handled as the default value. + * @param { Length } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets the stroke width. - * If this attribute is of the string type, percentage values are not supported and will be treated as 1 px. + * Sets the width of the dividing line. * - * @param { Length } value - Stroke width. - * The value must be greater than or equal to 0. - * Default value: 1. - * Default unit: vp. - * An invalid value is handled as the default value. + * @param { Length } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets the stroke width. - * If this attribute is of the string type, percentage values are not supported and will be treated as 1 px. + * Sets the width of the dividing line. * - * @param { Length } value - Stroke width. - * The value must be greater than or equal to 0. - * Default value: 1. - * Default unit: vp. - * An invalid value is handled as the default value. + * @param { Length } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28943,14 +27561,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets the stroke width. - * If this attribute is of the string type, percentage values are not supported and will be treated as 1 px. + * Sets the width of the dividing line. * - * @param { Length } value - Stroke width. - * The value must be greater than or equal to 0. - * Default value: 1. - * Default unit: vp. - * An invalid value is handled as the default value. + * @param { Length } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28961,35 +27574,26 @@ declare class CommonShapeMethod extends CommonMethod { strokeWidth(value: Length): T; /** - * Specifies whether anti-aliasing is enabled. + * Indicates whether to enable anti-aliasing * - * @param { boolean } value - Whether anti-aliasing is enabled. - * true: Anti-aliasing is enabled. - * false: Anti-aliasing is disabled. - * Default value: true + * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Specifies whether anti-aliasing is enabled. + * Indicates whether to enable anti-aliasing * - * @param { boolean } value - Whether anti-aliasing is enabled. - * true: Anti-aliasing is enabled. - * false: Anti-aliasing is disabled. - * Default value: true + * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Specifies whether anti-aliasing is enabled. + * Indicates whether to enable anti-aliasing * - * @param { boolean } value - Whether anti-aliasing is enabled. - * true: Anti-aliasing is enabled. - * false: Anti-aliasing is disabled. - * Default value: true + * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -28997,12 +27601,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Specifies whether anti-aliasing is enabled. + * Indicates whether to enable anti-aliasing * - * @param { boolean } value - Whether anti-aliasing is enabled. - * true: Anti-aliasing is enabled. - * false: Anti-aliasing is disabled. - * Default value: true + * @param { boolean } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -29013,35 +27614,26 @@ declare class CommonShapeMethod extends CommonMethod { antiAlias(value: boolean): T; /** - * Sets stroke dashes. - * The value must be greater than or equal to 0. Invalid values are treated as the default value. + * Sets the gap for the border. * - * @param { Array } value - Stroke dashes. - * Default value: [] - * Default unit: vp + * @param { Array } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Sets stroke dashes. - * The value must be greater than or equal to 0. Invalid values are treated as the default value. + * Sets the gap for the border. * - * @param { Array } value - Stroke dashes. - * Default value: [] - * Default unit: vp + * @param { Array } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Sets stroke dashes. - * The value must be greater than or equal to 0. Invalid values are treated as the default value. + * Sets the gap for the border. * - * @param { Array } value - Stroke dashes. - * Default value: [] - * Default unit: vp + * @param { Array } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -29049,12 +27641,9 @@ declare class CommonShapeMethod extends CommonMethod { * @since 10 */ /** - * Sets stroke dashes. - * The value must be greater than or equal to 0. Invalid values are treated as the default value. + * Sets the gap for the border. * - * @param { Array } value - Stroke dashes. - * Default value: [] - * Default unit: vp + * @param { Array } value * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -29202,7 +27791,7 @@ declare interface LinearGradient { } /** - * Defines the direction of pixel rounding at the component level. + * Defines the pixel round property. * * @interface PixelRoundPolicy * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29213,7 +27802,7 @@ declare interface LinearGradient { */ declare interface PixelRoundPolicy { /** - * Rounding for alignment with the start edge. + * start property. * * @type { ?PixelRoundCalcPolicy } * @default PixelRoundCalcPolicy.NO_FORCE_ROUND @@ -29226,7 +27815,7 @@ declare interface PixelRoundPolicy { start?: PixelRoundCalcPolicy; /** - * Rounding for alignment with the top edge. + * top property. * * @type { ?PixelRoundCalcPolicy } * @default PixelRoundCalcPolicy.NO_FORCE_ROUND @@ -29239,7 +27828,7 @@ declare interface PixelRoundPolicy { top?: PixelRoundCalcPolicy; /** - * Rounding for alignment with the end edge. + * end property. * * @type { ?PixelRoundCalcPolicy } * @default PixelRoundCalcPolicy.NO_FORCE_ROUND @@ -29252,7 +27841,7 @@ declare interface PixelRoundPolicy { end?: PixelRoundCalcPolicy; /** - * Rounding for alignment with the bottom edge. + * bottom property. * * @type { ?PixelRoundCalcPolicy } * @default PixelRoundCalcPolicy.NO_FORCE_ROUND @@ -29296,7 +27885,7 @@ declare interface LinearGradientBlurOptions { /** * Define motion blur anchor coordinates. - * + * * @interface MotionBlurAnchor * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -29326,7 +27915,7 @@ declare interface MotionBlurAnchor { /** * Define motion blur options. - * + * * @interface MotionBlurOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -29345,7 +27934,7 @@ declare interface MotionBlurOptions { radius: number; /** * Define motion blur anchor coordinates. - * + * * @type { MotionBlurAnchor } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -29505,7 +28094,7 @@ declare interface LayoutChild { * @since 9 * @deprecated since 10 */ - measure(childConstraint: ConstraintSizeOptions), + measure(childConstraint: ConstraintSizeOptions); /** * Call this layout method in onLayout callback to assign layout info to sub component. @@ -29516,7 +28105,7 @@ declare interface LayoutChild { * @since 9 * @deprecated since 10 */ - layout(childLayoutInfo: LayoutInfo), + layout(childLayoutInfo: LayoutInfo); } /** @@ -29606,7 +28195,7 @@ declare interface GeometryInfo extends SizeResult { * @since 10 */ /** - * Provides the child component layout information. + * Sub component info passed from framework when layout happens. * * @interface Layoutable * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29654,7 +28243,7 @@ declare interface Layoutable { * @since 10 */ /** - * Applies the specified position information to the child component. + * Call this layout method in onLayout callback to assign layout info to sub component. * * @param { Position } position * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29662,10 +28251,10 @@ declare interface Layoutable { * @atomicservice * @since 11 */ - layout(position: Position): void, + layout(position: Position): void; /** - * Obtains the margin of the child component. + * Call this method to get the margin of sub component. * * @returns { DirectionalEdgesT } the margin of sub component, unit is vp * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29673,21 +28262,21 @@ declare interface Layoutable { * @atomicservice * @since 12 */ - getMargin() : DirectionalEdgesT, + getMargin() : DirectionalEdgesT; /** * Call this method to get the padding of sub component. * - * @returns { DirectionalEdgesT } Padding of the child component, unit is vp. + * @returns { DirectionalEdgesT } the padding of sub component, unit is vp * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - getPadding() : DirectionalEdgesT, - + getPadding() : DirectionalEdgesT; + /** - * Obtains the border width of the child component. + * Call this method to get the borderWidth of sub component. * * @returns { DirectionalEdgesT } the borderWidth of sub component, unit is vp * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29695,7 +28284,7 @@ declare interface Layoutable { * @atomicservice * @since 12 */ - getBorderWidth() : DirectionalEdgesT, + getBorderWidth() : DirectionalEdgesT; } /** @@ -29717,7 +28306,7 @@ declare interface Layoutable { */ declare interface Measurable { /** - * Unique ID that the system assigns to the child component. + * Unique ID of the child component. * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29737,30 +28326,30 @@ declare interface Measurable { * @since 10 */ /** - * Applies the size constraint to the child component. + * Call this measure method in onMeasure callback to supply sub component size. * * @param { ConstraintSizeOptions } constraint - * @returns { MeasureResult } Provides the measurement result of the component. + * @returns { MeasureResult } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ - measure(constraint: ConstraintSizeOptions) : MeasureResult, + measure(constraint: ConstraintSizeOptions) : MeasureResult; /** - * Obtains the margin of the child component. + * Call this method to get the margin of sub component. * - * @returns { DirectionalEdgesT } Margin of the child component, unit is vp. + * @returns { DirectionalEdgesT } the margin of sub component, unit is vp * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - getMargin() : DirectionalEdgesT, + getMargin() : DirectionalEdgesT; /** - * Obtains the padding of the child component. + * Call this method to get the padding of sub component. * * @returns { DirectionalEdgesT } the padding of sub component, unit is vp * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29768,18 +28357,18 @@ declare interface Measurable { * @atomicservice * @since 12 */ - getPadding() : DirectionalEdgesT, + getPadding() : DirectionalEdgesT; /** - * Obtains the border width of the child component. + * Call this method to get the borderWidth of sub component. * - * @returns { DirectionalEdgesT } Border width of the child component, unit is vp. + * @returns { DirectionalEdgesT } the borderWidth of sub component, unit is vp * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - getBorderWidth() : DirectionalEdgesT, + getBorderWidth() : DirectionalEdgesT; } /** @@ -29791,7 +28380,7 @@ declare interface Measurable { * @since 10 */ /** - * Provides the component size information. + * Sub component SizeResult info. * * @interface SizeResult * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29809,7 +28398,7 @@ declare interface SizeResult { * @since 10 */ /** - * Width obtained from the measurement result. Unit: vp. + * Width obtained from the measurement result. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29828,7 +28417,7 @@ declare interface SizeResult { * @since 10 */ /** - * Height obtained from the measurement result. Unit: vp. + * Height obtained from the measurement result. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -29849,7 +28438,7 @@ declare interface SizeResult { * @since 10 */ /** - * Provides the measurement result of the component. + * Sub component MeasureResult info. * * @extends SizeResult * @interface MeasureResult @@ -29953,6 +28542,7 @@ declare type VisualEffect = import('../api/@ohos.graphics.uiEffect').default.Vis */ declare type Filter = import('../api/@ohos.graphics.uiEffect').default.Filter; + /** * Blender * @@ -30042,8 +28632,7 @@ declare type PromptActionDialogController = import('../api/@ohos.promptAction'). */ declare class CustomComponent extends BaseCustomComponent { /** - * Invoked when a reusable custom component is re-added to the node tree - * from the reuse cache to receive construction parameters of the component. + * aboutToReuse Method * * @param { object } params - Custom component init params. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30051,8 +28640,7 @@ declare class CustomComponent extends BaseCustomComponent { * @since 10 */ /** - * Invoked when a reusable custom component is re-added to the node tree - * from the reuse cache to receive construction parameters of the component. + * aboutToReuse Method * * @param { object } params - Custom component init params. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30061,8 +28649,7 @@ declare class CustomComponent extends BaseCustomComponent { * @since 11 */ /** - * Invoked when a reusable custom component is re-added to the node tree - * from the reuse cache to receive construction parameters of the component. + * aboutToReuse Method * * @param { Record } params - Custom component init params. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30111,9 +28698,9 @@ declare class CustomComponent extends BaseCustomComponent { */ declare class CustomComponentV2 extends BaseCustomComponent { /** - * Invoked when a reusable custom component managed by state management V2 - * is taken from the reuse pool and reinserted into the node tree. - * + * aboutToReuse Method for @ComponentV2, it is executed when fetching instance of custom component from RecyclePool. + * It is different from the @Reusable in CustomComponent, there is no param parameter in this callback. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -30133,7 +28720,7 @@ declare class CustomComponentV2 extends BaseCustomComponent { * @since 18 */ declare class BaseCustomComponent extends CommonAttribute { - /** + /** * Customize the pop-up content constructor . * * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30175,41 +28762,37 @@ declare class BaseCustomComponent extends CommonAttribute { build(): void; /** - * Invoked after a new instance of the custom component is created - * and before its build() function is executed. You can change state variables in aboutToAppear. - * The change will take effect when you execute the build() function next time. - * The aboutToAppear lifecycle callback of a custom component with a custom layout - * is invoked during the layout process. + * aboutToAppear Method + * + * The aboutToAppear function is executed after a new instance of the custom component is created, before its build() function is executed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Invoked after a new instance of the custom component is created - * and before its build() function is executed. You can change state variables in aboutToAppear. - * The change will take effect when you execute the build() function next time. - * The aboutToAppear lifecycle callback of a custom component with a custom layout - * is invoked during the layout process. + * aboutToAppear Method + * + * The aboutToAppear function is executed after a new instance of the custom component is created, before its build() function is executed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Invoked after a new instance of the custom component is created - * and before its build() function is executed. You can change state variables in aboutToAppear. - * The change will take effect when you execute the build() function next time. - * The aboutToAppear lifecycle callback of a custom component with a custom layout - * is invoked during the layout process. + * aboutToAppear Method + * + * The aboutToAppear function is executed after a new instance of the custom component is created, before its build() function is executed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 10 */ /** - * Invoked after a new instance of the custom component is created - * and before its build() function is executed. You can change state variables in aboutToAppear. - * The change will take effect when you execute the build() function next time. - * The aboutToAppear lifecycle callback of a custom component with a custom layout - * is invoked during the layout process. + * aboutToAppear Method + * + * The aboutToAppear function is executed after a new instance of the custom component is created, before its build() function is executed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -30217,11 +28800,10 @@ declare class BaseCustomComponent extends CommonAttribute { * @since 11 */ /** - * Invoked after a new instance of the custom component is created - * and before its build() function is executed. You can change state variables in aboutToAppear. - * The change will take effect when you execute the build() function next time. - * The aboutToAppear lifecycle callback of a custom component with a custom layout - * is invoked during the layout process. + * aboutToAppear Method and it is migrated from class CustomComponent. + * + * The aboutToAppear function is executed after a new instance of the custom component is created, before its build() function is executed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -30231,33 +28813,37 @@ declare class BaseCustomComponent extends CommonAttribute { aboutToAppear?(): void; /** - * Invoked when this component is about to disappear. - * Do not change state variables in the aboutToDisappear function as doing this can cause unexpected errors. - * For example, the modification of the @Link decorated variable may cause unstable application running. + * aboutToDisappear Method + * + * The aboutToDisappear function executes before a custom component is destroyed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Invoked when this component is about to disappear. - * Do not change state variables in the aboutToDisappear function as doing this can cause unexpected errors. - * For example, the modification of the @Link decorated variable may cause unstable application running. + * aboutToDisappear Method + * + * The aboutToDisappear function executes before a custom component is destroyed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 9 */ /** - * Invoked when this component is about to disappear. - * Do not change state variables in the aboutToDisappear function as doing this can cause unexpected errors. - * For example, the modification of the @Link decorated variable may cause unstable application running. + * aboutToDisappear Method + * + * The aboutToDisappear function executes before a custom component is destroyed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form * @since 10 */ /** - * Invoked when this component is about to disappear. - * Do not change state variables in the aboutToDisappear function as doing this can cause unexpected errors. - * For example, the modification of the @Link decorated variable may cause unstable application running. + * aboutToDisappear Method + * + * The aboutToDisappear function executes before a custom component is destroyed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -30265,9 +28851,10 @@ declare class BaseCustomComponent extends CommonAttribute { * @since 11 */ /** - * Invoked when this component is about to disappear. - * Do not change state variables in the aboutToDisappear function as doing this can cause unexpected errors. - * For example, the modification of the @Link decorated variable may cause unstable application running. + * aboutToDisappear Method and it is migrated from class CustomComponent. + * + * The aboutToDisappear function executes before a custom component is destroyed. + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @form @@ -30303,7 +28890,7 @@ declare class BaseCustomComponent extends CommonAttribute { /** * The onWillApplyTheme function is a custom hook to get active theme object from the context - * + * * @param { Theme } theme - Custom theme init params. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -30312,7 +28899,7 @@ declare class BaseCustomComponent extends CommonAttribute { */ /** * The onWillApplyTheme function is a custom hook to get active theme object from the context, it is migrated from class CustomComponent. - * + * * @param { Theme } theme - Custom theme init params. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -30390,37 +28977,37 @@ declare class BaseCustomComponent extends CommonAttribute { onMeasureSize?(selfLayoutInfo: GeometryInfo, children: Array, constraint: ConstraintSizeOptions): SizeResult; /** - * Invoked each time the page is displayed, for example, during page redirection. - * When the application is switched to the foreground. - * It works only for the custom components decorated by **@Entry**. - * + * onPageShow Method + * + * The page is triggered once each time it is displayed, including scenarios such as the routing process and the application entering the foreground + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Invoked each time the page is displayed, for example, during page redirection. - * When the application is switched to the foreground. - * It works only for the custom components decorated by **@Entry**. - * + * onPageShow Method + * + * The page is triggered once each time it is displayed, including scenarios such as the routing process and the application entering the foreground + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Invoked each time the page is displayed, for example, during page redirection. - * When the application is switched to the foreground. - * It works only for the custom components decorated by **@Entry**. - * + * onPageShow Method + * + * The page is triggered once each time it is displayed, including scenarios such as the routing process and the application entering the foreground + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ /** - * Invoked each time the page is displayed, for example, during page redirection. - * When the application is switched to the foreground. - * It works only for the custom components decorated by **@Entry**. - * + * onPageShow Method and it is migrated from class CustomComponent. + * + * The page is triggered once each time it is displayed, including scenarios such as the routing process and the application entering the foreground + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -30429,37 +29016,37 @@ declare class BaseCustomComponent extends CommonAttribute { onPageShow?(): void; /** - * Invoked each time the page is hidden, for example, during page redirection. - * When the application is switched to the background. - * It works only for the custom components decorated by **@Entry**. - * + * onPageHide Method + * + * It is triggered once each time the page is hidden, including scenarios such as the routing process and the application entering the background + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 */ /** - * Invoked each time the page is hidden, for example, during page redirection. - * When the application is switched to the background. - * It works only for the custom components decorated by **@Entry**. - * + * onPageHide Method + * + * It is triggered once each time the page is hidden, including scenarios such as the routing process and the application entering the background + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Invoked each time the page is hidden, for example, during page redirection. - * When the application is switched to the background. - * It works only for the custom components decorated by **@Entry**. - * + * onPageHide Method + * + * It is triggered once each time the page is hidden, including scenarios such as the routing process and the application entering the background + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ /** - * Invoked each time the page is hidden, for example, during page redirection. - * When the application is switched to the background. - * It works only for the custom components decorated by **@Entry**. - * + * onPageHide Method and it is migrated from class CustomComponent. + * + * It is triggered once each time the page is hidden, including scenarios such as the routing process and the application entering the background + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -30538,11 +29125,8 @@ declare class BaseCustomComponent extends CommonAttribute { /** * onBackPress Method * - * Invoked when the user clicks the Back button. - * It works only for the custom components decorated by @Entry. - * The value **true** means that the page executes its own return logic. - * And **false** (default) means that the default return logic is used. - * + * Triggered when the user clicks the back button + * * @returns { void | boolean } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 @@ -30550,11 +29134,8 @@ declare class BaseCustomComponent extends CommonAttribute { /** * onBackPress Method * - * Invoked when the user clicks the Back button. - * It works only for the custom components decorated by @Entry. - * The value **true** means that the page executes its own return logic. - * And **false** (default) means that the default return logic is used. - * + * Triggered when the user clicks the back button + * * @returns { void | boolean } true means that the page itself processes the return logic. * false means that the default return logic is used. * If no value is returned, the default return logic is used. @@ -30565,11 +29146,8 @@ declare class BaseCustomComponent extends CommonAttribute { /** * onBackPress Method * - * Invoked when the user clicks the Back button. - * It works only for the custom components decorated by @Entry. - * The value **true** means that the page executes its own return logic. - * And **false** (default) means that the default return logic is used. - * + * Triggered when the user clicks the back button + * * @returns { void | boolean } true means that the page itself processes the return logic. * false means that the default return logic is used. * If no value is returned, the default return logic is used. @@ -30579,11 +29157,10 @@ declare class BaseCustomComponent extends CommonAttribute { * @since 11 */ /** - * Invoked when the user clicks the Back button. - * It works only for the custom components decorated by @Entry. - * The value **true** means that the page executes its own return logic. - * And **false** (default) means that the default return logic is used. - * + * onBackPress Method and it is migrated from class CustomComponent. + * + * Triggered when the user clicks the back button + * * @returns { void | boolean } true means that the page itself processes the return logic. * false means that the default return logic is used. * If no value is returned, the default return logic is used. @@ -30659,9 +29236,6 @@ declare class BaseCustomComponent extends CommonAttribute { /** * Get uniqueId of the custom component. - * This unique ID is assigned by the system to each component. - * If this API is called before the component's corresponding node is created or after it has been destroyed, an - * invalid unique ID, which is -1, will be returned. * * @returns { number } - The uniqueId of the custom component. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30671,9 +29245,6 @@ declare class BaseCustomComponent extends CommonAttribute { */ /** * Get uniqueId of the custom component and it is migrated from class CustomComponent. - * This unique ID is assigned by the system to each component. - * If this API is called before the component's corresponding node is created or after it has been destroyed, an - * invalid unique ID, which is -1, will be returned. * * @returns { number } - The uniqueId of the custom component. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30684,7 +29255,7 @@ declare class BaseCustomComponent extends CommonAttribute { getUniqueId(): number; /** - * Queries the **NavDestination** information of this custom component. + * Queries the navigation destination information. * * @returns { NavDestinationInfo | undefined } The navigation destination information, or undefined if it is not available. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30692,7 +29263,7 @@ declare class BaseCustomComponent extends CommonAttribute { * @since 11 */ /** - * Queries the **NavDestination** information of this custom component. + * Queries the navigation destination information. * * @returns { NavDestinationInfo | undefined } The navigation destination information, or undefined if it is not available. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30701,7 +29272,7 @@ declare class BaseCustomComponent extends CommonAttribute { * @since 12 */ /** - * Queries the **NavDestination** information of this custom component. + * Queries the navigation destination information and it is migrated from class CustomComponent. * * @returns { NavDestinationInfo | undefined } The navigation destination information, or undefined if it is not available. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30725,8 +29296,8 @@ declare class BaseCustomComponent extends CommonAttribute { queryNavDestinationInfo(isInner: Optional): NavDestinationInfo | undefined; /** - * Queries the **Navigation** information of this custom component. - * + * Query the navigation information of the current custom component. + * * @returns { NavigationInfo | undefined } The navigation information, or undefined if it is not available * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -30734,8 +29305,8 @@ declare class BaseCustomComponent extends CommonAttribute { * @since 12 */ /** - * Queries the **Navigation** information of this custom component. - * + * Query the navigation information of the current custom component and it is migrated from class CustomComponent. + * * @returns { NavigationInfo | undefined } The navigation information, or undefined if it is not available * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -30745,7 +29316,7 @@ declare class BaseCustomComponent extends CommonAttribute { queryNavigationInfo(): NavigationInfo | undefined; /** - * Obtains a **RouterPageInfo** instance. + * Query the router page information of the current custom component. * * @returns { RouterPageInfo | undefined } The router page information, or undefined if it is not available. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30754,7 +29325,7 @@ declare class BaseCustomComponent extends CommonAttribute { * @since 12 */ /** - * Obtains a **RouterPageInfo** instance. + * Query the router page information of the current custom component and it is migrated from class CustomComponent. * * @returns { RouterPageInfo | undefined } The router page information, or undefined if it is not available. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30762,7 +29333,7 @@ declare class BaseCustomComponent extends CommonAttribute { * @atomicservice * @since 18 */ - queryRouterPageInfo(): RouterPageInfo | undefined; + queryRouterPageInfo(): RouterPageInfo | undefined; /** * The callback method after the custom component is built. @@ -30784,7 +29355,7 @@ declare class BaseCustomComponent extends CommonAttribute { * @atomicservice * @since 18 */ - onDidBuild?(): void; + onDidBuild?(): void; /** * The dialog controller of the custom component. @@ -30855,7 +29426,7 @@ declare class View { * @since 10 */ /** - * Describe the position, width, and height of a component. + * Rect info. * * @interface RectResult * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30872,7 +29443,7 @@ declare interface RectResult { * @since 10 */ /** - * Horizontal coordinate. + * x:Horizontal coordinate relative to the component. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30890,7 +29461,7 @@ declare interface RectResult { * @since 10 */ /** - * Vertical coordinate. + * y:Vertical axis coordinate relative to the component. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30908,7 +29479,7 @@ declare interface RectResult { * @since 10 */ /** - * Content width. + * Get the width of the current textRect. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30926,7 +29497,7 @@ declare interface RectResult { * @since 10 */ /** - * Content height. + * Get the height of the current textRect. * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -30988,7 +29559,7 @@ declare interface CaretOffset { * @since 12 */ x: number; - + /** * Get the y of the relative position. * @@ -31056,15 +29627,6 @@ declare abstract class TextContentControllerBase { /** * Get the index and relative position of the CaretOffset. * - *

NOTE: - *
If this API is called when the caret position is updated in the current frame, it will not take effect. - *
For the Search component, the returned position information is the offset of the first character - * relative to the search icon in the component. - *
If no text is entered in the Search component, - * the return value contains the position information relative to the component. - *
The location information in the return value is the location of the caret relative to the editable component. - *

- * * @returns { CaretOffset } index and relative position of the CaretOffset. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31084,15 +29646,7 @@ declare abstract class TextContentControllerBase { /** * Get the start and end positions of the text content. * - *

NOTE: - *
If no text is entered, the return value contains the position information, but the size is 0. - *
The position information is the offset of the first character relative to the editable area. - *
For the Search component, the returned position information is the offset of the first character - * relative to the search icon in the component. - *
If there is input, the width in the return value is the fixed width of the editable area. - *

- * - * @returns { RectResult } Text content rect.The unit of the return value is pixel. + * @returns { RectResult } Text content rect. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -31110,8 +29664,7 @@ declare abstract class TextContentControllerBase { */ /** * Get the lines number of the text content. - * The getTextContentLineCount type is used to obtain the number of lines of the edited text. - * + * * @returns { number } Text content line count * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31215,7 +29768,7 @@ declare enum ContentClipMode { * @atomicservice * @since 14 */ - SAFE_AREA = 2, + SAFE_AREA = 2 } /** @@ -31239,10 +29792,9 @@ declare enum ContentClipMode { */ declare class ScrollableCommonMethod extends CommonMethod { /** - * Sets the scrollbar state. + * Scrollbar status. * - * @param { BarState } barState - Scrollbar state.
Default value: BarState.Auto for the List, Grid, - * and Scroll components and BarState.Off for the WaterFlow component + * @param { BarState } barState - Scrollbar status. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31252,11 +29804,9 @@ declare class ScrollableCommonMethod extends CommonMethod { scrollBar(barState: BarState): T; /** - * Sets the scrollbar color. + * Color of the scrollbar. * - * @param { Color | number | string } color - Scrollbar color.
Default value: '\#182431' (40% opacity) - *
A number value indicates a HEX color in RGB or ARGB format, - * for example, 0xffffff. A string value indicates a color in RGB or ARGB format, for example, '#ffffff'. + * @param { Color | number | string } color - Color of the scrollbar. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31266,7 +29816,7 @@ declare class ScrollableCommonMethod extends CommonMethod { scrollBarColor(color: Color | number | string): T; /** - * Sets the scrollbar width. + * Sets the scrollbar color. * * @param { number | string } value - Scrollbar width.
Default value: 4 *
Unit: vp @@ -31293,14 +29843,10 @@ declare class ScrollableCommonMethod extends CommonMethod { scrollBarMargin(margin: ScrollBarMargin): T; /** - * Sets the effect used when the scroll boundary is reached. + * Edge scrolling effect. * - * @param { EdgeEffect } edgeEffect - Effect used when the scroll boundary is reached. The spring and shadow effects are supported. - *
Default value: EdgeEffect.None for the Grid, Scroll, and WaterFlow components and EdgeEffect.Spring for the List component - * @param { EdgeEffectOptions } options - Whether to enable the scroll effect when the component content is smaller than the component itself. - * The value { alwaysEnabled: true } means to enable the scroll effect, and { alwaysEnabled: false } means the opposite. - *
Default value:
{ alwaysEnabled: false } for the List, Grid, and WaterFlow components, - * and { alwaysEnabled: true } for the Scroll component + * @param { EdgeEffect } edgeEffect - edge scrolling effect. + * @param { EdgeEffectOptions } options - edge scrolling effect options. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31323,10 +29869,10 @@ declare class ScrollableCommonMethod extends CommonMethod { fadingEdge(enabled: Optional, options?: FadingEdgeOptions): T; /** - * Sets the nested scrolling options. + * Nested scrolling options. * - * @param { NestedScrollOptions } value - Nested scrolling options. - * @returns { T } + * @param { NestedScrollOptions } value - options for nested scrolling. + * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -31335,10 +29881,10 @@ declare class ScrollableCommonMethod extends CommonMethod { nestedScroll(value: NestedScrollOptions): T; /** - * Sets whether to support scroll gestures. + * Whether to support scroll gestures by finger or mouse. * - * @param { boolean } value - Whether to support scroll gestures.
Default value: true - * @returns { T } + * @param { boolean } value - Whether to support scroll gestures by finger or mouse. + * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -31347,10 +29893,10 @@ declare class ScrollableCommonMethod extends CommonMethod { enableScrollInteraction(value: boolean): T; /** - * Sets the friction coefficient. + * Friction coefficient. * - * @param { number | Resource } value - Friction coefficient. - * @returns { T } + * @param { number | Resource } value - friction coefficient. + * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -31359,7 +29905,7 @@ declare class ScrollableCommonMethod extends CommonMethod { friction(value: number | Resource): T; /** - * Triggered when the scrollable component scrolls. + * Called when the scrollable scrolls. * * @param { function } event - callback of scrollable, * scrollOffset is offset per frame scrolling, ScrollState is current scroll state. @@ -31386,9 +29932,10 @@ declare class ScrollableCommonMethod extends CommonMethod { onWillScroll(handler: Optional): T; /** - * Triggered when the scrollable component scrolls. + * Called when the scrollable did scroll. * - * @param { OnScrollCallback } handler - Callback triggered when the scrollable component scrolls. + * @param { OnScrollCallback } handler - callback of scrollable, + * scrollOffset is offset this frame did scroll, scrollState is current scroll state. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31401,7 +29948,7 @@ declare class ScrollableCommonMethod extends CommonMethod { /** * Called when the scrollable will end dragging. * - * @param { OnWillStopDraggingCallback } handler - callback of end dragging. + * @param { OnWillStopDraggingCallback } handler - callback of end dragging, * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31412,7 +29959,7 @@ declare class ScrollableCommonMethod extends CommonMethod { onWillStopDragging(handler: OnWillStopDraggingCallback): T; /** - * Triggered when the scrollable component reaches the start position. + * Called when the scrollable reaches the start position. * * @param { function } event - Callback function, triggered when the scrollable reaches the start position. * @returns { T } @@ -31424,7 +29971,7 @@ declare class ScrollableCommonMethod extends CommonMethod { onReachStart(event: () => void): T; /** - * Triggered when the scrollable component reaches the end position. + * Called when the scrollable reaches the end position. * * @param { function } event - Callback function, triggered when the scrollable reaches the end position. * @returns { T } @@ -31436,7 +29983,7 @@ declare class ScrollableCommonMethod extends CommonMethod { onReachEnd(event: () => void): T; /** - * Triggered when the scrollable component starts scrolling initiated by the user's finger dragging the component or its scrollbar. + * Called when the scrollable starts scrolling. * * @param { function } event - Callback function, triggered when the scrollable starts scrolling. * @returns { T } @@ -31448,7 +29995,7 @@ declare class ScrollableCommonMethod extends CommonMethod { onScrollStart(event: () => void): T; /** - * Triggered when scrolling stops after the user's finger leaves the screen. + * Called when the scrollable stops scrolling. * * @param { function } event - Callback function, triggered when the scrollable stops scrolling. * @returns { T } @@ -31460,12 +30007,10 @@ declare class ScrollableCommonMethod extends CommonMethod { onScrollStop(event: () => void): T; /** - * Sets the maximum initial velocity at the start of the fling animation that occurs after gesture-driven scrolling ends. + * Limit the max speed when fling. * - * @param { number } speedLimit - Maximum initial velocity at the start of the fling animation. - *
Default value: 9000 - *
Unit: vp/s - *
Value range: (0, +∞). If this parameter is set to a value less than or equal to 0, the default value is used. + * @param { number } speedLimit - Max fling speed, the minimum value is 0, the maximum value is not limited. + * The unit is vp/s. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31475,8 +30020,8 @@ declare class ScrollableCommonMethod extends CommonMethod { flingSpeedLimit(speedLimit: number): T; /** - * Sets the content clipping area for this scrollable component. - * + * Clip the content of the scrollable container, excluding background. + * * @param { ContentClipMode | RectShape } clip - A value from enum ContentClipMode or a customized clip rect. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -31497,12 +30042,12 @@ declare class ScrollableCommonMethod extends CommonMethod { * @since 18 */ digitalCrownSensitivity(sensitivity: Optional): T; - + /** - * Sets whether to enable the back-to-top feature for a scrollable component when the status bar is touched. - * - * @param { boolean } backToTop - Whether to enable the back-to-top feature for a scrollable component when the status bar is touched. - *
Default value: false + * Controls whether the scrollable scrolls back to top when status bar is clicked. + * + * @param { boolean } backToTop - whether the scrollable scrolls back to top when status bar is clicked. + * The default value is false. * @returns { T } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31538,7 +30083,7 @@ declare class ScrollResult { * @param { number } scrollOffset - offset this frame will scroll, which may or may not be reached. * @param { ScrollState } scrollState - current scroll state. * @param { ScrollSource } scrollSource - source of current scroll. - * @returns { void | ScrollResult } the remain offset for the scrollable, + * @returns { void | ScrollResult } the remain offset for the scrollable, * same as scrollOffset when no ScrollResult is returned. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -31549,30 +30094,30 @@ declare type OnWillScrollCallback = (scrollOffset: number, scrollState: ScrollState, scrollSource: ScrollSource) => void | ScrollResult; /** - * On scroll callback using in scrollable onDidScroll. - * - * @typedef { function } OnScrollCallback - * @param { number } scrollOffset - offset this frame did scroll. - * @param { ScrollState } scrollState - current scroll state. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ + * On scroll callback using in scrollable onDidScroll. + * + * @typedef { function } OnScrollCallback + * @param { number } scrollOffset - offset this frame did scroll. + * @param { ScrollState } scrollState - current scroll state. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 12 + */ declare type OnScrollCallback = (scrollOffset: number, scrollState: ScrollState) => void; /** - * On scroll callback using in scrollable onWillStopDragging. - * - * @typedef { function } OnWillStopDraggingCallback - * @param { number } velocity - The velocity of the scroll view at the moment the touch was released. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ + * On scroll callback using in scrollable onWillStopDragging. + * + * @typedef { function } OnWillStopDraggingCallback + * @param { number } velocity - The veolicity of the scroll view at the moment the touch was released. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ declare type OnWillStopDraggingCallback = (velocity: number) => void; /** @@ -31653,10 +30198,7 @@ declare interface ItemDragEventHandler { */ declare class DynamicNode { /** - * Invoked when data is moved during drag and drop sorting. - * This callback is only applicable in a List component. - * where each ForEach iteration generates a ListItem component. - * It allows you to define custom drag actions and handle various drag events. + * Set the move action. * * @param { Optional } handler * @returns { T } @@ -31668,10 +30210,7 @@ declare class DynamicNode { onMove(handler: Optional): T; /** - * Invoked when data is moved during drag and drop sorting. - * This callback is only applicable in a List component. - * where each ForEach iteration generates a ListItem component. - * It allows you to define custom drag actions and handle various drag events. + * Set the move action. * * @param { Optional } handler * @param { ItemDragEventHandler } eventHandler @@ -31778,7 +30317,7 @@ declare class ChildrenMainSize { * * @param { number } childDefaultSize - default main size, in vp. If the main axis is vertical, it indicates height. * If the main axis is horizontal, it indicates width. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. @@ -31794,7 +30333,7 @@ declare class ChildrenMainSize { * * @param { number } value - default main size, in vp. If the main axis is vertical, it indicates height. * If the main axis is horizontal, it indicates width. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. @@ -31823,7 +30362,7 @@ declare class ChildrenMainSize { * @param { number } start - Zero-based index at which to start changing the children main size. * @param { number } [deleteCount] - Indicating the number of children main size to remove from start. * @param { Array } [childrenSize] - Add the new children main size, beginning from start. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. @@ -31842,7 +30381,7 @@ declare class ChildrenMainSize { * * @param { number } index - index of child to be updated. * @param { number } childSize - new section options. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. @@ -31865,10 +30404,10 @@ declare class ChildrenMainSize { declare interface BackgroundBrightnessOptions { /** - * Brightness change rate. A higher rate means that brightness decreases more quickly. - * If **rate** is set to **0**, **lightUpDegree** will not take effect, meaning no brightening effect will occur. + * Rate represents the rate at which lightUpDegree + * decreases with increasing pixel brightness. * - * @type { number } - The default value is 0.0, value range: (0.0, +∞). + * @type { number } -The default value is 0.0, value range: (0.0, +∞). * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 @@ -31876,9 +30415,11 @@ declare interface BackgroundBrightnessOptions { rate: number; /** - * Light up degree. A greater degree indicates a greater increase in brightness. + * LightUpDegree represents the degree of brightness + * of the rgb value changes when its brightness + * is 0. * - * @type { number } - The default value is 0.0, value range: [-1.0, 1.0]. + * @type { number } -The default value is 0.0, value range: [-1.0, 1.0]. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 @@ -31980,13 +30521,11 @@ declare interface LightSource { * @systemapi * @since 12 */ - color?: ResourceColor; + color?: ResourceColor; } /** - * wrapBuilder is a template function that returns a WrappedBuilder object. - * wrapBuilder only accepts a global @Builder decorated function as its argument. - * Of the WrappedBuilder object it returns, the builder attribute method can be used only inside the struct. + * Defining wrapBuilder function. * @param { function } builder * @returns { WrappedBuilder } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -31994,9 +30533,7 @@ declare interface LightSource { * @since 11 */ /** - * wrapBuilder is a template function that returns a WrappedBuilder object. - * wrapBuilder only accepts a global @Builder decorated function as its argument. - * Of the WrappedBuilder object it returns, the builder attribute method can be used only inside the struct. + * Defining wrapBuilder function. * @param { function } builder * @returns { WrappedBuilder } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -32007,13 +30544,13 @@ declare interface LightSource { declare function wrapBuilder(builder: (...args: Args) => void): WrappedBuilder; /** - * The WrappedBuilder object is also a template class. + * Defines the WrappedBuilder class. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 */ /** - * The WrappedBuilder object is also a template class. + * Defines the WrappedBuilder class. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -32021,14 +30558,12 @@ declare function wrapBuilder(builder: (...args: Args) => */ declare class WrappedBuilder { /** - * global @Builder decorated function. * @type { function } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 */ /** - * global @Builder decorated function. * @type { function } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -32137,6 +30672,7 @@ declare interface KeyframeAnimateParam { * Indicates expectedFrameRateRange of keyframe animation. * * @type { ?ExpectedFrameRateRange } + * @default { min: 0, expected: 0, max: 0 } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -32186,6 +30722,7 @@ declare interface KeyframeState { * Animation curve of this keyframe. * * @type { ?(Curve | string | ICurve) } + * @default Curve.EaseInOut * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 11 @@ -32194,6 +30731,7 @@ declare interface KeyframeState { * Animation curve of this keyframe. * * @type { ?(Curve | string | ICurve) } + * @default Curve.EaseInOut * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -32231,7 +30769,7 @@ declare interface KeyframeState { * @atomicservice * @since 12 */ -declare interface Callback { +declare interface Callback { /** * Defines the callback info. * @@ -32258,7 +30796,7 @@ declare interface Callback { * @atomicservice * @since 12 */ -declare type HoverCallback = (isHover: boolean, event: HoverEvent) => void +declare type HoverCallback = (isHover: boolean, event: HoverEvent) => void; /** * Defines the callback type used in accessibility hover events. @@ -32273,7 +30811,7 @@ declare type HoverCallback = (isHover: boolean, event: HoverEvent) => void * @atomicservice * @since 12 */ -declare type AccessibilityCallback = (isHover: boolean, event: AccessibilityHoverEvent) => void +declare type AccessibilityCallback = (isHover: boolean, event: AccessibilityHoverEvent) => void; /** * Defines the callback type used in accessibility hover transparent event. @@ -32285,7 +30823,7 @@ declare type AccessibilityCallback = (isHover: boolean, event: AccessibilityHove * @atomicservice * @since 20 */ -declare type AccessibilityTransparentCallback = (event: TouchEvent) => void +declare type AccessibilityTransparentCallback = (event: TouchEvent) => void; /** * Defines the options about VisibleAreaEvent. @@ -32392,7 +30930,7 @@ declare interface UICommonEvent { /** * Set or reset the callback is triggered when component uninstallation disappears. - * + * * @param { Callback | undefined } callback - The callback will be triggered when component uninstallation disappears. If set undefined will reset the target callback. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -32437,7 +30975,7 @@ declare interface UICommonEvent { /** * Set or reset the callback which is triggered when has a hover event. - * + * * @param { HoverCallback | undefined } callback - The callback will be triggered when has a hover event. If set undefined will reset the target callback. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -32447,29 +30985,29 @@ declare interface UICommonEvent { setOnHover(callback: HoverCallback | undefined): void; /** - * Set or reset the callback which is triggered when has a mouse event. - * - * @param { Callback | undefined } callback - The callback will be triggered when has mouse input. If set undefined will reset the target callback. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ + * Set or reset the callback which is triggered when has a mouse event. + * + * @param { Callback | undefined } callback - The callback will be triggered when has mouse input. If set undefined will reset the target callback. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ setOnMouse(callback: Callback | undefined): void; /** - * Sets the callback for the onSizeChange event. - * - * @param { SizeChangeCallback | undefined } callback - The callback will be triggered when the size of component changed. If set undefined will reset the target callback. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ + * Set or reset the callback which is triggered when the size of component changed. + * + * @param { SizeChangeCallback | undefined } callback - The callback will be triggered when the size of component changed. If set undefined will reset the target callback. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ setOnSizeChange(callback: SizeChangeCallback | undefined): void; /** - * Sets the onVisibleAreaChange callback that limits the callback interval. + * Set or reset the callback which is triggered when the visibleArea of component changed. * * @param { VisibleAreaEventOptions } options - The options for the visibility event. * @param { VisibleAreaChangeCallback | undefined } event - The callback will be triggered when the visibleArea of component changed and get close to any number in ratios defined by options. @@ -32574,9 +31112,9 @@ declare interface UIGestureEvent { * @since 12 */ addGesture(gesture: GestureHandler, priority?: GesturePriority, mask?: GestureMask): void; - + /** - * Adds a gesture that can be recognized at once by the component and its child component. + * Add a parallel gesture bound to the component. * * @param { GestureHandler } gesture - gesture indicates the gesture bound to a component. * @param { GestureMask } mask - mask indicates the gesture's GestureMask value. @@ -32588,7 +31126,7 @@ declare interface UIGestureEvent { addParallelGesture(gesture: GestureHandler, mask?: GestureMask): void; /** - * Remove a gesture from a component that has been bound with a specific tag through a modifier. + * Remove the gesture that is bound to the component and marked as tag. * * @param { string } tag - tag indicates the gesture's tag. * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -32611,7 +31149,7 @@ declare interface UIGestureEvent { /** * Defines the gesture modifier. - * + * * @interface GestureModifier * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -32621,7 +31159,7 @@ declare interface UIGestureEvent { declare interface GestureModifier { /** * Defines the gesture update function. - * + * * @param { UIGestureEvent } event * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -32736,7 +31274,7 @@ declare interface FocusMovement { */ declare enum KeyboardAvoidMode { /** - * Automatically avoids the soft keyboard and compresses the height when reaching the maximum limit. + * Defines avoid keyboard when keyboard shows. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -32746,14 +31284,14 @@ declare enum KeyboardAvoidMode { DEFAULT = 0, /** - * Does not avoid the soft keyboard. + * Defines not avoid keyboard when keyboard shows. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 */ - NONE = 1, + NONE = 1 } /** @@ -32785,12 +31323,12 @@ declare enum HoverModeAreaType { * @atomicservice * @since 14 */ - BOTTOM_SCREEN = 1, + BOTTOM_SCREEN = 1 } /** * Defines a range of dates. - * + * * @interface DateRange * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform diff --git a/api/@internal/component/ets/container_span.d.ts b/api/@internal/component/ets/container_span.d.ts index 93349f5594110fdd20fb8b40db8e0634d890e2ac..aa555965ff5a376b23918f47ae722555a6d84828 100644 --- a/api/@internal/component/ets/container_span.d.ts +++ b/api/@internal/component/ets/container_span.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { TextBackgroundStyle } from './span'; -import { AttributeModifier } from './common'; -/*** endif */ - /** * Span container interface. * @@ -38,8 +33,7 @@ import { AttributeModifier } from './common'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface ContainerSpanInterface { /** @@ -57,8 +51,7 @@ interface ContainerSpanInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ (): ContainerSpanAttribute; } @@ -76,8 +69,7 @@ interface ContainerSpanInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class ContainerSpanAttribute { /** @@ -97,8 +89,7 @@ declare class ContainerSpanAttribute { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textBackgroundStyle(style: TextBackgroundStyle): ContainerSpanAttribute; @@ -110,8 +101,7 @@ declare class ContainerSpanAttribute { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ attributeModifier(modifier: AttributeModifier): ContainerSpanAttribute; } diff --git a/api/@internal/component/ets/content_slot.d.ts b/api/@internal/component/ets/content_slot.d.ts index 79d291376e5b609e3da7154bdc6f034118edba0f..8e45e9a32e92a657332800bd7bf9eb2786edacb5 100644 --- a/api/@internal/component/ets/content_slot.d.ts +++ b/api/@internal/component/ets/content_slot.d.ts @@ -18,10 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Content } from '../../@ohos.arkui.node'; -/*** endif */ - /** * Define Content type * @@ -39,8 +35,7 @@ declare type Content = import('../api/@ohos.arkui.node').Content; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class ContentSlotAttribute { } @@ -52,8 +47,7 @@ declare class ContentSlotAttribute { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface ContentSlotInterface { /** @@ -64,8 +58,7 @@ interface ContentSlotInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ (content: Content): ContentSlotAttribute; } @@ -78,4 +71,4 @@ interface ContentSlotInterface { * @atomicservice * @since 12 */ -declare const ContentSlot: ContentSlotInterface; \ No newline at end of file +declare const ContentSlot: ContentSlotInterface; diff --git a/api/@internal/component/ets/context_menu.d.ts b/api/@internal/component/ets/context_menu.d.ts index d730292d8564a43abe2d2699314940fbb13de728..d170cc40d5aca664bf350b8939fb9199dfe764a6 100644 --- a/api/@internal/component/ets/context_menu.d.ts +++ b/api/@internal/component/ets/context_menu.d.ts @@ -12,56 +12,54 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - /** * @file * @kit ArkUI */ - /** * Defines Close contextMenu. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 8 */ /** * Defines Close contextMenu. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** * Defines Close contextMenu. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 11 */ declare class ContextMenu { - /** - * Invoking method close. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Invoking method close. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Invoking method close. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - * @deprecated since 18 - * @useinstead ohos.arkui.UIContext.ContextMenuController#close - */ - static close(); + /** + * Invoking method close. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 8 + */ + /** + * Invoking method close. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Invoking method close. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + * @deprecated since 18 + * @useinstead ohos.arkui.UIContext.ContextMenuController#close + */ + static close(); } diff --git a/api/@internal/component/ets/counter.d.ts b/api/@internal/component/ets/counter.d.ts index c71cb953d8895791c1addc4b88d4980afbae03a4..9fb6cf9cc9fa2759b59f405ff41a7123d2f7594c 100644 --- a/api/@internal/component/ets/counter.d.ts +++ b/api/@internal/component/ets/counter.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod } from './common' -import { VoidCallback } from './units' -/*** endif */ - /** * Counter component, which provides corresponding increment or decrement counting operations. * @@ -55,8 +50,7 @@ import { VoidCallback } from './units' * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface CounterInterface { /** @@ -91,8 +85,7 @@ interface CounterInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): CounterAttribute; } @@ -129,8 +122,7 @@ interface CounterInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CounterAttribute extends CommonMethod { /** @@ -181,8 +173,7 @@ declare class CounterAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onInc(event: VoidCallback): CounterAttribute; @@ -234,8 +225,7 @@ declare class CounterAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDec(event: VoidCallback): CounterAttribute; @@ -256,8 +246,7 @@ declare class CounterAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableDec(value: boolean): CounterAttribute; @@ -278,8 +267,7 @@ declare class CounterAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableInc(value: boolean): CounterAttribute; } diff --git a/api/@internal/component/ets/custom_dialog_controller.d.ts b/api/@internal/component/ets/custom_dialog_controller.d.ts index ad2578e930b22abb42f4dc5d90d15f7524a19da9..8002913639470deb5b3d08ab8cd462b682851a63 100644 --- a/api/@internal/component/ets/custom_dialog_controller.d.ts +++ b/api/@internal/component/ets/custom_dialog_controller.d.ts @@ -18,22 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { - Rectangle, AnimateParam, Callback, ShadowOptions, ShadowStyle, KeyboardAvoidMode, BlurStyle, HoverModeAreaType, - DismissReason, BackgroundBlurStyleOptions, BackgroundEffectOptions -} from './common'; -import { CustomBuilder } from './builder'; -import { ExtendableComponent } from './extendableComponent'; -import { DialogAlignment } from './alertDialog'; -import { Offset, ResourceColor, Dimension, BorderRadiuses, EdgeWidths, EdgeColors, EdgeStyles } from './units'; -import { BorderStyle } from './enums'; -import { LengthMetrics } from '../Graphics'; -import { LevelMode, LevelOrder, ImmersiveMode } from '../../@ohos.promptAction'; -import { CustomBuilder } from './builder'; -import { DismissDialogAction } from './actionSheet'; -/*** endif */ - /** * Defines the options of CustomDialogController. * @@ -56,8 +40,7 @@ import { DismissDialogAction } from './actionSheet'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CustomDialogControllerOptions { /** @@ -86,18 +69,6 @@ declare interface CustomDialogControllerOptions { */ builder: any; - /** - * Custom builder function. - * - * @type { CustomBuilder | ExtendableComponent } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - builder: CustomBuilder | ExtendableComponent; - /** * Defines the cancel function. * @@ -120,8 +91,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ cancel?: () => void; @@ -147,8 +117,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ autoCancel?: boolean; @@ -174,8 +143,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignment?: DialogAlignment; @@ -201,8 +169,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset?: Offset; @@ -228,8 +195,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ customStyle?: boolean; @@ -255,8 +221,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ gridCount?: number; @@ -275,8 +240,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maskColor?: ResourceColor; @@ -295,8 +259,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maskRect?: Rectangle; @@ -315,8 +278,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ openAnimation?: AnimateParam; @@ -335,8 +297,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ closeAnimation?: AnimateParam; @@ -356,8 +317,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showInSubWindow?: boolean; @@ -376,8 +336,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ backgroundColor?: ResourceColor; @@ -396,8 +355,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ cornerRadius?: Dimension | BorderRadiuses; @@ -416,8 +374,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isModal?: boolean; @@ -428,8 +385,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillDismiss?: Callback; @@ -440,8 +396,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width?: Dimension; @@ -452,8 +407,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height?: Dimension; @@ -464,8 +418,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderWidth?: Dimension | EdgeWidths; @@ -476,8 +429,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderColor?: ResourceColor | EdgeColors; @@ -488,8 +440,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderStyle?: BorderStyle | EdgeStyles; @@ -500,8 +451,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shadow?: ShadowOptions | ShadowStyle; @@ -513,8 +463,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundBlurStyle?: BlurStyle; @@ -525,8 +474,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -537,8 +485,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -550,8 +497,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ keyboardAvoidMode?: KeyboardAvoidMode; @@ -563,8 +509,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableHoverMode?: boolean; @@ -576,8 +521,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ hoverModeArea?: HoverModeAreaType; @@ -588,8 +532,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onDidAppear?: Callback; @@ -600,8 +543,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onDidDisappear?: Callback; @@ -612,8 +554,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onWillAppear?: Callback; @@ -624,8 +565,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ onWillDisappear?: Callback; @@ -636,8 +576,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ keyboardAvoidDistance?: LengthMetrics; @@ -649,8 +588,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ levelMode?: LevelMode; @@ -661,8 +599,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ levelUniqueId?: number; @@ -674,8 +611,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ immersiveMode?: ImmersiveMode; @@ -687,8 +623,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ levelOrder?: LevelOrder; @@ -700,8 +635,7 @@ declare interface CustomDialogControllerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ focusable?: boolean; } @@ -768,8 +702,7 @@ declare type PromptActionCommonState = import('../api/@ohos.promptAction').promp * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class CustomDialogController { /** @@ -794,8 +727,7 @@ declare class CustomDialogController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(value: CustomDialogControllerOptions); @@ -822,17 +754,6 @@ declare class CustomDialogController { */ open(); - /** - * Display the content of the customized pop-up window. If the content has been displayed, it does not take effect. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - open(): void; - /** * Closes the custom pop-up window. If the window is closed, the window does not take effect. * @@ -855,17 +776,6 @@ declare class CustomDialogController { * @since 11 */ close(); - - /** - * Closes the custom pop-up window. If the window is closed, the window does not take effect. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - close(): void; /** * Get the state of the custom pop-up window. diff --git a/api/@internal/component/ets/data_panel.d.ts b/api/@internal/component/ets/data_panel.d.ts index a68c0a2617af7956befb55d0df0f1db64a0fb264..02fa057c4e305c64e3a0987eadca2622188b0030 100644 --- a/api/@internal/component/ets/data_panel.d.ts +++ b/api/@internal/component/ets/data_panel.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceColor, Length } from './units' -import { CommonMethod, ContentModifier, CommonConfiguration, MultiShadowOptions } from './common' -/*** endif */ - /** * DataPanelType enum * @@ -55,8 +50,7 @@ import { CommonMethod, ContentModifier, CommonConfiguration, MultiShadowOptions * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum DataPanelType { /** @@ -87,8 +81,7 @@ declare enum DataPanelType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Line, @@ -120,8 +113,7 @@ declare enum DataPanelType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Circle, } @@ -138,8 +130,7 @@ declare enum DataPanelType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ColorStop { /** @@ -155,8 +146,7 @@ declare interface ColorStop { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ color: ResourceColor; @@ -173,8 +163,7 @@ declare interface ColorStop { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset: Length; } @@ -192,8 +181,7 @@ declare interface ColorStop { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class LinearGradient { /** @@ -211,8 +199,7 @@ declare class LinearGradient { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(colorStops: ColorStop[]); } @@ -234,8 +221,7 @@ declare class LinearGradient { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface DataPanelShadowOptions extends MultiShadowOptions { /** @@ -255,8 +241,7 @@ declare interface DataPanelShadowOptions extends MultiShadowOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ colors?: Array; } @@ -293,8 +278,7 @@ declare interface DataPanelShadowOptions extends MultiShadowOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface DataPanelOptions { /** @@ -329,8 +313,7 @@ declare interface DataPanelOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ values: number[]; @@ -366,8 +349,7 @@ declare interface DataPanelOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ max?: number; @@ -403,8 +385,7 @@ declare interface DataPanelOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ type?: DataPanelType; } @@ -441,8 +422,7 @@ declare interface DataPanelOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface DataPanelInterface { /** @@ -481,8 +461,7 @@ interface DataPanelInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options: DataPanelOptions): DataPanelAttribute; } @@ -495,8 +474,7 @@ interface DataPanelInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface DataPanelConfiguration extends CommonConfiguration { /** @@ -506,8 +484,7 @@ declare interface DataPanelConfiguration extends CommonConfiguration { /** @@ -596,8 +571,7 @@ declare class DataPanelAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ closeEffect(value: boolean): DataPanelAttribute; @@ -618,8 +592,7 @@ declare class DataPanelAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ valueColors(value: Array): DataPanelAttribute; @@ -640,8 +613,7 @@ declare class DataPanelAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ trackBackgroundColor(value: ResourceColor): DataPanelAttribute; @@ -662,8 +634,7 @@ declare class DataPanelAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth(value: Length): DataPanelAttribute; @@ -684,8 +655,7 @@ declare class DataPanelAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ trackShadow(value: DataPanelShadowOptions): DataPanelAttribute; @@ -697,8 +667,7 @@ declare class DataPanelAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentModifier(modifier: ContentModifier): DataPanelAttribute; } diff --git a/api/@internal/component/ets/date_picker.d.ts b/api/@internal/component/ets/date_picker.d.ts index 606505938242c1f8347f043ba066a6e7aeba9916..76a8d6884846b2d13fe7f7e7b8f8c6e5d37e7034 100644 --- a/api/@internal/component/ets/date_picker.d.ts +++ b/api/@internal/component/ets/date_picker.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod, PickerTextStyle, PickerDialogButtonStyle, Rectangle, Callback, BlurStyle, ShadowOptions, ShadowStyle, HoverModeAreaType, BackgroundBlurStyleOptions, BackgroundEffectOptions, Optional, DateTimeOptions, Bindable } from './common' -import { ResourceColor, Offset, VoidCallback } from './units' -import { DialogAlignment } from './alertDialog' -import { CrownSensitivity } from './enums' -/*** endif */ - /** * Defines the struct of DatePickerResult. * @@ -47,8 +40,7 @@ import { CrownSensitivity } from './enums' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface DatePickerResult { /** @@ -78,8 +70,7 @@ declare interface DatePickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ year?: number; @@ -110,8 +101,7 @@ declare interface DatePickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ month?: number; @@ -141,8 +131,7 @@ declare interface DatePickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ day?: number; } @@ -154,8 +143,7 @@ declare interface DatePickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare enum DatePickerMode { /** @@ -164,8 +152,7 @@ declare enum DatePickerMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ DATE = 0, @@ -175,8 +162,7 @@ declare enum DatePickerMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ YEAR_AND_MONTH = 1, @@ -189,8 +175,7 @@ declare enum DatePickerMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ MONTH_AND_DAY = 2, } @@ -217,8 +202,7 @@ declare enum DatePickerMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface DatePickerOptions { /** @@ -244,8 +228,7 @@ declare interface DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ start?: Date; @@ -272,8 +255,7 @@ declare interface DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ end?: Date; @@ -303,18 +285,6 @@ declare interface DatePickerOptions { * @since 11 */ selected?: Date; - - /** - * Specifies the date selector check date or time selector check time. - * - * @type { ?(Date | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected?: Date | Bindable; /** * Date columns to be displayed. @@ -330,8 +300,7 @@ declare interface DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ mode?: DatePickerMode; } @@ -358,8 +327,7 @@ declare interface DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface DatePickerInterface { /** @@ -387,8 +355,7 @@ interface DatePickerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options?: DatePickerOptions): DatePickerAttribute; } @@ -415,8 +382,7 @@ interface DatePickerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class DatePickerAttribute extends CommonMethod { /** @@ -442,13 +408,11 @@ declare class DatePickerAttribute extends CommonMethod { * @param { boolean } value - Whether to display the lunar calendar. *
- true: Display the lunar calendar. *
- false: Do not display the lunar. - * @default false * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lunar(value: boolean): DatePickerAttribute; @@ -459,13 +423,11 @@ declare class DatePickerAttribute extends CommonMethod { * @param { Optional } isLunar - Whether to display the lunar calendar. *
- true: Display the lunar calendar. *
- false: Do not display the lunar. - * @default false * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ lunar(isLunar: Optional): DatePickerAttribute; @@ -482,13 +444,11 @@ declare class DatePickerAttribute extends CommonMethod { * Sets the text style for the top and bottom items. * * @param { PickerTextStyle } value - Font color, font size, and font weight of the top and bottom items. - * @default {
color: '#ff182431',
font: {
size: '14fp',
weight: FontWeight.Regular
}
} * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ disappearTextStyle(value: PickerTextStyle): DatePickerAttribute; @@ -497,13 +457,11 @@ declare class DatePickerAttribute extends CommonMethod { * This API supports the undefined type for the style parameter. * * @param { Optional } style - Font color, font size, and font weight of the top and bottom items. - * @default {
color: '#ff182431',
font: {
size: '14fp',
weight: FontWeight.Regular
}
} * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ disappearTextStyle(style: Optional): DatePickerAttribute; @@ -521,13 +479,11 @@ declare class DatePickerAttribute extends CommonMethod { * * @param { PickerTextStyle } value - Font color, font size, and font weight of all items except the top, *
bottom, and selected items. - * @default {
color: '#ff182431',
font: {
size: '16fp',
weight: FontWeight.Regular
}
} * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle(value: PickerTextStyle): DatePickerAttribute; @@ -537,13 +493,11 @@ declare class DatePickerAttribute extends CommonMethod { * * @param { Optional } style - Font color, font size, and font weight of all items except the top, *
bottom, and selected items. - * @default {
color: '#ff182431',
font: {
size: '16fp',
weight: FontWeight.Regular
}
} * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ textStyle(style: Optional): DatePickerAttribute; @@ -560,13 +514,11 @@ declare class DatePickerAttribute extends CommonMethod { * Sets the text style for the selected item. * * @param { PickerTextStyle } value - Font color, font size, and font weight of the selected item. - * @default {
color: '#ff007dff',
font: {
size: '20vp',
weight: FontWeight.Medium
}
} * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedTextStyle(value: PickerTextStyle): DatePickerAttribute; @@ -575,13 +527,11 @@ declare class DatePickerAttribute extends CommonMethod { * this API supports the undefined type for the style parameter. * * @param { Optional } style - Font color, font size, and font weight of the selected item. - * @default {
color: '#ff007dff',
font: {
size: '20vp',
weight: FontWeight.Medium
}
} * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ selectedTextStyle(style: Optional): DatePickerAttribute; @@ -625,8 +575,7 @@ declare class DatePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDateChange(callback: Callback): DatePickerAttribute; @@ -638,8 +587,7 @@ declare class DatePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDateChange(callback: Optional>): DatePickerAttribute; @@ -647,13 +595,11 @@ declare class DatePickerAttribute extends CommonMethod { * Sets the sensitivity to the digital crown rotation. * * @param { Optional } sensitivity - Sensitivity to the digital crown rotation. - * @default CrownSensitivity.MEDIUM * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ digitalCrownSensitivity(sensitivity: Optional): DatePickerAttribute; @@ -663,12 +609,10 @@ declare class DatePickerAttribute extends CommonMethod { * @param { Optional } enable - Whether to enable haptic feedback. *
true (default): Haptic feedback is enabled. *
false: Haptic feedback is disabled. - * @default true * @returns { DatePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableHapticFeedback(enable: Optional): DatePickerAttribute; @@ -692,8 +636,7 @@ declare class DatePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare interface LunarSwitchStyle { /** @@ -704,8 +647,7 @@ declare interface LunarSwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ selectedColor?: ResourceColor; @@ -717,8 +659,7 @@ declare interface LunarSwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ unselectedColor?: ResourceColor; @@ -730,8 +671,7 @@ declare interface LunarSwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ strokeColor?: ResourceColor; } @@ -761,8 +701,7 @@ declare interface LunarSwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface DatePickerDialogOptions extends DatePickerOptions { /** @@ -789,8 +728,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lunar?: boolean; @@ -811,8 +749,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lunarSwitch?: boolean; @@ -825,8 +762,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ lunarSwitchStyle?: LunarSwitchStyle; @@ -852,8 +788,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showTime?: boolean; @@ -878,8 +813,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ useMilitaryTime?: boolean; @@ -899,8 +833,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ disappearTextStyle?: PickerTextStyle; @@ -920,8 +853,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle?: PickerTextStyle; @@ -938,8 +870,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ acceptButtonStyle?: PickerDialogButtonStyle; @@ -956,8 +887,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ cancelButtonStyle?: PickerDialogButtonStyle; @@ -977,8 +907,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedTextStyle?: PickerTextStyle; @@ -999,8 +928,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maskRect?: Rectangle; @@ -1020,8 +948,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignment?: DialogAlignment; @@ -1041,8 +968,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset?: Offset; @@ -1089,8 +1015,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onCancel?: VoidCallback; @@ -1135,8 +1060,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDateAccept?: Callback; @@ -1171,8 +1095,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDateChange?: Callback; @@ -1193,8 +1116,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundColor?: ResourceColor; @@ -1215,8 +1137,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundBlurStyle?: BlurStyle; @@ -1227,8 +1148,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -1239,8 +1159,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -1271,8 +1190,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDidAppear?: VoidCallback; @@ -1297,8 +1215,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDidDisappear?: VoidCallback; @@ -1325,8 +1242,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onWillAppear?: VoidCallback; @@ -1353,8 +1269,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onWillDisappear?: VoidCallback; @@ -1367,8 +1282,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shadow?: ShadowOptions | ShadowStyle; @@ -1386,8 +1300,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dateTimeOptions?: DateTimeOptions; @@ -1399,8 +1312,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableHoverMode?: boolean; @@ -1412,8 +1324,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ hoverModeArea?: HoverModeAreaType; @@ -1425,8 +1336,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableHapticFeedback?: boolean; @@ -1462,8 +1372,7 @@ declare interface DatePickerDialogOptions extends DatePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class DatePickerDialog { /** @@ -1540,5 +1449,3 @@ declare const DatePicker: DatePickerInterface; * @since 11 */ declare const DatePickerInstance: DatePickerAttribute; - - diff --git a/api/@internal/component/ets/divider.d.ts b/api/@internal/component/ets/divider.d.ts index 8bb25614340f5bb5c60584051d70b11885e1e0da..2ee8f0971bbda0b25ebc343538ec63643465cef9 100644 --- a/api/@internal/component/ets/divider.d.ts +++ b/api/@internal/component/ets/divider.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceColor } from './units'; -import { CommonMethod} from './common'; -import { LineCapStyle } from './enums'; -/*** endif */ - /** * Provides a divider component to separate different content blocks/content elements. * @@ -56,8 +50,7 @@ import { LineCapStyle } from './enums'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface DividerInterface { /** @@ -92,8 +85,7 @@ interface DividerInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): DividerAttribute; } @@ -130,8 +122,7 @@ interface DividerInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class DividerAttribute extends CommonMethod { /** @@ -174,8 +165,7 @@ declare class DividerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ vertical(value: boolean): DividerAttribute; @@ -215,8 +205,7 @@ declare class DividerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ color(value: ResourceColor): DividerAttribute; @@ -256,8 +245,7 @@ declare class DividerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth(value: number | string): DividerAttribute; @@ -297,8 +285,7 @@ declare class DividerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lineCap(value: LineCapStyle): DividerAttribute; } diff --git a/api/@internal/component/ets/effect_component.d.ts b/api/@internal/component/ets/effect_component.d.ts index 98d39ed6473b2f2a706e1e6512025f030a78db3a..da94bc059d80c9e09d341476a0764f1aa6c51938 100644 --- a/api/@internal/component/ets/effect_component.d.ts +++ b/api/@internal/component/ets/effect_component.d.ts @@ -17,10 +17,7 @@ * @file * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod} from './common'; -/*** endif */ /** * Provides an Effect Component, which is invisible, but setting properties on this component defines an effect template * that child components can apply by setting useEffect(true). @@ -28,8 +25,8 @@ import { CommonMethod} from './common'; * @interface EffectComponentInterface * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 + * @noninterop */ interface EffectComponentInterface { /** @@ -38,8 +35,7 @@ interface EffectComponentInterface { * @returns { EffectComponentAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ (): EffectComponentAttribute; @@ -101,8 +97,8 @@ declare enum EffectLayer { * @since 20 */ declare interface EffectComponentOptions { - - /** Use this to determine the component layer 1evel. Default value is none. + /** + * Use this to determine the component layer level. Default value is none. * * @type { ?EffectLayer } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -118,8 +114,8 @@ declare interface EffectComponentOptions { * @extends CommonMethod * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 + * @noninterop */ declare class EffectComponentAttribute extends CommonMethod { /** @@ -141,6 +137,7 @@ declare class EffectComponentAttribute extends CommonMethod {} @@ -381,30 +375,3 @@ declare const Ellipse: EllipseInterface; * @since 11 */ declare const EllipseInstance: EllipseAttribute; - -/** - * Ellipse drawing. - * - * @interface EllipseInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface EllipseInterface { - /** - * Set the value. - * - * @param { EllipseOptions } [options] - ellipse options - * @returns { EllipseAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (options?: EllipseOptions): EllipseAttribute; -} diff --git a/api/@internal/component/ets/embedded_component.d.ts b/api/@internal/component/ets/embedded_component.d.ts index 1dca4bf8ee5164ec85f53afb032ba35fc9cf8250..810607e06aa36008608b238568df792ec714331e 100644 --- a/api/@internal/component/ets/embedded_component.d.ts +++ b/api/@internal/component/ets/embedded_component.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import Want from '../../@ohos.app.ability.Want' -import { Callback, ErrorCallback ,BusinessError} from '../../@ohos.base' -import { CommonMethod, TerminationInfo } from './common' -import { EmbeddedType } from './enums' -/*** endif */ - /** * Provide an interface for the EmbeddedComponent, which is used *
to render UI asynchronously @@ -32,8 +25,8 @@ import { EmbeddedType } from './enums' * @interface EmbeddedComponentInterface * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 + * @noninterop */ interface EmbeddedComponentInterface { /** @@ -51,23 +44,6 @@ interface EmbeddedComponentInterface { loader: import('../api/@ohos.app.ability.Want').default, type: EmbeddedType ): EmbeddedComponentAttribute; - - /** - * Construct the EmbeddedComponent.
- * Called when the EmbeddedComponent is used. - * - * @param { Want } loader - indicates initialization parameter - * @param { EmbeddedType } type - indicates type of the EmbeddedComponent - * @returns { EmbeddedComponentAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - ( - loader: Want, - type: EmbeddedType - ): EmbeddedComponentAttribute; } /** @@ -87,7 +63,7 @@ declare interface TerminationInfo { * @atomicservice * @since 12 */ - code: number; + code: number; /** * Defines the additional termination information. @@ -97,7 +73,7 @@ declare interface TerminationInfo { * @atomicservice * @since 12 */ - want?: import('../api/@ohos.app.ability.Want').default; + want?: import('../api/@ohos.app.ability.Want').default; } /** @@ -106,8 +82,8 @@ declare interface TerminationInfo { * @extends CommonMethod * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 + * @noninterop */ declare class EmbeddedComponentAttribute extends CommonMethod { /** @@ -120,18 +96,6 @@ declare class EmbeddedComponentAttribute extends CommonMethod): EmbeddedComponentAttribute; - - /** - * Called when the provider of the embedded UI is terminated. - * - * @param { Callback } callback - * @returns { EmbeddedComponentAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onTerminated(callback: Callback): EmbeddedComponentAttribute; /** * Called when some error occurred. @@ -143,18 +107,6 @@ declare class EmbeddedComponentAttribute extends CommonMethod } callback - * @returns { EmbeddedComponentAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onError(callback: ErrorCallback): EmbeddedComponentAttribute; } /** @@ -163,6 +115,7 @@ declare class EmbeddedComponentAttribute extends CommonMethod = T | undefined; /** - * Decide whether the width of select menu fit the trigger or content + * Decide whether the width of select menu fit the trigger or content * * @enum { string } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -10198,14 +9854,13 @@ declare type Nullable = T | undefined; * @since 11 */ /** - * Decide whether the width of select menu fit the trigger or content + * Decide whether the width of select menu fit the trigger or content * * @enum { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum OptionWidthMode { /** @@ -10221,8 +9876,7 @@ declare enum OptionWidthMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FIT_CONTENT = 'fit_content', @@ -10239,8 +9893,7 @@ declare enum OptionWidthMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FIT_TRIGGER = 'fit_trigger', } @@ -10260,8 +9913,7 @@ declare enum OptionWidthMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum FoldStatus { /** @@ -10277,8 +9929,7 @@ declare enum FoldStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FOLD_STATUS_UNKNOWN = 0, /** @@ -10294,8 +9945,7 @@ declare enum FoldStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FOLD_STATUS_EXPANDED = 1, /** @@ -10311,8 +9961,7 @@ declare enum FoldStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FOLD_STATUS_FOLDED = 2, /** @@ -10328,8 +9977,7 @@ declare enum FoldStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FOLD_STATUS_HALF_FOLDED = 3, } @@ -10340,8 +9988,7 @@ declare enum FoldStatus { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum AppRotation { @@ -10350,8 +9997,7 @@ declare enum AppRotation { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ROTATION_0 = 0, @@ -10360,8 +10006,7 @@ declare enum AppRotation { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ROTATION_90 = 1, @@ -10370,8 +10015,7 @@ declare enum AppRotation { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ROTATION_180 = 2, @@ -10380,8 +10024,7 @@ declare enum AppRotation { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ROTATION_270 = 3 } @@ -10392,8 +10035,7 @@ declare enum AppRotation { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum EmbeddedType { /** @@ -10401,8 +10043,7 @@ declare enum EmbeddedType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ EMBEDDED_UI_EXTENSION = 0, } @@ -10414,18 +10055,16 @@ declare enum EmbeddedType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -declare enum MarqueeUpdateStrategy { +declare enum MarqueeUpdateStrategy { /** * Reset scroll position and restart scroll. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DEFAULT = 0, @@ -10435,75 +10074,68 @@ declare enum MarqueeUpdateStrategy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PRESERVE_POSITION = 1 } /** * Type of text decoration line style. - * + * * @enum {number} * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum TextDecorationStyle { /** * Solid line. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SOLID = 0, /** * Double lines. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DOUBLE = 1, /** * Dotted line. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DOTTED = 2, /** * Dashed line. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DASHED = 3, /** * Wavy line. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ WAVY = 4, } @@ -10515,8 +10147,7 @@ declare enum TextDecorationStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum TextSelectableMode { /** @@ -10525,8 +10156,7 @@ declare enum TextSelectableMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SELECTABLE_UNFOCUSABLE = 0, @@ -10536,8 +10166,7 @@ declare enum TextSelectableMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SELECTABLE_FOCUSABLE = 1, @@ -10547,8 +10176,7 @@ declare enum TextSelectableMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ UNSELECTABLE = 2, } @@ -10560,8 +10188,7 @@ declare enum TextSelectableMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum AccessibilityHoverType { /** @@ -10570,8 +10197,7 @@ declare enum AccessibilityHoverType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ HOVER_ENTER = 0, @@ -10581,8 +10207,7 @@ declare enum AccessibilityHoverType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ HOVER_MOVE = 1, @@ -10592,8 +10217,7 @@ declare enum AccessibilityHoverType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ HOVER_EXIT = 2, @@ -10603,8 +10227,7 @@ declare enum AccessibilityHoverType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ HOVER_CANCEL = 3, } @@ -10615,8 +10238,7 @@ declare enum AccessibilityHoverType { * @enum {number} * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ declare enum WidthBreakpoint { /** @@ -10624,8 +10246,7 @@ declare enum WidthBreakpoint { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ WIDTH_XS = 0, @@ -10634,8 +10255,7 @@ declare enum WidthBreakpoint { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ WIDTH_SM = 1, @@ -10644,8 +10264,7 @@ declare enum WidthBreakpoint { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ WIDTH_MD = 2, @@ -10654,8 +10273,7 @@ declare enum WidthBreakpoint { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ WIDTH_LG = 3, @@ -10664,8 +10282,7 @@ declare enum WidthBreakpoint { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ WIDTH_XL = 4, } @@ -10676,8 +10293,7 @@ declare enum WidthBreakpoint { * @enum {number} * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ declare enum HeightBreakpoint { /** @@ -10685,8 +10301,7 @@ declare enum HeightBreakpoint { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ HEIGHT_SM = 0, @@ -10695,8 +10310,7 @@ declare enum HeightBreakpoint { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ HEIGHT_MD = 1, @@ -10705,8 +10319,7 @@ declare enum HeightBreakpoint { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ HEIGHT_LG = 2, } @@ -10717,8 +10330,7 @@ declare enum HeightBreakpoint { * @enum {number} * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare enum AxisModel { /** @@ -10726,19 +10338,16 @@ declare enum AxisModel { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ABS_X = 0, /** - * ABS_Y axis type. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ABS_Y = 1, @@ -10747,8 +10356,7 @@ declare enum AxisModel { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ABS_Z = 2, @@ -10757,8 +10365,7 @@ declare enum AxisModel { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ABS_RZ = 3, @@ -10767,8 +10374,7 @@ declare enum AxisModel { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ABS_GAS = 4, @@ -10777,8 +10383,7 @@ declare enum AxisModel { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ABS_BRAKE = 5, @@ -10787,8 +10392,7 @@ declare enum AxisModel { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ABS_HAT0X = 6, @@ -10797,49 +10401,11 @@ declare enum AxisModel { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ABS_HAT0Y = 7, } -/** - * Page flip mode of Swiper and Tabs on mouse wheel event. - - * @enum { number } PageFlipMode - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 - */ -declare enum PageFlipMode { - /** - * Turn pages continuously according to the number of mouse wheel events. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 - */ - CONTINUOUS = 0, - - /** - * The page-turning animation remains unresponsive to other mouse wheel events until it completes. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 - */ - SINGLE = 1, -} - /** * Focus wrap mode of a list or grid when moving focus using the arrow keys. @@ -10877,8 +10443,7 @@ declare enum FocusWrapMode { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare enum CrownAction { /** @@ -10886,8 +10451,7 @@ declare enum CrownAction { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ BEGIN = 0, @@ -10896,8 +10460,7 @@ declare enum CrownAction { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ UPDATE = 1, @@ -10906,8 +10469,7 @@ declare enum CrownAction { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ END = 2 } @@ -10918,8 +10480,7 @@ declare enum CrownAction { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare enum CrownSensitivity { /** @@ -10927,8 +10488,7 @@ declare enum CrownSensitivity { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ LOW = 0, @@ -10937,8 +10497,7 @@ declare enum CrownSensitivity { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ MEDIUM = 1, @@ -10947,20 +10506,52 @@ declare enum CrownSensitivity { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ HIGH = 2 } +/** + * Page flip mode of Swiper and Tabs on mouse wheel event. + + * @enum { number } PageFlipMode + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 15 + */ +declare enum PageFlipMode { + /** + * Turn pages continuously according to the number of mouse wheel events. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 15 + */ + CONTINUOUS = 0, + + /** + * The page-turning animation remains unresponsive to other mouse wheel events until it completes. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 15 + */ + SINGLE = 1, +} + /** * Type of axis action. * * @enum {number} * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'17','1.2':'20'} - * @arkts 1.1&1.2 + * @since 17 */ declare enum AxisAction { /** @@ -10968,8 +10559,7 @@ declare enum AxisAction { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'17','1.2':'20'} - * @arkts 1.1&1.2 + * @since 17 */ NONE = 0, @@ -10978,8 +10568,7 @@ declare enum AxisAction { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'17','1.2':'20'} - * @arkts 1.1&1.2 + * @since 17 */ BEGIN = 1, @@ -10988,8 +10577,7 @@ declare enum AxisAction { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'17','1.2':'20'} - * @arkts 1.1&1.2 + * @since 17 */ UPDATE = 2, @@ -10998,8 +10586,7 @@ declare enum AxisAction { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'17','1.2':'20'} - * @arkts 1.1&1.2 + * @since 17 */ END = 3, @@ -11008,8 +10595,7 @@ declare enum AxisAction { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'17','1.2':'20'} - * @arkts 1.1&1.2 + * @since 17 */ CANCEL = 4, } @@ -11022,10 +10608,9 @@ declare enum AxisAction { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ - declare enum FocusDrawLevel { +declare enum FocusDrawLevel { /** * Draw focus on node self level. * @@ -11033,8 +10618,7 @@ declare enum AxisAction { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ SELF = 0, @@ -11045,8 +10629,7 @@ declare enum AxisAction { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ TOP = 1, } @@ -11058,8 +10641,7 @@ declare enum AxisAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare enum DividerMode { /** @@ -11068,8 +10650,7 @@ declare enum DividerMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ FLOATING_ABOVE_MENU = 0, @@ -11079,8 +10660,7 @@ declare enum DividerMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ EMBEDDED_IN_MENU = 1, } @@ -11107,7 +10687,7 @@ declare enum EventQueryType { } /** - * Follow position type. + * Tips show position type. * * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full diff --git a/api/@internal/component/ets/flex.d.ts b/api/@internal/component/ets/flex.d.ts index 640ce789835ee36a08f496888d3e41821a9a604e..7e5a2e45036a5c51d6eca298499d30fdbe8317ad 100644 --- a/api/@internal/component/ets/flex.d.ts +++ b/api/@internal/component/ets/flex.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { LengthMetrics } from '../Graphics'; -import { PointLightStyle, CommonMethod } from './common'; -import { FlexWrap, FlexDirection, ItemAlign, FlexAlign } from './enums'; -/*** endif */ - /** * Defines the options of Flex. * @@ -56,8 +50,7 @@ import { FlexWrap, FlexDirection, ItemAlign, FlexAlign } from './enums'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface FlexOptions { /** @@ -93,8 +86,7 @@ declare interface FlexOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ direction?: FlexDirection; @@ -131,8 +123,7 @@ declare interface FlexOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ wrap?: FlexWrap; @@ -169,8 +160,7 @@ declare interface FlexOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ justifyContent?: FlexAlign; @@ -207,8 +197,7 @@ declare interface FlexOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignItems?: ItemAlign; @@ -246,8 +235,7 @@ declare interface FlexOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignContent?: FlexAlign; @@ -259,8 +247,7 @@ declare interface FlexOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ space?: FlexSpaceOptions; } @@ -272,8 +259,7 @@ declare interface FlexOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface FlexSpaceOptions { @@ -284,8 +270,7 @@ declare interface FlexSpaceOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ main?: LengthMetrics; @@ -296,8 +281,7 @@ declare interface FlexSpaceOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ cross?: LengthMetrics; } @@ -334,8 +318,7 @@ declare interface FlexSpaceOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface FlexInterface { /** @@ -374,8 +357,7 @@ interface FlexInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value?: FlexOptions): FlexAttribute; } @@ -412,8 +394,7 @@ interface FlexInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class FlexAttribute extends CommonMethod { /** @@ -423,8 +404,7 @@ declare class FlexAttribute extends CommonMethod { * @returns { FlexAttribute } The attribute of the flex. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pointLight(value: PointLightStyle): FlexAttribute; } diff --git a/api/@internal/component/ets/flow_item.d.ts b/api/@internal/component/ets/flow_item.d.ts index 70cf009cce4621798a1bdf6ed9125db999f3e241..9f803bda91c39a3ecff5432178989610a91232d6 100644 --- a/api/@internal/component/ets/flow_item.d.ts +++ b/api/@internal/component/ets/flow_item.d.ts @@ -18,9 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod } from './common' -/*** endif */ /** * Mesh container for static fixed-size layout scenarios. @@ -44,8 +41,7 @@ import { CommonMethod } from './common' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface FlowItemInterface { /** @@ -70,8 +66,7 @@ interface FlowItemInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): FlowItemAttribute; } @@ -98,8 +93,7 @@ interface FlowItemInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class FlowItemAttribute extends CommonMethod {} diff --git a/api/@internal/component/ets/focus.d.ts b/api/@internal/component/ets/focus.d.ts index 74bdff450b6a9735dd7d6475a2efb14f5f0e4970..495e4f6bbd24387a2f2cc8e0ce18ba47da37a708 100644 --- a/api/@internal/component/ets/focus.d.ts +++ b/api/@internal/component/ets/focus.d.ts @@ -18,10 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { LengthMetrics , ColorMetrics } from '../Graphics'; -/*** endif */ - /** * Focus box style. * @@ -29,8 +25,7 @@ import { LengthMetrics , ColorMetrics } from '../Graphics'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface FocusBoxStyle { /** @@ -40,8 +35,7 @@ declare interface FocusBoxStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ margin?: LengthMetrics; /** @@ -51,8 +45,7 @@ declare interface FocusBoxStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ strokeColor?: ColorMetrics; /** @@ -62,8 +55,7 @@ declare interface FocusBoxStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ strokeWidth?: LengthMetrics; } @@ -75,8 +67,7 @@ declare interface FocusBoxStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum FocusPriority { /** @@ -85,8 +76,7 @@ declare enum FocusPriority { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ AUTO = 0, @@ -96,8 +86,7 @@ declare enum FocusPriority { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PRIOR = 2000, @@ -107,8 +96,7 @@ declare enum FocusPriority { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PREVIOUS = 3000, } @@ -121,8 +109,7 @@ declare enum FocusPriority { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare enum KeyProcessingMode { /** @@ -131,8 +118,7 @@ declare enum KeyProcessingMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ FOCUS_NAVIGATION = 0, @@ -142,8 +128,7 @@ declare enum KeyProcessingMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ANCESTOR_EVENT = 1, } \ No newline at end of file diff --git a/api/@internal/component/ets/folder_stack.d.ts b/api/@internal/component/ets/folder_stack.d.ts index 6a2747be6a4b70a37f3289d7a2849fa960d49354..571e3102b6c8ac2b6fa90c7edbcbbf18ce33f972 100644 --- a/api/@internal/component/ets/folder_stack.d.ts +++ b/api/@internal/component/ets/folder_stack.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import window from '../../@ohos.window'; -import { FoldStatus, Alignment, AppRotation } from './enums'; -import { CommonMethod } from './common'; -/*** endif */ - /** * Import the WindowStatusType type object for onHoverStatusChange. * @@ -34,17 +28,6 @@ import { CommonMethod } from './common'; */ declare type WindowStatusType = import('../api/@ohos.window').default.WindowStatusType; -/** - * Import the WindowStatusType type object for onHoverStatusChange. - * - * @typedef { window.WindowStatusType } WindowStatusType - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type WindowStatusType = window.WindowStatusType - /** * FolderStack constructor options. * @@ -52,8 +35,7 @@ declare type WindowStatusType = window.WindowStatusType * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface FolderStackOptions { /** @@ -81,8 +63,7 @@ interface FolderStackOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ upperItems?: Array; } @@ -102,8 +83,7 @@ interface FolderStackOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface FolderStackInterface { @@ -135,8 +115,7 @@ interface FolderStackInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: FolderStackOptions): FolderStackAttribute; } @@ -148,8 +127,7 @@ interface FolderStackInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface OnFoldStatusChangeInfo { /** @@ -177,8 +155,7 @@ interface OnFoldStatusChangeInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ foldStatus: FoldStatus } @@ -192,8 +169,7 @@ interface OnFoldStatusChangeInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnFoldStatusChangeCallback = (event: OnFoldStatusChangeInfo) => void; @@ -205,8 +181,7 @@ declare type OnFoldStatusChangeCallback = (event: OnFoldStatusChangeInfo) => voi * @param { HoverEventParam } param - hover event param * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnHoverStatusChangeCallback = (param: HoverEventParam) => void; @@ -221,8 +196,7 @@ declare type OnHoverStatusChangeCallback = (param: HoverEventParam) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class FolderStackAttribute extends CommonMethod { /** @@ -242,8 +216,7 @@ declare class FolderStackAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ alignContent(value: Alignment): FolderStackAttribute; @@ -275,8 +248,7 @@ declare class FolderStackAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onFolderStateChange(callback: OnFoldStatusChangeCallback): FolderStackAttribute; @@ -298,8 +270,7 @@ declare class FolderStackAttribute extends CommonMethod { * @returns { FolderStackAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onHoverStatusChange(handler: OnHoverStatusChangeCallback): FolderStackAttribute; @@ -320,8 +291,7 @@ declare class FolderStackAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableAnimation(value: boolean): FolderStackAttribute; @@ -342,8 +312,7 @@ declare class FolderStackAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ autoHalfFold(value: boolean): FolderStackAttribute; } @@ -354,8 +323,7 @@ declare class FolderStackAttribute extends CommonMethod { * @interface HoverEventParam * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface HoverEventParam { /** @@ -364,8 +332,7 @@ declare interface HoverEventParam { * @type { FoldStatus } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ foldStatus: FoldStatus @@ -375,8 +342,7 @@ declare interface HoverEventParam { * @type { boolean } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isHoverMode: boolean @@ -386,8 +352,7 @@ declare interface HoverEventParam { * @type { AppRotation } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ appRotation: AppRotation @@ -397,8 +362,7 @@ declare interface HoverEventParam { * @type { WindowStatusType } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ windowStatusType: WindowStatusType } diff --git a/api/@internal/component/ets/gauge.d.ts b/api/@internal/component/ets/gauge.d.ts index 0d3ebe2d139d1a8d8a32a3f135911025f412f34c..9b39da9c99f24917745844fb511e953d9b0e56c7 100644 --- a/api/@internal/component/ets/gauge.d.ts +++ b/api/@internal/component/ets/gauge.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod,CommonConfiguration,ContentModifier,MultiShadowOptions,Optional } from './common' -import { CustomBuilder } from './builder' -import { ResourceStr,Dimension,ResourceColor,Length } from './units' -import { LinearGradient } from './dataPanel' -/*** endif */ - /** * Defines Gauge constructor options. * @@ -33,8 +26,7 @@ import { LinearGradient } from './dataPanel' * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface GaugeOptions { /** @@ -80,8 +72,7 @@ interface GaugeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ value: number; @@ -128,8 +119,7 @@ interface GaugeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ min?: number; @@ -176,8 +166,7 @@ interface GaugeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ max?: number; } @@ -214,8 +203,7 @@ interface GaugeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface GaugeInterface { /** @@ -274,8 +262,7 @@ interface GaugeInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options: GaugeOptions): GaugeAttribute; } @@ -297,8 +284,7 @@ interface GaugeInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface GaugeShadowOptions extends MultiShadowOptions {} @@ -317,8 +303,7 @@ declare interface GaugeShadowOptions extends MultiShadowOptions {} * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface GaugeIndicatorOptions { @@ -339,8 +324,7 @@ declare interface GaugeIndicatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ icon?: ResourceStr; @@ -361,8 +345,7 @@ declare interface GaugeIndicatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ space?: Dimension; } @@ -375,8 +358,7 @@ declare interface GaugeIndicatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface GaugeConfiguration extends CommonConfiguration { /** @@ -386,8 +368,7 @@ declare interface GaugeConfiguration extends CommonConfiguration { /** @@ -480,8 +458,7 @@ declare class GaugeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value(value: number): GaugeAttribute; @@ -521,8 +498,7 @@ declare class GaugeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ startAngle(angle: number): GaugeAttribute; @@ -562,8 +538,7 @@ declare class GaugeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ endAngle(angle: number): GaugeAttribute; @@ -603,8 +578,7 @@ declare class GaugeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ colors(colors: ResourceColor | LinearGradient | Array<[ResourceColor | LinearGradient, number]>): GaugeAttribute; @@ -644,8 +618,7 @@ declare class GaugeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth(length: Length): GaugeAttribute; @@ -666,8 +639,7 @@ declare class GaugeAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ description(value: CustomBuilder): GaugeAttribute; @@ -688,8 +660,7 @@ declare class GaugeAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ trackShadow(value: GaugeShadowOptions): GaugeAttribute; @@ -710,8 +681,7 @@ declare class GaugeAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ indicator(value: GaugeIndicatorOptions): GaugeAttribute; @@ -724,8 +694,7 @@ declare class GaugeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ privacySensitive(isPrivacySensitiveMode: Optional): GaugeAttribute; @@ -737,8 +706,7 @@ declare class GaugeAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentModifier(modifier: ContentModifier): GaugeAttribute; } diff --git a/api/@internal/component/ets/gesture.d.ts b/api/@internal/component/ets/gesture.d.ts index ed6977605a32b3c7bac5070ba735606e6a8ecb28..464be9eddb6335b1ceb7b5d579eca77e1f18d81c 100644 --- a/api/@internal/component/ets/gesture.d.ts +++ b/api/@internal/component/ets/gesture.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { BaseEvent, SourceTool, Callback } from './common' -import { InteractionHand } from './enums' -/*** endif */ - /** * Creating an Object * @@ -45,8 +40,7 @@ import { InteractionHand } from './enums' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum PanDirection { /** @@ -68,8 +62,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ None, @@ -92,8 +85,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Horizontal, @@ -116,8 +108,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Left, @@ -140,8 +131,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Right, @@ -164,8 +154,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Vertical, @@ -188,8 +177,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Up, @@ -212,8 +200,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Down, @@ -236,8 +223,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ All, } @@ -264,8 +250,7 @@ declare enum PanDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SwipeDirection { /** @@ -287,8 +272,7 @@ declare enum SwipeDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ None, @@ -311,8 +295,7 @@ declare enum SwipeDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Horizontal, @@ -335,8 +318,7 @@ declare enum SwipeDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Vertical, @@ -359,8 +341,7 @@ declare enum SwipeDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ All, } @@ -387,8 +368,7 @@ declare enum SwipeDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum GestureMode { /** @@ -410,8 +390,7 @@ declare enum GestureMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Sequence, @@ -434,8 +413,7 @@ declare enum GestureMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Parallel, @@ -458,8 +436,7 @@ declare enum GestureMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Exclusive, } @@ -486,8 +463,7 @@ declare enum GestureMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum GestureMask { /** @@ -509,8 +485,7 @@ declare enum GestureMask { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Normal, @@ -533,8 +508,7 @@ declare enum GestureMask { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ IgnoreInternal, } @@ -554,8 +528,7 @@ declare enum GestureMask { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum GestureJudgeResult { /** @@ -571,8 +544,7 @@ declare enum GestureJudgeResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CONTINUE = 0, @@ -589,8 +561,7 @@ declare enum GestureJudgeResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ REJECT = 1, } @@ -610,8 +581,7 @@ declare enum GestureJudgeResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare namespace GestureControl { /** @@ -629,8 +599,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enum GestureType { /** @@ -646,8 +615,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ TAP_GESTURE = 0, @@ -664,8 +632,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ LONG_PRESS_GESTURE = 1, @@ -682,8 +649,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PAN_GESTURE = 2, @@ -700,8 +666,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PINCH_GESTURE = 3, @@ -718,8 +683,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SWIPE_GESTURE = 4, @@ -736,8 +700,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ROTATION_GESTURE = 5, @@ -754,8 +717,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DRAG = 6, @@ -772,8 +734,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CLICK = 7, } @@ -794,8 +755,7 @@ declare namespace GestureControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface GestureInfo { /** @@ -813,8 +773,7 @@ declare interface GestureInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ tag?: string; @@ -833,8 +792,7 @@ declare interface GestureInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type: GestureControl.GestureType; @@ -853,8 +811,7 @@ declare interface GestureInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isSystemGesture: boolean; } @@ -958,8 +915,7 @@ declare interface EventLocationInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface FingerInfo { /** @@ -984,8 +940,7 @@ interface FingerInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ id: number; @@ -1033,8 +988,7 @@ interface FingerInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ globalX: number; @@ -1060,8 +1014,7 @@ interface FingerInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ globalY: number; @@ -1087,8 +1040,7 @@ interface FingerInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ localX: number; @@ -1114,8 +1066,7 @@ interface FingerInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ localY: number; @@ -1126,8 +1077,7 @@ interface FingerInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ displayX: number; @@ -1138,8 +1088,7 @@ interface FingerInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ displayY: number; @@ -1150,8 +1099,7 @@ interface FingerInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ hand?: InteractionHand; } @@ -1189,18 +1137,6 @@ declare type GestureType = | RotationGestureInterface | GestureGroupInterface; -/** - * Defines the Gesture Type. - * - * @typedef { Gesture | GestureGroup } GestureType - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -export type GestureType = Gesture | GestureGroup; - /** * Defines the gesture base event. * @@ -1218,8 +1154,7 @@ export type GestureType = Gesture | GestureGroup; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface BaseGestureEvent extends BaseEvent { /** @@ -1237,8 +1172,7 @@ interface BaseGestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fingerList: FingerInfo[]; @@ -1272,8 +1206,7 @@ interface BaseGestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface TapGestureEvent extends BaseGestureEvent { /** @@ -1305,8 +1238,7 @@ interface TapGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface LongPressGestureEvent extends BaseGestureEvent { /** @@ -1324,8 +1256,7 @@ interface LongPressGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ repeat: boolean; } @@ -1347,8 +1278,7 @@ interface LongPressGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface PanGestureEvent extends BaseGestureEvent { /** @@ -1368,8 +1298,7 @@ interface PanGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ offsetX: number; @@ -1390,8 +1319,7 @@ interface PanGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ offsetY: number; @@ -1408,8 +1336,7 @@ interface PanGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ velocityX: number; @@ -1426,8 +1353,7 @@ interface PanGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ velocityY: number; @@ -1444,8 +1370,7 @@ interface PanGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ velocity: number; } @@ -1467,8 +1392,7 @@ interface PanGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface PinchGestureEvent extends BaseGestureEvent { /** @@ -1486,8 +1410,7 @@ interface PinchGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ scale: number; @@ -1508,8 +1431,7 @@ interface PinchGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pinchCenterX: number; @@ -1530,8 +1452,7 @@ interface PinchGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pinchCenterY: number; } @@ -1553,8 +1474,7 @@ interface PinchGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface RotationGestureEvent extends BaseGestureEvent { /** @@ -1574,8 +1494,7 @@ interface RotationGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ angle: number; } @@ -1597,8 +1516,7 @@ interface RotationGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'112','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface SwipeGestureEvent extends BaseGestureEvent { /** @@ -1618,8 +1536,7 @@ interface SwipeGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ angle: number; @@ -1640,8 +1557,7 @@ interface SwipeGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ speed: number; } @@ -1671,8 +1587,7 @@ interface SwipeGestureEvent extends BaseGestureEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface GestureEvent extends BaseEvent { /** @@ -1700,8 +1615,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ repeat: boolean; @@ -1730,8 +1644,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fingerList: FingerInfo[]; @@ -1775,8 +1688,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offsetX: number; @@ -1808,8 +1720,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offsetY: number; @@ -1841,8 +1752,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ angle: number; @@ -1874,8 +1784,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ speed: number; @@ -1904,8 +1813,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scale: number; @@ -1937,8 +1845,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pinchCenterX: number; @@ -1970,8 +1877,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pinchCenterY: number; @@ -1988,8 +1894,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ velocityX: number; @@ -2006,8 +1911,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ velocityY: number; @@ -2024,8 +1928,7 @@ interface GestureEvent extends BaseEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ velocity: number; @@ -2082,8 +1985,7 @@ interface GestureInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ interface BaseHandlerOptions { /** @@ -2094,49 +1996,11 @@ interface GestureInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ isFingerCountLimited?: boolean; } -/** - * Defines Gesture interface. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -export declare class Gesture { - /** - * Set gesture's tag. - * - * @param { string } tag - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - tag(tag: string): this; - - /** - * Input source type for gesture response. - * - * @param { Array } types - indicate the allowed input source for gesture to response - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - allowedTypes(types: Array): this; -} - /** * Defines TapGesture parameters. * @@ -2154,8 +2018,7 @@ export declare class Gesture { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare interface TapGestureParameters extends BaseHandlerOptions { /** @@ -2165,8 +2028,7 @@ declare interface TapGestureParameters extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ count?: number; /** @@ -2176,8 +2038,7 @@ declare interface TapGestureParameters extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fingers?: number; /** @@ -2187,8 +2048,7 @@ declare interface TapGestureParameters extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ distanceThreshold?: number; } @@ -2297,46 +2157,6 @@ interface TapGestureInterface extends GestureInterface { onAction(event: (event: GestureEvent) => void): TapGestureInterface; } -/*** if arkts 1.2 */ -/** - * Defines TapGesture. - * - * @extends Gesture - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class TapGesture extends Gesture { - /** - * Set the value. - * TapGestureParameters: The parameters of the tapGesture. - * - * @param { function } factory - * @param { TapGestureParameters } value - * @returns { TapGesture } - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - static $_instantiate(factory: () => TapGesture, value?: TapGestureParameters): TapGesture - - /** - * Tap gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onAction(event: Callback): this; -} -/*** endif */ - /** * Defines LongPressGesture interface. * @@ -2514,72 +2334,6 @@ interface LongPressGestureInterface extends GestureInterface): LongPressGestureInterface; } -/*** if arkts 1.2 */ -/** - * Defines LongPressGesture. - * - * @extends Gesture - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class LongPressGesture extends Gesture { - /** - * Set the value. - * fingers: Indicates the hand index that triggers the long press. - * repeat: Indicates whether to trigger event callback continuously. - * duration: Minimum press and hold time, in milliseconds. - * - * @param { function } factory - * @param { LongPressGestureHandlerOptions } value - * @returns { LongPressGesture } - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - static $_instantiate(factory: () => LongPressGesture, value?: LongPressGestureHandlerOptions): LongPressGesture - - /** - * LongPress gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onAction(event: Callback): this; - - /** - * The LongPress gesture is successfully recognized. When the finger is lifted, the callback is triggered. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionEnd(event: Callback): this; - - /** - * The LongPress gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionCancel(event: Callback): this; -} -/*** endif */ - /** * Defines the PanGesture options. * @@ -2599,8 +2353,7 @@ export declare class LongPressGesture extends Gesture { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class PanGestureOptions { /** @@ -2629,18 +2382,6 @@ declare class PanGestureOptions { */ constructor(value?: { fingers?: number; direction?: PanDirection; distance?: number }); - /** - * Constructor parameters. - * - * @param { PanGestureHandlerOptions } value - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - constructor(value?: PanGestureHandlerOptions); - /** * Sets the direction attribute. * @@ -2667,18 +2408,6 @@ declare class PanGestureOptions { */ setDirection(value: PanDirection); - /** - * Sets the direction attribute. - * - * @param { PanDirection } value - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - setDirection(value: PanDirection): void; - /** * Sets the setDistance attribute. * @@ -2705,18 +2434,6 @@ declare class PanGestureOptions { */ setDistance(value: number); - /** - * Sets the setDistance attribute. - * - * @param { number } value - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - setDistance(value: number): void; - /** * Sets the setFingers attribute. * @@ -2743,18 +2460,6 @@ declare class PanGestureOptions { */ setFingers(value: number); - /** - * Sets the setFingers attribute. - * - * @param { number } value - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - setFingers(value: number): void; - /** * Get the pan direction attribute. * @@ -2762,8 +2467,7 @@ declare class PanGestureOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getDirection(): PanDirection; /** @@ -2774,8 +2478,7 @@ declare class PanGestureOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getDistance(): number; } @@ -2978,97 +2681,22 @@ interface PanGestureInterface extends GestureInterface { } -/*** if arkts 1.2 */ /** - * Defines PanGesture. + * Defines the SwipeGesture interface. + * + * @extends GestureInterface + * @interface SwipeGestureInterface + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 8 + */ +/** + * Defines the SwipeGesture interface. * - * @extends Gesture + * @extends GestureInterface + * @interface SwipeGestureInterface * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class PanGesture extends Gesture { - /** - * Set the value. - * - * @param { function } factory - * @param { PanGestureHandlerOptions | PanGestureOptions } value - * @returns { PanGesture } - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - static $_instantiate(factory: () => PanGesture, value?: PanGestureHandlerOptions | PanGestureOptions): PanGesture - - /** - * Pan gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionStart(event: Callback): this; - - /** - * Callback when the Pan gesture is moving. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionUpdate(event: Callback): this; - - /** - * The Pan gesture is successfully recognized. When the finger is lifted, the callback is triggered. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionEnd(event: Callback): this; - - /** - * The Pan gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionCancel(event: Callback): this; -} -/*** endif */ - -/** - * Defines the SwipeGesture interface. - * - * @extends GestureInterface - * @interface SwipeGestureInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ -/** - * Defines the SwipeGesture interface. - * - * @extends GestureInterface - * @interface SwipeGestureInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 + * @since 10 */ /** * Defines SwipeGesture interface extends GestureInterface. @@ -3153,45 +2781,6 @@ interface SwipeGestureInterface extends GestureInterface onAction(event: (event: GestureEvent) => void): SwipeGestureInterface; } -/*** if arkts 1.2 */ -/** - * Defines SwipeGesture. - * - * @extends Gesture - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class SwipeGesture extends Gesture { - /** - * Set the value. - * - * @param { function } factory - * @param { SwipeGestureHandlerOptions } value - * @returns { SwipeGesture } - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - static $_instantiate(factory: () => SwipeGesture, value?: SwipeGestureHandlerOptions): SwipeGesture - - /** - * Slide gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onAction(event: Callback): this; -} -/*** endif */ - /** * Defines the PinchGesture interface. * @@ -3390,81 +2979,6 @@ interface PinchGestureInterface extends GestureInterface onActionCancel(event: Callback): PinchGestureInterface; } -/*** if arkts 1.2 */ -/** - * Defines PinchGesture. - * - * @extends Gesture - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class PinchGesture extends Gesture { - /** - * Set the value. - * - * @param { function } factory - * @param { PinchGestureHandlerOptions } value - * @returns { PinchGesture } - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - static $_instantiate(factory: () => PinchGesture, value?: PinchGestureHandlerOptions): PinchGesture - - /** - * Pinch gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionStart(event: Callback): this; - - /** - * Callback when the Pinch gesture is moving. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionUpdate(event: Callback): this; - - /** - * The Pinch gesture is successfully recognized. When the finger is lifted, the callback is triggered. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionEnd(event: Callback): this; - - /** - * The Pinch gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionCancel(event: Callback): this; -} -/*** endif */ - /** * Defines the RotationGesture interface. * @@ -3663,81 +3177,6 @@ interface RotationGestureInterface extends GestureInterface): RotationGestureInterface; } -/*** if arkts 1.2 */ -/** - * Defines RotationGesture. - * - * @extends Gesture - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class RotationGesture extends Gesture { - /** - * Set the value. - * - * @param { function } factory - * @param { RotationGestureHandlerOptions } value - * @returns { RotationGesture } - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - static $_instantiate(factory: () => RotationGesture, value?: RotationGestureHandlerOptions): RotationGesture - - /** - * Rotation gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionStart(event: Callback): this; - - /** - * Callback when the Rotation gesture is moving. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionUpdate(event: Callback): this; - - /** - * The Rotation gesture is successfully recognized. When the finger is lifted, the callback is triggered. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionEnd(event: Callback): this; - - /** - * The Rotation gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionCancel(event: Callback): this; -} -/*** endif */ - /** * Defines the GestureGroup interface. * @@ -3825,45 +3264,6 @@ interface GestureGroupInterface { onCancel(event: () => void): GestureGroupInterface; } -/*** if arkts 1.2 */ -/** - * Defines the GestureGroup. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class GestureGroup { - /** - * Return to Obtain GestureGroup. - * - * @param { function } factory - * @param { GestureMode } mode - * @param { GestureType[] } gesture - * @returns { GestureGroup } - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - static $_instantiate(factory: () => GestureGroup, mode: GestureMode, ...gesture: GestureType[]): GestureGroup; - - /** - * The Gesture group is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { GestureGroup } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onCancel(event: Callback): GestureGroup; -} -/*** endif */ - /** * Defines TapGesture Component. * @@ -4060,42 +3460,6 @@ declare class GestureHandler implements GestureInterface { allowedTypes(types: Array): T; } -/*** if arkts 1.2 */ -/** - * Defines the gesture handler. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class GestureHandler { - /** - * Set the GestureHandler's tag. - * - * @param { string } tag - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - tag(tag: string): this; - - /** - * Input source type for gesture response. - * - * @param { Array } types - indicate the allowed input source for gesture to response - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - allowedTypes(types: Array): this; -} -/*** endif */ - /** * Defines the TapGestureHandler options. * @@ -4113,8 +3477,7 @@ export declare class GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ interface TapGestureHandlerOptions extends BaseHandlerOptions { /** @@ -4125,8 +3488,7 @@ interface TapGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ count?: number; /** @@ -4137,8 +3499,7 @@ interface TapGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fingers?: number; } @@ -4176,41 +3537,6 @@ declare class TapGestureHandler extends GestureHandler { onAction(event: Callback): TapGestureHandler; } -/*** if arkts 1.2 */ -/** - * Defines the TapGesture handler. - * - * @extends GestureHandler - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class TapGestureHandler extends GestureHandler { - /** - * Constructor parameters. - * - * @param { TapGestureHandlerOptions } options - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - constructor(options?: TapGestureHandlerOptions); - /** - * Tap gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onAction(event: Callback): this; -} -/*** endif */ - /** * Defines the LongPressGestureHandler options. * @@ -4228,8 +3554,7 @@ export declare class TapGestureHandler extends GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ interface LongPressGestureHandlerOptions extends BaseHandlerOptions { /** @@ -4240,8 +3565,7 @@ interface LongPressGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fingers?: number; /** @@ -4252,8 +3576,7 @@ interface LongPressGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ repeat?: boolean; /** @@ -4264,8 +3587,7 @@ interface LongPressGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ duration?: number; } @@ -4337,63 +3659,6 @@ declare class LongPressGestureHandler extends GestureHandler): LongPressGestureHandler; } -/*** if arkts 1.2 */ -/** - * Defines the LongPressGesture handler. - * - * @extends GestureHandler - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class LongPressGestureHandler extends GestureHandler { - /** - * Constructor parameters. - * - * @param { LongPressGestureHandlerOptions } options - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - constructor(options?: LongPressGestureHandlerOptions); - /** - * LongPress gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onAction(event: Callback): this; - /** - * The LongPress gesture is successfully recognized. When the finger is lifted, the callback is triggered. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionEnd(event: Callback): this; - /** - * The LongPress gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionCancel(event: Callback): this; -} -/*** endif */ - /** * Defines the PanGestureHandler options. * @@ -4411,8 +3676,7 @@ export declare class LongPressGestureHandler extends GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ interface PanGestureHandlerOptions extends BaseHandlerOptions { /** @@ -4423,8 +3687,7 @@ interface PanGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fingers?: number; /** @@ -4435,8 +3698,7 @@ interface PanGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ direction?: PanDirection; /** @@ -4447,8 +3709,7 @@ interface PanGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ distance?: number; /** @@ -4466,92 +3727,13 @@ interface PanGestureHandlerOptions extends BaseHandlerOptions { /** * Defines the PanGesture handler. * - * @extends GestureHandler - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ -declare class PanGestureHandler extends GestureHandler { - /** - * Constructor parameters. - * - * @param { PanGestureHandlerOptions } options - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - constructor(options?: PanGestureHandlerOptions); - /** - * Pan gesture recognition success callback. - * - * @param { Callback } event - * @returns { PanGestureHandler } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - onActionStart(event: Callback): PanGestureHandler; - /** - * Callback when the Pan gesture is moving. - * - * @param { Callback } event - * @returns { PanGestureHandler } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - onActionUpdate(event: Callback): PanGestureHandler; - /** - * The Pan gesture is successfully recognized. When the finger is lifted, the callback is triggered. - * - * @param { Callback } event - * @returns { PanGestureHandler } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - onActionEnd(event: Callback): PanGestureHandler; - /** - * The Pan gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { PanGestureHandler } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - onActionCancel(event: Callback): PanGestureHandler; - /** - * The Pan gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * Add GestureEvent in cancel callback. - * - * @param { Callback } event - * @returns { PanGestureHandler } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - onActionCancel(event: Callback): PanGestureHandler; -} - -/*** if arkts 1.2 */ -/** - * Defines the PanGesture handler. - * - * @extends GestureHandler + * @extends GestureHandler * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 20 + * @since 12 */ -export declare class PanGestureHandler extends GestureHandler { +declare class PanGestureHandler extends GestureHandler { /** * Constructor parameters. * @@ -4559,55 +3741,66 @@ export declare class PanGestureHandler extends GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 20 + * @since 12 */ constructor(options?: PanGestureHandlerOptions); /** * Pan gesture recognition success callback. * * @param { Callback } event - * @returns { this } + * @returns { PanGestureHandler } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 20 + * @since 12 */ - onActionStart(event: Callback): this; + onActionStart(event: Callback): PanGestureHandler; /** * Callback when the Pan gesture is moving. * * @param { Callback } event - * @returns { this } + * @returns { PanGestureHandler } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 20 + * @since 12 */ - onActionUpdate(event: Callback): this; + onActionUpdate(event: Callback): PanGestureHandler; /** * The Pan gesture is successfully recognized. When the finger is lifted, the callback is triggered. * * @param { Callback } event - * @returns { this } + * @returns { PanGestureHandler } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 20 + * @since 12 + */ + onActionEnd(event: Callback): PanGestureHandler; + /** + * The Pan gesture is successfully recognized and a callback is triggered when the touch cancel event is received. + * + * @param { Callback } event + * @returns { PanGestureHandler } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 */ - onActionEnd(event: Callback): this; + onActionCancel(event: Callback): PanGestureHandler; /** * The Pan gesture is successfully recognized and a callback is triggered when the touch cancel event is received. + * Add GestureEvent in cancel callback. * * @param { Callback } event - * @returns { this } + * @returns { PanGestureHandler } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 20 + * @since 18 */ - onActionCancel(event: Callback): this; + onActionCancel(event: Callback): PanGestureHandler; } -/*** endif */ /** * Defines the SwipeGestureHandler options. @@ -4626,8 +3819,7 @@ export declare class PanGestureHandler extends GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ interface SwipeGestureHandlerOptions extends BaseHandlerOptions { /** @@ -4638,8 +3830,7 @@ interface SwipeGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fingers?: number; /** @@ -4650,8 +3841,7 @@ interface SwipeGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ direction?: SwipeDirection; /** @@ -4662,8 +3852,7 @@ interface SwipeGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ speed?: number; } @@ -4701,41 +3890,6 @@ declare class SwipeGestureHandler extends GestureHandler { onAction(event: Callback): SwipeGestureHandler; } -/*** if arkts 1.2 */ -/** - * Defines the SwipeGesture handler. - * - * @extends GestureHandler - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class SwipeGestureHandler extends GestureHandler { - /** - * Constructor parameters. - * - * @param { SwipeGestureHandlerOptions } options - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - constructor(options?: SwipeGestureHandlerOptions); - /** - * Swipe gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onAction(event: Callback): this; -} -/*** endif */ - /** * Defines the PinchGestureHandler options. * @@ -4753,8 +3907,7 @@ export declare class SwipeGestureHandler extends GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ interface PinchGestureHandlerOptions extends BaseHandlerOptions { /** @@ -4765,8 +3918,7 @@ interface PinchGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fingers?: number; /** @@ -4777,8 +3929,7 @@ interface PinchGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ distance?: number; } @@ -4861,74 +4012,6 @@ declare class PinchGestureHandler extends GestureHandler { onActionCancel(event: Callback): PinchGestureHandler; } -/*** if arkts 1.2 */ -/** - * Defines the PinchGesture handler. - * - * @extends GestureHandler - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class PinchGestureHandler extends GestureHandler { - /** - * Constructor parameters. - * - * @param { PinchGestureHandlerOptions } options - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - constructor(options?: PinchGestureHandlerOptions); - /** - * Pinch gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionStart(event: Callback): this; - /** - * Callback when the Pinch gesture is moving. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionUpdate(event: Callback): this; - /** - * The Pinch gesture is successfully recognized. When the finger is lifted, the callback is triggered. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionEnd(event: Callback): this; - /** - * The Pinch gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionCancel(event: Callback): this; -} -/*** endif */ - /** * Defines the RotationGestureHandler options. * @@ -4946,8 +4029,7 @@ export declare class PinchGestureHandler extends GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ interface RotationGestureHandlerOptions extends BaseHandlerOptions { /** @@ -4958,8 +4040,7 @@ interface RotationGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fingers?: number; /** @@ -4970,8 +4051,7 @@ interface RotationGestureHandlerOptions extends BaseHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ angle?: number; } @@ -5054,74 +4134,6 @@ declare class RotationGestureHandler extends GestureHandler): RotationGestureHandler; } -/*** if arkts 1.2 */ -/** - * Defines the RotationGesture handler. - * - * @extends GestureHandler - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class RotationGestureHandler extends GestureHandler { - /** - * Constructor parameters. - * - * @param { RotationGestureHandlerOptions } options - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - constructor(options?: RotationGestureHandlerOptions); - /** - * Rotation gesture recognition success callback. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionStart(event: Callback): this; - /** - * Callback when the Rotation gesture is moving. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionUpdate(event: Callback): this; - /** - * The Rotation gesture is successfully recognized. When the finger is lifted, the callback is triggered. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionEnd(event: Callback): this; - /** - * The Rotation gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onActionCancel(event: Callback): this; -} -/*** endif */ - /** * Defines the GestureGroupGestureHandler options. * @@ -5129,8 +4141,7 @@ export declare class RotationGestureHandler extends GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface GestureGroupGestureHandlerOptions { /** @@ -5140,8 +4151,7 @@ interface GestureGroupGestureHandlerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ mode: GestureMode; /** @@ -5154,17 +4164,6 @@ interface GestureGroupGestureHandlerOptions { * @since 12 */ gestures: GestureHandler[]; - /** - * Indicates the gestures included in the gesture group. - * - * @type { GestureHandler[] } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - gestures: GestureHandler[]; } /** @@ -5200,41 +4199,6 @@ declare class GestureGroupHandler extends GestureHandler { onCancel(event: Callback): GestureGroupHandler; } -/*** if arkts 1.2 */ -/** - * Defines the GestureGroup handler. - * - * @extends GestureHandler - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ -export declare class GestureGroupHandler extends GestureHandler { - /** - * Constructor parameters. - * - * @param { GestureGroupGestureHandlerOptions } options - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - constructor(options?: GestureGroupGestureHandlerOptions); - /** - * The GestureGroup gesture is successfully recognized and a callback is triggered when the touch cancel event is received. - * - * @param { Callback } event - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - onCancel(event: Callback): this; -} -/*** endif */ - /** * Creating an Object * @@ -5242,8 +4206,7 @@ export declare class GestureGroupHandler extends GestureHandler { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum GesturePriority { /** @@ -5252,8 +4215,7 @@ declare enum GesturePriority { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NORMAL = 0, /** @@ -5262,8 +4224,7 @@ declare enum GesturePriority { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PRIORITY = 1, } @@ -5275,8 +4236,7 @@ declare enum GesturePriority { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum GestureRecognizerState { /** @@ -5285,8 +4245,7 @@ declare enum GestureRecognizerState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ READY = 0, /** @@ -5295,8 +4254,7 @@ declare enum GestureRecognizerState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DETECTING = 1, /** @@ -5305,8 +4263,7 @@ declare enum GestureRecognizerState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PENDING = 2, /** @@ -5315,8 +4272,7 @@ declare enum GestureRecognizerState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BLOCKED = 3, /** @@ -5325,8 +4281,7 @@ declare enum GestureRecognizerState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SUCCESSFUL = 4, /** @@ -5335,8 +4290,7 @@ declare enum GestureRecognizerState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FAILED = 5, } @@ -5348,8 +4302,7 @@ declare enum GestureRecognizerState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class ScrollableTargetInfo extends EventTargetInfo { /** @@ -5359,8 +4312,7 @@ declare class ScrollableTargetInfo extends EventTargetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isBegin(): boolean; /** @@ -5370,8 +4322,7 @@ declare class ScrollableTargetInfo extends EventTargetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isEnd(): boolean; } @@ -5382,8 +4333,7 @@ declare class ScrollableTargetInfo extends EventTargetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class EventTargetInfo { /** @@ -5393,8 +4343,7 @@ declare class EventTargetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getId(): string; } @@ -5435,8 +4384,7 @@ declare class TouchRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class GestureRecognizer { /** @@ -5446,8 +4394,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getTag(): string; /** @@ -5457,8 +4404,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getType(): GestureControl.GestureType; /** @@ -5468,8 +4414,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isBuiltIn(): boolean; /** @@ -5479,8 +4424,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setEnabled(isEnabled: boolean): void; /** @@ -5490,8 +4434,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isEnabled(): boolean; /** @@ -5501,8 +4444,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getState(): GestureRecognizerState; /** @@ -5512,8 +4454,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getEventTargetInfo(): EventTargetInfo; /** @@ -5522,8 +4463,7 @@ declare class GestureRecognizer { * @returns { boolean } - true is valid, false is invalid * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isValid(): boolean; /** @@ -5533,8 +4473,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getFingerCount(): number; /** @@ -5544,8 +4483,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ isFingerCountLimit(): boolean; /** @@ -5572,8 +4510,7 @@ declare class GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare class TapRecognizer extends GestureRecognizer { /** @@ -5583,8 +4520,7 @@ declare class TapRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getTapCount(): number; } @@ -5596,8 +4532,7 @@ declare class TapRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare class LongPressRecognizer extends GestureRecognizer { /** @@ -5607,8 +4542,7 @@ declare class LongPressRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ isRepeat(): boolean; /** @@ -5619,8 +4553,7 @@ declare class LongPressRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getDuration(): number; } @@ -5632,8 +4565,7 @@ declare class LongPressRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare class SwipeRecognizer extends GestureRecognizer { /** @@ -5644,8 +4576,7 @@ declare class SwipeRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getVelocityThreshold(): number; /** @@ -5655,8 +4586,7 @@ declare class SwipeRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getDirection(): SwipeDirection; } @@ -5668,8 +4598,7 @@ declare class SwipeRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare class PinchRecognizer extends GestureRecognizer { /** @@ -5680,8 +4609,7 @@ declare class PinchRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getDistance(): number; } @@ -5693,8 +4621,7 @@ declare class PinchRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare class RotationRecognizer extends GestureRecognizer { /** @@ -5704,8 +4631,7 @@ declare class RotationRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getAngle(): number; } @@ -5717,8 +4643,7 @@ declare class RotationRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class PanRecognizer extends GestureRecognizer { /** @@ -5728,8 +4653,7 @@ declare class PanRecognizer extends GestureRecognizer { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getPanGestureOptions(): PanGestureOptions; /** diff --git a/api/@internal/component/ets/grid.d.ts b/api/@internal/component/ets/grid.d.ts index 32de925e32d970cceb7e497455fcbcb914ae4b4c..0464889341d3d118dd79440b127290887d38e6be 100644 --- a/api/@internal/component/ets/grid.d.ts +++ b/api/@internal/component/ets/grid.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { EdgeEffectOptions, NestedScrollOptions, ItemDragInfo, ScrollableCommonMethod, Optional, CommonMethod, OnWillScrollCallback, OnScrollCallback, OnItemDragStartCallback } from './common'; -import { Length, Resource } from './units'; -import { Scroller, OnScrollFrameBeginCallback } from './scroll'; -import { ScrollState } from './list'; -import { BarState, Color, EdgeEffect } from './enums'; -/*** endif */ /** * The options to help grid layout @@ -41,8 +34,7 @@ import { BarState, Color, EdgeEffect } from './enums'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface GridLayoutOptions { /** @@ -60,8 +52,7 @@ declare interface GridLayoutOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ regularSize: [number, number]; @@ -82,8 +73,7 @@ declare interface GridLayoutOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ irregularIndexes?: number[]; @@ -104,8 +94,7 @@ declare interface GridLayoutOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onGetIrregularSizeByIndex?: (index: number) => [number, number] @@ -126,8 +115,7 @@ declare interface GridLayoutOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onGetRectByIndex?: (index: number) => [number, number, number, number] } @@ -154,8 +142,7 @@ declare interface GridLayoutOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface GridInterface { /** @@ -185,8 +172,7 @@ interface GridInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (scroller?: Scroller, layoutOptions?: GridLayoutOptions): GridAttribute; } @@ -213,8 +199,7 @@ interface GridInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum GridDirection { /** @@ -236,8 +221,7 @@ declare enum GridDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Row, @@ -260,8 +244,7 @@ declare enum GridDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Column, @@ -284,8 +267,7 @@ declare enum GridDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ RowReverse, @@ -308,8 +290,7 @@ declare enum GridDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ColumnReverse, } @@ -321,8 +302,7 @@ declare enum GridDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum GridItemAlignment { @@ -332,8 +312,7 @@ declare enum GridItemAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DEFAULT = 0, @@ -344,8 +323,7 @@ declare enum GridItemAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ STRETCH = 1, } @@ -365,8 +343,7 @@ declare enum GridItemAlignment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ComputedBarAttribute { /** @@ -384,8 +361,7 @@ declare interface ComputedBarAttribute { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ totalOffset: number; @@ -404,8 +380,7 @@ declare interface ComputedBarAttribute { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ totalLength: number; } @@ -491,8 +466,7 @@ declare type OnGridScrollIndexCallback = (first: number, last: number) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class GridAttribute extends ScrollableCommonMethod { /** @@ -520,8 +494,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ columnsTemplate(value: string): GridAttribute; @@ -550,8 +523,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rowsTemplate(value: string): GridAttribute; @@ -580,8 +552,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ columnsGap(value: Length): GridAttribute; @@ -610,8 +581,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rowsGap(value: Length): GridAttribute; @@ -723,8 +693,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onScrollBarUpdate(event: (index: number, offset: number) => ComputedBarAttribute): GridAttribute; @@ -758,8 +727,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onScrollIndex(event: (first: number, last: number) => void): GridAttribute; @@ -788,8 +756,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ cachedCount(value: number): GridAttribute; @@ -801,8 +768,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ cachedCount(count: number, show: boolean): GridAttribute; @@ -831,8 +797,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ editMode(value: boolean): GridAttribute; @@ -861,8 +826,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ multiSelectable(value: boolean): GridAttribute; @@ -891,8 +855,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maxCount(value: number): GridAttribute; @@ -921,8 +884,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ minCount(value: number): GridAttribute; @@ -951,8 +913,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ cellLength(value: number): GridAttribute; @@ -981,8 +942,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ layoutDirection(value: GridDirection): GridAttribute; @@ -1011,8 +971,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ supportAnimation(value: boolean): GridAttribute; @@ -1048,19 +1007,6 @@ declare class GridAttribute extends ScrollableCommonMethod { */ onItemDragStart(event: (event: ItemDragInfo, itemIndex: number) => (() => any) | void): GridAttribute; - /** - * After a listener is bound, the component can be dragged. After the drag occurs, a callback is triggered. - * (To be triggered, press and hold for 170 milliseconds (ms)) - * - * @param { OnItemDragStartCallback } event - * @returns { GridAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onItemDragStart(event: OnItemDragStartCallback): GridAttribute; - /** * After binding, a callback is triggered when the component is dragged to the range of the component. * @@ -1086,8 +1032,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemDragEnter(event: (event: ItemDragInfo) => void): GridAttribute; @@ -1116,8 +1061,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemDragMove(event: (event: ItemDragInfo, itemIndex: number, insertIndex: number) => void): GridAttribute; @@ -1146,8 +1090,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemDragLeave(event: (event: ItemDragInfo, itemIndex: number) => void): GridAttribute; @@ -1179,8 +1122,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemDrop( event: (event: ItemDragInfo, itemIndex: number, insertIndex: number, isSuccess: boolean) => void, @@ -1278,8 +1220,7 @@ declare class GridAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ alignItems(alignment: Optional): GridAttribute; @@ -1295,18 +1236,6 @@ declare class GridAttribute extends ScrollableCommonMethod { */ focusWrapMode(mode: Optional): GridAttribute; - /** - * Set whether to synchronously load child nodes within one frame. - * - * @param { boolean } enable - Whether to synchronously load child nodes within one frame - * @returns { GridAttribute } The attribute of the grid. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - syncLoad(enable: boolean): GridAttribute; - /** * Called When sliding the grid. * @@ -1449,34 +1378,8 @@ declare class GridAttribute extends ScrollableCommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ onScrollFrameBegin(event: OnScrollFrameBeginCallback): GridAttribute; - - /** - * Called when the scrollable will scroll. - * - * @param { Optional } handler - callback of scrollable. - * @returns { GridAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onWillScroll(handler: Optional): GridAttribute; - - /** - * Called when the scrollable did scroll. - * - * @param { OnScrollCallback } handler - callback of scrollable, - * scrollOffset is offset this frame did scroll, scrollState is current scroll state. - * @returns { GridAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onDidScroll(handler: OnScrollCallback): GridAttribute; } /** diff --git a/api/@internal/component/ets/gridItem.d.ts b/api/@internal/component/ets/gridItem.d.ts index bfb75483273e5d351dd0ad6c171063c4dbac34e1..bee0e059369c660e51330edbcbf93f42c7e1a94c 100644 --- a/api/@internal/component/ets/gridItem.d.ts +++ b/api/@internal/component/ets/gridItem.d.ts @@ -18,9 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod, Bindable } from './common' -/*** endif */ /** * Defines the grid item style. @@ -37,8 +34,7 @@ import { CommonMethod, Bindable } from './common' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum GridItemStyle { /** @@ -54,8 +50,7 @@ declare enum GridItemStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NONE = 0, @@ -72,8 +67,7 @@ declare enum GridItemStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PLAIN = 1, } @@ -93,8 +87,7 @@ declare enum GridItemStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface GridItemOptions { /** @@ -112,8 +105,7 @@ declare interface GridItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style?: GridItemStyle; } @@ -140,8 +132,7 @@ declare interface GridItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface GridItemInterface { /** @@ -167,8 +158,7 @@ interface GridItemInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value?: GridItemOptions): GridItemAttribute; } @@ -189,8 +179,7 @@ interface GridItemInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class GridItemAttribute extends CommonMethod { /** @@ -218,8 +207,7 @@ declare class GridItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rowStart(value: number): GridItemAttribute; @@ -248,8 +236,7 @@ declare class GridItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rowEnd(value: number): GridItemAttribute; @@ -278,8 +265,7 @@ declare class GridItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ columnStart(value: number): GridItemAttribute; @@ -308,8 +294,7 @@ declare class GridItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ columnEnd(value: number): GridItemAttribute; @@ -349,8 +334,7 @@ declare class GridItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectable(value: boolean): GridItemAttribute; @@ -377,20 +361,6 @@ declare class GridItemAttribute extends CommonMethod { */ selected(value: boolean): GridItemAttribute; - /** - * Called when judging whether it is selected. - * This parameter supports $$ for two-way binding of variables. - * - * @param { boolean | Bindable } value - * @returns { GridItemAttribute } the attribute of the gridItem. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected(value: boolean | Bindable): GridItemAttribute; - /** * Called when the gridItem is selected. * @@ -416,8 +386,7 @@ declare class GridItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onSelect(event: (isSelected: boolean) => void): GridItemAttribute; } diff --git a/api/@internal/component/ets/grid_col.d.ts b/api/@internal/component/ets/grid_col.d.ts index 5889c45d0dd67c30636031d705265532ac774f33..147401413a5d1d76e374d19dfaeaf91d95c34c91 100644 --- a/api/@internal/component/ets/grid_col.d.ts +++ b/api/@internal/component/ets/grid_col.d.ts @@ -18,10 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod } from './common'; -/*** endif */ - /** * Defines the option in number unit of grid-container child component. * @@ -47,8 +43,7 @@ import { CommonMethod } from './common'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface GridColColumnOption { /** @@ -76,8 +71,7 @@ declare interface GridColColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xs?: number, @@ -106,8 +100,7 @@ declare interface GridColColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ sm?: number, @@ -136,8 +129,7 @@ declare interface GridColColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ md?: number, @@ -166,8 +158,7 @@ declare interface GridColColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lg?: number, @@ -196,8 +187,7 @@ declare interface GridColColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xl?: number, @@ -226,8 +216,7 @@ declare interface GridColColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xxl?: number, } @@ -257,8 +246,7 @@ declare interface GridColColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface GridColOptions { /** @@ -286,8 +274,7 @@ declare interface GridColOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ span?: number | GridColColumnOption; @@ -316,8 +303,7 @@ declare interface GridColOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset?: number | GridColColumnOption; @@ -346,8 +332,7 @@ declare interface GridColOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ order?: number | GridColColumnOption; } @@ -377,8 +362,7 @@ declare interface GridColOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface GridColInterface { /** @@ -409,8 +393,7 @@ interface GridColInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (option?: GridColOptions): GridColAttribute; } @@ -440,8 +423,7 @@ interface GridColInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class GridColAttribute extends CommonMethod { /** @@ -472,8 +454,7 @@ declare class GridColAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ span(value: number | GridColColumnOption): GridColAttribute; @@ -505,8 +486,7 @@ declare class GridColAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ gridColOffset(value: number | GridColColumnOption): GridColAttribute; @@ -538,8 +518,7 @@ declare class GridColAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ order(value: number | GridColColumnOption): GridColAttribute; } diff --git a/api/@internal/component/ets/grid_row.d.ts b/api/@internal/component/ets/grid_row.d.ts index a5ea02dc1072a3a5f2bb8f488f3e56806f6e395b..beaa5ea7a4b6601bdcb8cbec1162a6161da24bed 100644 --- a/api/@internal/component/ets/grid_row.d.ts +++ b/api/@internal/component/ets/grid_row.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ItemAlign } from './enums'; -import { CommonMethod } from './common'; -import { Length } from './units'; -/*** endif */ - /** * Defines the option in length unit of grid-row component. * @@ -49,8 +43,7 @@ import { Length } from './units'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface GridRowSizeOption { /** @@ -78,8 +71,7 @@ declare interface GridRowSizeOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xs?: Length, @@ -108,8 +100,7 @@ declare interface GridRowSizeOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ sm?: Length, @@ -138,8 +129,7 @@ declare interface GridRowSizeOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ md?: Length, @@ -168,8 +158,7 @@ declare interface GridRowSizeOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lg?: Length, @@ -198,8 +187,7 @@ declare interface GridRowSizeOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xl?: Length, @@ -228,8 +216,7 @@ declare interface GridRowSizeOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xxl?: Length, } @@ -259,8 +246,7 @@ declare interface GridRowSizeOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface GridRowColumnOption { /** @@ -288,8 +274,7 @@ declare interface GridRowColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xs?: number, @@ -318,8 +303,7 @@ declare interface GridRowColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ sm?: number, @@ -348,8 +332,7 @@ declare interface GridRowColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ md?: number, @@ -378,8 +361,7 @@ declare interface GridRowColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lg?: number, @@ -408,8 +390,7 @@ declare interface GridRowColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xl?: number, @@ -438,8 +419,7 @@ declare interface GridRowColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xxl?: number, } @@ -469,8 +449,7 @@ declare interface GridRowColumnOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface GutterOption { /** @@ -498,8 +477,7 @@ declare interface GutterOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ x?: Length | GridRowSizeOption, @@ -528,8 +506,7 @@ declare interface GutterOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ y?: Length | GridRowSizeOption } @@ -559,8 +536,7 @@ declare interface GutterOption { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum BreakpointsReference { /** @@ -585,8 +561,7 @@ declare enum BreakpointsReference { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ WindowSize, @@ -612,8 +587,7 @@ declare enum BreakpointsReference { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ComponentSize, } @@ -643,8 +617,7 @@ declare enum BreakpointsReference { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum GridRowDirection { /** @@ -669,8 +642,7 @@ declare enum GridRowDirection { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Row, @@ -696,8 +668,7 @@ declare enum GridRowDirection { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ RowReverse, } @@ -727,8 +698,7 @@ declare enum GridRowDirection { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface BreakPoints { /** @@ -756,8 +726,7 @@ declare interface BreakPoints { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value?: Array, @@ -786,8 +755,7 @@ declare interface BreakPoints { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ reference?: BreakpointsReference, } @@ -817,8 +785,7 @@ declare interface BreakPoints { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface GridRowOptions { /** @@ -846,8 +813,7 @@ declare interface GridRowOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ gutter?: Length | GutterOption; @@ -876,8 +842,7 @@ declare interface GridRowOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ columns?: number | GridRowColumnOption; @@ -906,8 +871,7 @@ declare interface GridRowOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ breakpoints?: BreakPoints; @@ -936,8 +900,7 @@ declare interface GridRowOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ direction?: GridRowDirection; } @@ -967,8 +930,7 @@ declare interface GridRowOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface GridRowInterface { /** @@ -999,8 +961,7 @@ interface GridRowInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (option?: GridRowOptions): GridRowAttribute; } @@ -1030,8 +991,7 @@ interface GridRowInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class GridRowAttribute extends CommonMethod { /** @@ -1062,8 +1022,7 @@ declare class GridRowAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onBreakpointChange(callback: (breakpoints: string) => void): GridRowAttribute; @@ -1086,8 +1045,7 @@ declare class GridRowAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignItems(value: ItemAlign): GridRowAttribute; } diff --git a/api/@internal/component/ets/hyperlink.d.ts b/api/@internal/component/ets/hyperlink.d.ts index 19098e14e34b84d5f131d9cdf991a9a1e3f1d79d..416030a85662572826d024b0c73678b34261f1b3 100755 --- a/api/@internal/component/ets/hyperlink.d.ts +++ b/api/@internal/component/ets/hyperlink.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from './../../../api/global/resource' -import { CommonMethod } from './common' -import { Color } from './enums' -/*** endif */ - /** * Defines the hyperlink interface. * @@ -47,7 +41,6 @@ import { Color } from './enums' * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ interface HyperlinkInterface { /** @@ -85,7 +78,6 @@ interface HyperlinkInterface { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ (address: string | Resource, content?: string | Resource): HyperlinkAttribute; } @@ -113,7 +105,6 @@ interface HyperlinkInterface { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ declare class HyperlinkAttribute extends CommonMethod { /** @@ -142,7 +133,6 @@ declare class HyperlinkAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ color(value: Color | number | string | Resource): HyperlinkAttribute; } diff --git a/api/@internal/component/ets/image.d.ts b/api/@internal/component/ets/image.d.ts index 9a930bd96e3702f2fbb3a4c8f0a9749fa00260ca..3cb2eb41774ebdf233b90c78f5ad045c5b27c2ea 100644 --- a/api/@internal/component/ets/image.d.ts +++ b/api/@internal/component/ets/image.d.ts @@ -18,19 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import image from '../../@ohos.multimedia.image'; -import drawing from '../../@ohos.graphics.drawing'; -import matrix4 from '../../@ohos.matrix4' -import { BusinessError } from '../../@ohos.base'; -import { DrawableDescriptor } from '../../@ohos.arkui.drawableDescriptor'; -import { ImageAIOptions, ImageAnalyzerConfig } from './imageCommon'; -import { ResourceStr, ResourceColor, ColorFilter, EdgeWidths, ColorMetrics } from './units'; -import { ImageFit, ImageRepeat, CopyOptions } from './enums'; -import { Resource } from '../../global/resource'; -import { CommonMethod, PointLightStyle, PixelMap } from './common' -/*** endif */ - /** * Use the DrawableDescriptor class to get drawable image. * @@ -58,18 +45,6 @@ declare type DrawableDescriptor = import ('../api/@ohos.arkui.drawableDescriptor */ declare type DrawingColorFilter = import('../api/@ohos.graphics.drawing').default.ColorFilter; -/** - * Import the DrawingColorFilter type object for image color filter setting. - * - * @typedef { drawing.ColorFilter } DrawingColorFilter - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type DrawingColorFilter = drawing.ColorFilter; - /** * Enumerates all the levels available for the image resolution quality. * @@ -78,18 +53,7 @@ declare type DrawingColorFilter = drawing.ColorFilter; * @systemapi * @since 12 */ -declare type ResolutionQuality = import('../api/@ohos.multimedia.image').default.ResolutionQuality; - -/** - * Enumerates all the levels available for the image resolution quality. - * - * @typedef { image.ResolutionQuality } ResolutionQuality - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since 20 - * @arkts 1.2 - */ -declare type ResolutionQuality = image.ResolutionQuality; +declare type ResolutionQuality = import('../api/@ohos.multimedia.image').default.ResolutionQuality; /** * Lattice for dividing an image into grids. @@ -100,19 +64,7 @@ declare type ResolutionQuality = image.ResolutionQuality; * @atomicservice * @since 12 */ -declare type DrawingLattice = import('../api/@ohos.graphics.drawing').default.Lattice; - -/** - * Lattice for dividing an image into grids. - * - * @typedef { drawing.Lattice } DrawingLattice - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type DrawingLattice = drawing.Lattice; +declare type DrawingLattice = import('../api/@ohos.graphics.drawing').default.Lattice; /** * Object matrix used for setting image transformations. @@ -125,18 +77,6 @@ declare type DrawingLattice = drawing.Lattice; */ declare type ImageMatrix = import ('../api/@ohos.matrix4').default.Matrix4Transit; -/** - * Object matrix used for setting image transformations. - * - * @typedef { matrix4.Matrix4Transit } Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type ImageMatrix = matrix4.Matrix4Transit; - /** * Business error in onError callback. * @@ -173,8 +113,7 @@ declare type BusinessError = import('../api/@ohos.base').BusinessError; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ImageRenderMode { /** @@ -205,8 +144,7 @@ declare enum ImageRenderMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Original, @@ -238,8 +176,7 @@ declare enum ImageRenderMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Template, } @@ -252,8 +189,7 @@ declare enum ImageRenderMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum ImageContent { /** @@ -263,8 +199,7 @@ declare enum ImageContent { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ EMPTY = 0, } @@ -273,8 +208,7 @@ declare enum ImageContent { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum DynamicRangeMode { /** @@ -282,8 +216,7 @@ declare enum DynamicRangeMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ HIGH = 0, @@ -292,8 +225,7 @@ declare enum DynamicRangeMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CONSTRAINT = 1, @@ -302,8 +234,7 @@ declare enum DynamicRangeMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ STANDARD = 2, } @@ -332,8 +263,7 @@ declare enum DynamicRangeMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ImageInterpolation { /** @@ -364,8 +294,7 @@ declare enum ImageInterpolation { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ None, @@ -397,8 +326,7 @@ declare enum ImageInterpolation { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Low, @@ -430,8 +358,7 @@ declare enum ImageInterpolation { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Medium, @@ -463,8 +390,7 @@ declare enum ImageInterpolation { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ High, } @@ -474,8 +400,7 @@ declare enum ImageInterpolation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare enum ImageRotateOrientation { /** @@ -484,8 +409,7 @@ declare enum ImageRotateOrientation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ AUTO = 0, @@ -495,8 +419,7 @@ declare enum ImageRotateOrientation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ UP = 1, @@ -506,8 +429,7 @@ declare enum ImageRotateOrientation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ RIGHT = 2, @@ -517,8 +439,7 @@ declare enum ImageRotateOrientation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ DOWN = 3, @@ -528,8 +449,7 @@ declare enum ImageRotateOrientation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ LEFT = 4, @@ -540,7 +460,6 @@ declare enum ImageRotateOrientation { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ UP_MIRRORED = 5, @@ -551,7 +470,6 @@ declare enum ImageRotateOrientation { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ RIGHT_MIRRORED = 6, @@ -562,7 +480,6 @@ declare enum ImageRotateOrientation { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ DOWN_MIRRORED = 7, @@ -573,135 +490,10 @@ declare enum ImageRotateOrientation { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ LEFT_MIRRORED = 8, } -/** - * ImageCompleteEvent - * - * @interface ImageCompleteEvent - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -export interface ImageCompleteEvent { - /** - * The width of the image source. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - width: number; - /** - * The height of the image source. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - height: number; - /** - * The width of the component source. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - componentWidth: number; - /** - * The height of the component source. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - componentHeight: number; - /** - * The value of the status of the image being loaded successfully. - * If the returned status value is 0, the image data is successfully loaded. - * If the returned status value is 1, the image is successfully decoded. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - loadingStatus: number; - /** - * The width of the picture that is actually drawn. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - contentWidth: number; - /** - * The height of the picture that is actually drawn. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - contentHeight: number; - /** - * The actual draw is offset from the x-axis of the component itself. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - contentOffsetX: number; - /** - * The actual draw is offset from the y-axis of the component itself. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - contentOffsetY: number; -} - /** * @interface ImageInterface * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -726,8 +518,7 @@ export interface ImageCompleteEvent { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ImageInterface { /** @@ -779,8 +570,7 @@ interface ImageInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ (src: PixelMap | ResourceStr | DrawableDescriptor | ImageContent): ImageAttribute; @@ -792,8 +582,7 @@ interface ImageInterface { * @returns { ImageAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ (src: PixelMap | ResourceStr | DrawableDescriptor, imageAIOptions: ImageAIOptions): ImageAttribute; } @@ -806,8 +595,7 @@ interface ImageInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface ImageSourceSize { @@ -854,8 +642,7 @@ interface ImageSourceSize { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ width: number; @@ -902,8 +689,7 @@ interface ImageSourceSize { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ height: number; } @@ -914,8 +700,7 @@ interface ImageSourceSize { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare class ColorContent { /** @@ -927,8 +712,7 @@ declare class ColorContent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ static readonly ORIGIN: ColorContent; } @@ -957,8 +741,7 @@ declare class ColorContent { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ImageAttribute extends CommonMethod { /** @@ -1012,8 +795,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ alt(value: string | Resource | PixelMap): ImageAttribute; @@ -1057,8 +839,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ matchTextDirection(value: boolean): ImageAttribute; @@ -1102,8 +883,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fitOriginalSize(value: boolean): ImageAttribute; @@ -1189,7 +969,6 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ fillColor(color: ResourceColor | ColorContent | ColorMetrics): ImageAttribute; @@ -1229,8 +1008,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ objectFit(value: ImageFit): ImageAttribute; @@ -1242,8 +1020,7 @@ declare class ImageAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ imageMatrix(matrix: ImageMatrix): ImageAttribute; @@ -1288,8 +1065,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ objectRepeat(value: ImageRepeat): ImageAttribute; @@ -1335,8 +1111,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ autoResize(value: boolean): ImageAttribute; @@ -1382,8 +1157,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ renderMode(value: ImageRenderMode): ImageAttribute; @@ -1399,8 +1173,7 @@ declare class ImageAttribute extends CommonMethod { * dynamicRangeMode.Standard. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dynamicRangeMode(value: DynamicRangeMode): ImageAttribute; @@ -1456,8 +1229,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interpolation(value: ImageInterpolation): ImageAttribute; @@ -1520,8 +1292,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ sourceSize(value: ImageSourceSize): ImageAttribute; @@ -1568,8 +1339,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ syncLoad(value: boolean): ImageAttribute; @@ -1616,8 +1386,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ colorFilter(value: ColorFilter | DrawingColorFilter): ImageAttribute; @@ -1654,8 +1423,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ copyOption(value: CopyOptions): ImageAttribute; @@ -1690,8 +1458,7 @@ declare class ImageAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ draggable(value: boolean): ImageAttribute; @@ -1702,8 +1469,7 @@ declare class ImageAttribute extends CommonMethod { * @returns { ImageAttribute } The attribute of the image. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pointLight(value: PointLightStyle): ImageAttribute; @@ -1716,8 +1482,7 @@ declare class ImageAttribute extends CommonMethod { * @returns { ImageAttribute } The attribute of the image. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ edgeAntialiasing(value: number): ImageAttribute; @@ -2035,21 +1800,6 @@ declare class ImageAttribute extends CommonMethod { }) => void, ): ImageAttribute; - /** - * This callback is triggered when an image is successfully loaded. - * The size of the image source that is successfully loaded is returned, in pixels. - * - * @param { ImageOnCompleteCallback } callback - * @returns { ImageAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onComplete(callback: ImageOnCompleteCallback): ImageAttribute; - /** * This callback is triggered when an exception occurs during image loading. * The field of "message" carries the detailed information of failed image loading. @@ -2085,8 +1835,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onError(callback: ImageErrorCallback): ImageAttribute; @@ -2135,8 +1884,7 @@ declare class ImageAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onFinish(event: () => void): ImageAttribute; @@ -2170,8 +1918,7 @@ declare class ImageAttribute extends CommonMethod { * @returns { ImageAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableAnalyzer(enable: boolean): ImageAttribute; @@ -2182,8 +1929,7 @@ declare class ImageAttribute extends CommonMethod { * @returns { ImageAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ analyzerConfig(config: ImageAnalyzerConfig): ImageAttribute; @@ -2214,11 +1960,21 @@ declare class ImageAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ resizable(value: ResizableOptions): ImageAttribute; + /** + * Set the quality enhancement level of image. + * + * @param { ResolutionQuality } imageQuality + * @returns { ImageAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 12 + */ + enhancedImageQuality(imageQuality: ResolutionQuality): ImageAttribute; + /** * Sets whether to secure sensitive information on widgets. * @@ -2231,23 +1987,10 @@ declare class ImageAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ privacySensitive(supported: boolean): ImageAttribute; - /** - * Set the quality enhancement level of image. - * - * @param { ResolutionQuality } imageQuality - * @returns { ImageAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - enhancedImageQuality(imageQuality: ResolutionQuality): ImageAttribute; - /** * Sets the display orientation of the image content. * @@ -2257,8 +2000,7 @@ declare class ImageAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ orientation(orientation: ImageRotateOrientation) : ImageAttribute; } @@ -2357,25 +2099,10 @@ declare const ImageInstance: ImageAttribute; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ type ImageErrorCallback = (error: ImageError) => void; -/** - * ImageOnCompleteCallback - * - * @typedef { function } ImageOnCompleteCallback - * @param { ImageCompleteEvent } loadEvent - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -type ImageOnCompleteCallback = (loadEvent?: ImageCompleteEvent) => void; - /** * @interface ImageError * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -2395,8 +2122,7 @@ type ImageOnCompleteCallback = (loadEvent?: ImageCompleteEvent) => void; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ImageError { /** @@ -2424,8 +2150,7 @@ declare interface ImageError { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ componentWidth: number; @@ -2454,8 +2179,7 @@ declare interface ImageError { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ componentHeight: number; @@ -2476,8 +2200,7 @@ declare interface ImageError { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ message: string @@ -2490,7 +2213,6 @@ declare interface ImageError { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ error?: BusinessError; } @@ -2510,8 +2232,7 @@ declare interface ImageError { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ResizableOptions { /** @@ -2529,8 +2250,7 @@ declare interface ResizableOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ slice?: EdgeWidths; @@ -2541,8 +2261,7 @@ declare interface ResizableOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lattice?: DrawingLattice; } diff --git a/api/@internal/component/ets/image_animator.d.ts b/api/@internal/component/ets/image_animator.d.ts index 32f8826119dc8227a7be868565bc32aaf8f0d615..051bdb7211779551cb4f2d6ef13c08956c0ce858 100644 --- a/api/@internal/component/ets/image_animator.d.ts +++ b/api/@internal/component/ets/image_animator.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from "../../global/resource"; -import image from '../../@ohos.multimedia.image' -import { CommonMethod, PixelMap } from './common' -import { AnimationStatus,FillMode } from './enums' -/*** endif */ - /** * Defines the ImageAnimator Interface. * @@ -49,8 +42,7 @@ import { AnimationStatus,FillMode } from './enums' * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ImageAnimatorInterface { /** @@ -77,8 +69,7 @@ interface ImageAnimatorInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): ImageAnimatorAttribute; } @@ -107,8 +98,7 @@ interface ImageAnimatorInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ImageFrameInfo { /** @@ -152,8 +142,7 @@ interface ImageFrameInfo { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ src: string | Resource | PixelMap; /** @@ -180,8 +169,7 @@ interface ImageFrameInfo { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ width?: number | string; /** @@ -208,8 +196,7 @@ interface ImageFrameInfo { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ height?: number | string; /** @@ -236,8 +223,7 @@ interface ImageFrameInfo { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ top?: number | string; /** @@ -264,8 +250,7 @@ interface ImageFrameInfo { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ left?: number | string; /** @@ -290,8 +275,7 @@ interface ImageFrameInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ duration?: number; } @@ -320,8 +304,7 @@ interface ImageFrameInfo { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ImageAnimatorAttribute extends CommonMethod { /** @@ -355,8 +338,7 @@ declare class ImageAnimatorAttribute extends CommonMethod): ImageAnimatorAttribute; @@ -387,8 +369,7 @@ declare class ImageAnimatorAttribute extends CommonMethod void): ImageAnimatorAttribute; @@ -643,8 +616,7 @@ declare class ImageAnimatorAttribute extends CommonMethod void): ImageAnimatorAttribute; @@ -673,8 +645,7 @@ declare class ImageAnimatorAttribute extends CommonMethod void): ImageAnimatorAttribute; @@ -705,8 +676,7 @@ declare class ImageAnimatorAttribute extends CommonMethod void): ImageAnimatorAttribute; @@ -737,8 +707,7 @@ declare class ImageAnimatorAttribute extends CommonMethod void): ImageAnimatorAttribute; } diff --git a/api/@internal/component/ets/image_common.d.ts b/api/@internal/component/ets/image_common.d.ts index 7415991b1a970aabdba46f343a33f201a59f309c..24962e1329561a009cb806c3940915d4890ad86c 100644 --- a/api/@internal/component/ets/image_common.d.ts +++ b/api/@internal/component/ets/image_common.d.ts @@ -24,8 +24,7 @@ * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum ImageAnalyzerType { /** @@ -33,8 +32,7 @@ declare enum ImageAnalyzerType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SUBJECT = 0, @@ -43,8 +41,7 @@ declare enum ImageAnalyzerType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ TEXT, @@ -53,8 +50,7 @@ declare enum ImageAnalyzerType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ OBJECT_LOOKUP, } @@ -64,8 +60,7 @@ declare enum ImageAnalyzerType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class ImageAnalyzerController { /** @@ -73,19 +68,17 @@ declare class ImageAnalyzerController { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(); - + /** * Get image analyzer support types. * * @returns { ImageAnalyzerType[] } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getImageAnalyzerSupportTypes(): ImageAnalyzerType[]; } @@ -96,8 +89,7 @@ declare class ImageAnalyzerController { * @interface ImageAnalyzerConfig * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ImageAnalyzerConfig { /** @@ -106,8 +98,7 @@ declare interface ImageAnalyzerConfig { * @type { ImageAnalyzerType[] } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ types: ImageAnalyzerType[]; } @@ -118,8 +109,7 @@ declare interface ImageAnalyzerConfig { * @interface ImageAIOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ImageAIOptions { /** @@ -128,8 +118,7 @@ declare interface ImageAIOptions { * @type { ?ImageAnalyzerType[] } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ types?: ImageAnalyzerType[]; @@ -139,8 +128,7 @@ declare interface ImageAIOptions { * @type { ?ImageAnalyzerController } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ aiController?: ImageAnalyzerController; -} \ No newline at end of file +} diff --git a/api/@internal/component/ets/image_span.d.ts b/api/@internal/component/ets/image_span.d.ts index 5c5ec30316e1ae505ccd0d9d429b289666f6c77c..40109b352aff809c0bbcaec6101689cdf5ef2e42 100644 --- a/api/@internal/component/ets/image_span.d.ts +++ b/api/@internal/component/ets/image_span.d.ts @@ -18,15 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceStr, ColorFilter} from './units'; -import { BaseSpan } from './span'; -import { ImageSpanAlignment, ImageFit } from './enums'; -import { ImageErrorCallback, DrawingColorFilter } from './image'; -import { PixelMap } from './common'; -import image from '../../@ohos.multimedia.image'; -/*** endif */ - /** * Provide image decoration in the text component. * @@ -42,8 +33,7 @@ import image from '../../@ohos.multimedia.image'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ImageSpanInterface { /** @@ -63,8 +53,7 @@ interface ImageSpanInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value: ResourceStr | PixelMap): ImageSpanAttribute; } @@ -84,8 +73,7 @@ interface ImageSpanInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ImageSpanAttribute extends BaseSpan { /** @@ -105,8 +93,7 @@ declare class ImageSpanAttribute extends BaseSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ verticalAlign(value: ImageSpanAlignment): ImageSpanAttribute; @@ -118,8 +105,7 @@ declare class ImageSpanAttribute extends BaseSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ colorFilter(filter: ColorFilter | DrawingColorFilter): ImageSpanAttribute; @@ -140,8 +126,7 @@ declare class ImageSpanAttribute extends BaseSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ objectFit(value: ImageFit): ImageSpanAttribute; @@ -154,8 +139,7 @@ declare class ImageSpanAttribute extends BaseSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onComplete(callback: ImageCompleteCallback): ImageSpanAttribute; @@ -168,8 +152,7 @@ declare class ImageSpanAttribute extends BaseSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onError(callback: ImageErrorCallback): ImageSpanAttribute; @@ -180,8 +163,7 @@ declare class ImageSpanAttribute extends BaseSpan { * @returns { ImageSpanAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ alt(value: PixelMap): ImageSpanAttribute; } @@ -228,8 +210,7 @@ declare const ImageSpanInstance: ImageSpanAttribute; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type ImageCompleteCallback = (result: ImageLoadResult) => void; @@ -240,8 +221,7 @@ type ImageCompleteCallback = (result: ImageLoadResult) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ImageLoadResult { /** @@ -251,8 +231,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width: number; /** @@ -262,8 +241,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height: number; /** @@ -273,8 +251,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ componentWidth: number; /** @@ -284,8 +261,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ componentHeight: number; /** @@ -297,8 +273,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ loadingStatus: number; /** @@ -308,8 +283,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentWidth: number; /** @@ -319,8 +293,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentHeight: number; /** @@ -330,8 +303,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentOffsetX: number; /** @@ -341,8 +313,7 @@ declare interface ImageLoadResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentOffsetY: number; } diff --git a/api/@internal/component/ets/index-full.d.ts b/api/@internal/component/ets/index-full.d.ts index ba50d08873b44a39d66bc756de705a2b5193d9f4..c7759460f30f6a5e9338b421c5796be38f59eec0 100644 --- a/api/@internal/component/ets/index-full.d.ts +++ b/api/@internal/component/ets/index-full.d.ts @@ -64,7 +64,6 @@ /// /// /// -/// /// /// /// @@ -150,5 +149,4 @@ /// /// /// -/// -/// \ No newline at end of file +/// \ No newline at end of file diff --git a/api/@internal/component/ets/indicatorcomponent.d.ts b/api/@internal/component/ets/indicatorcomponent.d.ts index fea813bcc067cc81fec075831ffdb0b7a5f51430..c8bce3374b74a44c11962df144bce2434be37e66 100644 --- a/api/@internal/component/ets/indicatorcomponent.d.ts +++ b/api/@internal/component/ets/indicatorcomponent.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod, Callback } from './common'; -import { DotIndicator, DigitIndicator } from './swiper'; -/*** endif */ - /** * Provides methods for switching components. * @@ -30,8 +25,7 @@ import { DotIndicator, DigitIndicator } from './swiper'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare class IndicatorComponentController { /** @@ -41,8 +35,7 @@ declare class IndicatorComponentController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ constructor(); @@ -53,8 +46,7 @@ declare class IndicatorComponentController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ showNext():void; @@ -65,8 +57,7 @@ declare class IndicatorComponentController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ showPrevious():void; @@ -80,8 +71,7 @@ declare class IndicatorComponentController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ changeIndex(index: number, useAnimation?: boolean):void; } @@ -94,8 +84,8 @@ declare class IndicatorComponentController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 + * @noninterop */ interface IndicatorComponentInterface { @@ -108,8 +98,7 @@ interface IndicatorComponentInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ (controller?: IndicatorComponentController): IndicatorComponentAttribute; } @@ -122,8 +111,8 @@ interface IndicatorComponentInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 + * @noninterop */ declare class IndicatorComponentAttribute extends CommonMethod { /** @@ -135,8 +124,7 @@ declare class IndicatorComponentAttribute extends CommonMethod): IndicatorComponentAttribute; } @@ -219,6 +202,7 @@ declare class IndicatorComponentAttribute extends CommonMethod void): void; @@ -71,9 +69,8 @@ declare namespace Profiler { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'8','1.2':'20'} + * @since 8 * @test - * @arkts 1.1&1.2 */ function unregisterVsyncCallback(): void; } @@ -84,8 +81,7 @@ declare namespace Profiler { * @param { string } value * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'8','1.2':'20'} + * @since 8 * @test - * @arkts 1.1&1.2 */ declare function setAppBgColor(value: string): void; diff --git a/api/@internal/component/ets/isolated_component.d.ts b/api/@internal/component/ets/isolated_component.d.ts index b32ad143ddfeba0ed3f12a18c08b9e47d7ca1898..730bf5b0ea87688a2dc84bcba2970e5cfdebf17f 100644 --- a/api/@internal/component/ets/isolated_component.d.ts +++ b/api/@internal/component/ets/isolated_component.d.ts @@ -84,6 +84,7 @@ declare interface IsolatedOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi * @since 12 + * @noninterop */ declare type IsolatedComponentInterface = (options: IsolatedOptions) => IsolatedComponentAttribute; @@ -94,6 +95,7 @@ declare type IsolatedComponentInterface = (options: IsolatedOptions) => Isolated * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi * @since 12 + * @noninterop */ declare class IsolatedComponentAttribute extends CommonMethod { /** @@ -115,6 +117,7 @@ declare class IsolatedComponentAttribute extends CommonMethod extends CommonMethod { /** @@ -67,8 +60,7 @@ declare class LazyGridLayoutAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ rowsGap(value: LengthMetrics): T; @@ -80,8 +72,7 @@ declare class LazyGridLayoutAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ columnsGap(value: LengthMetrics): T; } @@ -93,8 +84,7 @@ declare class LazyGridLayoutAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare class LazyVGridLayoutAttribute extends LazyGridLayoutAttribute { /** @@ -105,8 +95,7 @@ declare class LazyVGridLayoutAttribute extends LazyGridLayoutAttribute { /** @@ -395,20 +375,6 @@ declare class LineAttribute extends CommonShapeMethod { */ startPoint(value: Array): LineAttribute; - /** - * Coordinate of the start point of the line (relative coordinate). - * - * @param { ShapePoint } value - * @returns { LineAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - startPoint(value: ShapePoint): LineAttribute; - /** * Line end coordinates (relative coordinates). * @@ -448,20 +414,6 @@ declare class LineAttribute extends CommonShapeMethod { * @since 11 */ endPoint(value: Array): LineAttribute; - - /** - * Line end coordinates (relative coordinates). - * - * @param { ShapePoint } value - * @returns { LineAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - endPoint(value: ShapePoint): LineAttribute; } /** @@ -527,30 +479,3 @@ declare const Line: LineInterface; * @since 11 */ declare const LineInstance: LineAttribute; - -/** - * Line drawing component. - * - * @interface LineInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface LineInterface { - /** - * The return value of the parameter is Line. - * - * @param { LineOptions } [options] - Line options - * @returns { LineAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (options?: LineOptions): LineAttribute; -} diff --git a/api/@internal/component/ets/linearindicator.d.ts b/api/@internal/component/ets/linearindicator.d.ts deleted file mode 100644 index 3b548b466ad7aebae21832188fbfcc8f5b5b2360..0000000000000000000000000000000000000000 --- a/api/@internal/component/ets/linearindicator.d.ts +++ /dev/null @@ -1,325 +0,0 @@ -/* - * Copyright (c) 2024 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit ArkUI - */ - -/*** if arkts 1.2 */ -import { CommonMethod, Optional } from './common'; -import { ColorMetrics, LengthMetrics } from './units'; -/*** endif */ - -/** - * Defines the LinearIndicator Controller. - * - * @interface LinearIndicatorController - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ -declare class LinearIndicatorController { - /** - * constructor. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - constructor(); - - /** - * Sets the progress of indicator. - * - * @param { number } index - the index of current indicator, value range: [0, count - 1]. - * If index value is out of range, do nothing. - * @param { number } progress - current indicator progress value, value range: [0, 100]. - * If the progress value is out of range, do nothing. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - setProgress(index: number, progress: number): void; - - /** - * Start indicator auto play. - * - * @param { LinearIndicatorStartOptions } [options] - the options of indicator auto play. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - start(options?: LinearIndicatorStartOptions): void; - - /** - * Pause indicator auto play. - * Start auto play will be resumed from this paused position. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - pause(): void; - - /** - * Stop indicator auto play. - * Start auto play will restart from the very beginning. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - stop(): void; -} - -/** - * Provides options of indicator auto play. - * - * @interface LinearIndicatorAutoPlayOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ -declare interface LinearIndicatorStartOptions { - /** - * The interval between twice auto play. The unit is ms. - * - * @type { ?number } - * @default The default value is 0. if value is less than 0, the value will be 0. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - interval?: number; - - /** - * The animation curve duration. The unit is ms. - * - * @type { ?number } - * @default 4000 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - duration?: number; -} - -/** - * Provides linear indicator style. - * - * @interface LinearIndicatorStyle - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ -declare interface LinearIndicatorStyle { - /** - * The space of two linear indicator. - * - * @type { ?LengthMetrics } - * @default The default value is 4.0vp. if value is less than 0, the value will be 4.0vp. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - space?: LengthMetrics; - - /** - * Stroke width of the progress indicator. - * - * @type { ?LengthMetrics } - * @default The default value is 2.0vp. if value is less than 0, the value will be 2.0vp. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - strokeWidth?: LengthMetrics; - - /** - * The stroke radius of linear indicator. - * - * @type { ?LengthMetrics } - * @default The default value is 1.0vp. if value is more than strokeWidth/2, the value will be strokeWidth/2. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - strokeRadius?: LengthMetrics; - - /** - * The track background color of linear indicator. - * - * @type { ?ColorMetrics } - * @default comp_background_tertiary - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - trackBackgroundColor?: ColorMetrics; - - /** - * The track color of linear indicator. - * - * @type { ?ColorMetrics } - * @default comp_background_emphasize - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - trackColor?: ColorMetrics; -} - -/** - * Provides an interface for indicator. - * - * @interface LinearIndicatorInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ -interface LinearIndicatorInterface { - /** - * Constructor parameters - * - * @param { number } count - the number of progress in LinearIndicator. minimum value is 2(default is 5). - * if count is less than 2, the value will be 2. - * @param { LinearIndicatorController } controller - Controller of LinearIndicator. - * @returns { LinearIndicatorAttribute } return the instance of the LinearIndicatorAttribute - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - (count?: number, controller?: LinearIndicatorController): LinearIndicatorAttribute; -} - -/** - * Defines the Indicator attribute functions. - * - * @extends CommonMethod - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ -declare class LinearIndicatorAttribute extends CommonMethod { - /** - * Sets the indicator style. - * - * @param { Optional } style - the style of LinearIndicator - * @returns { LinearIndicatorAttribute } return the instance of the LinearIndicatorAttribute - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - indicatorStyle(style: Optional): LinearIndicatorAttribute; - - /** - * Sets whether indicator supports loop, default is true. - * - * @param { Optional } loop - indicate whether loop playback is supported - * @returns { LinearIndicatorAttribute } return the instance of the LinearIndicatorAttribute - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - indicatorLoop(loop: Optional): LinearIndicatorAttribute; - - /** - * Called when progress value update. - * - * @param { Optional } callback - callback of the progress change event. - * @returns { LinearIndicatorAttribute } return the instance of the LinearIndicatorAttribute - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - onChange(callback: Optional): LinearIndicatorAttribute; -} - -/** - * Defines the callback type used in the indicator progress change event. - * - * @typedef { function } OnLinearIndicatorChangeCallback - * @param { number } index - index of current indicator. - * @param { number } progress - current indicator progress value. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ -declare type OnLinearIndicatorChangeCallback = (index: number, progress: number) => void; - -/** - * Defines Indicator Component. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ -declare const LinearIndicator: LinearIndicatorInterface; - -/** - * Defines Indicator Component instance. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ -declare const LinearIndicatorInstance: LinearIndicatorAttribute diff --git a/api/@internal/component/ets/list.d.ts b/api/@internal/component/ets/list.d.ts index caf96d1ff6ff1ab7f88cd867e4e461f26d4e27c3..0e43b0660746498d27a71a9f577223cf464fd616 100644 --- a/api/@internal/component/ets/list.d.ts +++ b/api/@internal/component/ets/list.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ChildrenMainSize, ItemDragInfo, RectResult, ScrollableCommonMethod, Optional, - OnWillScrollCallback, OnScrollCallback, OnItemDragStartCallback } from './common'; -import { Axis } from './enums'; -import { OnScrollFrameBeginCallback, ScrollAlign, Scroller } from './scroll'; -import { Dimension, Length, LengthConstrain, ResourceColor } from './units'; -/*** endif */ /** * Declare scroll status @@ -58,8 +51,7 @@ import { Dimension, Length, LengthConstrain, ResourceColor } from './units'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ScrollState { /** @@ -91,8 +83,7 @@ declare enum ScrollState { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Idle, @@ -125,8 +116,7 @@ declare enum ScrollState { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Scroll, @@ -158,8 +148,7 @@ declare enum ScrollState { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Fling, } @@ -189,8 +178,7 @@ declare enum ScrollState { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ListItemAlign { /** @@ -215,8 +203,7 @@ declare enum ListItemAlign { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Start, @@ -242,8 +229,7 @@ declare enum ListItemAlign { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Center, @@ -269,8 +255,7 @@ declare enum ListItemAlign { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ End, } @@ -282,8 +267,7 @@ declare enum ListItemAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum ListItemGroupArea { /** @@ -292,8 +276,7 @@ declare enum ListItemGroupArea { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NONE = 0, @@ -303,8 +286,7 @@ declare enum ListItemGroupArea { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ IN_LIST_ITEM_AREA = 1, @@ -314,8 +296,7 @@ declare enum ListItemGroupArea { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ IN_HEADER_AREA = 2, @@ -325,8 +306,7 @@ declare enum ListItemGroupArea { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ IN_FOOTER_AREA = 3, } @@ -356,8 +336,7 @@ declare enum ListItemGroupArea { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum StickyStyle { /** @@ -383,8 +362,7 @@ declare enum StickyStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ None = 0, @@ -411,8 +389,7 @@ declare enum StickyStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Header = 1, @@ -439,8 +416,7 @@ declare enum StickyStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Footer = 2, } @@ -451,8 +427,7 @@ declare enum StickyStyle { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ declare enum ChainEdgeEffect { /** @@ -461,8 +436,7 @@ declare enum ChainEdgeEffect { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ DEFAULT, @@ -471,8 +445,7 @@ declare enum ChainEdgeEffect { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ STRETCH, } @@ -491,8 +464,7 @@ declare enum ChainEdgeEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ScrollSnapAlign { /** @@ -508,8 +480,7 @@ declare enum ScrollSnapAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NONE = 0, @@ -530,8 +501,7 @@ declare enum ScrollSnapAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ START = 1, @@ -552,8 +522,7 @@ declare enum ScrollSnapAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CENTER = 2, @@ -574,8 +543,7 @@ declare enum ScrollSnapAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ END = 3, } @@ -586,8 +554,7 @@ declare enum ScrollSnapAlign { * @interface ChainAnimationOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ declare interface ChainAnimationOptions { /** @@ -596,8 +563,7 @@ declare interface ChainAnimationOptions { * @type { Length } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ minSpace: Length; @@ -607,8 +573,7 @@ declare interface ChainAnimationOptions { * @type { Length } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ maxSpace: Length; @@ -619,8 +584,7 @@ declare interface ChainAnimationOptions { * @default 0.7 * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ conductivity?: number; @@ -631,8 +595,7 @@ declare interface ChainAnimationOptions { * @default 0.3 * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ intensity?: number; @@ -643,8 +606,7 @@ declare interface ChainAnimationOptions { * @default ChainEdgeEffect.DEFAULT * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ edgeEffect?: ChainEdgeEffect; @@ -655,8 +617,7 @@ declare interface ChainAnimationOptions { * @default 228 * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ stiffness?: number; @@ -667,8 +628,7 @@ declare interface ChainAnimationOptions { * @default 30 * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ damping?: number; } @@ -746,8 +706,7 @@ declare interface UIListEvent extends UIScrollableCommonEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface CloseSwipeActionOptions { /** @@ -765,8 +724,7 @@ declare interface CloseSwipeActionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onFinish?: ()=>void } @@ -778,8 +736,7 @@ declare interface CloseSwipeActionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface VisibleListContentInfo { /** @@ -789,8 +746,7 @@ declare interface VisibleListContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ index: number @@ -802,8 +758,7 @@ declare interface VisibleListContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ itemGroupArea?: ListItemGroupArea @@ -815,8 +770,7 @@ declare interface VisibleListContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ itemIndexInGroup?: number } @@ -830,8 +784,7 @@ declare interface VisibleListContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type OnScrollVisibleContentChangeCallback = (start: VisibleListContentInfo, end: VisibleListContentInfo) => void; @@ -861,8 +814,7 @@ declare type OnListScrollIndexCallback = (start: number, end: number, center: nu * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class ListScroller extends Scroller { /** @@ -904,8 +856,7 @@ declare class ListScroller extends Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getItemRectInGroup(index: number, indexInGroup: number): RectResult; @@ -947,8 +898,7 @@ declare class ListScroller extends Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ scrollToItemInGroup(index: number, indexInGroup:number, smooth?: boolean, align?: ScrollAlign): void; @@ -981,8 +931,7 @@ declare class ListScroller extends Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ closeAllSwipeActions(options?: CloseSwipeActionOptions): void; @@ -1006,8 +955,7 @@ declare class ListScroller extends Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ getVisibleListContentInfo(x: number, y: number): VisibleListContentInfo; } @@ -1024,8 +972,7 @@ declare class ListScroller extends Scroller { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface ListOptions { /** @@ -1077,8 +1024,7 @@ interface ListOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ initialIndex?: number; /** @@ -1122,7 +1068,8 @@ interface ListOptions { *

NOTE *
If this parameter is set to a negative number or a value greater than or equal to the length of the list content area, the default value is used. *
If this parameter is set to a value less than the width of the list divider, the width of the list divider is used as the spacing. - *
Child components of List whose visibility attribute is set to None are not displayed, but the spacing above and below them still takes effect. + *
Child components of List whose visibility attribute is set to None are not displayed, + * but the spacing above and below them still takes effect. *

* * @type { ?(number | string) } @@ -1131,8 +1078,7 @@ interface ListOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ space?: number | string; /** @@ -1182,8 +1128,7 @@ interface ListOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ scroller?: Scroller; } @@ -1220,8 +1165,7 @@ interface ListOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ListInterface { /** @@ -1272,8 +1216,7 @@ interface ListInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: ListOptions): ListAttribute; } @@ -1286,8 +1229,7 @@ interface ListInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface ListDividerOptions { /** @@ -1333,8 +1275,7 @@ declare interface ListDividerOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ strokeWidth: Length; /** @@ -1381,8 +1322,7 @@ declare interface ListDividerOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ color?: ResourceColor; /** @@ -1429,8 +1369,7 @@ declare interface ListDividerOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ startMargin?: Length; /** @@ -1477,8 +1416,7 @@ declare interface ListDividerOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ endMargin?: Length; } @@ -1507,8 +1445,7 @@ declare interface ListDividerOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ListAttribute extends ScrollableCommonMethod { /** @@ -1542,8 +1479,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lanes(value: number | LengthConstrain, gutter?: Dimension): ListAttribute; @@ -1576,8 +1512,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignListItem(value: ListItemAlign): ListAttribute; @@ -1617,8 +1552,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ listDirection(value: Axis): ListAttribute; @@ -1730,8 +1664,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentStartOffset(value: number): ListAttribute; @@ -1752,8 +1685,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentEndOffset(value: number): ListAttribute; @@ -1805,8 +1737,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ divider( value: ListDividerOptions | null, @@ -1861,8 +1792,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ multiSelectable(value: boolean): ListAttribute; @@ -1904,8 +1834,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ cachedCount(value: number): ListAttribute; @@ -1921,8 +1850,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ cachedCount(count: number, show: boolean): ListAttribute; @@ -1965,8 +1893,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ chainAnimation(value: boolean): ListAttribute; @@ -1977,8 +1904,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @returns { ListAttribute } the attribute of the list. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ chainAnimationOptions(value: ChainAnimationOptions): ListAttribute; @@ -2016,8 +1942,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ sticky(value: StickyStyle): ListAttribute; @@ -2038,8 +1963,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scrollSnapAlign(value: ScrollSnapAlign): ListAttribute; @@ -2120,8 +2044,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ childrenMainSize(value: ChildrenMainSize): ListAttribute; @@ -2145,8 +2068,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ maintainVisibleContentPosition(enabled: boolean): ListAttribute; @@ -2168,8 +2090,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ stackFromEnd(enabled: boolean): ListAttribute; @@ -2185,18 +2106,6 @@ declare class ListAttribute extends ScrollableCommonMethod { */ focusWrapMode(mode: Optional): ListAttribute; - /** - * Set whether to synchronously load child nodes within one frame. - * - * @param { boolean } enable - Whether to synchronously load child nodes within one frame - * @returns { ListAttribute } The attribute of the list. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - syncLoad(enable: boolean): ListAttribute; - /** * Called when the offset and status callback of the slide are set. * @@ -2275,8 +2184,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onScrollIndex(event: (start: number, end: number, center: number) => void): ListAttribute; @@ -2288,8 +2196,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onScrollVisibleContentChange(handler: OnScrollVisibleContentChangeCallback): ListAttribute; @@ -2483,8 +2390,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemMove(event: (from: number, to: number) => boolean): ListAttribute; @@ -2519,19 +2425,6 @@ declare class ListAttribute extends ScrollableCommonMethod { */ onItemDragStart(event: (event: ItemDragInfo, itemIndex: number) => ((() => any) | void)): ListAttribute; - /** - * After a listener is bound, the component can be dragged. After the drag occurs, a callback is triggered. - * (To be triggered, press and hold for 170 milliseconds (ms)) - * - * @param { OnItemDragStartCallback } event - callback function, triggered when the item drag start. - * @returns { ListAttribute } Returns the instance of the ListAttribute. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onItemDragStart(event: OnItemDragStartCallback): ListAttribute; - /** * After binding, a callback is triggered when the component is dragged to the range of the component. * @@ -2557,8 +2450,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemDragEnter(event: (event: ItemDragInfo) => void): ListAttribute; @@ -2587,8 +2479,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemDragMove(event: (event: ItemDragInfo, itemIndex: number, insertIndex: number) => void): ListAttribute; @@ -2617,8 +2508,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemDragLeave(event: (event: ItemDragInfo, itemIndex: number) => void): ListAttribute; @@ -2649,8 +2539,7 @@ declare class ListAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onItemDrop(event: (event: ItemDragInfo, itemIndex: number, insertIndex: number, isSuccess: boolean) => void): ListAttribute; @@ -2696,35 +2585,8 @@ declare class ListAttribute extends ScrollableCommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ onScrollFrameBegin(event: OnScrollFrameBeginCallback): ListAttribute; - - /** - * Called when the scrollable will scroll. - * - * @param { Optional } handler - callback of scrollable. - * @returns { ListAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onWillScroll(handler: Optional): ListAttribute; - - /** - * Called when the scrollable did scroll. - * - * @param { OnScrollCallback } handler - callback of scrollable, - * scrollOffset is offset this frame did scroll, scrollState is current scroll state. - * @returns { ListAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onDidScroll(handler: OnScrollCallback): ListAttribute; } /** diff --git a/api/@internal/component/ets/list_item.d.ts b/api/@internal/component/ets/list_item.d.ts index 914f1fd993696cd8acf72f8115b0161625ab4c7f..e495eebd63803fc142661dc4a33fa0f911c33f5c 100644 --- a/api/@internal/component/ets/list_item.d.ts +++ b/api/@internal/component/ets/list_item.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod, Bindable } from './common'; -import { CustomBuilder } from './builder' -import { Length } from './units'; -import { ComponentContent } from '../ComponentContent' -/*** endif */ /** * Declare item ceiling attribute. @@ -122,8 +116,7 @@ declare enum EditMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SwipeEdgeEffect { /** @@ -145,8 +138,7 @@ declare enum SwipeEdgeEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Spring, @@ -169,8 +161,7 @@ declare enum SwipeEdgeEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ None, } @@ -190,8 +181,7 @@ declare enum SwipeEdgeEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum SwipeActionState { /** @@ -205,8 +195,7 @@ declare enum SwipeActionState { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ COLLAPSED, @@ -221,8 +210,7 @@ declare enum SwipeActionState { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ EXPANDED, @@ -237,8 +225,7 @@ declare enum SwipeActionState { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ACTIONING, } @@ -257,8 +244,7 @@ declare enum SwipeActionState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface SwipeActionItem { /** @@ -277,8 +263,7 @@ declare interface SwipeActionItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ builder?: CustomBuilder; @@ -290,8 +275,7 @@ declare interface SwipeActionItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ builderComponent?: ComponentContent; @@ -311,8 +295,7 @@ declare interface SwipeActionItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ actionAreaDistance?: Length; @@ -330,8 +313,7 @@ declare interface SwipeActionItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onAction?: () => void; @@ -349,8 +331,7 @@ declare interface SwipeActionItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onEnterActionArea?: () => void; @@ -368,8 +349,7 @@ declare interface SwipeActionItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onExitActionArea?: () => void; @@ -388,8 +368,7 @@ declare interface SwipeActionItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onStateChange?: (state: SwipeActionState) => void; } @@ -416,8 +395,7 @@ declare interface SwipeActionItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface SwipeActionOptions { /** @@ -445,8 +423,7 @@ declare interface SwipeActionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ start?: CustomBuilder | SwipeActionItem; @@ -475,8 +452,7 @@ declare interface SwipeActionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ end?: CustomBuilder | SwipeActionItem; @@ -502,8 +478,7 @@ declare interface SwipeActionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ edgeEffect?: SwipeEdgeEffect; @@ -522,8 +497,7 @@ declare interface SwipeActionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onOffsetChange?: (offset: number) => void; } @@ -542,8 +516,7 @@ declare interface SwipeActionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ListItemStyle { /** @@ -558,8 +531,7 @@ declare enum ListItemStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NONE = 0, @@ -575,8 +547,7 @@ declare enum ListItemStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CARD = 1, } @@ -595,8 +566,7 @@ declare enum ListItemStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ListItemOptions { /** @@ -613,8 +583,7 @@ declare interface ListItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ style?: ListItemStyle; } @@ -651,8 +620,7 @@ declare interface ListItemOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ListItemInterface { /** @@ -674,8 +642,7 @@ interface ListItemInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value?: ListItemOptions): ListItemAttribute; @@ -725,8 +692,7 @@ interface ListItemInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ListItemAttribute extends CommonMethod { /** @@ -788,8 +754,7 @@ declare class ListItemAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectable(value: boolean): ListItemAttribute; @@ -818,21 +783,6 @@ declare class ListItemAttribute extends CommonMethod { */ selected(value: boolean): ListItemAttribute; - /** - * Called when judging whether it is selected. - * This parameter supports $$ for two-way binding of variables. - * - * @param { boolean | Bindable } value - if the listItem is selected. - * @returns { ListItemAttribute } the attribute of the listItem. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected(value: boolean | Bindable): ListItemAttribute; - /** * Sets the action item that appears when the list item slides in the cross axis direction of the list. * @@ -858,8 +808,7 @@ declare class ListItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ swipeAction(value: SwipeActionOptions): ListItemAttribute; @@ -899,8 +848,7 @@ declare class ListItemAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onSelect(event: (isSelected: boolean) => void): ListItemAttribute; } diff --git a/api/@internal/component/ets/list_item_group.d.ts b/api/@internal/component/ets/list_item_group.d.ts index 44000be5c58f8c36e06573ee8f8d808ff96917d1..d057851109a0731d8df10600c4b678f52783e225 100644 --- a/api/@internal/component/ets/list_item_group.d.ts +++ b/api/@internal/component/ets/list_item_group.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ChildrenMainSize, CommonMethod } from './common'; -import { CustomBuilder } from './builder' -import { ComponentContent } from '../ComponentContent' -import { ListDividerOptions } from './list'; -/*** endif */ /** * Defines the list item group style. @@ -39,8 +33,7 @@ import { ListDividerOptions } from './list'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ListItemGroupStyle { /** @@ -55,8 +48,7 @@ declare enum ListItemGroupStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NONE = 0, @@ -72,8 +64,7 @@ declare enum ListItemGroupStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CARD = 1, } @@ -100,8 +91,7 @@ declare enum ListItemGroupStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ListItemGroupOptions { /** @@ -126,8 +116,7 @@ declare interface ListItemGroupOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ header?: CustomBuilder; @@ -138,8 +127,7 @@ declare interface ListItemGroupOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ headerComponent?: ComponentContent; @@ -165,8 +153,7 @@ declare interface ListItemGroupOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ footer?: CustomBuilder; @@ -177,8 +164,7 @@ declare interface ListItemGroupOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ footerComponent?: ComponentContent; @@ -204,8 +190,7 @@ declare interface ListItemGroupOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ space?: number | string; @@ -223,8 +208,7 @@ declare interface ListItemGroupOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ style?: ListItemGroupStyle; } @@ -251,8 +235,7 @@ declare interface ListItemGroupOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ListItemGroupInterface { /** @@ -280,8 +263,7 @@ interface ListItemGroupInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options?: ListItemGroupOptions): ListItemGroupAttribute; } @@ -308,8 +290,7 @@ interface ListItemGroupInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ListItemGroupAttribute extends CommonMethod { /** @@ -363,8 +344,7 @@ declare class ListItemGroupAttribute extends CommonMethod { /** @@ -305,8 +293,7 @@ declare class LoadingProgressAttribute extends CommonMethod): LoadingProgressAttribute; } @@ -354,8 +339,7 @@ declare class LoadingProgressAttribute extends CommonMethod { /** @@ -365,10 +349,9 @@ declare interface LoadingProgressConfiguration extends CommonConfiguration { /** @@ -462,8 +446,7 @@ declare class MarqueeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): MarqueeAttribute; @@ -508,8 +491,7 @@ declare class MarqueeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize(value: Length): MarqueeAttribute; @@ -553,8 +535,7 @@ declare class MarqueeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ allowScale(value: boolean): MarqueeAttribute; @@ -603,8 +584,7 @@ declare class MarqueeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontWeight(value: number | FontWeight | string): MarqueeAttribute; @@ -650,8 +630,7 @@ declare class MarqueeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontFamily(value: string | Resource): MarqueeAttribute; @@ -668,8 +647,7 @@ declare class MarqueeAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ marqueeUpdateStrategy(value: MarqueeUpdateStrategy): MarqueeAttribute; @@ -709,8 +687,7 @@ declare class MarqueeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onStart(event: () => void): MarqueeAttribute; @@ -754,8 +731,7 @@ declare class MarqueeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onBounce(event: () => void): MarqueeAttribute; @@ -795,8 +771,7 @@ declare class MarqueeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onFinish(event: () => void): MarqueeAttribute; } diff --git a/api/@internal/component/ets/matrix2d.d.ts b/api/@internal/component/ets/matrix2d.d.ts index a0378005cc60e1bfdce048b0084f3a15ad0d3d25..594e7dc4e95d61c89672e5ad35dc8fb12201d0d5 100644 --- a/api/@internal/component/ets/matrix2d.d.ts +++ b/api/@internal/component/ets/matrix2d.d.ts @@ -18,10 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { LengthMetricsUnit } from '../Graphics'; -/*** endif */ - /** * 2D transformation matrix, supporting rotation, translation, and scaling of the X-axis and Y-axis * @@ -50,8 +46,7 @@ import { LengthMetricsUnit } from '../Graphics'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class Matrix2D { /** @@ -86,8 +81,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scaleX?: number; @@ -123,8 +117,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rotateY?: number; @@ -160,8 +153,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rotateX?: number; @@ -197,8 +189,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scaleY?: number; @@ -234,8 +225,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ translateX?: number; @@ -271,8 +261,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ translateY?: number; @@ -312,8 +301,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ identity(): Matrix2D; @@ -353,8 +341,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ invert(): Matrix2D; @@ -426,8 +413,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rotate(degree: number, rx?: number, ry?: number): Matrix2D; @@ -471,8 +457,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ translate(tx?: number, ty?: number): Matrix2D; @@ -516,8 +501,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scale(sx?: number, sy?: number): Matrix2D; @@ -536,8 +520,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -549,8 +532,7 @@ declare class Matrix2D { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(unit: LengthMetricsUnit); } diff --git a/api/@internal/component/ets/menu.d.ts b/api/@internal/component/ets/menu.d.ts index 52cc8ce8af590973b6ff4fae4f6ade4c3be35e4a..a2c3005f068cbd10b462750314bdb823a48ff3f5 100644 --- a/api/@internal/component/ets/menu.d.ts +++ b/api/@internal/component/ets/menu.d.ts @@ -12,17 +12,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - /** * @file * @kit ArkUI */ - -/*** if arkts 1.2 */ -import { CommonMethod } from './common'; -import { Length, Font, ResourceColor, Dimension, BorderRadiuses, DividerStyleOptions } from './units'; -/*** endif */ - /** * Defines the Menu Component. * @@ -45,38 +38,36 @@ import { Length, Font, ResourceColor, Dimension, BorderRadiuses, DividerStyleOpt * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface MenuInterface { - /** - * Creates the menu component. - * - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Creates the menu component. - * - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Creates the menu component. - * - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - (): MenuAttribute; + /** + * Creates the menu component. + * + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Creates the menu component. + * + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Creates the menu component. + * + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + (): MenuAttribute; } - /** * Declare SubMenuExpandingMode * @@ -84,44 +75,37 @@ interface MenuInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum SubMenuExpandingMode { - /** - * Sub-menu will expand besides main menu - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - SIDE_EXPAND = 0, - - /** - * Sub-menu will expand embedded in main menu - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - EMBEDDED_EXPAND = 1, - - /** - * Sub-menu will expand over main menu - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - STACK_EXPAND = 2, + /** + * Sub-menu will expand besides main menu + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + SIDE_EXPAND = 0, + /** + * Sub-menu will expand embedded in main menu + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + EMBEDDED_EXPAND = 1, + /** + * Sub-menu will expand over main menu + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + STACK_EXPAND = 2 } - /** * Defines the Menu component attribute functions. * @@ -144,143 +128,129 @@ declare enum SubMenuExpandingMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class MenuAttribute extends CommonMethod { - /** - * Sets the Menu text size. - * - * @param { Length } value - Indicates the font size of menu item. - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - * @deprecated since 10 - * @useinstead font - */ - fontSize(value: Length): MenuAttribute; - - /** - * Sets the font style. - * Family and style are not supported currently and will be fixed in future. - * - * @param { Font } value - Indicates the font style of menu item. - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Sets the font style. - * Family and style are not supported currently and will be fixed in future. - * - * @param { Font } value - Indicates the font style of menu item. - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - font(value: Font): MenuAttribute; - - /** - * Sets the Menu font color. - * - * @param { ResourceColor } value - Indicates the font color of menu item. - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Sets the Menu font color. - * - * @param { ResourceColor } value - Indicates the font color of menu item. - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - fontColor(value: ResourceColor): MenuAttribute; - - /** - * Sets the radius of the corner around the menu. - * When the radius is less than the menu width, the default border radius is used. - * - * @param { Dimension | BorderRadiuses } value - the border radius. - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Sets the radius of the corner around the menu. - * When the radius is less than the menu width, the default border radius is used. - * - * @param { Dimension | BorderRadiuses } value - the border radius. - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - radius(value: Dimension | BorderRadiuses): MenuAttribute; - - /** - * Set the divider of menu item - * - * @param { DividerStyleOptions | undefined } options - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - menuItemDivider(options: DividerStyleOptions | undefined): MenuAttribute; - - /** - * Set the divider of menu item group - * - * @param { DividerStyleOptions | undefined } options - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - menuItemGroupDivider(options: DividerStyleOptions | undefined): MenuAttribute; - - /** - * Set the expanding mode of sub-menu - * - * @param { SubMenuExpandingMode } mode - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - subMenuExpandingMode(mode: SubMenuExpandingMode): MenuAttribute; - - /** - * Set the expand symbol of sub-menu. - * - * @param { SymbolGlyphModifier } symbol - * @returns { MenuAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - */ - subMenuExpandSymbol(symbol: SymbolGlyphModifier): MenuAttribute; + /** + * Sets the Menu text size. + * + * @param { Length } value - Indicates the font size of menu item. + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + * @deprecated since 10 + * @useinstead font + */ + fontSize(value: Length): MenuAttribute; + /** + * Sets the font style. + * Family and style are not supported currently and will be fixed in future. + * + * @param { Font } value - Indicates the font style of menu item. + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Sets the font style. + * Family and style are not supported currently and will be fixed in future. + * + * @param { Font } value - Indicates the font style of menu item. + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + font(value: Font): MenuAttribute; + /** + * Sets the Menu font color. + * + * @param { ResourceColor } value - Indicates the font color of menu item. + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Sets the Menu font color. + * + * @param { ResourceColor } value - Indicates the font color of menu item. + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + fontColor(value: ResourceColor): MenuAttribute; + /** + * Sets the radius of the corner around the menu. + * When the radius is less than the menu width, the default border radius is used. + * + * @param { Dimension | BorderRadiuses } value - the border radius. + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Sets the radius of the corner around the menu. + * When the radius is less than the menu width, the default border radius is used. + * + * @param { Dimension | BorderRadiuses } value - the border radius. + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + radius(value: Dimension | BorderRadiuses): MenuAttribute; + /** + * Set the divider of menu item + * + * @param { DividerStyleOptions | undefined } options + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + menuItemDivider(options: DividerStyleOptions | undefined): MenuAttribute; + /** + * Set the divider of menu item group + * + * @param { DividerStyleOptions | undefined } options + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + menuItemGroupDivider(options: DividerStyleOptions | undefined): MenuAttribute; + /** + * Set the expanding mode of sub-menu + * + * @param { SubMenuExpandingMode } mode + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + subMenuExpandingMode(mode: SubMenuExpandingMode): MenuAttribute; + /** + * Set the expand symbol of sub-menu. + * + * @param { SymbolGlyphModifier } symbol + * @returns { MenuAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 20 + */ + subMenuExpandSymbol(symbol: SymbolGlyphModifier): MenuAttribute; } - /** * Defines Menu Component. * @@ -303,7 +273,6 @@ declare class MenuAttribute extends CommonMethod { * @since 11 */ declare const Menu: MenuInterface; - /** * Defines Menu Component instance. * diff --git a/api/@internal/component/ets/menu_item.d.ts b/api/@internal/component/ets/menu_item.d.ts index 0a1e00566da1b70fbd1f89d14047be7b52fa8ec2..d1713a2c0cd397206311f8c9c99a2a2b7e012e6d 100644 --- a/api/@internal/component/ets/menu_item.d.ts +++ b/api/@internal/component/ets/menu_item.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceStr, Font, ResourceColor } from './units'; -import { CommonMethod, Bindable } from './common'; -import { CustomBuilder } from './builder'; -import { SymbolGlyphModifier } from '../../arkui/SymbolGlyphModifier'; -/*** endif */ - /** * Defines the option of MenuItem. * @@ -47,8 +40,8 @@ import { SymbolGlyphModifier } from '../../arkui/SymbolGlyphModifier'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare interface MenuItemOptions { /** @@ -73,8 +66,7 @@ declare interface MenuItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ startIcon?: ResourceStr; @@ -94,7 +86,6 @@ declare interface MenuItemOptions { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ symbolStartIcon?: SymbolGlyphModifier; @@ -120,8 +111,7 @@ declare interface MenuItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ content?: ResourceStr; @@ -147,8 +137,7 @@ declare interface MenuItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ endIcon?: ResourceStr; @@ -168,7 +157,6 @@ declare interface MenuItemOptions { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ symbolEndIcon?: SymbolGlyphModifier; @@ -194,8 +182,7 @@ declare interface MenuItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ labelInfo?: ResourceStr; @@ -221,8 +208,7 @@ declare interface MenuItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ builder?: CustomBuilder; } @@ -249,8 +235,8 @@ declare interface MenuItemOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface MenuItemInterface { /** @@ -278,8 +264,7 @@ interface MenuItemInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value?: MenuItemOptions | CustomBuilder): MenuItemAttribute; } @@ -306,8 +291,8 @@ interface MenuItemInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class MenuItemAttribute extends CommonMethod { /** @@ -339,19 +324,6 @@ declare class MenuItemAttribute extends CommonMethod { */ selected(value: boolean): MenuItemAttribute; - /** - * Setting whether menuItem is selected. - * - * @param { boolean | undefined | Bindable } value - * @returns { MenuItemAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected(value: boolean | undefined | Bindable): MenuItemAttribute; - /** * Whether the relevant check icon is displayed when a menu item is selected. @@ -400,8 +372,7 @@ declare class MenuItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ selectIcon(value: boolean | ResourceStr | SymbolGlyphModifier): MenuItemAttribute; @@ -430,8 +401,7 @@ declare class MenuItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onChange(callback: (selected: boolean) => void): MenuItemAttribute; @@ -454,8 +424,7 @@ declare class MenuItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ contentFont(value: Font): MenuItemAttribute; @@ -476,8 +445,7 @@ declare class MenuItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ contentFontColor(value: ResourceColor): MenuItemAttribute; @@ -500,8 +468,7 @@ declare class MenuItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ labelFont(value: Font): MenuItemAttribute; @@ -522,8 +489,7 @@ declare class MenuItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ labelFontColor(value: ResourceColor): MenuItemAttribute; } diff --git a/api/@internal/component/ets/menu_item_group.d.ts b/api/@internal/component/ets/menu_item_group.d.ts index fa5e23ff42266d460da0a239e866870d6ff9cec1..59fc179231cd12015aab1dd13f4bfe15bb806757 100644 --- a/api/@internal/component/ets/menu_item_group.d.ts +++ b/api/@internal/component/ets/menu_item_group.d.ts @@ -12,18 +12,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - /** * @file * @kit ArkUI */ - -/*** if arkts 1.2 */ -import { CommonMethod } from './common'; -import { CustomBuilder } from './builder'; -import { ResourceStr } from './units'; -/*** endif */ - /** * Defines the option of MenuItemGroup. * @@ -46,65 +38,60 @@ import { ResourceStr } from './units'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface MenuItemGroupOptions { - /** - * Defines the header display info. - * - * @type { ?(ResourceStr | CustomBuilder) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Defines the header display info. - * - * @type { ?(ResourceStr | CustomBuilder) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Defines the header display info. - * - * @type { ?(ResourceStr | CustomBuilder) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - header?: ResourceStr | CustomBuilder; - - /** - * Defines the footer display info. - * - * @type { ?(ResourceStr | CustomBuilder) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Defines the footer display info. - * - * @type { ?(ResourceStr | CustomBuilder) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Defines the footer display info. - * - * @type { ?(ResourceStr | CustomBuilder) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - footer?: ResourceStr | CustomBuilder; + /** + * Defines the header display info. + * + * @type { ?(ResourceStr | CustomBuilder) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Defines the header display info. + * + * @type { ?(ResourceStr | CustomBuilder) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Defines the header display info. + * + * @type { ?(ResourceStr | CustomBuilder) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + header?: ResourceStr | CustomBuilder; + /** + * Defines the footer display info. + * + * @type { ?(ResourceStr | CustomBuilder) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Defines the footer display info. + * + * @type { ?(ResourceStr | CustomBuilder) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Defines the footer display info. + * + * @type { ?(ResourceStr | CustomBuilder) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + footer?: ResourceStr | CustomBuilder; } - /** * Defines the MenuItemGroup Component. * @@ -127,41 +114,39 @@ declare interface MenuItemGroupOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface MenuItemGroupInterface { - /** - * Creates the MenuItemGroup component. - * - * @param { MenuItemGroupOptions } value - * @returns { MenuItemGroupAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Creates the MenuItemGroup component. - * - * @param { MenuItemGroupOptions } value - * @returns { MenuItemGroupAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Creates the MenuItemGroup component. - * - * @param { MenuItemGroupOptions } value - * @returns { MenuItemGroupAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - (value?: MenuItemGroupOptions): MenuItemGroupAttribute; + /** + * Creates the MenuItemGroup component. + * + * @param { MenuItemGroupOptions } value + * @returns { MenuItemGroupAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Creates the MenuItemGroup component. + * + * @param { MenuItemGroupOptions } value + * @returns { MenuItemGroupAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Creates the MenuItemGroup component. + * + * @param { MenuItemGroupOptions } value + * @returns { MenuItemGroupAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + (value?: MenuItemGroupOptions): MenuItemGroupAttribute; } - /** * Defines the MenuItemGroup component attribute functions. * @@ -184,11 +169,11 @@ interface MenuItemGroupInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ -declare class MenuItemGroupAttribute extends CommonMethod {} - +declare class MenuItemGroupAttribute extends CommonMethod { +} /** * Defines MenuItemGroup Component. * @@ -211,7 +196,6 @@ declare class MenuItemGroupAttribute extends CommonMethod; @@ -699,8 +631,7 @@ declare interface NavDestinationTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ duration?: number; @@ -712,8 +643,7 @@ declare interface NavDestinationTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ curve?: Curve; @@ -725,8 +655,7 @@ declare interface NavDestinationTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ delay?: number; @@ -739,8 +668,7 @@ declare interface NavDestinationTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ event: Callback; } @@ -767,8 +695,8 @@ declare interface NavDestinationTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class NavDestinationAttribute extends CommonMethod { /** @@ -822,8 +750,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -902,8 +826,7 @@ declare class NavDestinationAttribute extends CommonMethod void): NavDestinationAttribute; @@ -924,8 +847,7 @@ declare class NavDestinationAttribute extends CommonMethod void): NavDestinationAttribute; @@ -948,8 +870,7 @@ declare class NavDestinationAttribute extends CommonMethod boolean): NavDestinationAttribute; @@ -963,18 +884,7 @@ declare class NavDestinationAttribute extends CommonMethod>} callback - Indicates callback when pop to the navDestination with result. - * @returns {NavDestinationAttribute} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ - onResult(callback: Optional>): NavDestinationAttribute; + onResult(callback: Optional>): NavDestinationAttribute; /** * Sets the mode of the **NavDestination** component. Dynamic modification is not supported. @@ -994,8 +904,7 @@ declare class NavDestinationAttribute extends CommonMethod | CustomBuilder): NavDestinationAttribute; @@ -1079,8 +985,7 @@ declare class NavDestinationAttribute extends CommonMethod | CustomBuilder, options?: NavigationMenuOptions): NavDestinationAttribute; @@ -1107,8 +1012,7 @@ declare class NavDestinationAttribute extends CommonMethod | CustomBuilder, options?: NavigationToolbarOptions): NavDestinationAttribute; @@ -1127,8 +1031,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; - - /** - * Invoked before sub-components of NavDestination are created. - * - * @param { Callback } callback - * - Indicates callback that invoked before sub-components of NavDestination are created. - * @returns { NavDestinationAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onReady(callback: Callback): NavDestinationAttribute; /** * Called when the navigation destination is about to be mounted. @@ -1168,8 +1057,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1182,8 +1070,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1195,8 +1082,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1208,8 +1094,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1224,8 +1109,7 @@ declare class NavDestinationAttribute extends CommonMethod, edges?: Array): NavDestinationAttribute; @@ -1242,8 +1126,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1265,8 +1148,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1280,8 +1162,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1337,8 +1217,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1352,8 +1231,7 @@ declare class NavDestinationAttribute extends CommonMethod>): NavDestinationAttribute; @@ -1367,8 +1245,7 @@ declare class NavDestinationAttribute extends CommonMethod>): NavDestinationAttribute; @@ -1384,8 +1261,7 @@ declare class NavDestinationAttribute extends CommonMethod>): NavDestinationAttribute; - - /** - * Invoked when destination be pushed with singleton mode. - * - * @param { Optional> } callback - Indicates callback when destination be pushed with singleton mode. - * @returns { NavDestinationAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onNewParam(callback: Optional>): NavDestinationAttribute; /** * Sets the display orientation for the **NavDestination** component. After the transition to the NavDestination, @@ -1438,8 +1301,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; @@ -1464,8 +1326,7 @@ declare class NavDestinationAttribute extends CommonMethod, animated?: boolean): NavDestinationAttribute; @@ -1488,8 +1349,7 @@ declare class NavDestinationAttribute extends CommonMethod): NavDestinationAttribute; } @@ -1514,6 +1374,7 @@ declare class NavDestinationAttribute extends CommonMethod Array | undefined; \ No newline at end of file diff --git a/api/@internal/component/ets/navigation.d.ts b/api/@internal/component/ets/navigation.d.ts index fa28000ab8fc2807a9551e17e9c8ebcff60ac8fe..03b7d5ccd6a9a69d271b182a0a8f3db761d8e8b5 100644 --- a/api/@internal/component/ets/navigation.d.ts +++ b/api/@internal/component/ets/navigation.d.ts @@ -18,19 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import window from '../../@ohos.window'; -import { Resource } from '../../global/resource'; -import { TextModifier } from '../../arkui/TextModifier'; -import { LengthMetrics } from '../../arkui/Graphics'; -import { Callback, BlurStyle, CommonMethod, Optional, LayoutSafeAreaType, LayoutSafeAreaEdge, BackgroundEffectOptions, BackgroundBlurStyleOptions, PixelMap, Bindable } from './common' -import { CustomBuilder, PageMapBuilder } from './builder' -import { Length, ResourceStr, ResourceColor, Dimension, VoidCallback } from './units' -import { TitleHeight } from './enums' -import { SymbolGlyphModifier } from '../../arkui/SymbolGlyphModifier' -import { NavDestinationContext, NavDestinationMode } from './navDestination' -/*** endif */ - /** * Import the SystemBarStyle type for Navigation. * @@ -41,18 +28,6 @@ import { NavDestinationContext, NavDestinationMode } from './navDestination' */ declare type SystemBarStyle = import('../api/@ohos.window').default.SystemBarStyle; - -/** - * Import the SystemBarStyle type for Navigation. - * - * @typedef { window.SystemBarStyle } SystemBarStyle - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type SystemBarStyle = window.SystemBarStyle; - /** * Defines the navigation common title. * @@ -75,8 +50,7 @@ declare type SystemBarStyle = window.SystemBarStyle; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface NavigationCommonTitle { /** @@ -110,8 +84,7 @@ declare interface NavigationCommonTitle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ main: string | Resource; @@ -146,8 +119,7 @@ declare interface NavigationCommonTitle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ sub: string | Resource; } @@ -174,8 +146,7 @@ declare interface NavigationCommonTitle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface NavigationCustomTitle { /** @@ -200,8 +171,7 @@ declare interface NavigationCustomTitle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ builder: CustomBuilder; @@ -227,8 +197,7 @@ declare interface NavigationCustomTitle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ height: TitleHeight | Length; } @@ -256,8 +225,7 @@ declare interface NavigationCustomTitle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum NavigationMode { /** @@ -279,8 +247,7 @@ declare enum NavigationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Stack, @@ -303,8 +270,7 @@ declare enum NavigationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Split, @@ -330,8 +296,7 @@ declare enum NavigationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Auto, } @@ -358,8 +323,7 @@ declare enum NavigationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum NavBarPosition { /** @@ -381,8 +345,7 @@ declare enum NavBarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Start, @@ -405,8 +368,7 @@ declare enum NavBarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ End, } @@ -433,8 +395,7 @@ declare enum NavBarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum NavigationTitleMode { /** @@ -495,8 +456,7 @@ declare enum NavigationTitleMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Free = 0, @@ -525,8 +485,7 @@ declare enum NavigationTitleMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Full, @@ -555,8 +514,7 @@ declare enum NavigationTitleMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Mini, } @@ -583,8 +541,8 @@ declare enum NavigationTitleMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare interface NavigationMenuItem { /** @@ -618,8 +576,7 @@ declare interface NavigationMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ value: string | Resource; @@ -654,8 +611,7 @@ declare interface NavigationMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ icon?: string | Resource; @@ -675,7 +631,6 @@ declare interface NavigationMenuItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ symbolIcon?: SymbolGlyphModifier; @@ -686,8 +641,7 @@ declare interface NavigationMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isEnabled?: boolean; @@ -713,8 +667,7 @@ declare interface NavigationMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ action?: () => void; } @@ -734,8 +687,7 @@ declare interface NavigationMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface PopInfo { /** @@ -753,8 +705,7 @@ declare interface PopInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ info: NavPathInfo; @@ -773,8 +724,7 @@ declare interface PopInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ result: Object; } @@ -792,8 +742,7 @@ declare interface PopInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class NavPathInfo { /** @@ -829,21 +778,6 @@ declare class NavPathInfo { * @since 12 */ constructor(name: string, param: unknown, onPop?: import('../api/@ohos.base').Callback, isEntry?: boolean); - - /** - * Creates an instance of NavPathInfo. - * - * @param { string } name - The name of NavDestination. - * @param { Object | null | undefined } param - The detailed parameter of the NavDestination. - * @param { Callback } [onPop] - The callback when next page returns. - * @param { boolean } [isEntry] - Indicates whether it is an entry destination. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - constructor(name: string, param: Object | null | undefined, onPop?: Callback, isEntry?: boolean); /** * Name of the navigation destination page. @@ -860,8 +794,7 @@ declare class NavPathInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ name: string; @@ -883,18 +816,6 @@ declare class NavPathInfo { * @since 11 */ param?: unknown; - - /** - * The detailed parameter of the NavDestination. - * - * @type { ?(Object | null | undefined) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - param?: Object | null | undefined; /** * Callback returned when pop is called on the navigation destination page. @@ -917,18 +838,6 @@ declare class NavPathInfo { */ onPop?: import('../api/@ohos.base').Callback; - /** - * The callback when next page returns. - * - * @type { ?Callback } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onPop?: Callback; - /** * Indicates whether it is an entry destination. * @@ -936,8 +845,7 @@ declare class NavPathInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isEntry?: boolean; @@ -948,8 +856,7 @@ declare class NavPathInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ navDestinationId?: string; } @@ -961,8 +868,7 @@ declare class NavPathInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum LaunchMode { /** @@ -973,8 +879,7 @@ declare enum LaunchMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ STANDARD = 0, @@ -985,8 +890,7 @@ declare enum LaunchMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ MOVE_TO_TOP_SINGLETON = 1, @@ -997,8 +901,7 @@ declare enum LaunchMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ POP_TO_SINGLETON = 2, @@ -1009,8 +912,7 @@ declare enum LaunchMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NEW_INSTANCE = 3, } @@ -1022,8 +924,7 @@ declare enum LaunchMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface NavigationOptions { /** @@ -1034,8 +935,7 @@ declare interface NavigationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ launchMode?: LaunchMode; @@ -1049,8 +949,7 @@ declare interface NavigationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ animated?: boolean; } @@ -1068,8 +967,7 @@ declare interface NavigationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class NavPathStack { /** @@ -1085,8 +983,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -1108,8 +1005,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pushPath(info: NavPathInfo, animated?: boolean): void; @@ -1122,8 +1018,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pushPath(info: NavPathInfo, options?: NavigationOptions): void; @@ -1168,8 +1063,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pushDestination(info: NavPathInfo, animated?: boolean): Promise; @@ -1191,8 +1085,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pushDestination(info: NavPathInfo, options?: NavigationOptions): Promise; @@ -1219,20 +1112,6 @@ declare class NavPathStack { * @since 11 */ pushPathByName(name: string, param: unknown, animated?: boolean): void; - - /** - * Pushes the specified NavDestination into the stack. - * - * @param { string } name - Indicates the name of the NavDestination to be pushed. - * @param { Object | null | undefined } param - Indicates the detailed parameter of the NavDestination to be pushed. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - pushPathByName(name: string, param: Object | null | undefined, animated?: boolean): void; /** * Pushes the specified NavDestination into the stack. @@ -1262,21 +1141,6 @@ declare class NavPathStack { * @since 12 */ pushPathByName(name: string, param: Object, onPop: import('../api/@ohos.base').Callback, animated?: boolean): void; - - /** - * Pushes the specified NavDestination into the stack. - * - * @param { string } name - Indicates the name of the NavDestination to be pushed. - * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. - * @param { Callback } onPop - The callback when next page returns. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - pushPathByName(name: string, param: Object, onPop: Callback, animated?: boolean): void; /** * Pushes the specified NavDestination into the stack. @@ -1313,8 +1177,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pushDestinationByName(name: string, param: Object, animated?: boolean): Promise; @@ -1359,29 +1222,6 @@ declare class NavPathStack { */ pushDestinationByName(name: string, param: Object, onPop: import('../api/@ohos.base').Callback, animated?: boolean): Promise; - /** - * Pushes the specified NavDestination into the stack. - * - * @param { string } name - Indicates the name of the NavDestination to be pushed. - * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. - * @param { Callback } onPop - The callback when next page returns. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @returns { Promise } The promise returned by the function. - * @throws { BusinessError } 401 - Parameter error. Possible causes: - * 1. Mandatory parameters are left unspecified. - * 2. Incorrect parameters types. - * 3. Parameter verification failed. - * @throws { BusinessError } 100001 - Internal error. - * @throws { BusinessError } 100005 - Builder function not registered. - * @throws { BusinessError } 100006 - NavDestination not found. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - pushDestinationByName(name: string, param: Object, onPop: Callback, animated?: boolean): Promise; - /** * Replace the current NavDestination with the specific one.The current NavDestination will be destroyed. * @@ -1399,8 +1239,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replacePath(info: NavPathInfo, animated?: boolean): void; @@ -1412,8 +1251,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replacePath(info: NavPathInfo, options?: NavigationOptions): void; @@ -1433,8 +1271,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ replaceDestination(info: NavPathInfo, options?: NavigationOptions): Promise; @@ -1461,8 +1298,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replacePathByName(name: string, param: Object, animated?: boolean): void; @@ -1483,8 +1319,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ removeByIndexes(indexes: Array): number; @@ -1505,8 +1340,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ removeByName(name: string): number; @@ -1520,8 +1354,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ removeByNavDestinationId(navDestinationId: string): boolean; @@ -1541,8 +1374,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pop(animated?: boolean): NavPathInfo | undefined; @@ -1565,8 +1397,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pop(result: Object, animated?: boolean): NavPathInfo | undefined; @@ -1590,8 +1421,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ popToName(name: string, animated?: boolean): number; @@ -1624,8 +1454,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ popToName(name: string, result: Object, animated?: boolean): number; @@ -1647,8 +1476,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ popToIndex(index: number, animated?: boolean): void; @@ -1663,8 +1491,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ popToIndex(index: number, result: Object, animated?: boolean): void; @@ -1688,8 +1515,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ moveToTop(name: string, animated?: boolean): number; @@ -1712,8 +1538,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ moveIndexToTop(index: number, animated?: boolean): void; @@ -1734,8 +1559,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ clear(animated?: boolean): void; @@ -1754,8 +1578,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getAllPathName(): Array; @@ -1781,19 +1604,6 @@ declare class NavPathStack { * @since 11 */ getParamByIndex(index: number): unknown | undefined; - - /** - * Obtains the param of the specified NavDestination. - * - * @param { number } index - Indicates the index of the NavDestination. - * @returns { Object | null | undefined } Returns the detailed parameter of the NavDestination if it exists in the stack, otherwise returns undefined; - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - getParamByIndex(index: number): Object | null | undefined; /** * Obtains the param of the specified NavDestination. @@ -1815,19 +1625,6 @@ declare class NavPathStack { * @since 11 */ getParamByName(name: string): Array; - - /** - * Obtains the param of the specified NavDestination. - * - * @param { string } name - Indicates the name of the NavDestination. - * @returns { Array } Returns the detailed parameter of all the NavDestinations. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - getParamByName(name: string): Array; /** * Obtains the indexes of all the navigation destination pages that match **name**. @@ -1846,8 +1643,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getIndexByName(name: string): Array; @@ -1860,8 +1656,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getParent(): NavPathStack | null; @@ -1882,8 +1677,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ size(): number; @@ -1908,8 +1702,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ disableAnimation(value: boolean): void; @@ -1920,8 +1713,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setInterception(interception: NavigationInterception): void; @@ -1932,8 +1724,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ getPathStack(): Array; @@ -1945,8 +1736,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ setPathStack(pathStack: Array, animated?: boolean): void; } @@ -1958,8 +1748,7 @@ declare class NavPathStack { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type NavBar = 'navBar' @@ -1974,8 +1763,7 @@ declare type NavBar = 'navBar' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type InterceptionShowCallback = (from: NavDestinationContext|NavBar, to: NavDestinationContext|NavBar, operation: NavigationOperation, isAnimated: boolean) => void; @@ -1987,8 +1775,7 @@ declare type InterceptionShowCallback = (from: NavDestinationContext|NavBar, to: * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type InterceptionModeCallback = (mode: NavigationMode) => void; @@ -1999,8 +1786,7 @@ declare type InterceptionModeCallback = (mode: NavigationMode) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface NavigationInterception { /** @@ -2011,8 +1797,7 @@ declare interface NavigationInterception { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ willShow?: InterceptionShowCallback; @@ -2023,8 +1808,7 @@ declare interface NavigationInterception { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ didShow?: InterceptionShowCallback; @@ -2035,8 +1819,7 @@ declare interface NavigationInterception { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ modeChange?: InterceptionModeCallback; } @@ -2096,8 +1879,8 @@ declare interface HomePathInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface NavigationInterface { /** @@ -2122,8 +1905,7 @@ interface NavigationInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): NavigationAttribute; @@ -2144,8 +1926,7 @@ interface NavigationInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (pathInfos: NavPathStack): NavigationAttribute; @@ -2177,8 +1958,7 @@ interface NavigationInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ToolbarItemStatus { /** @@ -2197,8 +1977,7 @@ declare enum ToolbarItemStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NORMAL = 0, @@ -2214,8 +1993,7 @@ declare enum ToolbarItemStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ DISABLED = 1, @@ -2233,8 +2011,7 @@ declare enum ToolbarItemStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ACTIVE = 2, } @@ -2254,8 +2031,7 @@ declare enum ToolbarItemStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum NavigationOperation { /** @@ -2271,8 +2047,7 @@ declare enum NavigationOperation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PUSH = 1, @@ -2289,8 +2064,7 @@ declare enum NavigationOperation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ POP = 2, @@ -2307,8 +2081,7 @@ declare enum NavigationOperation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ REPLACE = 3, } @@ -2336,7 +2109,7 @@ declare enum NavigationOperation { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 + * @noninterop */ declare interface ToolbarItem { /** @@ -2354,8 +2127,7 @@ declare interface ToolbarItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value: ResourceStr; @@ -2374,8 +2146,7 @@ declare interface ToolbarItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ icon?: ResourceStr; @@ -2395,7 +2166,6 @@ declare interface ToolbarItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ symbolIcon?: SymbolGlyphModifier; @@ -2414,8 +2184,7 @@ declare interface ToolbarItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ action?: () => void; @@ -2434,8 +2203,7 @@ declare interface ToolbarItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ status?: ToolbarItemStatus; @@ -2454,8 +2222,7 @@ declare interface ToolbarItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ activeIcon?: ResourceStr; @@ -2475,7 +2242,6 @@ declare interface ToolbarItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ activeSymbolIcon?: SymbolGlyphModifier; } @@ -2487,8 +2253,8 @@ declare interface ToolbarItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare interface NavigationTitleOptions { /** @@ -2498,8 +2264,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ backgroundColor?: ResourceColor; @@ -2511,8 +2276,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ backgroundBlurStyle?: BlurStyle; @@ -2523,8 +2287,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -2535,8 +2298,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -2549,8 +2311,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ barStyle?: BarStyle; @@ -2562,8 +2323,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ paddingStart?: LengthMetrics; @@ -2575,8 +2335,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ paddingEnd?: LengthMetrics; @@ -2587,8 +2346,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ mainTitleModifier?: TextModifier; @@ -2599,8 +2357,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ subTitleModifier?: TextModifier; @@ -2612,8 +2369,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ enableHoverMode?: boolean; } @@ -2625,8 +2381,7 @@ declare interface NavigationTitleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum BarStyle { /** @@ -2635,8 +2390,7 @@ declare enum BarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ STANDARD = 0, @@ -2646,8 +2400,7 @@ declare enum BarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ STACK = 1, @@ -2657,8 +2410,7 @@ declare enum BarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ SAFE_AREA_PADDING = 2, } @@ -2670,8 +2422,7 @@ declare enum BarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface NavigationToolbarOptions { /** @@ -2681,8 +2432,7 @@ declare interface NavigationToolbarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ backgroundColor?: ResourceColor; @@ -2694,8 +2444,7 @@ declare interface NavigationToolbarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ backgroundBlurStyle?: BlurStyle; @@ -2706,8 +2455,7 @@ declare interface NavigationToolbarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -2718,8 +2466,7 @@ declare interface NavigationToolbarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -2730,8 +2477,7 @@ declare interface NavigationToolbarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ moreButtonOptions?: MoreButtonOptions; @@ -2743,8 +2489,7 @@ declare interface NavigationToolbarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ barStyle?: BarStyle; @@ -2756,8 +2501,7 @@ declare interface NavigationToolbarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ hideItemValue?: boolean } @@ -2769,8 +2513,7 @@ declare interface NavigationToolbarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare interface NavigationMenuOptions { /** @@ -2780,8 +2523,7 @@ declare interface NavigationMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ moreButtonOptions?: MoreButtonOptions; } @@ -2793,8 +2535,7 @@ declare interface NavigationMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare interface MoreButtonOptions { /** @@ -2804,8 +2545,7 @@ declare interface MoreButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyle?: BlurStyle; @@ -2816,8 +2556,7 @@ declare interface MoreButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -2828,8 +2567,7 @@ declare interface MoreButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; } @@ -2856,8 +2594,8 @@ declare interface MoreButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class NavigationAttribute extends CommonMethod { /** @@ -2898,20 +2636,6 @@ declare class NavigationAttribute extends CommonMethod { */ navBarWidth(value: Length): NavigationAttribute; - /** - - * Sets the width of navigation bar. - * - * @param { Length | Bindable } value - * @returns { NavigationAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - navBarWidth(value: Length | Bindable): NavigationAttribute; - /** * Sets the position of the navigation bar. This attribute takes effect * only when the **Navigation** component is split. @@ -2943,8 +2667,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ navBarPosition(value: NavBarPosition): NavigationAttribute; @@ -2971,8 +2694,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ navBarWidthRange(value: [Dimension, Dimension]): NavigationAttribute; @@ -3003,8 +2725,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ minContentWidth(value: Dimension): NavigationAttribute; @@ -3039,8 +2760,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ mode(value: NavigationMode): NavigationAttribute; @@ -3079,8 +2799,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backButtonIcon(value: string | PixelMap | Resource | SymbolGlyphModifier): NavigationAttribute; @@ -3093,8 +2812,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backButtonIcon(icon: string | PixelMap | Resource | SymbolGlyphModifier, accessibilityText?: ResourceStr): NavigationAttribute; @@ -3127,8 +2845,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ hideNavBar(value: boolean): NavigationAttribute; @@ -3178,8 +2895,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ title(value: ResourceStr | CustomBuilder | NavigationCommonTitle | NavigationCustomTitle, options?: NavigationTitleOptions): NavigationAttribute; @@ -3223,8 +2939,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ hideTitleBar(value: boolean): NavigationAttribute; @@ -3240,8 +2955,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ hideTitleBar(hide: boolean, animated: boolean): NavigationAttribute; @@ -3276,8 +2990,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ hideBackButton(value: boolean): NavigationAttribute; @@ -3309,8 +3022,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ titleMode(value: NavigationTitleMode): NavigationAttribute; @@ -3351,8 +3063,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ menus(value: Array | CustomBuilder): NavigationAttribute; @@ -3365,8 +3076,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ menus(items: Array | CustomBuilder, options?: NavigationMenuOptions): NavigationAttribute; @@ -3404,8 +3114,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ toolbarConfiguration(value: Array | CustomBuilder, options?: NavigationToolbarOptions): NavigationAttribute; @@ -3437,8 +3146,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ hideToolBar(value: boolean): NavigationAttribute; @@ -3454,8 +3162,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ hideToolBar(hide: boolean, animated: boolean): NavigationAttribute; @@ -3467,8 +3174,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ enableToolBarAdaptation(enable: Optional): NavigationAttribute; @@ -3500,8 +3206,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onTitleModeChange(callback: (titleMode: NavigationTitleMode) => void): NavigationAttribute; @@ -3533,8 +3238,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onNavBarStateChange(callback: (isVisible: boolean) => void): NavigationAttribute; @@ -3547,8 +3251,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onNavigationModeChange(callback: (mode: NavigationMode) => void): NavigationAttribute; @@ -3577,19 +3280,6 @@ declare class NavigationAttribute extends CommonMethod { */ navDestination(builder: (name: string, param: unknown) => void): NavigationAttribute; - /** - * Set builder for user-defined NavDestination component. - * - * @param { PageMapBuilder | undefined } builder - The builder function of NavDestination component. - * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - navDestination(builder: PageMapBuilder | undefined): NavigationAttribute; - /** * Set custom navigation content transition animation. * @@ -3607,8 +3297,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ customNavContentTransition(delegate: (from: NavContentInfo, to: NavContentInfo, operation: NavigationOperation) => NavigationAnimatedTransition | undefined): NavigationAttribute; @@ -3623,8 +3312,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ignoreLayoutSafeArea(types?: Array, edges?: Array): NavigationAttribute; @@ -3635,11 +3323,10 @@ declare class NavigationAttribute extends CommonMethod { * @returns { NavigationAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ systemBarStyle(style: Optional): NavigationAttribute; - + /** * Set the Navigation can be restored after the application is terminated. * To enable this attribute, a navigation id must be set. @@ -3647,8 +3334,7 @@ declare class NavigationAttribute extends CommonMethod { * @param { boolean } recoverable - navigation can be recovered. * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ recoverable(recoverable: Optional): NavigationAttribute; @@ -3660,8 +3346,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableDragBar(isEnabled: Optional): NavigationAttribute; @@ -3673,8 +3358,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ enableModeChangeAnimation(isEnabled: Optional): NavigationAttribute; @@ -3706,8 +3390,7 @@ declare class NavigationAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice -* @since arkts {'1.1':'12','1.2':'20'} -* @arkts 1.1&1.2 +* @since 12 */ declare interface NavigationAnimatedTransition { /** @@ -3725,8 +3408,7 @@ declare interface NavigationAnimatedTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onTransitionEnd?: (success: boolean) => void @@ -3745,8 +3427,7 @@ declare interface NavigationAnimatedTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ timeout?: number; @@ -3758,8 +3439,7 @@ declare interface NavigationAnimatedTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isInteractive?: boolean; @@ -3778,8 +3458,7 @@ declare interface NavigationAnimatedTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ transition: (transitionProxy: NavigationTransitionProxy) => void } @@ -3799,8 +3478,7 @@ declare interface NavigationAnimatedTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice -* @since arkts {'1.1':'12','1.2':'20'} -* @arkts 1.1&1.2 + * @since 12 */ declare interface NavigationTransitionProxy { /** @@ -3818,8 +3496,7 @@ declare interface NavigationTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ from: NavContentInfo; @@ -3838,8 +3515,7 @@ declare interface NavigationTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ to: NavContentInfo; @@ -3851,8 +3527,7 @@ declare interface NavigationTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isInteractive?: boolean; @@ -3869,8 +3544,7 @@ declare interface NavigationTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ finishTransition(): void; @@ -3886,18 +3560,6 @@ declare interface NavigationTransitionProxy { */ cancelTransition?(): void; - /** - * Notification system transition animation canceled. - * - * @type { ?VoidCallback } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - cancelTransition?: VoidCallback; - /** * Updates the progress of this interactive transition animation. (Non-interactive * animations do not support setting the animation progress). @@ -3909,33 +3571,8 @@ declare interface NavigationTransitionProxy { * @since 12 */ updateTransition?(progress: number): void; - - /** - * Notification system transition animation update. - * - * @type { ?UpdateTransitionCallback } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - updateTransition?: UpdateTransitionCallback; } -/** - * navigation update transition callback. - * - * @typedef { function } UpdateTransitionCallback - * @param { number } progress - Indicates the process of transition - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type UpdateTransitionCallback = (progress: number) => void; - /** * Navigation content info. * @@ -3951,8 +3588,7 @@ declare type UpdateTransitionCallback = (progress: number) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface NavContentInfo { /** @@ -3970,8 +3606,7 @@ declare interface NavContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ name?: string; @@ -3990,8 +3625,7 @@ declare interface NavContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ index: number; @@ -4010,8 +3644,7 @@ declare interface NavContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ mode?: NavDestinationMode; @@ -4022,8 +3655,7 @@ declare interface NavContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ param?: Object; @@ -4034,8 +3666,7 @@ declare interface NavContentInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ navDestinationId?: string; } @@ -4060,6 +3691,7 @@ declare interface NavContentInfo { * @crossplatform * @atomicservice * @since 11 + * @noninterop */ declare const Navigation: NavigationInterface; @@ -4083,5 +3715,6 @@ declare const Navigation: NavigationInterface; * @crossplatform * @atomicservice * @since 11 + * @noninterop */ declare const NavigationInstance: NavigationAttribute; diff --git a/api/@internal/component/ets/node_container.d.ts b/api/@internal/component/ets/node_container.d.ts index 85dde515625b7cba65a8ee30830df501c9d15737..023dcb4943cf2009eda87115e678c471ce4eee81 100644 --- a/api/@internal/component/ets/node_container.d.ts +++ b/api/@internal/component/ets/node_container.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { NodeController } from '../../@ohos.arkui.node'; -import { CommonMethod } from './common'; -/*** endif */ - /** * Defines the Interface of NodeContainer. To display the node build by an associated NodeController. * @@ -38,8 +33,8 @@ import { CommonMethod } from './common'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @noninterop + * @since 12 */ interface NodeContainerInterface { /** @@ -51,29 +46,17 @@ interface NodeContainerInterface { * @crossplatform * @since 11 */ - /** - * Constructor parameters - * - * @param { import('../api/@ohos.arkui.node').NodeController } controller - Indicates the controller of the NodeContainer. - * @returns { NodeContainerAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - (controller: import('../api/@ohos.arkui.node').NodeController): NodeContainerAttribute; /** * Constructor parameters * - * @param { NodeController } controller - Indicates the controller of the NodeContainer. + * @param { import('../api/@ohos.arkui.node').NodeController } controller - Indicates the controller of the NodeContainer. * @returns { NodeContainerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 20 - * @arkts 1.2 + * @since 12 */ - (controller: NodeController): NodeContainerAttribute; + (controller: import('../api/@ohos.arkui.node').NodeController): NodeContainerAttribute; } /** @@ -89,8 +72,7 @@ interface NodeContainerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class NodeContainerAttribute extends CommonMethod {} diff --git a/api/@internal/component/ets/page_transition.d.ts b/api/@internal/component/ets/page_transition.d.ts index 518b2029f18cad31775d67ccef5e7b9a5716a4a8..1ee6c15fac5035805d5b306b9d36fde7df14bbf9 100644 --- a/api/@internal/component/ets/page_transition.d.ts +++ b/api/@internal/component/ets/page_transition.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ICurve, TranslateOptions, ScaleOptions } from './common'; -import { Curve } from './enums'; -/*** endif */ - /** * Declare the jump method. * @@ -45,8 +40,7 @@ import { Curve } from './enums'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum RouteType { /** @@ -68,8 +62,7 @@ declare enum RouteType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ None, @@ -92,8 +85,7 @@ declare enum RouteType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Push, @@ -116,8 +108,7 @@ declare enum RouteType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Pop, } @@ -144,8 +135,7 @@ declare enum RouteType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SlideEffect { /** @@ -167,8 +157,7 @@ declare enum SlideEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Left, @@ -191,8 +180,7 @@ declare enum SlideEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Right, @@ -215,8 +203,7 @@ declare enum SlideEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Top, @@ -239,8 +226,7 @@ declare enum SlideEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Bottom, @@ -250,8 +236,7 @@ declare enum SlideEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ START = 5, @@ -261,8 +246,7 @@ declare enum SlideEffect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ END = 6, } @@ -451,69 +435,6 @@ declare class CommonTransition { opacity(value: number): T; } -/** - * Provides interfaces for common transitions. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare class CommonTransition { - /** - * Called when the slide in effect of the transition is set. - * - * @param { SlideEffect } value - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - slide(value: SlideEffect): this; - - /** - * Called when the translation effect of page transition is set. - * - * @param { TranslateOptions } value - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - translate(value: TranslateOptions): this; - - /** - * Called when setting the zoom effect of page transition. - * - * @param { ScaleOptions } value - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - scale(value: ScaleOptions): this; - - /** - * Called when the transparency value of the starting point of entry or the ending point of exit is set. - * - * @param { number } value - * @returns { this } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - opacity(value: number): this; -} - /** * Defines pageTransition constructor parameters. * @@ -536,8 +457,7 @@ declare class CommonTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface PageTransitionOptions { /** @@ -559,8 +479,7 @@ declare interface PageTransitionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ type?: RouteType; /** @@ -582,8 +501,7 @@ declare interface PageTransitionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ duration?: number; /** @@ -608,8 +526,7 @@ declare interface PageTransitionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ curve?: Curve | string | ICurve; /** @@ -634,8 +551,7 @@ declare interface PageTransitionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ delay?: number; } @@ -649,8 +565,7 @@ declare interface PageTransitionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type PageTransitionCallback = (type: RouteType, progress: number) => void; @@ -755,47 +670,6 @@ interface PageTransitionEnterInterface extends CommonTransition = [T1, T2]; @@ -44,8 +36,7 @@ declare type ParticleTuple = [T1, T2]; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface VelocityOptions { /** @@ -71,8 +62,7 @@ declare interface VelocityOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ speed: ParticleTuple; @@ -99,8 +89,7 @@ declare interface VelocityOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ angle: ParticleTuple; } @@ -173,42 +162,6 @@ declare interface AccelerationOptions< angle?: ParticlePropertyOptions; } -/** - * Defines acceleration options. - * - * @interface AccelerationOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare interface AccelerationOptions { - /** - * Speed property options. - * - * @type { ?ParticlePropertyOptions } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - speed?: ParticlePropertyOptions; - - /** - * Angle property options. - * - * @type { ?ParticlePropertyOptions } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - angle?: ParticlePropertyOptions; -} - /** * Defines the ParticleOptions Interface. * @interface ParticleOptions @@ -387,102 +340,6 @@ interface ParticleOptions< spin?: ParticlePropertyOptions; } -/** - * Defines the ParticleOptions Interface. - * @interface ParticleOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface ParticleOptions { - /** - * Particle emitter. - * @type { EmitterOptions } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - emitter: EmitterOptions; - - /** - * Particle color. - * @type { ?ParticleColorPropertyOptions } - * @default {range:['#FFFFFF','#FFFFFF']} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - color?: ParticleColorPropertyOptions; - - /** - * Particle opacity. - * @type { ?ParticlePropertyOptions } - * @default {range:[1.0,1.0]} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - opacity?: ParticlePropertyOptions; - - /** - * Particle scale. - * @type { ?ParticlePropertyOptions } - * @default {range:[1.0,1.0]} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - scale?: ParticlePropertyOptions; - - /** - * Particle velocity. - * - * @type { ?VelocityOptions } - * @default {speed:[0,0];angle:[0,0]} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - velocity?: VelocityOptions; - - /** - * Particle acceleration. - * - * @type { ?AccelerationOptions } - * @default {speed:{range:[0,0]};angle:{range:[0,0]}} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - acceleration?: AccelerationOptions; - - /** - * Particle spin. - * @type { ?ParticlePropertyOptions } - * @default {range:[0,0]} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - spin?: ParticlePropertyOptions; -} - /** * Defines the parameters for a point-like particle. * @interface PointParticleParameters @@ -496,8 +353,7 @@ interface ParticleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface PointParticleParameters { /** @@ -513,8 +369,7 @@ interface PointParticleParameters { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ radius: VP; } @@ -532,8 +387,7 @@ interface PointParticleParameters { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ImageParticleParameters { /** @@ -549,8 +403,7 @@ interface ImageParticleParameters { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ src: ResourceStr; @@ -577,8 +430,7 @@ interface ImageParticleParameters { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ size: ParticleTuple; @@ -597,8 +449,7 @@ interface ImageParticleParameters { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ objectFit?: ImageFit; } @@ -654,17 +505,6 @@ interface ParticleConfigs { [ParticleType.IMAGE]: ImageParticleParameters; } -/** - * Defines the particle configs. - * @typedef {PointParticleParameters | ImageParticleParameters} ParticleConfigs - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type ParticleConfigs = PointParticleParameters | ImageParticleParameters; - /** * Defines the emitter property. * @@ -672,8 +512,7 @@ declare type ParticleConfigs = PointParticleParameters | ImageParticleParameters * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface EmitterProperty { @@ -684,8 +523,7 @@ interface EmitterProperty { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ index: number; @@ -696,8 +534,7 @@ interface EmitterProperty { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ emitRate?: number; @@ -708,8 +545,7 @@ interface EmitterProperty { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ position?: PositionT; @@ -720,8 +556,7 @@ interface EmitterProperty { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ size?: SizeT; @@ -733,7 +568,6 @@ interface EmitterProperty { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ annulusRegion?: ParticleAnnulusRegion; } @@ -883,81 +717,6 @@ interface EmitterParticleOptions { lifetimeRange?: number; } -/** - * Defines parameters of particles used by emitters. - * - * @interface EmitterParticleOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface EmitterParticleOptions { - /** - * Particle type. - * - * @type { ParticleType } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - type: ParticleType; - - /** - * Particle config. - * - * @type { ParticleConfigs } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - config: ParticleConfigs; - - /** - * Particle count. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - count: number; - - /** - * Particle lifetime. - * - * @type { ?number } - * @default 1000 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - lifetime?: number; - - /** - * Particle lifetimeRange,value range [0, ∞). - * when lifetimeRange>lifetime,minimum lifetime is 0. - * - * @type { ?number } - * @default 0 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - lifetimeRange?: number; -} - /** * Defines the emitter Options. * @interface EmitterOptions @@ -1124,96 +883,6 @@ interface EmitterOptions { annulusRegion?: ParticleAnnulusRegion; } -/** - * Defines the emitter Options. - * @interface EmitterOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface EmitterOptions { - /** - * Set particle config. - * - * @type { EmitterParticleOptions } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - particle: EmitterParticleOptions; - - /** - * Emitting rate, that is, the number of particles produced per second. - * @type { ?number } - * @default 5 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - emitRate?: number; - - /** - * Shape of emitter. - * @type { ?ParticleEmitterShape } - * @default ParticleEmitterShape.RECTANGLE - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - shape?: ParticleEmitterShape; - - /** - * Position of emitter. - * The first element means X-axis location. - * The second element means the Y-axis location. - * - * @type { ?ParticleTuple } - * @default [0,0] - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - position?: ParticleTuple; - - /** - * Size of emitter. - * The first element means emitter width. - * The second element means emitter height. - * - * @type { ?ParticleTuple } - * @default ['100%','100%'] - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - size?: ParticleTuple; - - /** - * the description of the annulus region. This parameter is valid only for emitter whose shape is annulus. - * - * @type { ?ParticleAnnulusRegion } - * @default {innerRadius:LengthMetrics.vp(0),outerRadius:LengthMetrics.vp(0)} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - annulusRegion?: ParticleAnnulusRegion; -} - /** * Defines the particle property updater configs. * @interface ParticlePropertyUpdaterConfigs @@ -1294,17 +963,6 @@ interface ParticlePropertyUpdaterConfigs { [ParticleUpdater.CURVE]: Array>; } -/** - * Defines the particle property updater configs. - * @typedef { undefined | ParticleTuple | Array> } ParticlePropertyUpdaterConfigs - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type ParticlePropertyUpdaterConfigs = undefined | ParticleTuple | Array>; - /** * Defines the particle updater options. * @@ -1370,42 +1028,6 @@ interface ParticleUpdaterOptions { config: ParticlePropertyUpdaterConfigs[UPDATER]; } -/** - * Defines the particle updater options. - * - * @typedef ParticleUpdaterOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface ParticleUpdaterOptions { - /** - * Particle updater type. - * - * @type { ParticleUpdater } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - type: ParticleUpdater; - - /** - * Particle updater configuration. - * - * @type { ParticlePropertyUpdaterConfigs } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - config: ParticlePropertyUpdaterConfigs; -} - /** * Defines the particle color options. * @@ -1413,8 +1035,7 @@ interface ParticleUpdaterOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface ParticleColorOptions { /** @@ -1440,8 +1061,7 @@ interface ParticleColorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ r: ParticleTuple; @@ -1468,8 +1088,7 @@ interface ParticleColorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ g: ParticleTuple; @@ -1496,8 +1115,7 @@ interface ParticleColorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ b: ParticleTuple; @@ -1524,8 +1142,7 @@ interface ParticleColorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ a: ParticleTuple; } @@ -1595,42 +1212,6 @@ interface ParticleColorUpdaterOptions { config: ParticleColorPropertyUpdaterConfigs[UPDATER]; } -/** - * Defines the particle color updater options. - * - * @interface ParticleColorUpdaterOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface ParticleColorUpdaterOptions { - /** - * Color updater. - * - * @type { ParticleUpdater } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - type: ParticleUpdater; - - /** - * Color updater configuration. - * - * @type { ParticleColorPropertyUpdaterConfigs } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - config: ParticleColorPropertyUpdaterConfigs; -} - /** * Defines the particle property Options. * @interface ParticlePropertyOptions @@ -1705,42 +1286,6 @@ interface ParticlePropertyOptions { updater?: ParticleUpdaterOptions; } -/** - * Defines the particle property Options. - * @interface ParticlePropertyOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface ParticlePropertyOptions { - /** - * Initial range, within which the initial value are randomly generated. - * - * @type { ParticleTuple } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - range: ParticleTuple; - - /** - * Particle property updater. - * - * @type { ?ParticleUpdaterOptions } - * @default {type:UPDATER.NONE;config:undefined} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - updater?: ParticleUpdaterOptions; -} - /** * Defines the particle color property updater configs. * @interface ParticleColorPropertyUpdaterConfigs @@ -1823,17 +1368,6 @@ interface ParticleColorPropertyUpdaterConfigs { [ParticleUpdater.CURVE]: Array>; } -/** - * Defines the particle color property updater configs. - * @typedef {undefined | ParticleColorOptions | Array>} ParticleColorPropertyUpdaterConfigs - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type ParticleColorPropertyUpdaterConfigs = undefined | ParticleColorOptions | Array>; - /** * Defines the particle color property updater configs which can support generics. * @interface ParticleColorPropertyOptions @@ -1919,54 +1453,6 @@ interface ParticleColorPropertyOptions { updater?: ParticleColorUpdaterOptions; } -/** - * Defines the particle color property updater. - * @interface ParticleColorPropertyOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface ParticleColorPropertyOptions { - /** - * Initial color range, within which the initial color is randomly generated. - * - * @type { ParticleTuple } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - range: ParticleTuple; - - /** - * Distribution type of particle color. - * @type { ?DistributionType } - * @default DistributionType.UNIFORM - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - distributionType?: DistributionType; - - /** - * Particle color property updater. - * - * @type { ?ParticleColorUpdaterOptions } - * @default {type:UPDATER.NONE;config:undefined} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - updater?: ParticleColorUpdaterOptions; -} - /** * Defines the particle property lifecycle. * @interface ParticlePropertyAnimation @@ -1980,8 +1466,7 @@ interface ParticleColorPropertyOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ParticlePropertyAnimation { /** @@ -1997,8 +1482,7 @@ interface ParticlePropertyAnimation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ from: T; @@ -2015,8 +1499,7 @@ interface ParticlePropertyAnimation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ to: T; @@ -2033,8 +1516,7 @@ interface ParticlePropertyAnimation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ startMillis: number; @@ -2051,8 +1533,7 @@ interface ParticlePropertyAnimation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ endMillis: number; @@ -2071,8 +1552,7 @@ interface ParticlePropertyAnimation { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ curve?: Curve | ICurve; } @@ -2133,30 +1613,6 @@ interface Particles< >; } -/** - * Defines the Particles interface. - * - * @interface Particles - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface Particles { - /** - * Array of particles. - * - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - particles: Array; -} - /** * Defines the particle Interface. * @interface ParticleInterface @@ -2170,8 +1626,7 @@ interface Particles { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ParticleInterface { /** @@ -2222,19 +1677,6 @@ interface ParticleInterface { ACC_ANGLE_UPDATER, SPIN_UPDATER >): ParticleAttribute; - - /** - * create a particle array. - * - * @param { Particles } particles - Array of particles. - * @returns { ParticleAttribute } Returns the particle attribute. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (particles: Particles): ParticleAttribute; } /** @@ -2250,8 +1692,7 @@ interface ParticleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ParticleType { /** @@ -2265,8 +1706,7 @@ declare enum ParticleType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ POINT = 'point', @@ -2281,8 +1721,7 @@ declare enum ParticleType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ IMAGE = 'image', } @@ -2300,8 +1739,7 @@ declare enum ParticleType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ParticleEmitterShape { /** @@ -2315,8 +1753,7 @@ declare enum ParticleEmitterShape { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ RECTANGLE = 'rectangle', @@ -2331,8 +1768,7 @@ declare enum ParticleEmitterShape { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CIRCLE = 'circle', @@ -2347,8 +1783,7 @@ declare enum ParticleEmitterShape { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ELLIPSE = 'ellipse', @@ -2358,7 +1793,6 @@ declare enum ParticleEmitterShape { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ ANNULUS = 'annulus', } @@ -2370,8 +1804,7 @@ declare enum ParticleEmitterShape { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum DistributionType { /** @@ -2380,19 +1813,17 @@ declare enum DistributionType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ UNIFORM = 0, /** * Gaussian distribution. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ GAUSSIAN = 1, } @@ -2410,8 +1841,7 @@ declare enum DistributionType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ParticleUpdater { /** @@ -2425,8 +1855,7 @@ declare enum ParticleUpdater { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NONE = 'none', @@ -2441,8 +1870,7 @@ declare enum ParticleUpdater { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ RANDOM = 'random', @@ -2457,8 +1885,7 @@ declare enum ParticleUpdater { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CURVE = 'curve', } @@ -2474,7 +1901,7 @@ declare enum ParticleUpdater { */ declare type SizeT = import('../api/arkui/Graphics').SizeT; - /** +/** * Defines the PositionT type. * * @typedef { import('../api/arkui/Graphics').PositionT } @@ -2498,8 +1925,7 @@ declare type PositionT = import('../api/arkui/Graphics').PositionT; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ParticleAttribute extends CommonMethod { /** @@ -2510,8 +1936,7 @@ declare class ParticleAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ disturbanceFields(fields: Array): ParticleAttribute; @@ -2523,8 +1948,7 @@ declare class ParticleAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ emitter(value : Array) : ParticleAttribute; } @@ -2550,8 +1974,7 @@ declare const Particle: ParticleInterface; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface DisturbanceFieldOptions { @@ -2565,8 +1988,7 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ strength?: number; @@ -2578,8 +2000,7 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shape?: DisturbanceFieldShape; @@ -2591,8 +2012,7 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ size?: SizeT; @@ -2604,8 +2024,7 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ position?: PositionT; @@ -2621,8 +2040,7 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ feather?: number; @@ -2634,12 +2052,11 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ noiseScale?: number; - /** + /** * Noise frequency with a value greater or equal 0. * * @type { ?number } @@ -2647,8 +2064,7 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ noiseFrequency?: number; @@ -2660,8 +2076,7 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ noiseAmplitude?: number; } @@ -2673,8 +2088,7 @@ declare interface DisturbanceFieldOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum DisturbanceFieldShape { @@ -2684,21 +2098,19 @@ declare enum DisturbanceFieldShape { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - RECT, + RECT = 0, - /** + /** * Shape circle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - CIRCLE, + CIRCLE = 1, /** * Shape eclipse. @@ -2706,11 +2118,9 @@ declare enum DisturbanceFieldShape { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - ELLIPSE - + ELLIPSE = 2 } /** @@ -2720,7 +2130,6 @@ declare enum DisturbanceFieldShape { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ declare interface ParticleAnnulusRegion { /** @@ -2732,7 +2141,6 @@ declare interface ParticleAnnulusRegion { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ center?: PositionT, /** @@ -2743,7 +2151,6 @@ declare interface ParticleAnnulusRegion { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ outerRadius: LengthMetrics, /** @@ -2754,7 +2161,6 @@ declare interface ParticleAnnulusRegion { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ innerRadius: LengthMetrics, /** @@ -2766,7 +2172,6 @@ declare interface ParticleAnnulusRegion { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ startAngle?: number, /** @@ -2778,7 +2183,6 @@ declare interface ParticleAnnulusRegion { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ endAngle?: number, } diff --git a/api/@internal/component/ets/path.d.ts b/api/@internal/component/ets/path.d.ts index af9beaf1e7acff17ad84962154285274ca184989..924c278aab7f3d87fd494716412e1134c466ef20 100644 --- a/api/@internal/component/ets/path.d.ts +++ b/api/@internal/component/ets/path.d.ts @@ -18,10 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonShapeMethod } from './common'; -/*** endif */ - /** * Define options used to construct a path. * @@ -30,8 +26,7 @@ import { CommonShapeMethod } from './common'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface PathOptions { /** @@ -363,8 +358,7 @@ interface PathInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class PathAttribute extends CommonShapeMethod { /** @@ -482,30 +476,3 @@ declare const Path: PathInterface; * @since 11 */ declare const PathInstance: PathAttribute; - -/** - * Provides the path drawing interface. - * - * @interface PathInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface PathInterface { - /** - * Called when drawing path. - * - * @param { PathOptions } [options] - path options - * @returns { PathAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (options?: PathOptions): PathAttribute; -} \ No newline at end of file diff --git a/api/@internal/component/ets/pattern_lock.d.ts b/api/@internal/component/ets/pattern_lock.d.ts index 3512f08dae2bfe7d79c78149e750bc74d4e6b4d1..9231675816a0d9ac46069d591ce107c9f458724b 100644 --- a/api/@internal/component/ets/pattern_lock.d.ts +++ b/api/@internal/component/ets/pattern_lock.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceColor, Length } from './units' -import { LengthMetrics } from '../Graphics' -import { CommonMethod, Callback, Optional } from './common' -/*** endif */ - /** * The challenge result based on input pattern for control pattern lock component. * @enum { number } @@ -37,8 +31,7 @@ import { CommonMethod, Callback, Optional } from './common' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum PatternLockChallengeResult { /** @@ -52,8 +45,7 @@ declare enum PatternLockChallengeResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CORRECT = 1, /** @@ -67,8 +59,7 @@ declare enum PatternLockChallengeResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ WRONG = 2 } @@ -80,8 +71,7 @@ declare enum PatternLockChallengeResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface CircleStyleOptions { /** @@ -91,8 +81,7 @@ declare interface CircleStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color?: ResourceColor; @@ -103,8 +92,7 @@ declare interface CircleStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radius?: LengthMetrics; @@ -115,8 +103,7 @@ declare interface CircleStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableWaveEffect?: boolean; @@ -127,8 +114,7 @@ declare interface CircleStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ enableForeground?: boolean; } @@ -152,8 +138,7 @@ declare interface CircleStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class PatternLockController { /** @@ -175,8 +160,7 @@ declare class PatternLockController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(); @@ -202,16 +186,6 @@ declare class PatternLockController { * @since 12 */ reset(); - /** - * Reset pattern lock. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - reset(): void; /** * Set challenge result. @@ -226,8 +200,7 @@ declare class PatternLockController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setChallengeResult(result: PatternLockChallengeResult): void; } @@ -254,8 +227,7 @@ declare class PatternLockController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface PatternLockInterface { /** @@ -283,8 +255,7 @@ interface PatternLockInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ (controller?: PatternLockController): PatternLockAttribute; } @@ -311,8 +282,7 @@ interface PatternLockInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class PatternLockAttribute extends CommonMethod { /** @@ -344,8 +314,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ sideLength(value: Length): PatternLockAttribute; @@ -378,8 +347,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ circleRadius(value: Length): PatternLockAttribute; @@ -408,8 +376,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundColor(value: ResourceColor): PatternLockAttribute; @@ -438,8 +405,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ regularColor(value: ResourceColor): PatternLockAttribute; @@ -468,8 +434,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ selectedColor(value: ResourceColor): PatternLockAttribute; @@ -498,8 +463,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ activeColor(value: ResourceColor): PatternLockAttribute; @@ -528,8 +492,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pathColor(value: ResourceColor): PatternLockAttribute; @@ -562,8 +525,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pathStrokeWidth(value: number | string): PatternLockAttribute; @@ -592,8 +554,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onPatternComplete(callback: (input: Array) => void): PatternLockAttribute; @@ -624,8 +585,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ autoReset(value: boolean): PatternLockAttribute; @@ -648,19 +608,7 @@ declare class PatternLockAttribute extends CommonMethod { * @since 12 */ onDotConnect(callback: import('../api/@ohos.base').Callback): PatternLockAttribute; - - /** - * Called when connecting to a grid dot. - * @param { Callback } callback - A callback instance used when connection to a grid dot. - * @returns { PatternLockAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onDotConnect(callback: Callback): PatternLockAttribute; - + /** * Sets the background circle style for the dots in a grid when they are in the activated state. * @@ -669,8 +617,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ activateCircleStyle(options: Optional): PatternLockAttribute; @@ -683,8 +630,7 @@ declare class PatternLockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ skipUnselectedPoint(skipped: boolean): PatternLockAttribute; } diff --git a/api/@internal/component/ets/plugin_component.d.ts b/api/@internal/component/ets/plugin_component.d.ts index c5749cdb6a647b081fe9f5f70347bb10aaae99aa..a87b15c7189a5d6d9659b0a1aefd99645695a47f 100644 --- a/api/@internal/component/ets/plugin_component.d.ts +++ b/api/@internal/component/ets/plugin_component.d.ts @@ -18,19 +18,13 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod } from './common' -import { VoidCallback } from './units' -/*** endif */ - /** * PluginComponentTemplate * * @interface PluginComponentTemplate * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface PluginComponentTemplate { /** @@ -39,8 +33,7 @@ interface PluginComponentTemplate { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ source: string; /** @@ -49,8 +42,7 @@ interface PluginComponentTemplate { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ bundleName: string; } @@ -62,8 +54,7 @@ interface PluginComponentTemplate { * @interface PluginComponentOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface PluginComponentOptions { /** @@ -79,8 +70,7 @@ declare interface PluginComponentOptions { * @type { PluginComponentTemplate } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ template: PluginComponentTemplate; @@ -100,16 +90,6 @@ declare interface PluginComponentOptions { * @since 18 */ data: any; - /** - * Plugin component data. - * AnonyMous Object Rectification - * @type { Object|undefined|null } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since 20 - * @arkts 1.2 - */ - data: Object|undefined|null; } /** @@ -119,8 +99,7 @@ declare interface PluginComponentOptions { * @interface PluginErrorData * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface PluginErrorData { /** @@ -136,8 +115,7 @@ declare interface PluginErrorData { * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ errcode: number; @@ -154,8 +132,7 @@ declare interface PluginErrorData { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ msg: string; } @@ -168,8 +145,7 @@ declare interface PluginErrorData { * @param { PluginErrorData } info - Plugin error data * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type PluginErrorCallback = (info: PluginErrorData) => void; @@ -179,8 +155,8 @@ declare type PluginErrorCallback = (info: PluginErrorData) => void; * @interface PluginComponentInterface * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @noninterop + * @since 9 */ interface PluginComponentInterface { /** @@ -200,8 +176,7 @@ interface PluginComponentInterface { * @returns { PluginComponentAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options: PluginComponentOptions): PluginComponentAttribute; } @@ -212,8 +187,8 @@ interface PluginComponentInterface { * @extends CommonMethod * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 + * @noninterop */ declare class PluginComponentAttribute extends CommonMethod { /** @@ -233,8 +208,7 @@ declare class PluginComponentAttribute extends CommonMethod { /** @@ -356,20 +349,6 @@ declare class PolygonAttribute extends CommonShapeMethod { * @since 11 */ points(value: Array): PolygonAttribute; - - /** - * Called when the vertex coordinate list of a polygon is set. - * - * @param { Array } value - * @returns { PolygonAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - points(value: Array): PolygonAttribute; } /** @@ -435,30 +414,3 @@ declare const Polygon: PolygonInterface; * @since 11 */ declare const PolygonInstance: PolygonAttribute; - -/** - * Provides the polygon drawing interface. - * - * @interface PolygonInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface PolygonInterface { - /** - * Called when drawing a polygon. - * - * @param { PolygonOptions } [options] - Polygon options - * @returns { PolygonAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (options?: PolygonOptions): PolygonAttribute; -} diff --git a/api/@internal/component/ets/polyline.d.ts b/api/@internal/component/ets/polyline.d.ts index f6937400d1df320eaad4e6c3b7b8da67a9447419..d2ddef1e828d1bd8db41aede69c7303d21d3a849 100644 --- a/api/@internal/component/ets/polyline.d.ts +++ b/api/@internal/component/ets/polyline.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonShapeMethod } from './common'; -import { ShapePoint } from './line'; -/*** endif */ - /** * Define options used to construct a polyline. * @@ -31,8 +26,7 @@ import { ShapePoint } from './line'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface PolylineOptions { /** @@ -306,8 +300,7 @@ interface PolylineInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class PolylineAttribute extends CommonShapeMethod { /** @@ -349,20 +342,6 @@ declare class PolylineAttribute extends CommonShapeMethod { * @since 11 */ points(value: Array): PolylineAttribute; - - /** - * Called when the polyline is set to pass through the coordinate point list. - * - * @param { Array } value - * @returns { PolylineAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - points(value: Array): PolylineAttribute; } /** @@ -428,30 +407,3 @@ declare const Polyline: PolylineInterface; * @since 11 */ declare const PolylineInstance: PolylineAttribute; - -/** - * Provides an interface for drawing polylines. - * - * @interface PolylineInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface PolylineInterface { - /** - * Set options for polyline component. - * - * @param { PolylineOptions } [options] - Poly line options - * @returns { PolylineAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (options?: PolylineOptions): PolylineAttribute; -} diff --git a/api/@internal/component/ets/progress.d.ts b/api/@internal/component/ets/progress.d.ts index 9b2aca0d3af7f4bd91b5976ec74af9944dbb1674..266c6478cbb9ae0fa17bbe00ad8b52afa7c57e45 100644 --- a/api/@internal/component/ets/progress.d.ts +++ b/api/@internal/component/ets/progress.d.ts @@ -18,14 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceColor,Length, PX , VP , LPX, Font, ResourceStr } from './units' -import { Resource } from '../../global/resource'; -import { CommonMethod, Optional,ContentModifier,CommonConfiguration } from './common' -import { LinearGradient } from './dataPanel' -import { LengthMetrics } from '../Graphics' -/*** endif */ - /** * Defines the option of Progress. * @@ -181,58 +173,6 @@ declare interface ProgressOptions { type?: Type } -/** - * Defines the option of Progress. - * - * @interface ProgressOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare interface ProgressOptions { - - /** - * Sets the value of Progress. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - value: number; - - /** - * Sets the total of Progress. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - total?: number; - - /** - * Sets the type of Progress. - * - * @type { ?ProgressType } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - type?: ProgressType -} /** * Type of progress bar * @@ -265,8 +205,7 @@ declare interface ProgressOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ProgressType { /** @@ -297,8 +236,7 @@ declare enum ProgressType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Linear = 0, @@ -330,8 +268,7 @@ declare enum ProgressType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Ring = 1, @@ -363,8 +300,7 @@ declare enum ProgressType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Eclipse = 2, @@ -396,8 +332,7 @@ declare enum ProgressType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ScaleRing = 3, @@ -429,8 +364,7 @@ declare enum ProgressType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Capsule = 4 } @@ -449,8 +383,7 @@ declare enum ProgressType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ProgressStatus { /** @@ -465,8 +398,7 @@ declare enum ProgressStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ LOADING, @@ -482,8 +414,7 @@ declare enum ProgressStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ PROGRESSING } @@ -524,8 +455,7 @@ declare enum ProgressStatus { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ProgressStyleOptions extends CommonProgressStyleOptions { /** @@ -560,8 +490,7 @@ declare interface ProgressStyleOptions extends CommonProgressStyleOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth?: Length; @@ -597,8 +526,7 @@ declare interface ProgressStyleOptions extends CommonProgressStyleOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scaleCount?: number; @@ -634,8 +562,7 @@ declare interface ProgressStyleOptions extends CommonProgressStyleOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scaleWidth?: Length; } @@ -654,8 +581,7 @@ declare interface ProgressStyleOptions extends CommonProgressStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CommonProgressStyleOptions { /** @@ -674,8 +600,7 @@ declare interface CommonProgressStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableSmoothEffect?: boolean; } @@ -694,8 +619,7 @@ declare interface CommonProgressStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ScanEffectOptions { /** @@ -714,8 +638,7 @@ declare interface ScanEffectOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableScanEffect?: boolean; } @@ -735,8 +658,7 @@ declare interface ScanEffectOptions { * @interface EclipseStyleOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface EclipseStyleOptions extends CommonProgressStyleOptions { @@ -758,8 +680,7 @@ declare interface EclipseStyleOptions extends CommonProgressStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ScaleRingStyleOptions extends CommonProgressStyleOptions { /** @@ -776,8 +697,7 @@ declare interface ScaleRingStyleOptions extends CommonProgressStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth?: Length; @@ -795,8 +715,7 @@ declare interface ScaleRingStyleOptions extends CommonProgressStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scaleWidth?: Length; @@ -814,8 +733,7 @@ declare interface ScaleRingStyleOptions extends CommonProgressStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scaleCount?: number; } @@ -836,8 +754,7 @@ declare interface ScaleRingStyleOptions extends CommonProgressStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RingStyleOptions extends ScanEffectOptions, CommonProgressStyleOptions { /** @@ -854,8 +771,7 @@ declare interface RingStyleOptions extends ScanEffectOptions, CommonProgressStyl * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth?: Length; @@ -873,8 +789,7 @@ declare interface RingStyleOptions extends ScanEffectOptions, CommonProgressStyl * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ shadow?: boolean; @@ -892,8 +807,7 @@ declare interface RingStyleOptions extends ScanEffectOptions, CommonProgressStyl * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ status?: ProgressStatus; } @@ -914,8 +828,7 @@ declare interface RingStyleOptions extends ScanEffectOptions, CommonProgressStyl * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface LinearStyleOptions extends ScanEffectOptions, CommonProgressStyleOptions { /** @@ -932,8 +845,7 @@ declare interface LinearStyleOptions extends ScanEffectOptions, CommonProgressSt * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth?: Length; /** @@ -952,8 +864,7 @@ declare interface LinearStyleOptions extends ScanEffectOptions, CommonProgressSt * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeRadius?: PX | VP | LPX | Resource; } @@ -974,8 +885,7 @@ declare interface LinearStyleOptions extends ScanEffectOptions, CommonProgressSt * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface CapsuleStyleOptions extends ScanEffectOptions, CommonProgressStyleOptions { /** @@ -992,8 +902,7 @@ declare interface CapsuleStyleOptions extends ScanEffectOptions, CommonProgressS * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ borderColor?: ResourceColor; @@ -1011,8 +920,7 @@ declare interface CapsuleStyleOptions extends ScanEffectOptions, CommonProgressS * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ borderWidth?: Length; @@ -1057,8 +965,7 @@ declare interface CapsuleStyleOptions extends ScanEffectOptions, CommonProgressS * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ font?: Font; @@ -1076,8 +983,7 @@ declare interface CapsuleStyleOptions extends ScanEffectOptions, CommonProgressS * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor?: ResourceColor; @@ -1097,8 +1003,7 @@ declare interface CapsuleStyleOptions extends ScanEffectOptions, CommonProgressS * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showDefaultPercentage?: boolean; @@ -1110,8 +1015,7 @@ declare interface CapsuleStyleOptions extends ScanEffectOptions, CommonProgressS * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ borderRadius?: LengthMetrics; } @@ -1148,8 +1052,7 @@ declare interface CapsuleStyleOptions extends ScanEffectOptions, CommonProgressS * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ProgressStyle { /** @@ -1180,8 +1083,7 @@ declare enum ProgressStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Linear, @@ -1213,8 +1115,7 @@ declare enum ProgressStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Ring, @@ -1246,8 +1147,7 @@ declare enum ProgressStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Eclipse, @@ -1279,8 +1179,7 @@ declare enum ProgressStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ScaleRing, @@ -1312,8 +1211,7 @@ declare enum ProgressStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Capsule, } @@ -1331,8 +1229,7 @@ declare enum ProgressStyle { * @interface ProgressStyleMap * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ProgressStyleMap { /** @@ -1448,8 +1345,7 @@ declare interface ProgressStyleMap { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ProgressInterface { /** @@ -1491,19 +1387,6 @@ interface ProgressInterface { * @since 11 */ (options: ProgressOptions): ProgressAttribute; - /** - * Called when the progress bar is set. - * - * @param { ProgressOptions } options - * @returns { ProgressAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (options: ProgressOptions): ProgressAttribute; } /** @@ -1688,88 +1571,6 @@ declare class ProgressAttribute): ProgressAttribute; } -/** - * Defines the progress attribute functions. - * - * @extends CommonMethod - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare class ProgressAttribute extends CommonMethod { - /** - * Called when the current progress value is set. - * - * @param { number } value - * @returns { ProgressAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - value(value: number): ProgressAttribute; - - /** - * Called when the progress bar foreground is set. - * - * @param { ResourceColor | LinearGradient } value - indicates the color of the progress. - * @returns { ProgressAttribute } the attribute of the progress. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - color(value: ResourceColor | LinearGradient): ProgressAttribute; - - /** - * Called when the style of progress bar is set. - * - * @param { LinearStyleOptions | RingStyleOptions | CapsuleStyleOptions | ProgressStyleOptions } value - indicates the style of the progress. - * @returns { ProgressAttribute } the attribute of the progress. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - style(value: LinearStyleOptions | RingStyleOptions | CapsuleStyleOptions | ProgressStyleOptions): ProgressAttribute; - - /** - * Sets if mark to privacy sensitive. - * - * @param { Optional } isPrivacySensitiveMode - indicates if mark to privacy sensitive. - * @returns { ProgressAttribute } the attribute of the progress. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - privacySensitive(isPrivacySensitiveMode: Optional): ProgressAttribute; - - /** - * Set the contentModifier of progress. - * - * @param { ContentModifier } modifier - The contentModifier of progress. - * @returns { ProgressAttribute } the attribute of the progress. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - contentModifier(modifier: ContentModifier): ProgressAttribute; -} - /** * ProgressConfiguration used by progress contentModifier * @@ -1778,8 +1579,7 @@ declare class ProgressAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ProgressConfiguration extends CommonConfiguration { /** @@ -1789,8 +1589,7 @@ declare interface ProgressConfiguration extends CommonConfiguration { /** @@ -185,8 +176,7 @@ declare class QRCodeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ color(value: ResourceColor): QRCodeAttribute; @@ -226,8 +216,7 @@ declare class QRCodeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ backgroundColor(value: ResourceColor): QRCodeAttribute; @@ -246,8 +235,7 @@ declare class QRCodeAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentOpacity(value: number | Resource): QRCodeAttribute; } diff --git a/api/@internal/component/ets/radio.d.ts b/api/@internal/component/ets/radio.d.ts index 5cfb6276a3494c112402a424f02ca9f636414a15..b9eee95fc4e65a3b840fb371760de00ad09eef87 100644 --- a/api/@internal/component/ets/radio.d.ts +++ b/api/@internal/component/ets/radio.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod, ContentModifier, CommonConfiguration, Callback, Bindable } from './common'; -import { CustomBuilder } from './builder'; -import { ResourceColor } from './units'; -/*** endif */ - /** * Defines the IndicatorType of Radio component * @@ -32,8 +26,7 @@ import { ResourceColor } from './units'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum RadioIndicatorType { /** @@ -43,8 +36,7 @@ declare enum RadioIndicatorType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ TICK = 0, /** @@ -54,8 +46,7 @@ declare enum RadioIndicatorType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DOT = 1, /** @@ -65,8 +56,7 @@ declare enum RadioIndicatorType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CUSTOM = 2, } @@ -103,8 +93,7 @@ declare enum RadioIndicatorType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RadioOptions { /** @@ -139,8 +128,7 @@ declare interface RadioOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ group: string; @@ -176,8 +164,7 @@ declare interface RadioOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value: string; /** @@ -188,8 +175,7 @@ declare interface RadioOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ indicatorType?: RadioIndicatorType; /** @@ -200,8 +186,7 @@ declare interface RadioOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ indicatorBuilder?: CustomBuilder; } @@ -221,8 +206,7 @@ declare interface RadioOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RadioStyle { /** @@ -242,8 +226,7 @@ declare interface RadioStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ checkedBackgroundColor?: ResourceColor; @@ -264,8 +247,7 @@ declare interface RadioStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ uncheckedBorderColor?: ResourceColor; @@ -286,8 +268,7 @@ declare interface RadioStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ indicatorColor?: ResourceColor; } @@ -324,8 +305,8 @@ declare interface RadioStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface RadioInterface { /** @@ -364,8 +345,7 @@ interface RadioInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options: RadioOptions): RadioAttribute; } @@ -377,8 +357,7 @@ interface RadioInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnRadioChangeCallback = (isChecked: boolean) => void; @@ -414,8 +393,8 @@ declare type OnRadioChangeCallback = (isChecked: boolean) => void; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class RadioAttribute extends CommonMethod { /** @@ -471,20 +450,6 @@ declare class RadioAttribute extends CommonMethod { */ checked(isChecked: Optional): RadioAttribute; - /** - * Called when the radio box is selected. - * - * @param { boolean | undefined | Bindable } isChecked - * @returns { RadioAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - checked(isChecked: boolean | undefined | Bindable): RadioAttribute; - /** * Called when the radio box selection status changes. * @@ -534,8 +499,7 @@ declare class RadioAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange(callback: Optional): RadioAttribute; @@ -556,8 +520,7 @@ declare class RadioAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ radioStyle(value?: RadioStyle): RadioAttribute; @@ -569,8 +532,7 @@ declare class RadioAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentModifier(modifier: ContentModifier): RadioAttribute; @@ -582,8 +544,7 @@ declare class RadioAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ contentModifier(modifier: Optional>): RadioAttribute; } @@ -596,8 +557,7 @@ declare class RadioAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RadioConfiguration extends CommonConfiguration { /** @@ -607,8 +567,7 @@ declare interface RadioConfiguration extends CommonConfiguration; } diff --git a/api/@internal/component/ets/rating.d.ts b/api/@internal/component/ets/rating.d.ts index d90b13c9def052b75d89e1df196c954be74cf0cc..1c9f7c8fd3ebc20ffb3bcf9f354aec5307e7f11b 100644 --- a/api/@internal/component/ets/rating.d.ts +++ b/api/@internal/component/ets/rating.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonConfiguration, Callback, CommonMethod, Optional, ContentModifier, Bindable } from './common' -import { ResourceStr } from './units'; -/*** endif */ - /** * Define options used to construct a rating. * @@ -31,8 +26,7 @@ import { ResourceStr } from './units'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface RatingOptions { /** @@ -82,19 +76,6 @@ declare interface RatingOptions { */ rating: number; - /** - * Rating option. - * - * @type { number | undefined | Bindable } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - rating: number | undefined | Bindable; - /** * Indicator option. * @@ -137,8 +118,7 @@ declare interface RatingOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ indicator?: boolean } @@ -151,8 +131,7 @@ declare interface RatingOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface StarStyleOptions { /** @@ -199,7 +178,6 @@ declare interface StarStyleOptions { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ backgroundUri: ResourceStr; @@ -247,7 +225,6 @@ declare interface StarStyleOptions { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ foregroundUri: ResourceStr; @@ -295,7 +272,6 @@ declare interface StarStyleOptions { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ secondaryUri?: ResourceStr } @@ -332,8 +308,8 @@ declare interface StarStyleOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface RatingInterface { /** @@ -384,8 +360,7 @@ interface RatingInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: RatingOptions): RatingAttribute; } @@ -398,8 +373,7 @@ interface RatingInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RatingConfiguration extends CommonConfiguration { /** @@ -409,8 +383,7 @@ declare interface RatingConfiguration extends CommonConfiguration; } @@ -471,8 +440,7 @@ declare interface RatingConfiguration extends CommonConfiguration void; @@ -508,8 +476,8 @@ declare interface RatingConfiguration extends CommonConfiguration { /** @@ -548,8 +516,7 @@ declare class RatingAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ stars(value: number): RatingAttribute; @@ -562,8 +529,7 @@ declare class RatingAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ stars(starCount: Optional): RatingAttribute; @@ -603,8 +569,7 @@ declare class RatingAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ stepSize(value: number): RatingAttribute; @@ -617,8 +582,7 @@ declare class RatingAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ stepSize(size: Optional): RatingAttribute; @@ -670,8 +634,7 @@ declare class RatingAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ starStyle(options: StarStyleOptions): RatingAttribute; @@ -684,8 +647,7 @@ declare class RatingAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ starStyle(options: Optional): RatingAttribute; @@ -738,8 +700,7 @@ declare class RatingAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange(callback: Optional): RatingAttribute; @@ -751,8 +712,7 @@ declare class RatingAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentModifier(modifier: ContentModifier): RatingAttribute; @@ -764,8 +724,7 @@ declare class RatingAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ contentModifier(modifier: Optional>): RatingAttribute; } diff --git a/api/@internal/component/ets/rect.d.ts b/api/@internal/component/ets/rect.d.ts index 84c8ecde7bd03677ac35ad1ea2c7cb730ebedf7c..a025e7543cc16629f8719133df639af4f804c4aa 100644 --- a/api/@internal/component/ets/rect.d.ts +++ b/api/@internal/component/ets/rect.d.ts @@ -18,24 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonShapeMethod } from './common'; -import { Length } from './units'; -/*** endif */ - -/** - * Defines the RadiusItem, the first element is the width of the rounded corner, the second is the height of the rounded corner. - * - * @typedef { [Length, Length] } RadiusItem - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type RadiusItem = [Length, Length]; - /** * Define options used to construct a rectangle. * @@ -44,8 +26,7 @@ declare type RadiusItem = [Length, Length]; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface RectOptions { /** @@ -102,7 +83,6 @@ declare interface RectOptions { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ width?: Length; @@ -160,7 +140,6 @@ declare interface RectOptions { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ height?: Length; @@ -220,19 +199,6 @@ declare interface RectOptions { * @since 20 */ radius?: Length | Array; - - /** - * Corner radius of the rectangle. - * - * @type { ?(Length | Array) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - radius?: Length | Array; } /** @@ -243,8 +209,7 @@ declare interface RectOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface RoundedRectOptions { /** @@ -569,7 +534,7 @@ interface RectInterface { * Called when a rectangle is created. * * @param { {width?: number | string;height?: number | string;radius?: number | string | Array;} | - * {width?: number | string;height?: number | string;radiusWidth?: number | string;radiusHeight?: number | string;} } value + * {width?: number | string;height?: number | string;radiusWidth?: number | string;radiusHeight?: number | string;} } value * @returns { RectAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 7 @@ -578,7 +543,7 @@ interface RectInterface { * Called when a rectangle is created. * * @param { {width?: number | string;height?: number | string;radius?: number | string | Array;} | - * {width?: number | string;height?: number | string;radiusWidth?: number | string;radiusHeight?: number | string;} } value + * {width?: number | string;height?: number | string;radiusWidth?: number | string;radiusHeight?: number | string;} } value * @returns { RectAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form @@ -656,8 +621,7 @@ interface RectInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class RectAttribute extends CommonShapeMethod { /** @@ -792,7 +756,7 @@ declare class RectAttribute extends CommonShapeMethod { /** * Called when the fillet size is set. * - * @param { Length | Array } value + * @param { number | string | Array } value * @returns { RectAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -812,20 +776,6 @@ declare class RectAttribute extends CommonShapeMethod { * @since 20 */ radius(value: Length | Array): RectAttribute; - - /** - * Called when the fillet size is set. - * - * @param { number | string | Array } value - * @returns { RectAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - radius(value: number | string | Array): RectAttribute; } /** @@ -884,32 +834,3 @@ declare const RectInStance: RectAttribute; * @since 11 */ declare const RectInstance: RectAttribute; - -/** - * Provides an interface for drawing rectangles. - * - * @interface RectInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface RectInterface { - /** - * Called when a rectangle is created. - * - * @param { RectOptions | RoundedRectOptions } [options] - Rect options - * @returns { RectAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - ( - options?: RectOptions | RoundedRectOptions, - ): RectAttribute; -} \ No newline at end of file diff --git a/api/@internal/component/ets/refresh.d.ts b/api/@internal/component/ets/refresh.d.ts index 4a6048db3d38adfdf9d129cd91cac99791e56413..858042f061ab9a0a1e01c171d5d6d2f8de8a7846 100644 --- a/api/@internal/component/ets/refresh.d.ts +++ b/api/@internal/component/ets/refresh.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Callback, Optional, CommonMethod, Bindable } from './common' -import { CustomBuilder } from './builder' -import { ResourceStr } from './units' -import { ComponentContent } from '../ComponentContent' -/*** endif */ /** * The refresh status of the drop-down refresh. @@ -47,8 +41,7 @@ import { ComponentContent } from '../ComponentContent' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum RefreshStatus { /** @@ -70,8 +63,7 @@ declare enum RefreshStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Inactive, @@ -94,8 +86,7 @@ declare enum RefreshStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Drag, @@ -118,8 +109,7 @@ declare enum RefreshStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ OverDrag, @@ -142,8 +132,7 @@ declare enum RefreshStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Refresh, @@ -166,8 +155,7 @@ declare enum RefreshStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Done, } @@ -194,8 +182,7 @@ declare enum RefreshStatus { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface RefreshOptions { /** @@ -226,18 +213,6 @@ interface RefreshOptions { * @since 11 */ refreshing: boolean; - /** - * Whether the current component is being refreshed. - * This parameter supports $$ for two-way binding of variables. - * - * @type { boolean | Bindable } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - refreshing: boolean | Bindable; /** * Distance to the top of the parent component from the component that @@ -292,8 +267,7 @@ interface RefreshOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ promptText?: ResourceStr; @@ -312,8 +286,7 @@ interface RefreshOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ builder?: CustomBuilder; @@ -324,8 +297,7 @@ interface RefreshOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ refreshingContent?: ComponentContent; } @@ -352,8 +324,7 @@ interface RefreshOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface RefreshInterface { /** @@ -381,8 +352,7 @@ interface RefreshInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value: RefreshOptions): RefreshAttribute; } @@ -409,8 +379,7 @@ interface RefreshInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class RefreshAttribute extends CommonMethod { /** @@ -438,8 +407,7 @@ declare class RefreshAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onStateChange(callback: (state: RefreshStatus) => void): RefreshAttribute; @@ -468,8 +436,7 @@ declare class RefreshAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onRefreshing(callback: () => void): RefreshAttribute; @@ -481,8 +448,7 @@ declare class RefreshAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ refreshOffset(value: number): RefreshAttribute; @@ -494,8 +460,7 @@ declare class RefreshAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pullToRefresh(value: boolean): RefreshAttribute; @@ -508,8 +473,7 @@ declare class RefreshAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onOffsetChange(callback: Callback): RefreshAttribute; @@ -521,8 +485,7 @@ declare class RefreshAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pullDownRatio(ratio: Optional): RefreshAttribute; diff --git a/api/@internal/component/ets/relative_container.d.ts b/api/@internal/component/ets/relative_container.d.ts index 1caa3043b68934d16bf5ec1ef5bcedb3f9cce0a1..cd67f313f5e676b8592ebd42beae25bc6c1555b5 100644 --- a/api/@internal/component/ets/relative_container.d.ts +++ b/api/@internal/component/ets/relative_container.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Dimension } from './units'; -import { Axis } from './enums'; -import { CommonMethod } from './common'; -/*** endif */ - /** * Provides ports for relative containers. * @@ -49,8 +43,7 @@ import { CommonMethod } from './common'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface RelativeContainerInterface { /** @@ -78,8 +71,7 @@ interface RelativeContainerInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): RelativeContainerAttribute; } @@ -91,8 +83,7 @@ interface RelativeContainerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface GuideLinePosition { /** @@ -102,8 +93,7 @@ declare interface GuideLinePosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start? : Dimension; @@ -114,8 +104,7 @@ declare interface GuideLinePosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ end? : Dimension; } @@ -127,8 +116,7 @@ declare interface GuideLinePosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface GuideLineStyle { /** @@ -138,8 +126,7 @@ declare interface GuideLineStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id : string; @@ -150,8 +137,7 @@ declare interface GuideLineStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ direction : Axis; @@ -162,8 +148,7 @@ declare interface GuideLineStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ position : GuideLinePosition; } @@ -175,8 +160,7 @@ declare interface GuideLineStyle { * @syscap SystemCapability.Test.UiTest * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum BarrierDirection { /** @@ -185,8 +169,7 @@ declare enum BarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ LEFT, @@ -196,8 +179,7 @@ declare enum BarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ RIGHT, @@ -207,8 +189,7 @@ declare enum BarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ TOP, @@ -218,8 +199,7 @@ declare enum BarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BOTTOM, } @@ -231,8 +211,7 @@ declare enum BarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum LocalizedBarrierDirection { /** @@ -241,8 +220,7 @@ declare enum LocalizedBarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ START = 0, @@ -252,8 +230,7 @@ declare enum LocalizedBarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ END = 1, @@ -263,8 +240,7 @@ declare enum LocalizedBarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ TOP = 2, @@ -274,8 +250,7 @@ declare enum LocalizedBarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BOTTOM = 3, } @@ -287,8 +262,7 @@ declare enum LocalizedBarrierDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface BarrierStyle { /** @@ -298,8 +272,7 @@ declare interface BarrierStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id : string; @@ -310,8 +283,7 @@ declare interface BarrierStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ direction : BarrierDirection; @@ -322,8 +294,7 @@ declare interface BarrierStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ referencedId : Array; } @@ -335,8 +306,7 @@ declare interface BarrierStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface LocalizedBarrierStyle { /** @@ -346,8 +316,7 @@ declare interface LocalizedBarrierStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id : string; @@ -358,8 +327,7 @@ declare interface LocalizedBarrierStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ localizedDirection : LocalizedBarrierDirection; @@ -370,8 +338,7 @@ declare interface LocalizedBarrierStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ referencedId : Array; } @@ -395,8 +362,7 @@ declare interface LocalizedBarrierStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class RelativeContainerAttribute extends CommonMethod { /** @@ -407,8 +373,7 @@ declare class RelativeContainerAttribute extends CommonMethod): RelativeContainerAttribute; @@ -420,8 +385,7 @@ declare class RelativeContainerAttribute extends CommonMethod): RelativeContainerAttribute; @@ -433,8 +397,7 @@ declare class RelativeContainerAttribute extends CommonMethod): RelativeContainerAttribute; } diff --git a/api/@internal/component/ets/rich_editor.d.ts b/api/@internal/component/ets/rich_editor.d.ts index 9ebb1c2f8c62bb09565051790d1894b2a144012d..416297d030cd273d8a13160e54164492b234beb5 100644 --- a/api/@internal/component/ets/rich_editor.d.ts +++ b/api/@internal/component/ets/rich_editor.d.ts @@ -18,21 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ShadowOptions, ClickEvent, SelectionOptions, CommonMethod, Callback, HapticFeedbackMode, RectResult, HoverEvent, PixelMap } from './common'; -import { CustomBuilder } from './builder'; -import { ResourceColor, Length, ResourceStr, Dimension, Margin, BorderRadiuses, Font, VoidCallback } from './units'; -import { FontStyle, FontWeight, TextAlign, WordBreak, LineBreakStrategy, ImageSpanAlignment, ImageFit, ResponseType, CopyOptions, BarState } from './enums'; -import { DecorationStyleInterface, StyledString, MutableStyledString } from './styledString'; -import { Resource } from './../../../api/global/resource'; -import { SymbolEffectStrategy, SymbolRenderingStrategy } from './symbolglyph'; -import { DecorationStyleResult, TextRange, MenuType, TextEditControllerEx, LayoutManager, PreviewText, StyledStringController, StyledStringChangedListener, TextDataDetectorConfig, OnDidChangeCallback, EditMenuOptions, KeyboardAppearance } from './textCommon'; -import { GestureEvent } from './gesture'; -import { EnterKeyType, SubmitEvent } from './textInput'; -import { LengthMetrics , ColorMetrics } from '../Graphics'; -import { TextBackgroundStyle } from "./span"; -/*** endif */ - /** * Defines delete text direction. * @@ -47,8 +32,7 @@ import { TextBackgroundStyle } from "./span"; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum RichEditorDeleteDirection { /** @@ -63,8 +47,7 @@ declare enum RichEditorDeleteDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ BACKWARD, @@ -80,8 +63,7 @@ declare enum RichEditorDeleteDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ FORWARD, } @@ -100,8 +82,7 @@ declare enum RichEditorDeleteDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum RichEditorSpanType { /** @@ -116,8 +97,7 @@ declare enum RichEditorSpanType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ TEXT = 0, @@ -133,8 +113,7 @@ declare enum RichEditorSpanType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ IMAGE = 1, @@ -150,8 +129,7 @@ declare enum RichEditorSpanType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ MIXED = 2, @@ -161,8 +139,7 @@ declare enum RichEditorSpanType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BUILDER = 3, @@ -172,8 +149,7 @@ declare enum RichEditorSpanType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ DEFAULT = 4, } @@ -224,8 +200,7 @@ declare enum UndoStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum RichEditorResponseType { /** @@ -241,8 +216,7 @@ declare enum RichEditorResponseType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ RIGHT_CLICK = 0, @@ -259,8 +233,7 @@ declare enum RichEditorResponseType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ LONG_PRESS = 1, @@ -277,8 +250,7 @@ declare enum RichEditorResponseType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SELECT = 2, @@ -288,8 +260,7 @@ declare enum RichEditorResponseType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ DEFAULT = 3, } @@ -308,8 +279,7 @@ declare enum RichEditorResponseType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorSpanPosition { /** @@ -326,8 +296,7 @@ declare interface RichEditorSpanPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ spanIndex: number; @@ -345,8 +314,7 @@ declare interface RichEditorSpanPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ spanRange: [number, number]; } @@ -365,8 +333,7 @@ declare interface RichEditorSpanPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorTextStyle { /** @@ -383,8 +350,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor?: ResourceColor; @@ -402,8 +368,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize?: Length | number; @@ -421,8 +386,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontStyle?: FontStyle; @@ -440,8 +404,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontWeight?: number | FontWeight | string; @@ -459,8 +422,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontFamily?: ResourceStr; @@ -487,8 +449,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ decoration?: DecorationStyleInterface; @@ -507,8 +468,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textShadow?: ShadowOptions | Array; @@ -519,8 +479,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ letterSpacing?: number | string; @@ -531,8 +490,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineHeight?: number | string | Resource; @@ -543,8 +501,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ halfLeading?: boolean; @@ -560,8 +517,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontFeature?: string; @@ -572,8 +528,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ textBackgroundStyle?: TextBackgroundStyle; } @@ -594,8 +549,7 @@ declare interface RichEditorTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface LeadingMarginPlaceholder { /** @@ -613,8 +567,7 @@ declare interface LeadingMarginPlaceholder { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pixelMap: PixelMap; @@ -633,8 +586,7 @@ declare interface LeadingMarginPlaceholder { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ size: [Dimension, Dimension]; } @@ -654,8 +606,7 @@ declare interface LeadingMarginPlaceholder { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorParagraphStyle { /** @@ -673,8 +624,7 @@ declare interface RichEditorParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textAlign?: TextAlign; @@ -704,8 +654,7 @@ declare interface RichEditorParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ leadingMargin?: Dimension | LeadingMarginPlaceholder; @@ -716,8 +665,7 @@ declare interface RichEditorParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ wordBreak?: WordBreak; @@ -728,8 +676,7 @@ declare interface RichEditorParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineBreakStrategy?: LineBreakStrategy; @@ -740,8 +687,7 @@ declare interface RichEditorParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ paragraphSpacing?: number; } @@ -753,8 +699,7 @@ declare interface RichEditorParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface PasteEvent { /** @@ -804,8 +749,7 @@ declare interface PasteEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorTextSpan { /** @@ -822,8 +766,7 @@ declare interface RichEditorTextSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ spanPosition: RichEditorSpanPosition; @@ -841,8 +784,7 @@ declare interface RichEditorTextSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value: string; @@ -860,8 +802,7 @@ declare interface RichEditorTextSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle?: RichEditorTextStyle; } @@ -881,8 +822,7 @@ declare interface RichEditorTextSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface RichEditorLayoutStyle { /** @@ -900,8 +840,7 @@ interface RichEditorLayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ margin?: Dimension | Margin; @@ -920,8 +859,7 @@ interface RichEditorLayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderRadius?: Dimension | BorderRadiuses; } @@ -940,8 +878,7 @@ interface RichEditorLayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorImageSpanStyle { /** @@ -958,8 +895,7 @@ declare interface RichEditorImageSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ size?: [Dimension, Dimension]; @@ -977,8 +913,7 @@ declare interface RichEditorImageSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ verticalAlign?: ImageSpanAlignment; @@ -996,8 +931,7 @@ declare interface RichEditorImageSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ objectFit?: ImageFit; @@ -1016,8 +950,7 @@ declare interface RichEditorImageSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ layoutStyle?: RichEditorLayoutStyle; } @@ -1037,8 +970,7 @@ declare interface RichEditorImageSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorSymbolSpanStyle { /** @@ -1056,8 +988,7 @@ declare interface RichEditorSymbolSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontSize?: number | string | Resource; @@ -1076,8 +1007,7 @@ declare interface RichEditorSymbolSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontColor?: Array; @@ -1096,8 +1026,7 @@ declare interface RichEditorSymbolSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontWeight?: number | FontWeight | string; @@ -1116,8 +1045,7 @@ declare interface RichEditorSymbolSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ effectStrategy?: SymbolEffectStrategy; @@ -1136,8 +1064,7 @@ declare interface RichEditorSymbolSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ renderingStrategy?: SymbolRenderingStrategy; } @@ -1156,8 +1083,7 @@ declare interface RichEditorSymbolSpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorTextStyleResult { /** @@ -1174,8 +1100,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor: ResourceColor; @@ -1193,8 +1118,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize: number; @@ -1212,8 +1136,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontStyle: FontStyle; @@ -1231,8 +1154,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontWeight: number; @@ -1250,8 +1172,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontFamily: string; @@ -1278,8 +1199,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ decoration: DecorationStyleResult; @@ -1290,8 +1210,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textShadow?: Array; @@ -1302,8 +1221,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ letterSpacing?: number; @@ -1314,8 +1232,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineHeight?: number; @@ -1326,8 +1243,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ halfLeading?: boolean; @@ -1343,8 +1259,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontFeature?: string; @@ -1355,8 +1270,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ textBackgroundStyle?: TextBackgroundStyle; } @@ -1376,8 +1290,7 @@ declare interface RichEditorTextStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorParagraphResult { /** @@ -1395,8 +1308,7 @@ declare interface RichEditorParagraphResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style: RichEditorParagraphStyle; @@ -1415,8 +1327,7 @@ declare interface RichEditorParagraphResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ range: [number, number]; } @@ -1436,8 +1347,7 @@ declare interface RichEditorParagraphResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorSymbolSpanStyleResult { /** @@ -1455,8 +1365,7 @@ declare interface RichEditorSymbolSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontSize: number | string | Resource; @@ -1475,8 +1384,7 @@ declare interface RichEditorSymbolSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontColor: Array; @@ -1495,8 +1403,7 @@ declare interface RichEditorSymbolSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontWeight: number | FontWeight | string; @@ -1515,8 +1422,7 @@ declare interface RichEditorSymbolSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ effectStrategy: SymbolEffectStrategy; @@ -1535,8 +1441,7 @@ declare interface RichEditorSymbolSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ renderingStrategy: SymbolRenderingStrategy; } @@ -1555,8 +1460,7 @@ declare interface RichEditorSymbolSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorTextSpanResult { /** @@ -1573,8 +1477,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ spanPosition: RichEditorSpanPosition; @@ -1592,8 +1495,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value: string; @@ -1611,8 +1513,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle: RichEditorTextStyleResult; @@ -1630,8 +1531,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offsetInSpan: [number, number]; @@ -1650,8 +1550,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ symbolSpanStyle?: RichEditorSymbolSpanStyle; @@ -1670,8 +1569,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ valueResource?: Resource; @@ -1682,8 +1580,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ paragraphStyle?: RichEditorParagraphStyle; @@ -1694,8 +1591,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ previewText?: string; @@ -1706,8 +1602,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ urlStyle?: RichEditorUrlStyle; } @@ -1726,8 +1621,7 @@ declare interface RichEditorTextSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorImageSpanStyleResult { /** @@ -1744,8 +1638,7 @@ declare interface RichEditorImageSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ size: [number, number]; @@ -1763,8 +1656,7 @@ declare interface RichEditorImageSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ verticalAlign: ImageSpanAlignment; @@ -1782,8 +1674,7 @@ declare interface RichEditorImageSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ objectFit: ImageFit; @@ -1794,8 +1685,7 @@ declare interface RichEditorImageSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ layoutStyle?: RichEditorLayoutStyle; } @@ -1814,8 +1704,7 @@ declare interface RichEditorImageSpanStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorImageSpanResult { /** @@ -1832,8 +1721,7 @@ declare interface RichEditorImageSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ spanPosition: RichEditorSpanPosition; @@ -1851,8 +1739,7 @@ declare interface RichEditorImageSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ valuePixelMap?: PixelMap; @@ -1870,8 +1757,7 @@ declare interface RichEditorImageSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ valueResourceStr?: ResourceStr; @@ -1889,8 +1775,7 @@ declare interface RichEditorImageSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ imageStyle: RichEditorImageSpanStyleResult; @@ -1908,8 +1793,7 @@ declare interface RichEditorImageSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offsetInSpan: [number, number]; } @@ -1928,8 +1812,7 @@ declare interface RichEditorImageSpanResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorImageSpan { /** @@ -1946,8 +1829,7 @@ declare interface RichEditorImageSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ spanPosition: RichEditorSpanPosition; @@ -1965,8 +1847,7 @@ declare interface RichEditorImageSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value: PixelMap | ResourceStr; @@ -1984,8 +1865,7 @@ declare interface RichEditorImageSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ imageStyle?: RichEditorImageSpanStyle; } @@ -2004,8 +1884,7 @@ declare interface RichEditorImageSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorRange { /** @@ -2024,8 +1903,7 @@ declare interface RichEditorRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ start?: number; @@ -2045,8 +1923,7 @@ declare interface RichEditorRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ end?: number; } @@ -2066,8 +1943,7 @@ declare interface RichEditorRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorGesture { /** @@ -2078,15 +1954,14 @@ declare interface RichEditorGesture { * @crossplatform * @since 11 */ - /** + /** * Trigger a click event when a click is clicked. * * @type { ?Callback } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onClick?: Callback; @@ -2105,8 +1980,7 @@ declare interface RichEditorGesture { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onLongPress?: Callback; @@ -2117,8 +1991,7 @@ declare interface RichEditorGesture { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @systemapi - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ onDoubleClick?: Callback; } @@ -2137,8 +2010,7 @@ declare interface RichEditorGesture { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorTextSpanOptions { /** @@ -2155,8 +2027,7 @@ declare interface RichEditorTextSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset?: number; @@ -2174,8 +2045,7 @@ declare interface RichEditorTextSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ style?: RichEditorTextStyle; @@ -2194,8 +2064,7 @@ declare interface RichEditorTextSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ paragraphStyle?: RichEditorParagraphStyle; @@ -2214,8 +2083,7 @@ declare interface RichEditorTextSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ gesture?: RichEditorGesture; @@ -2226,8 +2094,7 @@ declare interface RichEditorTextSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ urlStyle?: RichEditorUrlStyle; } @@ -2239,8 +2106,7 @@ declare interface RichEditorTextSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface KeyboardOptions { /** @@ -2250,8 +2116,7 @@ declare interface KeyboardOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ supportAvoidance?: boolean; } @@ -2270,8 +2135,7 @@ declare interface KeyboardOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorImageSpanOptions { /** @@ -2288,8 +2152,7 @@ declare interface RichEditorImageSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset?: number; @@ -2307,8 +2170,7 @@ declare interface RichEditorImageSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ imageStyle?: RichEditorImageSpanStyle; @@ -2327,8 +2189,7 @@ declare interface RichEditorImageSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ gesture?: RichEditorGesture; @@ -2339,8 +2200,7 @@ declare interface RichEditorImageSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ onHover?: OnHoverCallback; } @@ -2360,8 +2220,7 @@ declare interface RichEditorImageSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorBuilderSpanOptions { /** @@ -2379,8 +2238,7 @@ declare interface RichEditorBuilderSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ offset?: number; @@ -2390,8 +2248,7 @@ declare interface RichEditorBuilderSpanOptions { * @type { ?ColorMetrics } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ dragBackgroundColor? : ColorMetrics; @@ -2401,8 +2258,7 @@ declare interface RichEditorBuilderSpanOptions { * @type { ?boolean } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ isDragShadowNeeded?: boolean; } @@ -2414,8 +2270,7 @@ declare interface RichEditorBuilderSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface PlaceholderStyle { /** @@ -2425,8 +2280,7 @@ declare interface PlaceholderStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ font?: Font; @@ -2437,8 +2291,7 @@ declare interface PlaceholderStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontColor?: ResourceColor; } @@ -2459,8 +2312,7 @@ declare interface PlaceholderStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorSpanStyleOptions extends RichEditorRange { } @@ -2481,8 +2333,7 @@ declare interface RichEditorSpanStyleOptions extends RichEditorRange { } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorParagraphStyleOptions extends RichEditorRange { /** @@ -2500,8 +2351,7 @@ declare interface RichEditorParagraphStyleOptions extends RichEditorRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style: RichEditorParagraphStyle; } @@ -2522,8 +2372,7 @@ declare interface RichEditorParagraphStyleOptions extends RichEditorRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorUpdateTextSpanStyleOptions extends RichEditorSpanStyleOptions { /** @@ -2540,8 +2389,7 @@ declare interface RichEditorUpdateTextSpanStyleOptions extends RichEditorSpanSty * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle: RichEditorTextStyle; @@ -2552,8 +2400,7 @@ declare interface RichEditorUpdateTextSpanStyleOptions extends RichEditorSpanSty * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ urlStyle?: RichEditorUrlStyle; } @@ -2574,8 +2421,7 @@ declare interface RichEditorUpdateTextSpanStyleOptions extends RichEditorSpanSty * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorUpdateImageSpanStyleOptions extends RichEditorSpanStyleOptions { /** @@ -2592,8 +2438,7 @@ declare interface RichEditorUpdateImageSpanStyleOptions extends RichEditorSpanSt * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ imageStyle: RichEditorImageSpanStyle; } @@ -2615,8 +2460,7 @@ declare interface RichEditorUpdateImageSpanStyleOptions extends RichEditorSpanSt * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorUpdateSymbolSpanStyleOptions extends RichEditorSpanStyleOptions { /** @@ -2634,8 +2478,7 @@ declare interface RichEditorUpdateSymbolSpanStyleOptions extends RichEditorSpanS * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ symbolStyle: RichEditorSymbolSpanStyle; } @@ -2655,8 +2498,7 @@ declare interface RichEditorUpdateSymbolSpanStyleOptions extends RichEditorSpanS * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorSymbolSpanOptions { /** @@ -2674,8 +2516,7 @@ declare interface RichEditorSymbolSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ offset?: number; @@ -2694,8 +2535,7 @@ declare interface RichEditorSymbolSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style?: RichEditorSymbolSpanStyle; } @@ -2714,8 +2554,7 @@ declare interface RichEditorSymbolSpanOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorSelection { /** @@ -2732,8 +2571,7 @@ declare interface RichEditorSelection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selection: [number, number]; @@ -2751,8 +2589,7 @@ declare interface RichEditorSelection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ spans: Array; } @@ -2771,8 +2608,7 @@ declare interface RichEditorSelection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorInsertValue { /** @@ -2789,8 +2625,7 @@ declare interface RichEditorInsertValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ insertOffset: number; @@ -2808,8 +2643,7 @@ declare interface RichEditorInsertValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ insertValue: string; @@ -2820,8 +2654,7 @@ declare interface RichEditorInsertValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ previewText?: string; } @@ -2840,8 +2673,7 @@ declare interface RichEditorInsertValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorDeleteValue { /** @@ -2858,8 +2690,7 @@ declare interface RichEditorDeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset: number; @@ -2877,8 +2708,7 @@ declare interface RichEditorDeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ direction: RichEditorDeleteDirection; @@ -2896,8 +2726,7 @@ declare interface RichEditorDeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ length: number; @@ -2915,8 +2744,7 @@ declare interface RichEditorDeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ richEditorDeleteSpans: Array; } @@ -2928,8 +2756,7 @@ declare interface RichEditorDeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorChangeValue { /** @@ -2939,8 +2766,7 @@ declare interface RichEditorChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ rangeBefore: TextRange; @@ -2951,8 +2777,7 @@ declare interface RichEditorChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replacedSpans: Array; @@ -2963,8 +2788,7 @@ declare interface RichEditorChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replacedImageSpans: Array; @@ -2975,8 +2799,7 @@ declare interface RichEditorChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replacedSymbolSpans: Array; @@ -3006,8 +2829,7 @@ declare interface RichEditorChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface RichEditorOptions { /** @@ -3024,8 +2846,7 @@ declare interface RichEditorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ controller: RichEditorController; } @@ -3037,8 +2858,7 @@ declare interface RichEditorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface RichEditorStyledStringOptions { /** @@ -3048,8 +2868,7 @@ declare interface RichEditorStyledStringOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ controller: RichEditorStyledStringController; } @@ -3069,8 +2888,7 @@ declare interface RichEditorStyledStringOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface SelectionMenuOptions { /** @@ -3097,8 +2915,7 @@ declare interface SelectionMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onAppear?: MenuOnAppearCallback; @@ -3121,7 +2938,7 @@ declare interface SelectionMenuOptions { */ /** * Callback function when the selection menu disappears. - * + * * @type { ?Callback } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -3149,8 +2966,7 @@ declare interface SelectionMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ menuType?: MenuType; @@ -3161,8 +2977,7 @@ declare interface SelectionMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ onMenuShow?: MenuCallback; @@ -3173,8 +2988,7 @@ declare interface SelectionMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ onMenuHide?: MenuCallback; @@ -3184,8 +2998,7 @@ declare interface SelectionMenuOptions { * @type { ?PreviewMenuOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ previewMenuOptions?: PreviewMenuOptions; } @@ -3196,8 +3009,7 @@ declare interface SelectionMenuOptions { * @interface PreviewMenuOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface PreviewMenuOptions { /** @@ -3206,8 +3018,7 @@ declare interface PreviewMenuOptions { * @type { ?HapticFeedbackMode } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ hapticFeedbackMode? : HapticFeedbackMode; } @@ -3219,8 +3030,7 @@ declare interface PreviewMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class RichEditorBaseController implements TextEditControllerEx { /** @@ -3237,8 +3047,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getCaretOffset(): number; @@ -3258,8 +3067,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ setCaretOffset(offset: number): boolean; @@ -3275,8 +3083,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ closeSelectionMenu(): void; @@ -3295,8 +3102,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getTypingStyle(): RichEditorTextStyle; @@ -3315,8 +3121,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setTypingStyle(value: RichEditorTextStyle): void; @@ -3349,8 +3154,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setSelection(selectionStart: number, selectionEnd: number, options?: SelectionOptions): void; @@ -3361,8 +3165,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isEditing(): boolean; @@ -3372,8 +3175,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ stopEditing(): void; @@ -3384,8 +3186,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getLayoutManager(): LayoutManager; @@ -3396,8 +3197,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getPreviewText(): PreviewText; @@ -3408,8 +3208,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getCaretRect(): RectResult | undefined; } @@ -3435,8 +3234,7 @@ declare class RichEditorBaseController implements TextEditControllerEx { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class RichEditorController extends RichEditorBaseController { /** @@ -3469,7 +3267,6 @@ declare class RichEditorController extends RichEditorBaseController { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ addTextSpan(content: ResourceStr, options?: RichEditorTextSpanOptions): number; @@ -3491,8 +3288,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ addImageSpan(value: PixelMap | ResourceStr, options?: RichEditorImageSpanOptions): number; @@ -3515,8 +3311,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ addBuilderSpan(value: CustomBuilder, options?: RichEditorBuilderSpanOptions): number; @@ -3539,8 +3334,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ addSymbolSpan(value: Resource, options?: RichEditorSymbolSpanOptions ): number; @@ -3558,8 +3352,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ updateSpanStyle(value: RichEditorUpdateTextSpanStyleOptions | RichEditorUpdateImageSpanStyleOptions | RichEditorUpdateSymbolSpanStyleOptions): void; @@ -3578,8 +3371,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ updateParagraphStyle(value: RichEditorParagraphStyleOptions): void; @@ -3597,8 +3389,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ deleteSpans(value?: RichEditorRange): void; @@ -3618,8 +3409,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getSpans(value?: RichEditorRange): Array; @@ -3640,8 +3430,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getParagraphs(value?: RichEditorRange): Array; @@ -3660,8 +3449,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getSelection(): RichEditorSelection; @@ -3675,8 +3463,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fromStyledString(value: StyledString): Array; @@ -3690,8 +3477,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ toStyledString(value: RichEditorRange): StyledString; } @@ -3703,8 +3489,7 @@ declare class RichEditorController extends RichEditorBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type RichEditorSpan = RichEditorImageSpanResult | RichEditorTextSpanResult; @@ -3716,8 +3501,7 @@ declare type RichEditorSpan = RichEditorImageSpanResult | RichEditorTextSpanResu * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class RichEditorStyledStringController extends RichEditorBaseController implements StyledStringController { /** @@ -3727,8 +3511,7 @@ declare class RichEditorStyledStringController extends RichEditorBaseController * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setStyledString(styledString: StyledString): void; @@ -3748,7 +3531,6 @@ declare class RichEditorStyledStringController extends RichEditorBaseController * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ getStyledString(): MutableStyledString; @@ -3759,8 +3541,7 @@ declare class RichEditorStyledStringController extends RichEditorBaseController * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getSelection(): RichEditorRange; @@ -3771,8 +3552,7 @@ declare class RichEditorStyledStringController extends RichEditorBaseController * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onContentChanged(listener: StyledStringChangedListener): void; } @@ -3791,8 +3571,7 @@ declare class RichEditorStyledStringController extends RichEditorBaseController * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class RichEditorAttribute extends CommonMethod { /** @@ -3864,8 +3643,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onSelect(callback: Callback): RichEditorAttribute; @@ -3877,8 +3655,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onSelectionChange(callback: Callback): RichEditorAttribute; @@ -3908,8 +3685,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ aboutToIMEInput(callback: Callback): RichEditorAttribute; @@ -3939,8 +3715,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onIMEInputComplete(callback: Callback): RichEditorAttribute; @@ -3952,8 +3727,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidIMEInput(callback: Callback): RichEditorAttribute; @@ -3983,8 +3757,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ aboutToDelete(callback: Callback): RichEditorAttribute; @@ -4048,8 +3821,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ copyOptions(value: CopyOptions): RichEditorAttribute; @@ -4076,8 +3848,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ bindSelectionMenu(spanType: RichEditorSpanType, content: CustomBuilder, responseType: ResponseType | RichEditorResponseType, options?: SelectionMenuOptions): RichEditorAttribute; @@ -4109,8 +3880,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ customKeyboard(value: CustomBuilder, options?: KeyboardOptions): RichEditorAttribute; @@ -4131,8 +3901,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onPaste(callback: PasteEventCallback): RichEditorAttribute; @@ -4153,8 +3922,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableDataDetector(enable: boolean): RichEditorAttribute; @@ -4166,8 +3934,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enablePreviewText(enable: boolean): RichEditorAttribute; @@ -4188,8 +3955,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dataDetectorConfig(config: TextDataDetectorConfig): RichEditorAttribute; @@ -4202,8 +3968,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ placeholder(value: ResourceStr, style?: PlaceholderStyle): RichEditorAttribute; @@ -4215,8 +3980,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ caretColor(value: ResourceColor): RichEditorAttribute; @@ -4228,8 +3992,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ selectedBackgroundColor(value: ResourceColor): RichEditorAttribute; @@ -4241,8 +4004,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onEditingChange(callback: Callback): RichEditorAttribute; @@ -4254,8 +4016,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enterKeyType(value: EnterKeyType): RichEditorAttribute; @@ -4267,8 +4028,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onSubmit(callback: SubmitCallback): RichEditorAttribute; @@ -4280,8 +4040,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillChange(callback: Callback) : RichEditorAttribute; @@ -4293,8 +4052,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidChange(callback: OnDidChangeCallback) : RichEditorAttribute; @@ -4306,8 +4064,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onCut(callback: Callback): RichEditorAttribute; @@ -4319,8 +4076,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onCopy(callback: Callback): RichEditorAttribute; @@ -4332,8 +4088,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ editMenuOptions(editMenu: EditMenuOptions): RichEditorAttribute; @@ -4345,8 +4100,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableKeyboardOnFocus(isEnabled: boolean): RichEditorAttribute; @@ -4358,8 +4112,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ enableHapticFeedback(isEnabled: boolean): RichEditorAttribute; @@ -4371,8 +4124,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ barState(state: BarState): RichEditorAttribute; @@ -4384,8 +4136,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ maxLength(maxLength: Optional): RichEditorAttribute; @@ -4397,8 +4148,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ maxLines(maxLines: Optional): RichEditorAttribute; @@ -4421,8 +4171,7 @@ declare class RichEditorAttribute extends CommonMethod { * @returns { RichEditorAttribute } returns the instance of the RichEditorAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ keyboardAppearance(appearance: Optional): RichEditorAttribute; @@ -4433,8 +4182,7 @@ declare class RichEditorAttribute extends CommonMethod { * @returns { RichEditorAttribute } returns the instance of the RichEditorAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ stopBackPress(isStopped: Optional): RichEditorAttribute; @@ -4457,8 +4205,7 @@ declare class RichEditorAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface CutEvent { /** @@ -4491,8 +4238,7 @@ declare interface CutEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface CopyEvent { /** @@ -4525,8 +4271,7 @@ declare interface CopyEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare interface RichEditorUrlStyle { /** @@ -4536,8 +4281,7 @@ declare interface RichEditorUrlStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ url?: ResourceStr; } @@ -4551,8 +4295,7 @@ declare interface RichEditorUrlStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type SubmitCallback = (enterKey: EnterKeyType, event: SubmitEvent) => void; @@ -4565,8 +4308,7 @@ declare type SubmitCallback = (enterKey: EnterKeyType, event: SubmitEvent) => vo * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type MenuOnAppearCallback = (start: number, end: number) => void; @@ -4579,8 +4321,7 @@ declare type MenuOnAppearCallback = (start: number, end: number) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare type MenuCallback = (start: number, end: number) => void; @@ -4592,8 +4333,7 @@ declare type MenuCallback = (start: number, end: number) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type PasteEventCallback = (event?: PasteEvent) => void; @@ -4606,8 +4346,7 @@ declare type PasteEventCallback = (event?: PasteEvent) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare type OnHoverCallback = (status: boolean, event: HoverEvent) => void; @@ -4625,8 +4364,7 @@ declare type OnHoverCallback = (status: boolean, event: HoverEvent) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface RichEditorInterface { /** @@ -4645,8 +4383,7 @@ interface RichEditorInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value: RichEditorOptions): RichEditorAttribute; @@ -4658,8 +4395,7 @@ interface RichEditorInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ (options: RichEditorStyledStringOptions): RichEditorAttribute; } diff --git a/api/@internal/component/ets/rich_text.d.ts b/api/@internal/component/ets/rich_text.d.ts index e11c5718fd7ceb4f87694e9e94fa8302579228d6..0b0b823309bbb1c63a05ed9e32392ab4040f7966 100644 --- a/api/@internal/component/ets/rich_text.d.ts +++ b/api/@internal/component/ets/rich_text.d.ts @@ -20,6 +20,7 @@ /*** if arkts 1.2 */ import { CommonMethod} from './common'; +import { Resource } from '../../global/resource'; /*** endif */ /** @@ -82,21 +83,10 @@ interface RichTextInterface { * @returns { RichTextAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since 20 + * @since arkts {'1.1':'20','1.2':'20'} + * @arkts 1.1&1.2 */ (content: string | Resource): RichTextAttribute; - - /** - * Set value. - * - * @param { string } content - * @returns { RichTextAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 20 - * @arkts 1.2 - */ - (content: string): RichTextAttribute; } /** diff --git a/api/@internal/component/ets/row.d.ts b/api/@internal/component/ets/row.d.ts index b3981964e0ed82f58338a19756fb9cf55ba7ae84..36d502a1feb9129f65a79c70a37b64d30d47b1cb 100644 --- a/api/@internal/component/ets/row.d.ts +++ b/api/@internal/component/ets/row.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { PointLightStyle, Optional, CommonMethod } from './common'; -import { VerticalAlign, FlexAlign } from './enums'; -import { SpaceType } from './column'; -/*** endif */ - - /** * Define options used to construct a row. * @@ -33,8 +26,7 @@ import { SpaceType } from './column'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface RowOptions { /** @@ -80,8 +72,7 @@ declare interface RowOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ space?: string | number; } @@ -94,8 +85,7 @@ declare interface RowOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface RowOptionsV2 { /** @@ -106,8 +96,7 @@ interface RowOptionsV2 { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ space?: SpaceType; } @@ -144,8 +133,7 @@ interface RowOptionsV2 { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface RowInterface { /** @@ -196,8 +184,7 @@ interface RowInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: RowOptions): RowAttribute; /** @@ -210,8 +197,7 @@ interface RowInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: RowOptions | RowOptionsV2): RowAttribute; } @@ -248,8 +234,7 @@ interface RowInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class RowAttribute extends CommonMethod { /** @@ -288,8 +273,7 @@ declare class RowAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignItems(value: VerticalAlign): RowAttribute; @@ -329,8 +313,7 @@ declare class RowAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ justifyContent(value: FlexAlign): RowAttribute; /** @@ -340,8 +323,7 @@ declare class RowAttribute extends CommonMethod { * @returns { RowAttribute } The attribute of the row. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pointLight(value: PointLightStyle): RowAttribute; /** @@ -353,8 +335,7 @@ declare class RowAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ reverse(isReversed: Optional): RowAttribute; } diff --git a/api/@internal/component/ets/row_split.d.ts b/api/@internal/component/ets/row_split.d.ts index 395b1e5e0a2cd92953b1690dff8175fbac7153f4..936f5c47b8492df8935a174740a702e895cd2a10 100644 --- a/api/@internal/component/ets/row_split.d.ts +++ b/api/@internal/component/ets/row_split.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod } from './common'; -/*** endif */ - - /** * Provides interfaces for layout in the vertical direction. * @@ -45,8 +40,7 @@ import { CommonMethod } from './common'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface RowSplitInterface { /** @@ -71,8 +65,7 @@ interface RowSplitInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): RowSplitAttribute; } @@ -93,8 +86,7 @@ interface RowSplitInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class RowSplitAttribute extends CommonMethod { /** @@ -122,8 +114,7 @@ declare class RowSplitAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ resizeable(value: boolean): RowSplitAttribute; } diff --git a/api/@internal/component/ets/save_button.d.ts b/api/@internal/component/ets/save_button.d.ts index 9493007579e7cfe8ec67a333f4a9c5418eba9ba4..c1f1563e882f2b62e467576c235d28714c861e5a 100644 --- a/api/@internal/component/ets/save_button.d.ts +++ b/api/@internal/component/ets/save_button.d.ts @@ -251,8 +251,7 @@ declare enum SaveDescription { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ SAVE_ALL = 12 } diff --git a/api/@internal/component/ets/scroll.d.ts b/api/@internal/component/ets/scroll.d.ts index 3121a855698354b3228e5b62bfd16268f7d2fb2f..b6f8b26cdfc73aec620aa9972d23262f15ee828a 100644 --- a/api/@internal/component/ets/scroll.d.ts +++ b/api/@internal/component/ets/scroll.d.ts @@ -18,12 +18,7 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { BarState, Edge, Color, EdgeEffect, ScrollSource ,Curve} from './enums' -import { ICurve, RectResult, ScrollableCommonMethod, EdgeEffectOptions, NestedScrollOptions,CommonMethod } from './common' -import { Dimension, Length, VoidCallback, Resource, LengthMetrics } from './units' -import { ScrollSnapAlign, ScrollState } from './list' -/*** endif */ + /** * Content scroll direction. @@ -47,8 +42,7 @@ import { ScrollSnapAlign, ScrollState } from './list' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ScrollDirection { /** @@ -70,8 +64,7 @@ declare enum ScrollDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Vertical, @@ -94,8 +87,7 @@ declare enum ScrollDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Horizontal, @@ -127,8 +119,7 @@ declare enum ScrollDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ None, } @@ -148,8 +139,7 @@ declare enum ScrollDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ScrollAlign { /** @@ -165,8 +155,7 @@ declare enum ScrollAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ START, @@ -183,8 +172,7 @@ declare enum ScrollAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CENTER, @@ -201,8 +189,7 @@ declare enum ScrollAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ END, @@ -219,8 +206,7 @@ declare enum ScrollAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ AUTO, } @@ -232,8 +218,7 @@ declare enum ScrollAlign { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface OffsetResult { /** @@ -243,8 +228,7 @@ declare interface OffsetResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ xOffset: number; @@ -255,8 +239,7 @@ declare interface OffsetResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ yOffset: number; } @@ -268,8 +251,7 @@ declare interface OffsetResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ScrollEdgeOptions { /** @@ -281,8 +263,7 @@ declare interface ScrollEdgeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ velocity?: number; } @@ -294,8 +275,7 @@ declare interface ScrollEdgeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ScrollToIndexOptions { /** @@ -305,8 +285,7 @@ declare interface ScrollToIndexOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ extraOffset?: LengthMetrics; } @@ -318,8 +297,7 @@ declare interface ScrollToIndexOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ScrollAnimationOptions { /** @@ -334,8 +312,7 @@ declare interface ScrollAnimationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ duration?: number; @@ -347,8 +324,7 @@ declare interface ScrollAnimationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ curve?: Curve | ICurve; @@ -365,8 +341,7 @@ declare interface ScrollAnimationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ canOverScroll?: boolean; } @@ -378,8 +353,7 @@ declare interface ScrollAnimationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface OffsetOptions { /** @@ -390,8 +364,7 @@ declare interface OffsetOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ xOffset?: Dimension; @@ -403,8 +376,7 @@ declare interface OffsetOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ yOffset?: Dimension; } @@ -474,8 +446,7 @@ declare interface UIScrollEvent extends UIScrollableCommonEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class Scroller { /** @@ -497,8 +468,7 @@ declare class Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -538,17 +508,6 @@ declare class Scroller { */ scrollTo(options: ScrollOptions); - /** - * Called when the setting slides to the specified position. - * - * @param { ScrollOptions } options - scroll options - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - scrollTo(options: ScrollOptions): void; /** * Called when scrolling to the edge of the container. @@ -588,18 +547,6 @@ declare class Scroller { */ scrollEdge(value: Edge, options?: ScrollEdgeOptions); - /** - * Called when scrolling to the edge of the container. - * - * @param { Edge } value - Edge type of the container. - * @param { ScrollEdgeOptions } [options] - Options of scrolling to edge. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - scrollEdge(value: Edge, options?: ScrollEdgeOptions): void; /** * Performs inertial scrolling based on the initial velocity passed in. @@ -616,8 +563,7 @@ declare class Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fling(velocity: number): void; @@ -655,18 +601,6 @@ declare class Scroller { * @since 14 */ scrollPage(value: ScrollPageOptions); - - /** - * Called when page turning mode is set. - * - * @param { ScrollPageOptions } value - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - scrollPage(value: ScrollPageOptions): void; /** * Scrolls to the next or previous page. @@ -700,8 +634,7 @@ declare class Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ currentOffset() : OffsetResult; @@ -754,7 +687,8 @@ declare class Scroller { *
Default value when the container is WaterFlow: ScrollAlign.START *
NOTE *
This parameter is only available for the List, Grid, and WaterFlow components. - * @param { ScrollToIndexOptions } [options] - Options for scrolling to a specified index, for example, an extra offset for the scroll.
Default value: 0, in vp + * @param { ScrollToIndexOptions } [options] - Options for scrolling to a specified index, + * for example, an extra offset for the scroll.
Default value: 0, in vp * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice @@ -762,21 +696,6 @@ declare class Scroller { */ scrollToIndex(value: number, smooth?: boolean, align?: ScrollAlign, options?: ScrollToIndexOptions); - /** - * Scroll to the specified index. - * - * @param { number } value - Index to jump to. - * @param { boolean } [smooth] - If true, scroll to index item with animation. If false, scroll to index item without animation. - * @param { ScrollAlign } [align] - Sets the alignment mode of a specified index. - * @param { ScrollToIndexOptions } [options] - Sets the options of a specified index, such as extra offset. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - scrollToIndex(value: number, smooth?: boolean, align?: ScrollAlign, options?: ScrollToIndexOptions): void; - /** * Called when the setting slides by offset. * @@ -810,19 +729,6 @@ declare class Scroller { */ scrollBy(dx: Length, dy: Length); - /** - * Called when the setting slides by offset. - * - * @param { Length } dx - * @param { Length } dy - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - scrollBy(dx: Length, dy: Length): void; - /** * Indicates whether the component scrolls to the end position. * @@ -842,8 +748,7 @@ declare class Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ isAtEnd(): boolean; @@ -881,8 +786,7 @@ declare class Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getItemRect(index: number): RectResult; @@ -904,8 +808,7 @@ declare class Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ getItemIndex(x: number, y: number): number; } @@ -917,8 +820,7 @@ declare class Scroller { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface ScrollOptions { /** @@ -954,8 +856,7 @@ declare interface ScrollOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ xOffset: number | string; @@ -992,8 +893,7 @@ declare interface ScrollOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ yOffset: number | string; @@ -1040,8 +940,7 @@ declare interface ScrollOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ animation?: ScrollAnimationOptions | boolean; @@ -1063,8 +962,7 @@ declare interface ScrollOptions { * @interface ScrollPageOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare interface ScrollPageOptions { /** @@ -1075,8 +973,7 @@ declare interface ScrollPageOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ next: boolean; @@ -1089,8 +986,7 @@ declare interface ScrollPageOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ animation?: boolean; } @@ -1108,8 +1004,7 @@ declare interface ScrollPageOptions { * @interface ScrollSnapOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ScrollSnapOptions { /** @@ -1126,8 +1021,7 @@ declare interface ScrollSnapOptions { * @default ScrollSnapAlign.NONE * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ snapAlign: ScrollSnapAlign; @@ -1157,8 +1051,7 @@ declare interface ScrollSnapOptions { * @default 100% * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ snapPagination?: Dimension | Array; @@ -1183,8 +1076,7 @@ declare interface ScrollSnapOptions { * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableSnapToStart?: boolean; @@ -1209,8 +1101,7 @@ declare interface ScrollSnapOptions { * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableSnapToEnd?: boolean; } @@ -1237,8 +1128,7 @@ declare interface ScrollSnapOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ScrollInterface { /** @@ -1266,8 +1156,7 @@ interface ScrollInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (scroller?: Scroller): ScrollAttribute; } @@ -1280,8 +1169,7 @@ interface ScrollInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnScrollEdgeCallback = (side: Edge) => void; @@ -1292,8 +1180,7 @@ declare type OnScrollEdgeCallback = (side: Edge) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface OnScrollFrameBeginHandlerResult { /** @@ -1328,8 +1215,7 @@ interface OnScrollFrameBeginHandlerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ offsetRemain: number; } @@ -1344,8 +1230,7 @@ interface OnScrollFrameBeginHandlerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnScrollFrameBeginCallback = (offset: number, state: ScrollState) => OnScrollFrameBeginHandlerResult; @@ -1371,8 +1256,7 @@ declare type OnScrollFrameBeginCallback = (offset: number, state: ScrollState) = * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ScrollAttribute extends ScrollableCommonMethod { /** @@ -1400,8 +1284,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scrollable(value: ScrollDirection): ScrollAttribute; @@ -1459,8 +1342,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillScroll(handler: ScrollOnWillScrollCallback): ScrollAttribute; @@ -1479,8 +1361,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidScroll(handler: ScrollOnScrollCallback): ScrollAttribute; @@ -1527,8 +1408,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onScrollEdge(event: OnScrollEdgeCallback): ScrollAttribute; @@ -1573,8 +1453,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onScrollStart(event: VoidCallback): ScrollAttribute; @@ -1636,8 +1515,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onScrollStop(event: VoidCallback): ScrollAttribute; @@ -1666,8 +1544,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scrollBar(barState: BarState): ScrollAttribute; @@ -1696,8 +1573,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scrollBarColor(color: Color | number | string): ScrollAttribute; @@ -1726,8 +1602,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scrollBarWidth(value: number | string): ScrollAttribute; @@ -1760,8 +1635,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ edgeEffect(edgeEffect: EdgeEffect, options?: EdgeEffectOptions): ScrollAttribute; @@ -1801,8 +1675,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onScrollFrameBegin(event: OnScrollFrameBeginCallback): ScrollAttribute; @@ -1824,8 +1697,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ nestedScroll(value: NestedScrollOptions): ScrollAttribute; @@ -1847,8 +1719,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableScrollInteraction(value: boolean): ScrollAttribute; @@ -1874,8 +1745,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ friction(value: number | Resource): ScrollAttribute; @@ -1894,8 +1764,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @returns { ScrollAttribute } the attribute of the scroll. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scrollSnap(value: ScrollSnapOptions): ScrollAttribute; @@ -1917,8 +1786,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enablePaging(value: boolean): ScrollAttribute; @@ -1932,8 +1800,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ initialOffset(value: OffsetOptions): ScrollAttribute; } @@ -1958,8 +1825,7 @@ declare class ScrollAttribute extends ScrollableCommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type ScrollOnScrollCallback = (xOffset: number, yOffset: number, scrollState: ScrollState) => void; @@ -1985,25 +1851,6 @@ declare type ScrollOnScrollCallback = (xOffset: number, yOffset: number, scrollS declare type ScrollOnWillScrollCallback = (xOffset: number, yOffset: number, scrollState: ScrollState, scrollSource: ScrollSource) => void | OffsetResult; - /** - * Called before scroll to allow developer to control real offset the Scroll can scroll. - * - * @typedef { function } ScrollOnWillScrollCallback - * @param { number } xOffset - horizontal offset this frame will scroll, which may or may not be reached. - * @param { number } yOffset - vertical offset this frame will scroll, which may or may not be reached. - * @param { ScrollState } scrollState - current scroll state. - * @param { ScrollSource } scrollSource - source of current scroll. - * @returns { undefined | OffsetResult } the remain offset for the Scroll, - * same as (xOffset, yOffset) when no OffsetResult is returned. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - declare type ScrollOnWillScrollCallback = - (xOffset: number, yOffset: number, scrollState: ScrollState, scrollSource: ScrollSource) => undefined | OffsetResult; - /** * Defines Scroll Component. * diff --git a/api/@internal/component/ets/scroll_bar.d.ts b/api/@internal/component/ets/scroll_bar.d.ts index 3dfc4cf07a7a1a060e01eb5872d9cce97e0a7736..abf91c99ac4f42d1dc457d6cc1ba1a59fd15b147 100644 --- a/api/@internal/component/ets/scroll_bar.d.ts +++ b/api/@internal/component/ets/scroll_bar.d.ts @@ -18,11 +18,7 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Scroller } from './scroll' -import { BarState } from './enums' -import { Optional, CommonMethod } from './common' -/*** endif */ + /** * Content scroll direction. @@ -46,8 +42,7 @@ import { Optional, CommonMethod } from './common' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ScrollBarDirection { /** @@ -69,8 +64,7 @@ declare enum ScrollBarDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Vertical, @@ -93,8 +87,7 @@ declare enum ScrollBarDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Horizontal, } @@ -121,8 +114,7 @@ declare enum ScrollBarDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ScrollBarOptions { /** @@ -147,8 +139,7 @@ declare interface ScrollBarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scroller: Scroller; @@ -174,8 +165,7 @@ declare interface ScrollBarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ direction?: ScrollBarDirection; @@ -201,8 +191,7 @@ declare interface ScrollBarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ state?: BarState; } @@ -229,8 +218,7 @@ declare interface ScrollBarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ScrollBarInterface { /** @@ -258,8 +246,7 @@ interface ScrollBarInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value: ScrollBarOptions): ScrollBarAttribute; } @@ -286,8 +273,7 @@ interface ScrollBarInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ScrollBarAttribute extends CommonMethod { /** @@ -297,8 +283,7 @@ declare class ScrollBarAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableNestedScroll(enabled: Optional): ScrollBarAttribute; diff --git a/api/@internal/component/ets/search.d.ts b/api/@internal/component/ets/search.d.ts index fd40d664b01ee0a23ae9cf097c0c0dc8b8d1d25c..ba0de091712c43217f1166333edb8bc774e3f163 100644 --- a/api/@internal/component/ets/search.d.ts +++ b/api/@internal/component/ets/search.d.ts @@ -18,18 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { TextContentControllerBase, SelectionOptions,Callback,CommonMethod,Optional,TextDecorationOptions, Bindable } from './common'; -import { CustomBuilder } from './builder'; -import { ResourceStr,Length,ResourceColor ,Dimension,Font} from './units'; -import { CaretStyle, EditableTextOnChangeCallback, InsertValue, DeleteValue, EditMenuOptions,KeyboardAppearance,EditableTextChangeValue,AutoCapitalizationMode } from './textCommon'; -import { EnterKeyType, OnTextSelectionChangeCallback, OnContentScrollCallback, OnPasteCallback, SubmitEvent } from './textInput'; -import { CopyOptions,TextAlign } from './enums'; -import { KeyboardOptions } from './richEditor'; -import { Resource } from '../../global/resource'; -import { SymbolGlyphModifier } from '../SymbolGlyphModifier'; -/*** endif */ - /** * Provides the method of switching the cursor position. * @@ -52,8 +40,7 @@ import { SymbolGlyphModifier } from '../SymbolGlyphModifier'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class SearchController extends TextContentControllerBase { /** @@ -76,8 +63,7 @@ declare class SearchController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -103,8 +89,7 @@ declare class SearchController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ caretPosition(value: number): void; @@ -121,8 +106,7 @@ declare class SearchController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ stopEditing(): void; @@ -149,8 +133,7 @@ declare class SearchController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setTextSelection(selectionStart: number, selectionEnd: number, options?: SelectionOptions): void; } @@ -170,8 +153,7 @@ declare class SearchController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum CancelButtonStyle { /** @@ -187,8 +169,7 @@ declare enum CancelButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CONSTANT, @@ -205,8 +186,7 @@ declare enum CancelButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ INVISIBLE, @@ -223,8 +203,7 @@ declare enum CancelButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ INPUT } @@ -244,8 +223,7 @@ declare enum CancelButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum SearchType { /** @@ -261,8 +239,7 @@ declare enum SearchType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NORMAL = 0, @@ -279,8 +256,7 @@ declare enum SearchType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NUMBER = 2, @@ -298,8 +274,7 @@ declare enum SearchType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PHONE_NUMBER = 3, @@ -317,8 +292,7 @@ declare enum SearchType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ EMAIL = 5, @@ -328,8 +302,7 @@ declare enum SearchType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NUMBER_DECIMAL = 12, @@ -339,8 +312,7 @@ declare enum SearchType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ URL = 13, @@ -362,8 +334,7 @@ declare enum SearchType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface SearchOptions { /** @@ -406,17 +377,6 @@ declare interface SearchOptions { */ value?: ResourceStr; - /** - * Text input in the search text box. - * - * @type { ?(string | Bindable)} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - value?: string | Bindable; - /** * Text displayed when there is no input. * @@ -446,8 +406,7 @@ declare interface SearchOptions { * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ placeholder?: ResourceStr; @@ -484,8 +443,7 @@ declare interface SearchOptions { * @type { ?string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ icon?: string; @@ -511,8 +469,7 @@ declare interface SearchOptions { * @type { ?SearchController } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ controller?: SearchController; } @@ -539,8 +496,7 @@ declare interface SearchOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface SearchInterface { /** @@ -579,8 +535,7 @@ interface SearchInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: SearchOptions): SearchAttribute; } @@ -600,8 +555,7 @@ interface SearchInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface IconOptions { /** @@ -623,8 +577,7 @@ interface IconOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ size?: Length; @@ -643,8 +596,7 @@ interface IconOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ color?: ResourceColor; @@ -663,8 +615,7 @@ interface IconOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ src?: ResourceStr; } @@ -684,8 +635,7 @@ interface IconOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface SearchButtonOptions { /** @@ -707,8 +657,7 @@ interface SearchButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize?: Length; @@ -727,8 +676,7 @@ interface SearchButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor?: ResourceColor; @@ -745,8 +693,7 @@ interface SearchButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ autoDisable?: Boolean; } @@ -758,8 +705,7 @@ interface SearchButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface CancelButtonOptions { /** @@ -770,8 +716,7 @@ interface CancelButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style?: CancelButtonStyle; @@ -783,8 +728,7 @@ interface CancelButtonOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ icon?: IconOptions; } @@ -805,7 +749,6 @@ interface CancelButtonOptions { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ interface CancelButtonSymbolOptions { /** @@ -815,8 +758,7 @@ interface CancelButtonSymbolOptions { * @type { ?CancelButtonStyle } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style?: CancelButtonStyle; @@ -838,7 +780,6 @@ interface CancelButtonSymbolOptions { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ icon?: SymbolGlyphModifier; } @@ -852,8 +793,7 @@ interface CancelButtonSymbolOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare type SearchSubmitCallback = (searchContent: string, event?: SubmitEvent) => void; @@ -879,8 +819,7 @@ declare type SearchSubmitCallback = (searchContent: string, event?: SubmitEvent) * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class SearchAttribute extends CommonMethod { /** @@ -929,7 +868,6 @@ declare class SearchAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ searchButton(value: ResourceStr, option?: SearchButtonOptions): SearchAttribute; @@ -954,8 +892,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): SearchAttribute; @@ -1006,8 +943,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ searchIcon(value: IconOptions | SymbolGlyphModifier): SearchAttribute; @@ -1054,8 +990,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ cancelButton(value: CancelButtonOptions | CancelButtonSymbolOptions): SearchAttribute; @@ -1067,8 +1002,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textIndent(value: Dimension): SearchAttribute; @@ -1089,8 +1023,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ inputFilter(value: ResourceStr, error?: Callback): SearchAttribute; @@ -1103,8 +1036,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onEditChange(callback: Callback): SearchAttribute; @@ -1120,8 +1052,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ selectedBackgroundColor(value: ResourceColor): SearchAttribute; @@ -1153,8 +1084,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ caretStyle(value: CaretStyle): SearchAttribute; @@ -1183,8 +1113,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ placeholderColor(value: ResourceColor): SearchAttribute; @@ -1218,8 +1147,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ placeholderFont(value?: Font): SearchAttribute; @@ -1253,8 +1181,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textFont(value?: Font): SearchAttribute; @@ -1266,8 +1193,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enterKeyType(value: EnterKeyType): SearchAttribute; @@ -1323,19 +1249,6 @@ declare class SearchAttribute extends CommonMethod { */ onSubmit(callback: SearchSubmitCallback): SearchAttribute; - /** - * Call the function when clicked the search button. - * - * @param { Callback | SearchSubmitCallback } callback - callback of the listened event. - * @returns { SearchAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onSubmit(callback: Callback | SearchSubmitCallback): SearchAttribute; - /** * Call the function when editing the input text * @@ -1376,8 +1289,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onChange(callback: EditableTextOnChangeCallback): SearchAttribute; @@ -1409,8 +1321,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onTextSelectionChange(callback: OnTextSelectionChangeCallback): SearchAttribute; @@ -1442,8 +1353,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onContentScroll(callback: OnContentScrollCallback): SearchAttribute; @@ -1483,8 +1393,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onCopy(callback: Callback): SearchAttribute; @@ -1524,8 +1433,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onCut(callback: Callback): SearchAttribute; @@ -1568,8 +1476,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onPaste(callback: OnPasteCallback): SearchAttribute; @@ -1604,8 +1511,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ copyOption(value: CopyOptions): SearchAttribute; @@ -1645,7 +1551,6 @@ declare class SearchAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ maxLength(value: number): SearchAttribute; @@ -1678,8 +1583,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textAlign(value: TextAlign): SearchAttribute; @@ -1704,8 +1608,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableKeyboardOnFocus(value: boolean): SearchAttribute; @@ -1733,8 +1636,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectionMenuHidden(value: boolean): SearchAttribute; @@ -1752,8 +1654,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ minFontSize(value: number | string | Resource): SearchAttribute; @@ -1771,8 +1672,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ maxFontSize(value: number | string | Resource): SearchAttribute; @@ -1810,7 +1710,6 @@ declare class SearchAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ minFontScale(scale: Optional): SearchAttribute; @@ -1846,7 +1745,6 @@ declare class SearchAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ maxFontScale(scale: Optional): SearchAttribute; @@ -1891,8 +1789,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ customKeyboard(value: CustomBuilder, options?: KeyboardOptions): SearchAttribute; @@ -1904,8 +1801,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ decoration(value: TextDecorationOptions): SearchAttribute; @@ -1924,8 +1820,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ letterSpacing(value: number | string | Resource): SearchAttribute; @@ -1942,8 +1837,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineHeight(value: number | string | Resource): SearchAttribute; @@ -1964,8 +1858,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type(value: SearchType): SearchAttribute; @@ -1981,8 +1874,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontFeature(value: string): SearchAttribute; @@ -2000,8 +1892,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillInsert(callback: Callback): SearchAttribute; @@ -2017,8 +1908,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidInsert(callback: Callback): SearchAttribute; @@ -2036,8 +1926,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillDelete(callback: Callback): SearchAttribute; @@ -2053,8 +1942,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidDelete(callback: Callback): SearchAttribute; @@ -2080,8 +1968,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ editMenuOptions(editMenu: EditMenuOptions): SearchAttribute; @@ -2098,8 +1985,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enablePreviewText(enable: boolean): SearchAttribute; @@ -2123,8 +2009,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ enableHapticFeedback(isEnabled: boolean): SearchAttribute; @@ -2137,7 +2022,6 @@ declare class SearchAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ autoCapitalizationMode(mode: AutoCapitalizationMode): SearchAttribute; @@ -2149,8 +2033,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ halfLeading(halfLeading: Optional): SearchAttribute; @@ -2161,8 +2044,7 @@ declare class SearchAttribute extends CommonMethod { * @returns { SearchAttribute } returns the instance of the SearchAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ stopBackPress(isStopped: Optional): SearchAttribute; @@ -2179,8 +2061,7 @@ declare class SearchAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ onWillChange(callback: Callback): SearchAttribute; @@ -2191,8 +2072,7 @@ declare class SearchAttribute extends CommonMethod { * @returns { SearchAttribute } returns the instance of the SearchAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ keyboardAppearance(appearance: Optional): SearchAttribute; diff --git a/api/@internal/component/ets/select.d.ts b/api/@internal/component/ets/select.d.ts index d465cbfba78f9d1bb8416db7a4cbea5fb336ecad..db81363b3862942e95f3f8aa11ee5fd61b678ceb 100644 --- a/api/@internal/component/ets/select.d.ts +++ b/api/@internal/component/ets/select.d.ts @@ -18,16 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonConfiguration, CommonMethod, ContentModifier, Optional, BlurStyle, Bindable } from './common'; -import { ControlSize } from './button'; -import { DividerOptions } from './textPicker'; -import { ResourceStr, Dimension, EdgeOutlineWidths, ResourceColor, EdgeColors, Resource, Font, Length, Offset, DividerStyleOptions } from './units'; -import { SymbolGlyphModifier } from '../SymbolGlyphModifier'; -import { TextModifier } from '../TextModifier'; -import { OptionWidthMode } from './enums'; -/*** endif */ - /** * The declare of selectOption. * @@ -50,8 +40,8 @@ import { OptionWidthMode } from './enums'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare interface SelectOption { /** @@ -76,8 +66,7 @@ declare interface SelectOption { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value: ResourceStr; @@ -103,8 +92,7 @@ declare interface SelectOption { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ icon?: ResourceStr; @@ -124,7 +112,6 @@ declare interface SelectOption { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ symbolIcon?: SymbolGlyphModifier; } @@ -151,8 +138,8 @@ declare interface SelectOption { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface SelectInterface { /** @@ -180,8 +167,7 @@ interface SelectInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options: Array): SelectAttribute; } @@ -201,8 +187,7 @@ interface SelectInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ArrowPosition { /** @@ -218,8 +203,7 @@ declare enum ArrowPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ END = 0, @@ -236,8 +220,7 @@ declare enum ArrowPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ START = 1 } @@ -256,8 +239,7 @@ declare enum ArrowPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum MenuAlignType { /** @@ -272,8 +254,7 @@ declare enum MenuAlignType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ START, /** @@ -288,8 +269,7 @@ declare enum MenuAlignType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ CENTER, /** @@ -304,8 +284,7 @@ declare enum MenuAlignType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ END } @@ -316,8 +295,7 @@ declare enum MenuAlignType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare enum AvoidanceMode { /** @@ -326,8 +304,7 @@ declare enum AvoidanceMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ COVER_TARGET, /** @@ -336,8 +313,7 @@ declare enum AvoidanceMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ AVOID_AROUND_TARGET } @@ -351,8 +327,7 @@ declare enum AvoidanceMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnSelectCallback = (index: number, selectStr: string) => void; @@ -364,7 +339,6 @@ declare type OnSelectCallback = (index: number, selectStr: string) => void; * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ declare interface MenuOutlineOptions { /** @@ -375,7 +349,6 @@ declare interface MenuOutlineOptions { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ width?: Dimension | EdgeOutlineWidths; @@ -387,7 +360,6 @@ declare interface MenuOutlineOptions { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ color?: ResourceColor | EdgeColors; } @@ -414,8 +386,8 @@ declare interface MenuOutlineOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class SelectAttribute extends CommonMethod { /** @@ -459,19 +431,6 @@ declare class SelectAttribute extends CommonMethod { */ selected(numCount: Optional): SelectAttribute; - /** - * Sets the serial number of the select item, starting from 0. - * - * @param { number | Resource | undefined | Bindable | Bindable } numCount - the serial number of the select item. - * @returns { SelectAttribute } the attribute of the select. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected(numCount: number | Resource | undefined | Bindable | Bindable): SelectAttribute; - /** * Sets the text display of the select button itself. @@ -514,19 +473,6 @@ declare class SelectAttribute extends CommonMethod { */ value(resStr: Optional): SelectAttribute; - /** - * Sets the text display of the select button itself. - * - * @param { ResourceStr | undefined | Bindable | Bindable } resStr - the text display of the select button itself. - * @returns { SelectAttribute } the attribute of the select. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - value(resStr: ResourceStr | undefined | Bindable | Bindable): SelectAttribute; - /** * Sets the text properties of the select button itself. * @@ -552,8 +498,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ font(value: Font): SelectAttribute; @@ -565,8 +510,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ font(selectFont: Optional): SelectAttribute; @@ -595,8 +539,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): SelectAttribute; @@ -608,8 +551,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ fontColor(resColor: Optional): SelectAttribute; @@ -638,8 +580,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedOptionBgColor(value: ResourceColor): SelectAttribute; @@ -651,8 +592,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ selectedOptionBgColor(resColor: Optional): SelectAttribute; @@ -681,8 +621,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedOptionFont(value: Font): SelectAttribute; @@ -694,8 +633,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ selectedOptionFont(selectFont: Optional): SelectAttribute; @@ -724,8 +662,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedOptionFontColor(value: ResourceColor): SelectAttribute; @@ -737,8 +674,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ selectedOptionFontColor(resColor: Optional): SelectAttribute; @@ -767,8 +703,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ optionBgColor(value: ResourceColor): SelectAttribute; @@ -780,8 +715,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ optionBgColor(resColor: Optional): SelectAttribute; @@ -810,8 +744,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ optionFont(value: Font): SelectAttribute; @@ -823,8 +756,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ optionFont(selectFont: Optional): SelectAttribute; @@ -853,8 +785,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ optionFontColor(value: ResourceColor): SelectAttribute; @@ -866,8 +797,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ optionFontColor(resColor: Optional): SelectAttribute; @@ -908,8 +838,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onSelect(callback: Optional): SelectAttribute; @@ -930,8 +859,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ space(value: Length): SelectAttribute; @@ -943,8 +871,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ space(spaceLength: Optional): SelectAttribute; @@ -965,8 +892,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ arrowPosition(value: ArrowPosition): SelectAttribute; @@ -978,8 +904,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ arrowPosition(position: Optional): SelectAttribute; @@ -1001,8 +926,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ menuAlign(alignType: MenuAlignType, offset?: Offset): SelectAttribute; @@ -1015,8 +939,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ menuAlign(alignType: Optional, offset?: Offset): SelectAttribute; @@ -1037,8 +960,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ optionWidth(value: Dimension | OptionWidthMode ): SelectAttribute; @@ -1050,8 +972,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ optionWidth(width: Optional ): SelectAttribute; @@ -1072,8 +993,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ optionHeight(value: Dimension): SelectAttribute; @@ -1085,8 +1005,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ optionHeight(height: Optional): SelectAttribute; @@ -1107,8 +1026,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ menuBackgroundColor(value: ResourceColor): SelectAttribute; @@ -1120,8 +1038,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ menuBackgroundColor(resColor: Optional): SelectAttribute; @@ -1142,8 +1059,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ menuBackgroundBlurStyle(value: BlurStyle): SelectAttribute; @@ -1155,8 +1071,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ menuBackgroundBlurStyle(style: Optional): SelectAttribute; @@ -1168,8 +1083,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ controlSize(value: ControlSize): SelectAttribute; @@ -1181,8 +1095,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ controlSize(size: Optional): SelectAttribute; @@ -1194,8 +1107,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ menuItemContentModifier(modifier: ContentModifier): SelectAttribute; @@ -1207,8 +1119,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ menuItemContentModifier(modifier: Optional>): SelectAttribute; @@ -1220,8 +1131,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ divider(options: Optional | null): SelectAttribute; @@ -1234,7 +1144,6 @@ declare class SelectAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ textModifier(modifier: Optional): SelectAttribute; @@ -1247,7 +1156,6 @@ declare class SelectAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ arrowModifier(modifier: Optional): SelectAttribute; @@ -1260,7 +1168,6 @@ declare class SelectAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ optionTextModifier(modifier: Optional): SelectAttribute; @@ -1273,7 +1180,6 @@ declare class SelectAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ selectedOptionTextModifier(modifier: Optional): SelectAttribute; @@ -1285,8 +1191,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ dividerStyle(style: Optional): SelectAttribute; @@ -1298,8 +1203,7 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ avoidance(mode: AvoidanceMode): SelectAttribute; @@ -1312,10 +1216,9 @@ declare class SelectAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ menuOutline(outline: MenuOutlineOptions): SelectAttribute; - + /** * Sets whether to display in the sub window. * @@ -1328,6 +1231,7 @@ declare class SelectAttribute extends CommonMethod { */ showInSubWindow(showInSubWindow: Optional): SelectAttribute; + /** * Set whether to display the default selected icon * @@ -1349,8 +1253,8 @@ declare class SelectAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 + * @noninterop */ declare interface MenuItemConfiguration extends CommonConfiguration{ /** @@ -1360,8 +1264,7 @@ declare interface MenuItemConfiguration extends CommonConfiguration { /** @@ -470,8 +457,7 @@ declare class ShapeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ viewPort(value: ViewportRect): ShapeAttribute; @@ -511,8 +497,7 @@ declare class ShapeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ stroke(value: ResourceColor): ShapeAttribute; @@ -552,8 +537,7 @@ declare class ShapeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fill(value: ResourceColor): ShapeAttribute; @@ -587,7 +571,7 @@ declare class ShapeAttribute extends CommonMethod { /** * Called when the offset of the starting point of border drawing is set. * - * @param { Length } value + * @param { number | string } value * @returns { ShapeAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -605,7 +589,6 @@ declare class ShapeAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ strokeDashOffset(value: Length): ShapeAttribute; @@ -649,20 +632,6 @@ declare class ShapeAttribute extends CommonMethod { */ strokeDashArray(value: Array): ShapeAttribute; - /** - * Called when the gap of the border is set. - * - * @param { Array } value - * @returns { ShapeAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - strokeDashArray(value: Array): ShapeAttribute; - /** * Called when the path endpoint drawing style is set. * @@ -699,8 +668,7 @@ declare class ShapeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeLineCap(value: LineCapStyle): ShapeAttribute; @@ -740,8 +708,7 @@ declare class ShapeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeLineJoin(value: LineJoinStyle): ShapeAttribute; @@ -775,7 +742,7 @@ declare class ShapeAttribute extends CommonMethod { /** * Called when the limit value for drawing acute angles as oblique angles is set. * - * @param { Length } value + * @param { number | string } value * @returns { ShapeAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -793,7 +760,6 @@ declare class ShapeAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ strokeMiterLimit(value: Length): ShapeAttribute; @@ -833,8 +799,7 @@ declare class ShapeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeOpacity(value: number | string | Resource): ShapeAttribute; @@ -874,8 +839,7 @@ declare class ShapeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fillOpacity(value: number | string | Resource): ShapeAttribute; @@ -909,7 +873,7 @@ declare class ShapeAttribute extends CommonMethod { /** * Called when the width of the border is set. * - * @param { Length } value + * @param { number | string } value * @returns { ShapeAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -927,7 +891,6 @@ declare class ShapeAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ strokeWidth(value: Length): ShapeAttribute; @@ -967,8 +930,7 @@ declare class ShapeAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ antiAlias(value: boolean): ShapeAttribute; @@ -1019,22 +981,6 @@ declare class ShapeAttribute extends CommonMethod { * @since 11 */ mesh(value: Array, column: number, row: number): ShapeAttribute; - - /** - * Called when shape mesh. - * - * @param { Array } value - * @param { number } column - * @param { number } row - * @returns { ShapeAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - mesh(value: Array, column: number, row: number): ShapeAttribute; } /** @@ -1100,29 +1046,3 @@ declare const Shape: ShapeInterface; * @since 11 */ declare const ShapeInstance: ShapeAttribute; - -/** - * Provides interfaces for drawing components. - * - * @interface ShapeInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface ShapeInterface { - /** - * Shape component constructor. - * - * @param { PixelMap } [value] - PixelMap object to draw. - * @returns { ShapeAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (value?: PixelMap): ShapeAttribute; -} diff --git a/api/@internal/component/ets/sidebar.d.ts b/api/@internal/component/ets/sidebar.d.ts index d60a3cd1455c426a29e2e68347219c4b36c21797..2add0dfbfbbcca9f830764dbe1954a03bc436629 100644 --- a/api/@internal/component/ets/sidebar.d.ts +++ b/api/@internal/component/ets/sidebar.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from '../../global/resource' -import { Length, ResourceColor, Dimension } from './units' -import { CommonMethod, PixelMap, Bindable } from './common' -/*** endif */ - /** * Sets the sidebar style of showing * @@ -46,8 +40,7 @@ import { CommonMethod, PixelMap, Bindable } from './common' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SideBarContainerType { /** @@ -69,8 +62,7 @@ declare enum SideBarContainerType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Embed, @@ -93,8 +85,7 @@ declare enum SideBarContainerType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Overlay, @@ -109,8 +100,7 @@ declare enum SideBarContainerType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ AUTO, } @@ -137,8 +127,7 @@ declare enum SideBarContainerType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SideBarPosition { /** @@ -160,8 +149,7 @@ declare enum SideBarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Start, @@ -184,8 +172,7 @@ declare enum SideBarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ End, } @@ -197,8 +184,7 @@ declare enum SideBarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface ButtonIconOptions { /** @@ -233,8 +219,7 @@ declare interface ButtonIconOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ shown: string | PixelMap | Resource; @@ -270,8 +255,7 @@ declare interface ButtonIconOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ hidden: string | PixelMap | Resource; @@ -307,8 +291,7 @@ declare interface ButtonIconOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ switching?: string | PixelMap | Resource; } @@ -335,8 +318,7 @@ declare interface ButtonIconOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ButtonStyle { /** @@ -364,8 +346,7 @@ declare interface ButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ left?: number; @@ -394,8 +375,7 @@ declare interface ButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ top?: number; @@ -424,8 +404,7 @@ declare interface ButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ width?: number; @@ -454,8 +433,7 @@ declare interface ButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ height?: number; @@ -491,8 +469,7 @@ declare interface ButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ icons?: ButtonIconOptions; } @@ -519,8 +496,8 @@ declare interface ButtonStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface SideBarContainerInterface { /** @@ -548,8 +525,7 @@ interface SideBarContainerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (type?: SideBarContainerType): SideBarContainerAttribute; } @@ -571,8 +547,7 @@ interface SideBarContainerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface DividerStyle { /** @@ -592,8 +567,7 @@ interface DividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth: Length; @@ -612,8 +586,7 @@ interface DividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ color?: ResourceColor; @@ -632,8 +605,7 @@ interface DividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ startMargin?: Length; @@ -652,8 +624,7 @@ interface DividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ endMargin?: Length; } @@ -680,8 +651,8 @@ interface DividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class SideBarContainerAttribute extends CommonMethod { /** @@ -713,19 +684,6 @@ declare class SideBarContainerAttribute extends CommonMethod } value - * @returns { SideBarContainerAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - showSideBar(value: boolean | Bindable): SideBarContainerAttribute; - /** * Callback controlButton function when setting the style of button * @@ -751,8 +709,7 @@ declare class SideBarContainerAttribute extends CommonMethod void): SideBarContainerAttribute; @@ -848,20 +803,6 @@ declare class SideBarContainerAttribute extends CommonMethod } value - * @returns { SideBarContainerAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - sideBarWidth(value: number | Bindable): SideBarContainerAttribute; - /** * Sets the min length of sidebar. * default value is 200vp. @@ -890,8 +831,7 @@ declare class SideBarContainerAttribute extends CommonMethodNOTE: - *
The trigger occurs when an invalid value is restored to the default value, that is, when the value is set to - * less than min or greater than max. - *

- * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - End, - - /** - * Click the slider. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Click the slider. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Click the slider. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * The user moves the thumb by touching or clicking the track. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - Click, + /** + * Start dragging the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Start dragging the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Start dragging the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * The user touches or clicks the thumb. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + Begin, + /** + * Drag the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Drag the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Drag the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * The user is dragging the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + Moving, + /** + * End dragging the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * End dragging the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * End dragging the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * The user stops dragging the slider by lifting their finger or releasing the mouse device. + *

NOTE: + *
The trigger occurs when an invalid value is restored to the default value, that is, when the value is set to + * less than min or greater than max. + *

+ * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + End, + /** + * Click the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 8 + */ + /** + * Click the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Click the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * The user moves the thumb by touching or clicking the track. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + Click } - /** * Interaction mode between the user and the slider. * @@ -324,46 +295,39 @@ declare enum SliderChangeMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum SliderInteraction { - /** - * Users can drag the slider or touch the track to move the slider. The slider moves as soon as the mouse or - * finger is pressed. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - SLIDE_AND_CLICK, - - /** - * Users are not allowed to move the slider by touching the slider. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - SLIDE_ONLY, - - /** - * Users can drag the slider or touch the track to move the slider. The slider moves when the mouse is released or - * finger is lifted, if the release/lift position coincides with the screen press position. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - SLIDE_AND_CLICK_UP = 2 + /** + * Users can drag the slider or touch the track to move the slider. The slider moves as soon as the mouse or + * finger is pressed. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + SLIDE_AND_CLICK = 0, + /** + * Users are not allowed to move the slider by touching the slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + SLIDE_ONLY = 1, + /** + * Users can drag the slider or touch the track to move the slider. The slider moves when the mouse is released or + * finger is lifted, if the release/lift position coincides with the screen press position. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + SLIDE_AND_CLICK_UP = 2 } - /** * Defines the callback type used in SlideRange. *

NOTE: @@ -381,35 +345,30 @@ declare enum SliderInteraction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface SlideRange { - /** - * Start of the slide range. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - from?: number; - - /** - * End of the slide range. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - to?: number; + /** + * Start of the slide range. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + from?: number; + /** + * End of the slide range. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + to?: number; } - /** * Defines the options of Slider. * @@ -442,298 +401,271 @@ declare interface SlideRange { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface SliderOptions { - /** - * Current value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Current value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Current value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Current progress. - * - * @type { ?number } - * @default same as the value of min - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 11 - */ - value?: number; - - /** - * Current value of Slider. - * - * @type { ?(number| undefined | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - value?: number | undefined | Bindable; - - /** - * Sets the min value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Sets the min value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Sets the min value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Minimum value. - * - * @type { ?number } - * @default 0 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - min?: number; - - /** - * Sets the max value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Sets the max value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Sets the max value of Slider. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Maximum value. - *

NOTE: - *
If the value of min is greater than or equal to the value of max, the min value defaults to 0, and the max - * value defaults to 100. If the value is not within the [min, max] range, the value of min or max is used, whichever - * is closer. - *

- * - * @type { ?number } - * @default 100 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - max?: number; - - /** - * Sets the step of each slide value. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Sets the step of each slide value. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Sets the step of each slide value. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Step of the slider. - *

NOTE: - *
If this parameter is set to a value less than 0 or greater than the value of max, the default value is used. - *

- * - * @type { ?number } - * @default 1 - Value range: [0.01, max - min] - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - step?: number; - - /** - * Sets the slider style. - * - * @type { ?SliderStyle } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Sets the slider style. - * - * @type { ?SliderStyle } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Sets the slider style. - * - * @type { ?SliderStyle } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Style of the slider thumb and track. - * - * @type { ?SliderStyle } - * @default SliderStyle.OutSet - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - style?: SliderStyle; - - /** - * Sets the slider direction style. - * - * @type { ?Axis } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Sets the slider direction style. - * - * @type { ?Axis } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Sets the slider direction style. - * - * @type { ?Axis } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Whether the slider moves horizontally or vertically. - * - * @type { ?Axis } - * @default Axis.Horizontal - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - direction?: Axis; - - /** - * Set whether the direction of the slider needs to be reversed. - * - * @type { ?boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Set whether the direction of the slider needs to be reversed. - * - * @type { ?boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Set whether the direction of the slider needs to be reversed. - * - * @type { ?boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Whether the slider values are reversed. By default, the values increase from left to right for a horizontal - * slider and from top to bottom for a vertical slider. - * - * @type { ?boolean } - * @default false - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - reverse?: boolean; + /** + * Current value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Current value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Current value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Current progress. + * + * @type { ?number } + * @default same as the value of min + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + value?: number; + /** + * Sets the min value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Sets the min value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Sets the min value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Minimum value. + * + * @type { ?number } + * @default 0 + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + min?: number; + /** + * Sets the max value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Sets the max value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Sets the max value of Slider. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Maximum value. + *

NOTE: + *
If the value of min is greater than or equal to the value of max, the min value defaults to 0, and the max + * value defaults to 100. If the value is not within the [min, max] range, the value of min or max is used, whichever + * is closer. + *

+ * + * @type { ?number } + * @default 100 + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + max?: number; + /** + * Sets the step of each slide value. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Sets the step of each slide value. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Sets the step of each slide value. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Step of the slider. + *

NOTE: + *
If this parameter is set to a value less than 0 or greater than the value of max, the default value is used. + *

+ * + * @type { ?number } + * @default 1 - Value range: [0.01, max - min] + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + step?: number; + /** + * Sets the slider style. + * + * @type { ?SliderStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Sets the slider style. + * + * @type { ?SliderStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Sets the slider style. + * + * @type { ?SliderStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Style of the slider thumb and track. + * + * @type { ?SliderStyle } + * @default SliderStyle.OutSet + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + style?: SliderStyle; + /** + * Sets the slider direction style. + * + * @type { ?Axis } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 8 + */ + /** + * Sets the slider direction style. + * + * @type { ?Axis } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Sets the slider direction style. + * + * @type { ?Axis } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Whether the slider moves horizontally or vertically. + * + * @type { ?Axis } + * @default Axis.Horizontal + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + direction?: Axis; + /** + * Set whether the direction of the slider needs to be reversed. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 8 + */ + /** + * Set whether the direction of the slider needs to be reversed. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Set whether the direction of the slider needs to be reversed. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Whether the slider values are reversed. By default, the values increase from left to right for a horizontal + * slider and from top to bottom for a vertical slider. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + reverse?: boolean; } - /** * Declare SliderBlockType * @@ -749,65 +681,58 @@ declare interface SliderOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SliderBlockType { - /** - * Use the default block. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Round slider. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - DEFAULT, - - /** - * Use an image as the slider block. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Slider with an image background. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - IMAGE, - - /** - * Use a shape as the slider block. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Slider in a custom shape. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - SHAPE, + /** + * Use the default block. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Round slider. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + DEFAULT = 0, + /** + * Use an image as the slider block. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Slider with an image background. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + IMAGE = 1, + /** + * Use a shape as the slider block. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Slider in a custom shape. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + SHAPE = 2 } - /** * Defines the style of slider block. * @@ -823,87 +748,78 @@ declare enum SliderBlockType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface SliderBlockStyle { - /** - * Sets the type of slider block. - * - * @type { SliderBlockType } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Type of the slider in the block direction. - * - * @type { SliderBlockType } - * @default SliderBlockType.DEFAULT - indicating the round slider. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - type: SliderBlockType; - - /** - * Sets the image of slider block while the type is set to SliderBlockType.Image. - * - * @type { ?ResourceStr } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Image resource of the slider. The area size for displaying the image is subject to the blockSize attribute. - * Be mindful of the image size when selecting an image. - * - * @type { ?ResourceStr } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - image?: ResourceStr; - - /** - * Sets the shape of slider block while the type is set to SliderBlockType.Shape. - * - * @type { ?(CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Custom shape of the slider. - * - * @type { ?(CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - shape?: CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute; + /** + * Sets the type of slider block. + * + * @type { SliderBlockType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Type of the slider in the block direction. + * + * @type { SliderBlockType } + * @default SliderBlockType.DEFAULT - indicating the round slider. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + type: SliderBlockType; + /** + * Sets the image of slider block while the type is set to SliderBlockType.Image. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Image resource of the slider. The area size for displaying the image is subject to the blockSize attribute. + * Be mindful of the image size when selecting an image. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + image?: ResourceStr; + /** + * Sets the shape of slider block while the type is set to SliderBlockType.Shape. + * + * @type { ?(CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Custom shape of the slider. + * + * @type { ?(CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + shape?: CircleAttribute | EllipseAttribute | PathAttribute | RectAttribute; } - /** * Defines the callback type used in SliderConfiguration. * - * @typedef {function} SliderTriggerChangeCallback + * @typedef {function} SliderTriggerChangeCallback * @param { number } value - Current progress. * @param { SliderChangeMode } mode - State triggered by the event. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type SliderTriggerChangeCallback = (value: number, mode: SliderChangeMode) => void; - /** * You need a custom class to implement the ContentModifier API. * @@ -912,71 +828,60 @@ declare type SliderTriggerChangeCallback = (value: number, mode: SliderChangeMod * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface SliderConfiguration extends CommonConfiguration { - /** - * Current progress. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - value: number; - - /** - * Minimum value. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - min: number; - - /** - * Maximum value. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - max: number; - - /** - * Step of the slider. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - step: number; - - /** - * Triggers slider changes. - * - * @type { SliderTriggerChangeCallback } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - triggerChange: SliderTriggerChangeCallback; + /** + * Current progress. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + value: number; + /** + * Minimum value. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + min: number; + /** + * Maximum value. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + max: number; + /** + * Step of the slider. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + step: number; + /** + * Triggers slider changes. + * + * @type { SliderTriggerChangeCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + triggerChange: SliderTriggerChangeCallback; } - /** * Provides an interface for the slide bar component. * @@ -1009,52 +914,92 @@ declare interface SliderConfiguration extends CommonConfiguration } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + stepsAccessibility?: Map; } - /** * Defines the options for customizing the accessibility of content within a slider. * These options can be used to enhance the user experience for assistive technologies. @@ -1066,54 +1011,50 @@ interface SliderInterface { * @since 20 */ interface SliderCustomContentOptions { - /** - * The text used for accessibility purposes. This text will be read by screen readers - * to provide a more descriptive label for the slider content. - * - * @type { ?ResourceStr } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - accessibilityText?: ResourceStr; - - /** - * A more detailed description for accessibility. This can provide additional context - * about the slider content for users relying on assistive technologies. - * - * @type { ?ResourceStr } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - accessibilityDescription?: ResourceStr; - - /** - * The accessibility level of the slider content. This could be used to indicate the importance - * or priority of the content for assistive technologies. - * - * @type { ?string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - accessibilityLevel?: string; - - /** - * Indicates whether the slider content should be treated as an accessibility group. - * - * @type { ?boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - accessibilityGroup?: boolean; + /** + * The text used for accessibility purposes. This text will be read by screen readers + * to provide a more descriptive label for the slider content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + accessibilityText?: ResourceStr; + /** + * A more detailed description for accessibility. This can provide additional context + * about the slider content for users relying on assistive technologies. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + accessibilityDescription?: ResourceStr; + /** + * The accessibility level of the slider content. This could be used to indicate the importance + * or priority of the content for assistive technologies. + * + * @type { ?string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + accessibilityLevel?: string; + /** + * Indicates whether the slider content should be treated as an accessibility group. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + accessibilityGroup?: boolean; } - /** * Options used for customizing the prefix part of the slider. * It extends the SliderCustomContentOptions to inherit accessibility customization options. @@ -1127,7 +1068,6 @@ interface SliderCustomContentOptions { */ interface SliderPrefixOptions extends SliderCustomContentOptions { } - /** * Options used for customizing the suffix part of the slider. * It extends the SliderCustomContentOptions to inherit accessibility customization options. @@ -1141,7 +1081,6 @@ interface SliderPrefixOptions extends SliderCustomContentOptions { */ interface SliderSuffixOptions extends SliderCustomContentOptions { } - /** * Defines the attribute functions of Slider. * @@ -1174,634 +1113,600 @@ interface SliderSuffixOptions extends SliderCustomContentOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class SliderAttribute extends CommonMethod { - /** - * Called when the slider color of the slider bar is set. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Called when the slider color of the slider bar is set. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Called when the slider color of the slider bar is set. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Called when the slider color of the slider bar is set. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - blockColor(value: ResourceColor): SliderAttribute; - - /** - * Called when the track color of the slider is set. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Called when the track color of the slider is set. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Called when the track color of the slider is set. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Called when the track color of the slider is set. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 11 - */ - /** - * Called when the track color of the slider is set. - * - * @param { ResourceColor | LinearGradient } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - trackColor(value: ResourceColor | LinearGradient): SliderAttribute; - - /** - * Called when the slider of the slider bar is set to slide over the area color. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Called when the slider of the slider bar is set to slide over the area color. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Called when the slider of the slider bar is set to slide over the area color. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Called when the slider of the slider bar is set to slide over the area color. - * - * @param { ResourceColor } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - selectedColor(value: ResourceColor): SliderAttribute; - /** - * Called when the slider of the slider bar is set to slide over the area color. - * - * @param { ResourceColor | LinearGradient } selectedColor - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - selectedColor(selectedColor: ResourceColor | LinearGradient): SliderAttribute; - - /** - * Called when the minimum label is set. - * - * @param { string } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 9 - * @useinstead min - */ - minLabel(value: string): SliderAttribute; - - /** - * Called when the maximum label is set. - * - * @param { string } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 9 - * @useinstead max - */ - maxLabel(value: string): SliderAttribute; - - /** - * Called when setting whether to display step size. - * - * @param { boolean } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Called when setting whether to display step size. - * - * @param { boolean } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Called when setting whether to display step size. - * - * @param { boolean } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Called when setting whether to display step size. - * - * @param { boolean } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - showSteps(value: boolean): SliderAttribute; - - /** - * Called when the percentage of bubble prompt is set when sliding. - * - * @param { boolean } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Called when the percentage of bubble prompt is set when sliding. - * - * @param { boolean } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Called when the percentage of bubble prompt is set when sliding. - * - * @param { boolean } value - Whether to display the bubble. - * @param { ResourceStr } content - Text content in the bubble. If the content is not specified, the current - * percentage is displayed by default. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Called when the percentage of bubble prompt is set when sliding. - * - * @param { boolean } value - Whether to display the bubble. - * @param { ResourceStr } content - Text content in the bubble. If the content is not specified, the current - * percentage is displayed by default. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - showTips(value: boolean, content?: ResourceStr): SliderAttribute; - - /** - * Called when the thickness of track is set. - * - * @param { Length } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Called when the thickness of track is set. - * - * @param { Length } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Called when the thickness of track is set. - * - * @param { Length } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Called when the thickness of track is set. - * - * @param { Length } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - trackThickness(value: Length): SliderAttribute; - - /** - * Called when the selection value changes. - * - * @param { function } callback - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Called when the selection value changes. - * - * @param { function } callback - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @form - * @since 9 - */ - /** - * Called when the selection value changes. - * - * @param { function } callback - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @since 10 - */ - /** - * Triggered when the slider is dragged or clicked. - *

NOTE: - *
The Begin and End states are triggered when the slider is clicked with a gesture. The Moving and Click states - * are triggered when the value of value changes. If the coherent action is a drag action, the Click state will - * not be triggered. - *

- * - * @param { function } callback - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - onChange(callback: (value: number, mode: SliderChangeMode) => void): SliderAttribute; - - /** - * Called when the border color of block is set. - * - * @param { ResourceColor } value - the border color of block. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Called when the border color of block is set. - * - * @param { ResourceColor } value - the border color of block. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - blockBorderColor(value: ResourceColor): SliderAttribute; - - /** - * Called when the border width of block is set. - * - * @param { Length } value - the border width of block. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Called when the border width of block is set. - * - * @param { Length } value - the border width of block. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - blockBorderWidth(value: Length): SliderAttribute; - - /** - * Called when the color of step is set. - * - * @param { ResourceColor } value - the color of step. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Called when the color of step is set. - * - * @param { ResourceColor } value - the color of step. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - stepColor(value: ResourceColor): SliderAttribute; - - /** - * Called when the radius of track border is set. - * - * @param { Length } value - the radius of track border. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Called when the radius of track border is set. - * - * @param { Length } value - the radius of track border. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - trackBorderRadius(value: Length): SliderAttribute; - - /** - * Called when the radius of selected part is set. - * - * @param { Dimension } value - the radius of selected part. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ + /** + * Called when the slider color of the slider bar is set. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Called when the slider color of the slider bar is set. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Called when the slider color of the slider bar is set. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Called when the slider color of the slider bar is set. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + blockColor(value: ResourceColor): SliderAttribute; + /** + * Called when the track color of the slider is set. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Called when the track color of the slider is set. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Called when the track color of the slider is set. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Called when the track color of the slider is set. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + /** + * Called when the track color of the slider is set. + * + * @param { ResourceColor | LinearGradient } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 12 + */ + trackColor(value: ResourceColor | LinearGradient): SliderAttribute; + /** + * Called when the slider of the slider bar is set to slide over the area color. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Called when the slider of the slider bar is set to slide over the area color. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Called when the slider of the slider bar is set to slide over the area color. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Called when the slider of the slider bar is set to slide over the area color. + * + * @param { ResourceColor } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + selectedColor(value: ResourceColor): SliderAttribute; + /** + * Called when the slider of the slider bar is set to slide over the area color. + * + * @param { ResourceColor | LinearGradient } selectedColor + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 18 + */ + selectedColor(selectedColor: ResourceColor | LinearGradient): SliderAttribute; + /** + * Called when the minimum label is set. + * + * @param { string } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + * @deprecated since 9 + * @useinstead min + */ + minLabel(value: string): SliderAttribute; + /** + * Called when the maximum label is set. + * + * @param { string } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + * @deprecated since 9 + * @useinstead max + */ + maxLabel(value: string): SliderAttribute; + /** + * Called when setting whether to display step size. + * + * @param { boolean } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Called when setting whether to display step size. + * + * @param { boolean } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Called when setting whether to display step size. + * + * @param { boolean } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Called when setting whether to display step size. + * + * @param { boolean } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + showSteps(value: boolean): SliderAttribute; + /** + * Called when setting whether to display step size. + * + * @param { boolean } value + * @param { SliderShowStepOptions } [options] + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 20 + */ + showSteps(value: boolean, options?: SliderShowStepOptions): SliderAttribute; + /** + * Called when the percentage of bubble prompt is set when sliding. + * + * @param { boolean } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Called when the percentage of bubble prompt is set when sliding. + * + * @param { boolean } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Called when the percentage of bubble prompt is set when sliding. + * + * @param { boolean } value - Whether to display the bubble. + * @param { ResourceStr } content - Text content in the bubble. If the content is not specified, the current + * percentage is displayed by default. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Called when the percentage of bubble prompt is set when sliding. + * + * @param { boolean } value - Whether to display the bubble. + * @param { ResourceStr } content - Text content in the bubble. If the content is not specified, the current + * percentage is displayed by default. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + showTips(value: boolean, content?: ResourceStr): SliderAttribute; + /** + * Called when the thickness of track is set. + * + * @param { Length } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 8 + */ + /** + * Called when the thickness of track is set. + * + * @param { Length } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Called when the thickness of track is set. + * + * @param { Length } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Called when the thickness of track is set. + * + * @param { Length } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + trackThickness(value: Length): SliderAttribute; + /** + * Called when the selection value changes. + * + * @param { function } callback + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 7 + */ + /** + * Called when the selection value changes. + * + * @param { function } callback + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @form + * @since 9 + */ + /** + * Called when the selection value changes. + * + * @param { function } callback + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @since 10 + */ + /** + * Triggered when the slider is dragged or clicked. + *

NOTE: + *
The Begin and End states are triggered when the slider is clicked with a gesture. The Moving and Click states + * are triggered when the value of value changes. If the coherent action is a drag action, the Click state will + * not be triggered. + *

+ * + * @param { function } callback + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @form + * @atomicservice + * @since 11 + */ + onChange(callback: (value: number, mode: SliderChangeMode) => void): SliderAttribute; + /** + * Called when the border color of block is set. + * + * @param { ResourceColor } value - the border color of block. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Called when the border color of block is set. + * + * @param { ResourceColor } value - the border color of block. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + blockBorderColor(value: ResourceColor): SliderAttribute; + /** + * Called when the border width of block is set. + * + * @param { Length } value - the border width of block. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Called when the border width of block is set. + * + * @param { Length } value - the border width of block. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + blockBorderWidth(value: Length): SliderAttribute; + /** + * Called when the color of step is set. + * + * @param { ResourceColor } value - the color of step. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Called when the color of step is set. + * + * @param { ResourceColor } value - the color of step. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + stepColor(value: ResourceColor): SliderAttribute; + /** + * Called when the radius of track border is set. + * + * @param { Length } value - the radius of track border. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Called when the radius of track border is set. + * + * @param { Length } value - the radius of track border. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + trackBorderRadius(value: Length): SliderAttribute; + /** + * Called when the radius of selected part is set. + * + * @param { Dimension } value - the radius of selected part. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ selectedBorderRadius(value: Dimension): SliderAttribute; - - /** - * Called when the size of block is set. - * - * @param { SizeOptions } value - the size of block. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Called when the size of block is set. - * - * @param { SizeOptions } value - the size of block. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - blockSize(value: SizeOptions): SliderAttribute; - - /** - * Called when the style of block is set. - * - * @param { SliderBlockStyle } value - the style of block. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Sets the style of the slider in the block direction. - * - * @param { SliderBlockStyle } value - Style of the slider in the block direction. - *
Default value is SliderBlockType.DEFAULT, indicating the round slider. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - blockStyle(value: SliderBlockStyle): SliderAttribute; - - /** - * Called when the diameter of step is set. - * - * @param { Length } value - the diameter of step. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Called when the diameter of step is set. - * - * @param { Length } value - the diameter of step. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - stepSize(value: Length): SliderAttribute; - - /** - * Sets the interaction mode between the user and the slider. - * - * @param { SliderInteraction } value - Interaction mode between the user and the slider. - *
Default value is SliderInteraction.SLIDE_AND_CLICK. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - sliderInteractionMode(value: SliderInteraction): SliderAttribute; - - /** - * Sets the min value when Slider response to drag event. - * - * @param { number } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - minResponsiveDistance(value: number): SliderAttribute; - - /** - * Creates a content modifier. - * - * @param { ContentModifier } modifier - Content modifier to apply to the slider. - * modifier: content modifier. You need a custom class to implement the ContentModifier API. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - contentModifier(modifier: ContentModifier): SliderAttribute; - - /** - * Set the valid slidable range. - * - * @param { SlideRange } value - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - slideRange(value: SlideRange): SliderAttribute; - - /** - * Set the sensitivity of rotating crown. - * - * @param { Optional } sensitivity - The sensitivity of rotating crown, default value is { MEDIUM }. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - digitalCrownSensitivity(sensitivity: Optional): SliderAttribute; - - /** - * Enable or disable haptic feedback. - * - * @param { boolean } enabled - Default value is true, set false to disable haptic feedback. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - enableHapticFeedback(enabled: boolean): SliderAttribute; - - /** - * Sets the prefix part of the slider. - * The prefix is the content that appears before the main slider component. - * - * @param { ComponentContent } content - Custom components that will be displayed as the prefix. - * This can be any valid custom UI component structure. - * @param { SliderPrefixOptions } [options] - Optional options for customizing the prefix. - * These options can include accessibility settings. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - prefix(content: ComponentContent, options?: SliderPrefixOptions): SliderAttribute; - - /** - * Sets the suffix part of the slider. - * The suffix is the content that appears after the main slider component. - * - * @param { ComponentContent } content - Custom components that will be displayed as the suffix. - * This can be any valid custom UI component structure. - * @param { SliderSuffixOptions } [options] - Optional options for customizing the suffix. - * These options can include accessibility settings. - * @returns { SliderAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - suffix(content: ComponentContent, options?: SliderSuffixOptions): SliderAttribute; + /** + * Called when the size of block is set. + * + * @param { SizeOptions } value - the size of block. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Called when the size of block is set. + * + * @param { SizeOptions } value - the size of block. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + blockSize(value: SizeOptions): SliderAttribute; + /** + * Called when the style of block is set. + * + * @param { SliderBlockStyle } value - the style of block. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Sets the style of the slider in the block direction. + * + * @param { SliderBlockStyle } value - Style of the slider in the block direction. + *
Default value is SliderBlockType.DEFAULT, indicating the round slider. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + blockStyle(value: SliderBlockStyle): SliderAttribute; + /** + * Called when the diameter of step is set. + * + * @param { Length } value - the diameter of step. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Called when the diameter of step is set. + * + * @param { Length } value - the diameter of step. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + stepSize(value: Length): SliderAttribute; + /** + * Sets the interaction mode between the user and the slider. + * + * @param { SliderInteraction } value - Interaction mode between the user and the slider. + *
Default value is SliderInteraction.SLIDE_AND_CLICK. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + sliderInteractionMode(value: SliderInteraction): SliderAttribute; + /** + * Sets the min value when Slider response to drag event. + * + * @param { number } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + minResponsiveDistance(value: number): SliderAttribute; + /** + * Creates a content modifier. + * + * @param { ContentModifier } modifier - Content modifier to apply to the slider. + * modifier: content modifier. You need a custom class to implement the ContentModifier API. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + contentModifier(modifier: ContentModifier): SliderAttribute; + /** + * Set the valid slidable range. + * + * @param { SlideRange } value + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + slideRange(value: SlideRange): SliderAttribute; + /** + * Set the sensitivity of rotating crown. + * + * @param { Optional } sensitivity - The sensitivity of rotating crown, default value is { MEDIUM }. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ + digitalCrownSensitivity(sensitivity: Optional): SliderAttribute; + /** + * Enable or disable haptic feedback. + * + * @param { boolean } enabled - Default value is true, set false to disable haptic feedback. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 18 + */ + enableHapticFeedback(enabled: boolean): SliderAttribute; + /** + * Sets the prefix part of the slider. + * The prefix is the content that appears before the main slider component. + * + * @param { ComponentContent } content - Custom components that will be displayed as the prefix. + * This can be any valid custom UI component structure. + * @param { SliderPrefixOptions } [options] - Optional options for customizing the prefix. + * These options can include accessibility settings. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + prefix(content: ComponentContent, options?: SliderPrefixOptions): SliderAttribute; + /** + * Sets the suffix part of the slider. + * The suffix is the content that appears after the main slider component. + * + * @param { ComponentContent } content - Custom components that will be displayed as the suffix. + * This can be any valid custom UI component structure. + * @param { SliderSuffixOptions } [options] - Optional options for customizing the suffix. + * These options can include accessibility settings. + * @returns { SliderAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + suffix(content: ComponentContent, options?: SliderSuffixOptions): SliderAttribute; } - /** * Defines Slider Component. * @@ -1833,7 +1738,6 @@ declare class SliderAttribute extends CommonMethod { * @since 11 */ declare const Slider: SliderInterface; - /** * Defines Slider Component instance. * diff --git a/api/@internal/component/ets/span.d.ts b/api/@internal/component/ets/span.d.ts index 8646766bc0cac06d85f6054e4ba92d49bb02c36b..cdeb16157e9fba88c242802faf9dfd3db018be61 100644 --- a/api/@internal/component/ets/span.d.ts +++ b/api/@internal/component/ets/span.d.ts @@ -18,15 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceColor, Dimension, BorderRadiuses, Length, Font } from './units'; -import { CommonMethod, ShadowOptions } from './common'; -import { LengthMetrics } from './../Graphics'; -import { Resource } from './../../../api/global/resource'; -import { FontStyle, FontWeight, TextCase } from './enums'; -import { DecorationStyleInterface } from './styledString'; -/*** endif */ - /** * Define the background style of span. * @@ -42,8 +33,7 @@ import { DecorationStyleInterface } from './styledString'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextBackgroundStyle { /** @@ -61,8 +51,7 @@ declare interface TextBackgroundStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color?: ResourceColor; @@ -81,8 +70,7 @@ declare interface TextBackgroundStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radius?: Dimension | BorderRadiuses; } @@ -102,8 +90,7 @@ declare interface TextBackgroundStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class BaseSpan extends CommonMethod { /** @@ -123,8 +110,7 @@ declare class BaseSpan extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textBackgroundStyle(style: TextBackgroundStyle): T; @@ -136,8 +122,7 @@ declare class BaseSpan extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ baselineOffset(value: LengthMetrics): T; } @@ -174,8 +159,7 @@ declare class BaseSpan extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface SpanInterface { /** @@ -214,8 +198,7 @@ interface SpanInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value: string | Resource): SpanAttribute; } @@ -244,8 +227,7 @@ interface SpanInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class SpanAttribute extends BaseSpan { /** @@ -264,8 +246,7 @@ declare class SpanAttribute extends BaseSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ font(value: Font): SpanAttribute; @@ -305,8 +286,7 @@ declare class SpanAttribute extends BaseSpan { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): SpanAttribute; @@ -346,8 +326,7 @@ declare class SpanAttribute extends BaseSpan { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize(value: number | string | Resource): SpanAttribute; @@ -387,8 +366,7 @@ declare class SpanAttribute extends BaseSpan { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontStyle(value: FontStyle): SpanAttribute; @@ -443,20 +421,6 @@ declare class SpanAttribute extends BaseSpan { */ fontWeight(value: number | FontWeight | ResourceStr): SpanAttribute; - /** - * Called when the font weight is set. - * - * @param { number | FontWeight | string } value - * @returns { SpanAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - fontWeight(value: number | FontWeight | string): SpanAttribute; - /** * Called when the font list of text is set. * @@ -493,8 +457,7 @@ declare class SpanAttribute extends BaseSpan { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontFamily(value: string | Resource): SpanAttribute; @@ -545,8 +508,7 @@ declare class SpanAttribute extends BaseSpan { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ decoration(value: DecorationStyleInterface): SpanAttribute; @@ -601,20 +563,6 @@ declare class SpanAttribute extends BaseSpan { */ letterSpacing(value: number | ResourceStr): SpanAttribute; - /** - * Called when the distance between text fonts is set. - * - * @param { number | string } value - * @returns { SpanAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - letterSpacing(value: number | string): SpanAttribute; - /** * Called when the type of letter in the text font is set. * @@ -651,8 +599,7 @@ declare class SpanAttribute extends BaseSpan { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textCase(value: TextCase): SpanAttribute; @@ -672,8 +619,7 @@ declare class SpanAttribute extends BaseSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lineHeight(value: Length): SpanAttribute; @@ -694,8 +640,7 @@ declare class SpanAttribute extends BaseSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textShadow(value: ShadowOptions | Array): SpanAttribute; } diff --git a/api/@internal/component/ets/stack.d.ts b/api/@internal/component/ets/stack.d.ts index ccce79ba0264de8843d3758f9fd76f0d5f2769d6..38790a319fe1b5dee03857a64d2dd8aa18244898 100644 --- a/api/@internal/component/ets/stack.d.ts +++ b/api/@internal/component/ets/stack.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { PointLightStyle, CommonMethod } from './common'; -import { Alignment } from './enums'; -/*** endif */ - /** * Options used to construct the stack. * @@ -31,8 +26,7 @@ import { Alignment } from './enums'; * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface StackOptions { /** @@ -79,8 +73,7 @@ declare interface StackOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ alignContent?: Alignment; } @@ -117,8 +110,7 @@ declare interface StackOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface StackInterface { /** @@ -169,8 +161,7 @@ interface StackInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options?: StackOptions): StackAttribute; } @@ -199,8 +190,7 @@ interface StackInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class StackAttribute extends CommonMethod { /** @@ -239,8 +229,7 @@ declare class StackAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignContent(value: Alignment): StackAttribute; @@ -251,8 +240,7 @@ declare class StackAttribute extends CommonMethod { * @returns { StackAttribute } The attribute of the stack. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pointLight(value: PointLightStyle): StackAttribute; } diff --git a/api/@internal/component/ets/state_management.d.ts b/api/@internal/component/ets/state_management.d.ts index 9edb4e29fafcca00af5bd0a6f5d9ff4ac3e61388..7db8947e5c83e95aa17f2f194bea6131ba88fd2b 100644 --- a/api/@internal/component/ets/state_management.d.ts +++ b/api/@internal/component/ets/state_management.d.ts @@ -31,8 +31,7 @@ * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ColorMode { /** @@ -46,8 +45,7 @@ declare enum ColorMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ LIGHT = 0, @@ -62,8 +60,7 @@ declare enum ColorMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ DARK, } @@ -81,8 +78,7 @@ declare enum ColorMode { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum LayoutDirection { /** @@ -96,8 +92,7 @@ declare enum LayoutDirection { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ LTR, @@ -112,8 +107,7 @@ declare enum LayoutDirection { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ RTL, @@ -128,8 +122,7 @@ declare enum LayoutDirection { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Auto, } @@ -139,8 +132,7 @@ declare enum LayoutDirection { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'7','1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ declare class Storage { /** @@ -150,8 +142,7 @@ declare class Storage { * @param { string } file * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'7','1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ constructor(needCrossThread?: boolean, file?: string); @@ -162,8 +153,7 @@ declare class Storage { * @returns { string | undefined } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'7','1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ get(key: string): string | undefined; @@ -177,26 +167,13 @@ declare class Storage { * @since 7 */ set(key: string, val: any): void; - - /** - * Called when setting. - * - * @param { string } key - * @param { Object | undefined | null } val - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since 20 - * @arkts 1.2 - */ - set(key: string, val: Object | undefined | null): void; /** * Called when data is cleared. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'7','1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ clear(): void; @@ -206,8 +183,7 @@ declare class Storage { * @param { string } key * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'7','1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ delete(key: string): void; } diff --git a/api/@internal/component/ets/stepper.d.ts b/api/@internal/component/ets/stepper.d.ts index 59d4b0fc0f886d4b08b9f5ea20d758bf48ba7efe..c4a4fd0e75e337aca5e250acafe64159e63d5c1a 100644 --- a/api/@internal/component/ets/stepper.d.ts +++ b/api/@internal/component/ets/stepper.d.ts @@ -18,45 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Bindable, CommonMethod } from './common' -/*** endif */ - -/** - * Declare the StepperOptions. - * - * @interface StepperOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ -interface StepperOptions { - /** - * Set the stepper index. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - */ - index?: number; - - /** - * Set the stepper index. - * - * @type { ?(number | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - index?: number | Bindable; -} - /** * Declare the stepper. * @@ -79,8 +40,8 @@ interface StepperOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface StepperInterface { /** @@ -111,19 +72,6 @@ interface StepperInterface { * @since 11 */ (value?: { index?: number }): StepperAttribute; - /** - * Called when the stepper component is used. - * - * Anonymous Object Rectification. - * @param { StepperOptions } value - * @returns { StepperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (value?: StepperOptions): StepperAttribute; } /** @@ -148,8 +96,8 @@ interface StepperInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class StepperAttribute extends CommonMethod { /** @@ -177,8 +125,7 @@ declare class StepperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onFinish(callback: () => void): StepperAttribute; @@ -207,8 +154,7 @@ declare class StepperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onSkip(callback: () => void): StepperAttribute; @@ -237,8 +183,7 @@ declare class StepperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onChange(callback: (prevIndex: number, index: number) => void): StepperAttribute; @@ -267,8 +212,7 @@ declare class StepperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onNext(callback: (index: number, pendingIndex: number) => void): StepperAttribute; @@ -297,8 +241,7 @@ declare class StepperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onPrevious(callback: (index: number, pendingIndex: number) => void): StepperAttribute; } @@ -323,6 +266,7 @@ declare class StepperAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 11 + * @noninterop */ declare const Stepper: StepperInterface; @@ -346,5 +290,6 @@ declare const Stepper: StepperInterface; * @crossplatform * @atomicservice * @since 11 + * @noninterop */ declare const StepperInstance: StepperAttribute; diff --git a/api/@internal/component/ets/stepper_item.d.ts b/api/@internal/component/ets/stepper_item.d.ts index 3fab51d1d05d572944ffb59e68d4530f881ee84d..bae1bcb089405d44416ecbc7a9c5d43abda8399e 100644 --- a/api/@internal/component/ets/stepper_item.d.ts +++ b/api/@internal/component/ets/stepper_item.d.ts @@ -18,10 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod } from './common' -/*** endif */ - /** * ItemState * @@ -44,8 +40,7 @@ import { CommonMethod } from './common' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ItemState { /** @@ -67,8 +62,7 @@ declare enum ItemState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Normal, @@ -91,8 +85,7 @@ declare enum ItemState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Disabled, @@ -115,8 +108,7 @@ declare enum ItemState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Waiting, @@ -139,8 +131,7 @@ declare enum ItemState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Skip, } @@ -167,8 +158,8 @@ declare enum ItemState { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface StepperItemInterface { /** @@ -193,8 +184,7 @@ interface StepperItemInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): StepperItemAttribute; } @@ -221,8 +211,8 @@ interface StepperItemInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class StepperItemAttribute extends CommonMethod { /** @@ -250,8 +240,7 @@ declare class StepperItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ prevLabel(value: string): StepperItemAttribute; @@ -280,8 +269,7 @@ declare class StepperItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ nextLabel(value: string): StepperItemAttribute; @@ -310,8 +298,7 @@ declare class StepperItemAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ status(value?: ItemState): StepperItemAttribute; } @@ -336,6 +323,7 @@ declare class StepperItemAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 11 + * @noninterop */ declare const StepperItemInstance: StepperItemAttribute; @@ -359,5 +347,6 @@ declare const StepperItemInstance: StepperItemAttribute; * @crossplatform * @atomicservice * @since 11 + * @noninterop */ declare const StepperItem: StepperItemInterface; diff --git a/api/@internal/component/ets/styled_string.d.ts b/api/@internal/component/ets/styled_string.d.ts index a5ddf911e219a663d21a93cfb2666e2e8b78ce63..54f25c771a95be64955210a459bc55419b0b3ae2 100644 --- a/api/@internal/component/ets/styled_string.d.ts +++ b/api/@internal/component/ets/styled_string.d.ts @@ -12,25 +12,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - /** * @file * @kit ArkUI */ - -/*** if arkts 1.2 */ -import { Callback, ShadowOptions, ClickEvent, Optional, PixelMap } from './common'; -import { TextAlign, FontStyle, FontWeight, TextDecorationType, TextDecorationStyle, WordBreak, TextOverflow, ImageFit, ImageSpanAlignment } from './enums'; -import { ResourceStr, ResourceColor, LengthMetrics, SizeOptions, Margin, Padding, BorderRadiuses, ColorFilter } from './units'; -import { TextBackgroundStyle } from './span'; -import { GestureEvent } from "./gesture"; -import { DrawingColorFilter } from './image'; -import { LeadingMarginPlaceholder } from './richEditor'; -import image from '../../@ohos.multimedia.image'; -import drawing from '../../@ohos.graphics.drawing'; -import { DrawContext } from '../../arkui/Graphics'; -/*** endif */ - /** * Defines the StyledStringMarshallingValue Type. * @@ -39,12 +24,9 @@ import { DrawContext } from '../../arkui/Graphics'; * @systemapi * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare type StyledStringMarshallingValue = UserDataSpan; - - /** * Defines the callback type used in marshalling. * @@ -55,11 +37,9 @@ declare type StyledStringMarshallingValue = UserDataSpan; * @systemapi * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare type StyledStringMarshallCallback = (marshallableVal: StyledStringMarshallingValue) => ArrayBuffer; - /** * Defines the callback type used in unmarshalling. * @@ -70,19 +50,16 @@ declare type StyledStringMarshallCallback = (marshallableVal: StyledStringMarsha * @systemapi * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare type StyledStringUnmarshallCallback = (buf: ArrayBuffer) => StyledStringMarshallingValue; - /** * StyledString * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class StyledString { /** @@ -93,11 +70,9 @@ declare class StyledString { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(value: string | ImageAttachment | CustomSpan, styles?: Array); - /** * Get the length of the StyledString's characters. * @@ -106,11 +81,9 @@ declare class StyledString { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly length: number; - /** * Get the literal content of the StyledString. * @@ -118,11 +91,9 @@ declare class StyledString { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getString(): string; - /** * Get the attribute objects of the subStyledString. * @@ -130,18 +101,16 @@ declare class StyledString { * @param { number } length - the length of the subStyledString's characters. * @param { StyledStringKey } [styledKey] - the specified type. * @returns { Array } - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getStyles(start: number, length: number, styledKey?: StyledStringKey): Array; - /** * Judge if two attribute strings are equal. * @@ -150,63 +119,55 @@ declare class StyledString { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ equals(other: StyledString): boolean; - /** * Get the substring of the StyledString. * * @param { number } start - the start position of the subStyledString. * @param { number } [length] - the length of the subStyledString's characters. * @returns { StyledString } - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ subStyledString(start: number, length?: number): StyledString; - /** * Returns StyledString from the provided HTML string. * * @param { string } html - the html text will be converted to a StyledString. * @returns { Promise } - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @throws { BusinessError } 170001 - Convert Error. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static fromHtml(html: string): Promise; - /** * Returns HTML string from the provided StyledString. * * @param { StyledString } styledString - the StyledString will be converted to a HTML string. * @returns { string } Returns the HTML string converted from the provided StyledString. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ static toHtml(styledString: StyledString): string; - /** * Returns ArrayBuffer from the serialized styled string. * @@ -215,11 +176,9 @@ declare class StyledString { * @returns { ArrayBuffer } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ static marshalling(styledString: StyledString, callback: StyledStringMarshallCallback): ArrayBuffer; - /** * Returns StyledString from the deserialized ArrayBuffer. * @@ -233,11 +192,9 @@ declare class StyledString { * @throws { BusinessError } 170002 - Styled string decode error. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ static unmarshalling(buffer: ArrayBuffer, callback: StyledStringUnmarshallCallback): Promise; - /** * Returns ArrayBuffer from the serialized styled string. * @@ -245,29 +202,25 @@ declare class StyledString { * @returns { ArrayBuffer } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ static marshalling(styledString: StyledString): ArrayBuffer; - /** * Returns StyledString from the deserialized ArrayBuffer. * * @param { ArrayBuffer } buffer - The buffer will be deserialized to a StyledString. * @returns { Promise } - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @throws { BusinessError } 170002 - Styled string decode error. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ static unmarshalling(buffer: ArrayBuffer): Promise; } - /** * StyleOptions * @@ -275,8 +228,7 @@ declare class StyledString { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface StyleOptions { /** @@ -286,11 +238,9 @@ declare interface StyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start?: number; - /** * The length of the modifiedStyledString's characters. * @@ -298,11 +248,9 @@ declare interface StyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ length?: number; - /** * The attribute key of the StyleOptions. * @@ -310,11 +258,9 @@ declare interface StyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ styledKey: StyledStringKey; - /** * The attribute value of the StyleOptions. * @@ -322,12 +268,10 @@ declare interface StyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ styledValue: StyledStringValue; } - /** * SpanStyle * @@ -335,8 +279,7 @@ declare interface StyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface SpanStyle { /** @@ -346,11 +289,9 @@ declare interface SpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start: number; - /** * The length of the modifiedStyledString's characters. * @@ -358,11 +299,9 @@ declare interface SpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ length: number; - /** * The attribute key of the SpanStyle. * @@ -370,11 +309,9 @@ declare interface SpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ styledKey: StyledStringKey; - /** * The attribute value of the SpanStyle. * @@ -382,23 +319,19 @@ declare interface SpanStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ styledValue: StyledStringValue; } - /** * Defines TextStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class TextStyle { - /** * constructor. * @@ -406,11 +339,9 @@ declare class TextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(value?: TextStyleInterface); - /** * Get the fontColor of the StyledString. * @@ -419,11 +350,9 @@ declare class TextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly fontColor?: ResourceColor; - /** * Get the fontFamily of the StyledString. * @@ -432,11 +361,9 @@ declare class TextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly fontFamily?: string; - /** * Get the fontSize of the StyledString. * If not undefined, the unit is vp. @@ -446,11 +373,9 @@ declare class TextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly fontSize?: number; - /** * Get the fontWeight of the StyledString. * @@ -459,11 +384,9 @@ declare class TextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly fontWeight?: number; - /** * Get the fontStyle of the StyledString. * @@ -472,11 +395,9 @@ declare class TextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly fontStyle?: FontStyle; - /** * Get the stroke width of the StyledString with the unit 'vp'. * @@ -488,7 +409,6 @@ declare class TextStyle { * @since 20 */ readonly strokeWidth?: number; - /** * Get the stroke color of the StyledString. * @@ -500,7 +420,6 @@ declare class TextStyle { * @since 20 */ readonly strokeColor?: ResourceColor; - /** * Get the superscript style of the StyledString. * @@ -513,7 +432,6 @@ declare class TextStyle { */ readonly superscript?: SuperscriptStyle; } - /** * TextStyleInterface * @@ -521,8 +439,7 @@ declare class TextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextStyleInterface { /** @@ -532,11 +449,9 @@ declare interface TextStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontColor?: ResourceColor; - /** * The fontFamily value of the font property object. * @@ -544,11 +459,9 @@ declare interface TextStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontFamily?: ResourceStr; - /** * The fontSize value of the font property object. * @@ -556,11 +469,9 @@ declare interface TextStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontSize?: LengthMetrics; - /** * The fontWeight value of the font property object. * @@ -568,11 +479,9 @@ declare interface TextStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontWeight?: number | FontWeight | string; - /** * The fontStyle value of the font property object. * @@ -580,11 +489,9 @@ declare interface TextStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontStyle?: FontStyle; - /** * The stroke width of the text. * @@ -595,7 +502,6 @@ declare interface TextStyleInterface { * @since 20 */ strokeWidth?: LengthMetrics; - /** * The stroke color of the text. * @@ -606,7 +512,6 @@ declare interface TextStyleInterface { * @since 20 */ strokeColor?: ResourceColor; - /** * The superscript value of the font property object. * @@ -618,7 +523,6 @@ declare interface TextStyleInterface { */ superscript?: SuperscriptStyle; } - /** * Defines DecorationOptions for Decoration. * @@ -640,18 +544,15 @@ declare interface DecorationOptions { */ enableMultiType?: boolean; } - /** * Defines DecorationStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class DecorationStyle { - /** * constructor. * @@ -659,11 +560,9 @@ declare class DecorationStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(value: DecorationStyleInterface); - /** * constructor. * @@ -675,7 +574,6 @@ declare class DecorationStyle { * @since 20 */ constructor(value: DecorationStyleInterface, options?: DecorationOptions); - /** * Get the text decoration type of the StyledString. * @@ -684,11 +582,9 @@ declare class DecorationStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly type: TextDecorationType; - /** * Get the decorationColor of the StyledString. * @@ -697,11 +593,9 @@ declare class DecorationStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly color?: ResourceColor; - /** * Get the decorationStyle of the StyledString. * @@ -710,11 +604,9 @@ declare class DecorationStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly style?: TextDecorationStyle; - /** * Get the thickness scale of the StyledString. * @@ -726,7 +618,6 @@ declare class DecorationStyle { * @since 20 */ readonly thicknessScale?: number; - /** * Get the DecorationOptions of the StyledString. * @@ -739,7 +630,6 @@ declare class DecorationStyle { */ readonly options?: DecorationOptions; } - /** * DecorationStyleInterface * @@ -747,8 +637,7 @@ declare class DecorationStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface DecorationStyleInterface { /** @@ -758,11 +647,9 @@ declare interface DecorationStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type: TextDecorationType; - /** * The color value of the decoration property object. * @@ -770,11 +657,9 @@ declare interface DecorationStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color?: ResourceColor; - /** * The style value of the decoration property object. * @@ -782,11 +667,9 @@ declare interface DecorationStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style?: TextDecorationStyle; - /** * The thickness scale of the decoration * @@ -798,18 +681,15 @@ declare interface DecorationStyleInterface { */ thicknessScale?: number; } - /** * Defines BaselineOffsetStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class BaselineOffsetStyle { - /** * constructor. * @@ -817,11 +697,9 @@ declare class BaselineOffsetStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(value: LengthMetrics); - /** * Get the baselineOffset value of the StyledString. * The unit is vp. @@ -831,23 +709,19 @@ declare class BaselineOffsetStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly baselineOffset: number; } - /** * Defines LetterSpacingStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class LetterSpacingStyle { - /** * constructor. * @@ -855,37 +729,31 @@ declare class LetterSpacingStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(value: LengthMetrics); - /** * Get the letterSpacing value of the StyledString. * The unit is vp. - * + * * @type { number } - the letterSpacing value of the StyledString * @readonly * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly letterSpacing: number; } - /** * Defines TextShadowStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class TextShadowStyle { - /** * constructor. * @@ -893,11 +761,9 @@ declare class TextShadowStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(value: ShadowOptions | Array); - /** * Get the textShadow value of the StyledString. * @@ -906,23 +772,19 @@ declare class TextShadowStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly textShadow: Array; } - /** * Defines Sets the property string background color. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare class BackgroundColorStyle { - /** * constructor. * @@ -930,11 +792,9 @@ declare class BackgroundColorStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ constructor(textBackgroundStyle: TextBackgroundStyle); - /** * Get the textBackgroundStyle value of the StyledString. * @@ -943,23 +803,19 @@ declare class BackgroundColorStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ readonly textBackgroundStyle: TextBackgroundStyle; } - /** * Defines GestureStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class GestureStyle { - /** * constructor. * @@ -967,12 +823,10 @@ declare class GestureStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(value?: GestureStyleInterface); } - /** * Defines the Gesture Events. * @@ -980,8 +834,7 @@ declare class GestureStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface GestureStyleInterface { /** @@ -991,11 +844,9 @@ declare interface GestureStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onClick?: Callback; - /** * Trigger a gesture event when long press event is complete. * @@ -1003,11 +854,9 @@ declare interface GestureStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onLongPress?: Callback; - /** * Trigger a touch event when touched. * @@ -1019,18 +868,15 @@ declare interface GestureStyleInterface { */ onTouch?: Callback; } - /** * Defines ParagraphStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class ParagraphStyle { - /** * constructor. * @@ -1038,11 +884,9 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(value?: ParagraphStyleInterface); - /** * Get the text alignment of the StyledString. * @@ -1051,11 +895,9 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly textAlign?: TextAlign; - /** * Get the text vertical alignment of the StyledString. * @@ -1067,7 +909,6 @@ declare class ParagraphStyle { * @since 20 */ readonly textVerticalAlign?: TextVerticalAlign; - /** * Get the first line indentation of the StyledString. * The unit is vp. @@ -1077,11 +918,9 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly textIndent?: number; - /** * Get the maximum number of lines of the StyledString. * @@ -1090,11 +929,9 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly maxLines?: number; - /** * Get the overflow mode of the StyledString. * @@ -1103,11 +940,9 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly overflow?: TextOverflow; - /** * Get the wordBreak mode of the StyledString. * @@ -1116,11 +951,9 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly wordBreak?: WordBreak; - /** * Get the leading margin of the StyledString. * @@ -1129,11 +962,9 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly leadingMargin?: number | LeadingMarginPlaceholder; - /** * Get the paragraph spacing of the StyledString. * The unit is vp. @@ -1143,12 +974,10 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ readonly paragraphSpacing?: number; } - /** * ParagraphStyleInterface * @@ -1156,8 +985,7 @@ declare class ParagraphStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ParagraphStyleInterface { /** @@ -1167,11 +995,9 @@ declare interface ParagraphStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textAlign?: TextAlign; - /** * Vertical alignment of text. * @@ -1182,7 +1008,6 @@ declare interface ParagraphStyleInterface { * @since 20 */ textVerticalAlign?: TextVerticalAlign; - /** * Set the first line indentation. * @@ -1190,11 +1015,9 @@ declare interface ParagraphStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textIndent?: LengthMetrics; - /** * The maximum number of lines of content. * @@ -1202,11 +1025,9 @@ declare interface ParagraphStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ maxLines?: number; - /** * The overflow mode of the content. * @@ -1214,11 +1035,9 @@ declare interface ParagraphStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ overflow?: TextOverflow; - /** * Set word break type. * @@ -1226,11 +1045,9 @@ declare interface ParagraphStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ wordBreak?: WordBreak; - /** * Leading margin. * @@ -1238,11 +1055,9 @@ declare interface ParagraphStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ leadingMargin?: LengthMetrics | LeadingMarginPlaceholder; - /** * Set the paragraph spacing of the StyledString. * @@ -1250,23 +1065,19 @@ declare interface ParagraphStyleInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ paragraphSpacing?: LengthMetrics; } - /** * Defines LineHeightStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class LineHeightStyle { - /** * constructor. * @@ -1274,26 +1085,22 @@ declare class LineHeightStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(lineHeight: LengthMetrics); - /** * Get the lineHeight value of the StyledString. * The unit is vp. - * + * * @type { number } - the lineHeight value of the StyledString * @readonly * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly lineHeight: number; } - /** * Defines the URLStyle hyperlink that allows setting a URL string. When clicking on the text to * which the span is attached, the URLStyle will try to open the URL. @@ -1301,11 +1108,9 @@ declare class LineHeightStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare class UrlStyle { - /** * Constructor. * @@ -1313,11 +1118,9 @@ declare class UrlStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ constructor(url: string); - /** * Get the URL value of the StyledString. * @@ -1326,12 +1129,10 @@ declare class UrlStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ readonly url: string; } - /** * Defines the Span Type. * @@ -1343,7 +1144,6 @@ declare class UrlStyle { * @atomicservice * @since 12 */ - /** * Defines the Span Type. * @@ -1353,13 +1153,11 @@ declare class UrlStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare type StyledStringValue = TextStyle | DecorationStyle | BaselineOffsetStyle | LetterSpacingStyle | -TextShadowStyle | GestureStyle | ImageAttachment | ParagraphStyle | LineHeightStyle | UrlStyle | CustomSpan | -UserDataSpan | BackgroundColorStyle; - + TextShadowStyle | GestureStyle | ImageAttachment | ParagraphStyle | + LineHeightStyle | UrlStyle | CustomSpan | UserDataSpan | BackgroundColorStyle; /** * MutableStyledString * @@ -1367,91 +1165,69 @@ UserDataSpan | BackgroundColorStyle; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class MutableStyledString extends StyledString { - /** - * constructor. - * - * @param { string | ImageAttachment | CustomSpan } value - indicates the current object value of the MutableStyledString. - * @param { Array } [styles] - indicates the SpanStyle objects. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - constructor(value: string | ImageAttachment | CustomSpan, styles?: Array); - /** * Replace the string of the specified range. * * @param { number } start - the start position of the replacedString. * @param { number } length - the length of the replacedString's characters. * @param { string } other - must be unicode string. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replaceString(start: number, length: number, other: string): void; - /** * Insert the string at the specified location. * * @param { number } start - the start position of the insertedString. * @param { string } other - must be unicode string. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ insertString(start: number, other: string): void; - /** * Remove the string of the specified range. * * @param { number } start - the start position of the removedString. * @param { number } length - the length of the removedString's characters. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ removeString(start: number, length: number): void; - /** * Replace the specified range string attribute. * * @param { SpanStyle } spanStyle - the SpanStyle Object. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replaceStyle(spanStyle: SpanStyle): void; - /** * Add attributes to the specified range string. * @@ -1460,92 +1236,80 @@ declare class MutableStyledString extends StyledString { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setStyle(spanStyle: SpanStyle): void; - /** * Delete the specified type attributes for the specified range string. * * @param { number } start - the start position of the removedAttributeStyledString. * @param { number } length - the length of the removedAttributeStyledString's characters. * @param { StyledStringKey } styledKey - the specified attribute type's key. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ removeStyle(start: number, length: number, styledKey: StyledStringKey): void; - /** * Delete all attributes for the specified range styledString. * * @param { number } start - the start position of the attributeRemovedStyledString's characters. * @param { number } length - the length of the attributeRemovedStyledString's characters. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ removeStyles(start: number, length: number): void; - /** * Delete all attributes. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ clearStyles(): void; - /** * Replace the StyledString of the specified range. * * @param { number } start - the start position of the replacedStyledString. * @param { number } length - the length of the replacedStyledString's characters. * @param { StyledString } other - new StyledString. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replaceStyledString(start: number, length: number, other: StyledString): void; - /** * Insert new StyledString at the specified location. * * @param { number } start - the start position of the insertedStyledString. * @param { StyledString } other - new StyledString. - * @throws { BusinessError } 401 - Parameter error. Possible causes: + * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. *
2. Incorrect parameters types. *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ insertStyledString(start: number, other: StyledString): void; - /** * Append new StyledString at the end. * @@ -1553,13 +1317,10 @@ declare class MutableStyledString extends StyledString { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ appendStyledString(other: StyledString): void; } - - /** * the attribute type of the StyledString * @@ -1567,8 +1328,7 @@ declare class MutableStyledString extends StyledString { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum StyledStringKey { /** @@ -1577,155 +1337,127 @@ declare enum StyledStringKey { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FONT = 0, - /** * The key of DecorationStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - DECORATION = 1, - - /** - * The key of BaselineOffsetStyle. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - BASELINE_OFFSET = 2, - - /** - * The key of LetterSpacingStyle. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - LETTER_SPACING = 3, - - /** - * The key of TextShadowStyle. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - TEXT_SHADOW = 4, - - /** - * The key of LineHeightStyle. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - LINE_HEIGHT = 5, - - /** - * The key of BackgroundColorStyle. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 - */ - BACKGROUND_COLOR = 6, - - /** - * The key of UrlStyle. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 - */ - URL = 7, - + * @since 12 + */ + DECORATION = 1, + /** + * The key of BaselineOffsetStyle. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + BASELINE_OFFSET = 2, + /** + * The key of LetterSpacingStyle. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + LETTER_SPACING = 3, + /** + * The key of TextShadowStyle. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + TEXT_SHADOW = 4, + /** + * The key of LineHeightStyle. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + LINE_HEIGHT = 5, + /** + * The key of BackgroundColorStyle. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + BACKGROUND_COLOR = 6, + /** + * The key of UrlStyle. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + URL = 7, /** * The key of GestureStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ GESTURE = 100, - /** * The key of ParagraphStyle. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PARAGRAPH_STYLE = 200, - /** * The key of ImageAttachment. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ IMAGE = 300, - /** * The key of CustomSpan. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CUSTOM_SPAN = 400, - /** * The key of UserDataSpan. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - USER_DATA = 500, + USER_DATA = 500 } - /** * Defines ImageAttachment. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class ImageAttachment { - /** * constructor. * @@ -1736,7 +1468,6 @@ declare class ImageAttachment { * @since 12 */ constructor(value: ImageAttachmentInterface); - /** * constructor supported by AttachmentType. * @@ -1747,19 +1478,6 @@ declare class ImageAttachment { * @since 15 */ constructor(attachment: Optional); - - /** - * constructor supported by AttachmentType. - * - * @param { ImageAttachmentInterface | Optional } attachment - image attachment object. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - constructor(value: ImageAttachmentInterface | Optional); - /** * Get the image content of the StyledString. * @@ -1768,11 +1486,9 @@ declare class ImageAttachment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly value: PixelMap; - /** * Get the imageSize of the StyledString. * @@ -1781,11 +1497,9 @@ declare class ImageAttachment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly size?: SizeOptions; - /** * Get the ImageSpanAlignment of the StyledString. * @@ -1794,11 +1508,9 @@ declare class ImageAttachment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly verticalAlign?: ImageSpanAlignment; - /** * Get the imageFit of the StyledString. * @@ -1807,11 +1519,9 @@ declare class ImageAttachment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly objectFit?: ImageFit; - /** * Get the imageAttachmentLayoutStyle of the StyledString. * @@ -1820,11 +1530,9 @@ declare class ImageAttachment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly layoutStyle?: ImageAttachmentLayoutStyle; - /** * Get the imageAttachment colorFilter of the StyledString. * @@ -1833,12 +1541,10 @@ declare class ImageAttachment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ readonly colorFilter?: ColorFilterType; } - /** * Defines the ResourceImageAttachmentOptions. * @@ -1846,8 +1552,7 @@ declare class ImageAttachment { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare interface ResourceImageAttachmentOptions { /** @@ -1857,11 +1562,9 @@ declare interface ResourceImageAttachmentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ resourceValue: Optional; - /** * size of the ResourceImage. * @@ -1869,11 +1572,9 @@ declare interface ResourceImageAttachmentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ size?: SizeOptions; - /** * Image vertical align. * @@ -1881,11 +1582,9 @@ declare interface ResourceImageAttachmentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ verticalAlign?: ImageSpanAlignment; - /** * Sets the zoom type of the ImageAttachment. * @@ -1893,11 +1592,9 @@ declare interface ResourceImageAttachmentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ objectFit?: ImageFit; - /** * The Image Layout Style of the Resource Image. * @@ -1905,11 +1602,9 @@ declare interface ResourceImageAttachmentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ layoutStyle?: ImageAttachmentLayoutStyle; - /** * Sets the color filter effect on the image attachment. * @@ -1917,11 +1612,9 @@ declare interface ResourceImageAttachmentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ colorFilter?: ColorFilterType; - /** * Sets the synchronous or asynchronous mode for image loading. * The default parameter type is bool, and the default value is false. @@ -1930,12 +1623,10 @@ declare interface ResourceImageAttachmentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ syncLoad?: boolean; } - /** * Defines the ImageAttachmentInterface. * @@ -1943,8 +1634,7 @@ declare interface ResourceImageAttachmentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ImageAttachmentInterface { /** @@ -1954,11 +1644,9 @@ declare interface ImageAttachmentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ value: PixelMap; - /** * Image size. * @@ -1966,11 +1654,9 @@ declare interface ImageAttachmentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ size?: SizeOptions; - /** * Image vertical align. * @@ -1978,11 +1664,9 @@ declare interface ImageAttachmentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ verticalAlign?: ImageSpanAlignment; - /** * Image fit. * @@ -1990,11 +1674,9 @@ declare interface ImageAttachmentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ objectFit?: ImageFit; - /** * The Image Layout Style. * @@ -2002,11 +1684,9 @@ declare interface ImageAttachmentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ layoutStyle?: ImageAttachmentLayoutStyle; - /** * Sets the color filter effect on the image attachment. * @@ -2014,12 +1694,10 @@ declare interface ImageAttachmentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ colorFilter?: ColorFilterType; } - /** * Defines the Attachment Type. * @@ -2027,11 +1705,9 @@ declare interface ImageAttachmentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare type AttachmentType = ImageAttachmentInterface | ResourceImageAttachmentOptions; - /** * Defines the ColorFilter Type. * @@ -2039,11 +1715,9 @@ declare type AttachmentType = ImageAttachmentInterface | ResourceImageAttachment * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare type ColorFilterType = ColorFilter | DrawingColorFilter; - /** * Defines the ImageAttachment Layout Style. * @@ -2051,8 +1725,7 @@ declare type ColorFilterType = ColorFilter | DrawingColorFilter; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ImageAttachmentLayoutStyle { /** @@ -2062,11 +1735,9 @@ declare interface ImageAttachmentLayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ margin?: LengthMetrics | Margin; - /** * Inner margin. * @@ -2074,11 +1745,9 @@ declare interface ImageAttachmentLayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ padding?: LengthMetrics | Padding; - /** * Border radius. * @@ -2086,12 +1755,10 @@ declare interface ImageAttachmentLayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ borderRadius?: LengthMetrics | BorderRadiuses; } - /** * Defines the CustomSpanMetrics interface. * @@ -2099,8 +1766,7 @@ declare interface ImageAttachmentLayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface CustomSpanMetrics { /** @@ -2112,11 +1778,9 @@ declare interface CustomSpanMetrics { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width: number; - /** * CustomSpan Height. * The unit is vp. @@ -2125,12 +1789,10 @@ declare interface CustomSpanMetrics { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height?: number; } - /** * Defines the CustomSpanDrawInfo interface. * @@ -2138,63 +1800,54 @@ declare interface CustomSpanMetrics { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface CustomSpanDrawInfo { /** * CustomSpan's offset relative to the parent component. * The unit is px. - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ x: number; - /** * The top position of the line where customSpan is located. * The unit is px. - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineTop: number; - /** * The bottom position of the line where customSpan is located. * The unit is px. - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineBottom: number; - /** * The baseline offset of the line where customSpan is located. * The unit is px. - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ baseline: number; } - /** * Defines the CustomSpanMeasureInfo interface. * @@ -2202,32 +1855,28 @@ declare interface CustomSpanDrawInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface CustomSpanMeasureInfo { /** * Current component's fontSize value. * The unit is fp. - * + * * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontSize: number; } - /** * Defines CustomSpan. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare abstract class CustomSpan { /** @@ -2238,11 +1887,9 @@ declare abstract class CustomSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - abstract onMeasure(measureInfo: CustomSpanMeasureInfo) : CustomSpanMetrics; - + abstract onMeasure(measureInfo: CustomSpanMeasureInfo): CustomSpanMetrics; /** * Draw the custom span. * @@ -2251,30 +1898,26 @@ declare abstract class CustomSpan { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ abstract onDraw(context: DrawContext, drawInfo: CustomSpanDrawInfo): void; - /** * Invalidate all components that use the object, which will cause a re-render of all components. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ invalidate(): void; } - /** * Defines UserDataSpan. Used to store and obtain user data. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -declare abstract class UserDataSpan {} \ No newline at end of file +declare abstract class UserDataSpan { +} diff --git a/api/@internal/component/ets/swiper.d.ts b/api/@internal/component/ets/swiper.d.ts index cb232e2c3489f3b445736c068311a877f021f25c..bf63a8a7e52e1132d33a568b14796149665a55b4 100644 --- a/api/@internal/component/ets/swiper.d.ts +++ b/api/@internal/component/ets/swiper.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { IndicatorComponentController } from './indicatorcomponent'; -import { CommonMethod, Callback, ICurve, Optional, Bindable } from './common'; -import { EdgeEffect, Curve, PageFlipMode } from './enums'; -import { Length, LengthMetrics, VoidCallback, ResourceColor, VP, Font } from './units'; -/*** endif */ - /** * Provides methods for switching components. * @@ -46,8 +39,7 @@ import { Length, LengthMetrics, VoidCallback, ResourceColor, VP, Font } from './ * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class SwiperController { /** @@ -71,8 +63,7 @@ declare class SwiperController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -101,18 +92,6 @@ declare class SwiperController { */ showNext(); - /** - * Called when the next child component is displayed. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - showNext(): void; - /** * Called when the previous subcomponent is displayed. * @@ -138,18 +117,6 @@ declare class SwiperController { */ showPrevious(); - /** - * Called when the previous subcomponent is displayed. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - showPrevious(): void; - /** * Controlling Swiper to change to the specified subcomponent. * @@ -178,21 +145,6 @@ declare class SwiperController { */ changeIndex(index: number, animationMode?: SwiperAnimationMode | boolean); - /** - * Controlling Swiper to change to the specified subcomponent. - * - * @param { number } index - the index of item to be redirected. - * @param { SwiperAnimationMode | boolean } [animationMode] - animation mode for changeIndex, - * true is equivalent to SwiperAnimationMode.DEFAULT_ANIMATION, false is equivalent to SwiperAnimationMode.NO_ANIMATION - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - changeIndex(index: number, animationMode?: SwiperAnimationMode | boolean): void; - /** * Called when need to stop the swiper animation. * @@ -232,19 +184,6 @@ declare class SwiperController { */ finishAnimation(callback?: VoidCallback); - /** - * Called when need to stop the swiper animation. - * - * @param { ?VoidCallback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - finishAnimation(callback?: VoidCallback): void; - /** * Called when need to preload specified child. * @@ -259,8 +198,7 @@ declare class SwiperController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ preloadItems(indices: Optional>): Promise; } @@ -280,8 +218,7 @@ declare class SwiperController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class Indicator { /** @@ -303,8 +240,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ left(value: Length): T; @@ -327,8 +263,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ top(value: Length): T; @@ -352,8 +287,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ right(value: Length): T; @@ -377,8 +311,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ bottom(value: Length): T; @@ -407,8 +340,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start(value: LengthMetrics): T; @@ -422,8 +354,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ end(value: LengthMetrics): T; @@ -446,8 +377,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ static dot(): DotIndicator; @@ -470,8 +400,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ static digit(): DigitIndicator; } @@ -493,8 +422,7 @@ declare class Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class DotIndicator extends Indicator { /** @@ -512,8 +440,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -537,8 +464,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ itemWidth(value: Length): DotIndicator; @@ -562,8 +488,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ itemHeight(value: Length): DotIndicator; @@ -587,8 +512,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedItemWidth(value: Length): DotIndicator; @@ -612,8 +536,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedItemHeight(value: Length): DotIndicator; @@ -637,8 +560,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ mask(value: boolean): DotIndicator; @@ -662,8 +584,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ color(value: ResourceColor): DotIndicator; @@ -687,8 +608,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedColor(value: ResourceColor): DotIndicator; @@ -700,8 +620,7 @@ declare class DotIndicator extends Indicator { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ maxDisplayCount(maxDisplayCount: number): DotIndicator; @@ -714,8 +633,7 @@ declare class DotIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ space(space: LengthMetrics): DotIndicator; } @@ -744,8 +662,7 @@ declare class DotIndicator extends Indicator { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface SwiperAutoFill { /** @@ -761,8 +678,7 @@ declare interface SwiperAutoFill { * @type { VP } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 * @form */ minSize: VP; @@ -785,8 +701,7 @@ declare interface SwiperAutoFill { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class DigitIndicator extends Indicator { /** @@ -804,8 +719,7 @@ declare class DigitIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -828,8 +742,7 @@ declare class DigitIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): DigitIndicator; @@ -853,8 +766,7 @@ declare class DigitIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedFontColor(value: ResourceColor): DigitIndicator; @@ -883,8 +795,7 @@ declare class DigitIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ digitFont(value: Font): DigitIndicator; @@ -908,8 +819,7 @@ declare class DigitIndicator extends Indicator { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedDigitFont(value: Font): DigitIndicator; } @@ -928,8 +838,7 @@ declare class DigitIndicator extends Indicator { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ArrowStyle { /** @@ -948,8 +857,7 @@ declare interface ArrowStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showBackground?: boolean; @@ -971,8 +879,7 @@ declare interface ArrowStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ isSidebarMiddle?: boolean; @@ -994,8 +901,7 @@ declare interface ArrowStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ backgroundSize?: Length; @@ -1015,8 +921,7 @@ declare interface ArrowStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ backgroundColor?: ResourceColor; @@ -1040,8 +945,7 @@ declare interface ArrowStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ arrowSize?: Length; @@ -1061,8 +965,7 @@ declare interface ArrowStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ arrowColor?: ResourceColor; } @@ -1091,8 +994,7 @@ declare interface ArrowStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SwiperDisplayMode { /** @@ -1132,8 +1034,7 @@ declare enum SwiperDisplayMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ STRETCH, @@ -1183,8 +1084,8 @@ declare enum SwiperDisplayMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface SwiperInterface { /** @@ -1214,8 +1115,7 @@ interface SwiperInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (controller?: SwiperController): SwiperAttribute; } @@ -1325,8 +1225,7 @@ declare interface IndicatorStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface SwiperAnimationEvent { /** @@ -1345,8 +1244,7 @@ declare interface SwiperAnimationEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ currentOffset: number; @@ -1366,8 +1264,7 @@ declare interface SwiperAnimationEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ targetOffset: number; @@ -1387,8 +1284,7 @@ declare interface SwiperAnimationEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ velocity: number; } @@ -1401,8 +1297,7 @@ declare interface SwiperAnimationEvent { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface AutoPlayOptions { /** @@ -1414,8 +1309,7 @@ declare interface AutoPlayOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ stopWhenTouched: boolean; } @@ -1426,8 +1320,7 @@ declare interface AutoPlayOptions { * @enum { number } SwiperNestedScrollMode * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SwiperNestedScrollMode { /** @@ -1436,8 +1329,7 @@ declare enum SwiperNestedScrollMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ SELF_ONLY = 0, @@ -1446,8 +1338,7 @@ declare enum SwiperNestedScrollMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ SELF_FIRST = 1, } @@ -1460,8 +1351,7 @@ declare enum SwiperNestedScrollMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare enum SwiperAnimationMode { /** @@ -1471,8 +1361,7 @@ declare enum SwiperAnimationMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ NO_ANIMATION = 0, @@ -1483,8 +1372,7 @@ declare enum SwiperAnimationMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ DEFAULT_ANIMATION = 1, @@ -1496,8 +1384,7 @@ declare enum SwiperAnimationMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ FAST_ANIMATION = 2, } @@ -1513,8 +1400,7 @@ declare enum SwiperAnimationMode { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnSwiperAnimationStartCallback = (index: number, targetIndex: number, extraInfo: SwiperAnimationEvent) => void; @@ -1528,8 +1414,7 @@ declare type OnSwiperAnimationStartCallback = (index: number, targetIndex: numbe * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnSwiperAnimationEndCallback = (index: number, extraInfo: SwiperAnimationEvent) => void; @@ -1542,8 +1427,7 @@ declare type OnSwiperAnimationEndCallback = (index: number, extraInfo: SwiperAni * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnSwiperGestureSwipeCallback = (index: number, extraInfo: SwiperAnimationEvent) => void; @@ -1571,8 +1455,8 @@ declare type OnSwiperGestureSwipeCallback = (index: number, extraInfo: SwiperAni * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class SwiperAttribute extends CommonMethod { /** @@ -1607,19 +1491,6 @@ declare class SwiperAttribute extends CommonMethod { * @since 11 */ index(value: number): SwiperAttribute; - /** - * Called when the index value of the displayed subcomponent is set in the container. - * - * @param { number | Bindable } value - * @returns { SwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - index(value: number | Bindable): SwiperAttribute; /** * Called when setting whether the subcomponent plays automatically. @@ -1678,8 +1549,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ autoPlay(autoPlay: boolean, options: AutoPlayOptions): SwiperAttribute; @@ -1711,8 +1581,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interval(value: number): SwiperAttribute; @@ -1758,8 +1627,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ indicator(indicator: IndicatorComponentController | DotIndicator | DigitIndicator | boolean): SwiperAttribute; @@ -1782,8 +1650,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ displayArrow(value: ArrowStyle | boolean, isHoverShow?: boolean): SwiperAttribute; @@ -1814,8 +1681,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ loop(value: boolean): SwiperAttribute; @@ -1845,8 +1711,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ duration(value: number): SwiperAttribute; @@ -1877,8 +1742,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ vertical(value: boolean): SwiperAttribute; @@ -1916,8 +1780,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ itemSpace(value: number | string): SwiperAttribute; @@ -1950,8 +1813,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ displayMode(value: SwiperDisplayMode): SwiperAttribute; @@ -1988,8 +1850,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ cachedCount(value: number): SwiperAttribute; @@ -2005,8 +1866,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ cachedCount(count: number, isShown: boolean): SwiperAttribute; @@ -2045,8 +1905,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ displayCount(value: number | string | SwiperAutoFill, swipeByGroup?: boolean): SwiperAttribute; @@ -2082,8 +1941,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ effectMode(value: EdgeEffect): SwiperAttribute; @@ -2114,8 +1972,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ disableSwipe(value: boolean): SwiperAttribute; @@ -2151,8 +2008,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ curve(value: Curve | string | ICurve): SwiperAttribute; @@ -2195,8 +2051,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange(event: Callback): SwiperAttribute; @@ -2209,8 +2064,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onSelected(event: Callback): SwiperAttribute; @@ -2265,8 +2119,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ prevMargin(value: Length, ignoreBlank?: boolean): SwiperAttribute; @@ -2310,8 +2163,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ nextMargin(value: Length, ignoreBlank?: boolean): SwiperAttribute; @@ -2324,8 +2176,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onUnselected(event: Callback): SwiperAttribute; @@ -2387,8 +2238,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onAnimationStart(event: OnSwiperAnimationStartCallback): SwiperAttribute; @@ -2435,8 +2285,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onAnimationEnd(event: OnSwiperAnimationEndCallback): SwiperAttribute; @@ -2472,8 +2321,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onGestureSwipe(event: OnSwiperGestureSwipeCallback): SwiperAttribute; @@ -2492,8 +2340,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ nestedScroll(value: SwiperNestedScrollMode): SwiperAttribute; @@ -2514,8 +2361,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ customContentTransition(transition: SwiperContentAnimatedTransition): SwiperAttribute; @@ -2540,8 +2386,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onContentDidScroll(handler: ContentDidScrollCallback): SwiperAttribute; @@ -2553,8 +2398,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ indicatorInteractive(value: boolean): SwiperAttribute; @@ -2567,8 +2411,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ pageFlipMode(mode: Optional): SwiperAttribute; @@ -2581,8 +2424,7 @@ declare class SwiperAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ onContentWillScroll(handler: ContentWillScrollCallback): SwiperAttribute; @@ -2608,8 +2450,7 @@ declare class SwiperAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface SwiperContentAnimatedTransition { /** @@ -2621,8 +2462,7 @@ declare interface SwiperContentAnimatedTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ timeout?: number; @@ -2633,8 +2473,7 @@ declare interface SwiperContentAnimatedTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ transition: Callback; } @@ -2646,8 +2485,7 @@ declare interface SwiperContentAnimatedTransition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface SwiperContentTransitionProxy { /** @@ -2657,8 +2495,7 @@ declare interface SwiperContentTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ selectedIndex: number; @@ -2669,8 +2506,7 @@ declare interface SwiperContentTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ index: number; @@ -2681,8 +2517,7 @@ declare interface SwiperContentTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ position: number; @@ -2693,8 +2528,7 @@ declare interface SwiperContentTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ mainAxisLength: number; @@ -2704,8 +2538,7 @@ declare interface SwiperContentTransitionProxy { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ finishTransition(): void; } @@ -2718,8 +2551,7 @@ declare interface SwiperContentTransitionProxy { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare interface SwiperContentWillScrollResult { /** @@ -2730,8 +2562,7 @@ declare interface SwiperContentWillScrollResult { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ currentIndex: number; @@ -2743,8 +2574,7 @@ declare interface SwiperContentWillScrollResult { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ comingIndex: number; @@ -2757,8 +2587,7 @@ declare interface SwiperContentWillScrollResult { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ offset: number; } @@ -2774,8 +2603,7 @@ declare interface SwiperContentWillScrollResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type ContentDidScrollCallback = (selectedIndex: number, index: number, position: number, mainAxisLength: number) => void; @@ -2789,8 +2617,7 @@ declare type ContentDidScrollCallback = (selectedIndex: number, index: number, p * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare type ContentWillScrollCallback = (result: SwiperContentWillScrollResult) => boolean; @@ -2816,6 +2643,7 @@ declare type ContentWillScrollCallback = (result: SwiperContentWillScrollResult) * @form * @atomicservice * @since 11 + * @noninterop */ declare const Swiper: SwiperInterface; @@ -2841,5 +2669,6 @@ declare const Swiper: SwiperInterface; * @form * @atomicservice * @since 11 + * @noninterop */ declare const SwiperInstance: SwiperAttribute; diff --git a/api/@internal/component/ets/symbol_span.d.ts b/api/@internal/component/ets/symbol_span.d.ts index d78fc42c8c89daecb28934b517def4dd185eae4c..c11965a765e2aed98e742e75d274dfd563516d31 100644 --- a/api/@internal/component/ets/symbol_span.d.ts +++ b/api/@internal/component/ets/symbol_span.d.ts @@ -18,14 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from './../../../api/global/resource'; -import { CommonMethod, AttributeModifier } from './common'; -import { ResourceColor } from './units'; -import { FontWeight } from './enums'; -import { SymbolEffectStrategy, SymbolRenderingStrategy } from './symbolglyph'; -/*** endif */ - /** * Provides an interface for SymbolSpan. * @@ -51,7 +43,6 @@ import { SymbolEffectStrategy, SymbolRenderingStrategy } from './symbolglyph'; * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ interface SymbolSpanInterface { /** @@ -82,7 +73,6 @@ interface SymbolSpanInterface { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ (value: Resource): SymbolSpanAttribute; } @@ -112,7 +102,6 @@ interface SymbolSpanInterface { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ declare class SymbolSpanAttribute extends CommonMethod { /** @@ -143,7 +132,6 @@ declare class SymbolSpanAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ fontSize(value: number | string | Resource): SymbolSpanAttribute; @@ -175,7 +163,6 @@ declare class SymbolSpanAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ fontColor(value: Array): SymbolSpanAttribute; @@ -207,7 +194,6 @@ declare class SymbolSpanAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ fontWeight(value: number | FontWeight | string): SymbolSpanAttribute; @@ -239,7 +225,6 @@ declare class SymbolSpanAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ effectStrategy(value: SymbolEffectStrategy): SymbolSpanAttribute; @@ -271,7 +256,6 @@ declare class SymbolSpanAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ renderingStrategy(value: SymbolRenderingStrategy): SymbolSpanAttribute; @@ -293,7 +277,6 @@ declare class SymbolSpanAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ attributeModifier(modifier: AttributeModifier): SymbolSpanAttribute; } diff --git a/api/@internal/component/ets/tab_content.d.ts b/api/@internal/component/ets/tab_content.d.ts index 56eb3f714ad4c8d34039f841e950dbc7940aff3f..ad95ca2d59b171bc37555ef4c9a2ba8881a6e205 100644 --- a/api/@internal/component/ets/tab_content.d.ts +++ b/api/@internal/component/ets/tab_content.d.ts @@ -18,15 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonMethod } from './common'; -import { CustomBuilder } from './builder' -import { TextHeightAdaptivePolicy, TextOverflow, VerticalAlign } from './enums'; -import { Dimension, Font, Length, LocalizedPadding, Padding, Resource, ResourceColor, ResourceStr, VoidCallback } from './units'; -import { ComponentContent } from '../ComponentContent' -import { SymbolGlyphModifier } from '../SymbolGlyphModifier'; -/*** endif */ - /** * Enum for the mode of the tab bar when selected. * @@ -42,8 +33,7 @@ import { SymbolGlyphModifier } from '../SymbolGlyphModifier'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SelectedMode { /** @@ -59,8 +49,7 @@ declare enum SelectedMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ INDICATOR, @@ -77,8 +66,7 @@ declare enum SelectedMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ BOARD } @@ -98,8 +86,7 @@ declare enum SelectedMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum LayoutMode { @@ -116,8 +103,7 @@ declare enum LayoutMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ AUTO = 0, /** @@ -133,8 +119,7 @@ declare enum LayoutMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ VERTICAL = 1, @@ -151,8 +136,7 @@ declare enum LayoutMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ HORIZONTAL = 2 } @@ -284,77 +268,6 @@ interface IndicatorStyle { marginTop?: Length; } -/** - * Provide an interface for the style of an SubTabBar indicator including color, height, width, border radius - * and margin top - * - * @interface SubTabBarIndicatorStyle - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare interface SubTabBarIndicatorStyle { - /** - * Define the color of the indicator - * - * @type { ?ResourceColor } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - color?: ResourceColor; - - /** - * Define the height of the indicator - * - * @type { ?Length } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - height?: Length; - - /** - * Define the width of the indicator. - * If it is 0, the width will be equal to the width of the content - * - * @type { ?Length } - * @default 0 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - width?: Length; - - /** - * Define the border radius of the indicator - * - * @type { ?Length } - * @default 0 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - borderRadius?: Length; - - /** - * Define the margin top of the indicator - * - * @type { ?Length } - * @default 8 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - marginTop?: Length; -} - /** * Provide an interface for the style of an indicator including border radius * @@ -370,8 +283,7 @@ declare interface SubTabBarIndicatorStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface BoardStyle { /** @@ -389,8 +301,7 @@ interface BoardStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ borderRadius?: Length; } @@ -555,115 +466,6 @@ declare interface LabelStyle { unselectedColor?: ResourceColor; } -/** - * TabBarLabelStyle object. - * - * @interface TabBarLabelStyle - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare interface TabBarLabelStyle { - - /** - * overflow mode. - * - * @type { ?TextOverflow } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - overflow?: TextOverflow; - - /** - * Label max lines. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - maxLines?: number; - - /** - * Min font size for adapted height. - * - * @type { ?(number | ResourceStr) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - minFontSize?: number | ResourceStr; - - /** - * Max font size for adapted height. - * - * @type { ?(number | ResourceStr) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - maxFontSize?: number | ResourceStr; - - /** - * Adapt text height option. - * - * @type { ?TextHeightAdaptivePolicy } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - heightAdaptivePolicy?: TextHeightAdaptivePolicy; - - /** - * Font style. - * - * @type { ?Font } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - font?: Font; - - /** - * The text color of the selected tab bar. - * - * @type { ?ResourceColor } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selectedColor?: ResourceColor; - - /** - * The text color of the unselected tab bar. - * - * @type { ?ResourceColor } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - unselectedColor?: ResourceColor; -} - /** * TabBarIconStyle object. * @@ -671,8 +473,7 @@ declare interface TabBarLabelStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TabBarIconStyle { /** @@ -682,8 +483,7 @@ declare interface TabBarIconStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ selectedColor?: ResourceColor; @@ -694,8 +494,7 @@ declare interface TabBarIconStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ unselectedColor?: ResourceColor; } @@ -714,14 +513,12 @@ declare interface TabBarIconStyle { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ declare class TabBarSymbol { /** - * Symbol icon in the normal style. + * The properties of the symbol icon in the tab bar need to be unselected. * * @type { SymbolGlyphModifier } - * @default fontColor: #66182431, renderingStrategy: SymbolRenderingStrategy.MULTIPLE_OPACITY, fontSize: 24vp * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 @@ -735,15 +532,13 @@ declare class TabBarSymbol { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ normal: SymbolGlyphModifier; /** - * Symbol icon in the selected style. + * The properties of the symbol icon in the tab bar need to be unselected. * * @type { ?SymbolGlyphModifier } - * @default fontColor: #ff007dff, renderingStrategy: SymbolRenderingStrategy.MULTIPLE_OPACITY, fontSize: 24vp * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 @@ -757,7 +552,6 @@ declare class TabBarSymbol { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ selected?: SymbolGlyphModifier; } @@ -769,8 +563,7 @@ declare class TabBarSymbol { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface TabBarOptions { /** @@ -810,8 +603,7 @@ declare interface TabBarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ icon?: string | Resource; @@ -847,8 +639,7 @@ declare interface TabBarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ text?: string | Resource } @@ -872,8 +663,7 @@ declare interface TabBarOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class SubTabBarStyle { /** @@ -898,8 +688,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(content: ResourceStr); /** @@ -909,8 +698,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(content: ResourceStr | ComponentContent); @@ -933,8 +721,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ static of(content: ResourceStr): SubTabBarStyle; /** @@ -946,8 +733,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static of(content: ResourceStr | ComponentContent): SubTabBarStyle; @@ -972,18 +758,6 @@ declare class SubTabBarStyle { */ indicator(value: IndicatorStyle): SubTabBarStyle; - /** - * Set the style of the indicator when selected - * - * @param { SubTabBarIndicatorStyle } style - indicates the indicator style of the sub tab bar - * @returns { SubTabBarStyle } the style of the sub tab bar - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - indicator(style: SubTabBarIndicatorStyle): SubTabBarStyle; - /** * Set the mode of the indicator when selected * @@ -1005,8 +779,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedMode(value: SelectedMode): SubTabBarStyle; @@ -1031,8 +804,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ board(value: BoardStyle): SubTabBarStyle; @@ -1057,18 +829,6 @@ declare class SubTabBarStyle { */ labelStyle(value: LabelStyle): SubTabBarStyle; - /** - * Set the label style of the sub tab bar - * - * @param { TabBarLabelStyle } style - indicates the label style of the sub tab bar - * @returns { SubTabBarStyle } the style of the sub tab bar - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - labelStyle(style: TabBarLabelStyle): SubTabBarStyle; - /** * Set the padding of the sub tab bar * @@ -1091,8 +851,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ padding(value: Padding | Dimension): SubTabBarStyle; @@ -1108,8 +867,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ padding(padding: LocalizedPadding): SubTabBarStyle; @@ -1130,8 +888,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id(value: string): SubTabBarStyle; } @@ -1155,8 +912,7 @@ declare class SubTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class BottomTabBarStyle { /** @@ -1194,8 +950,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(icon: ResourceStr | TabBarSymbol, text: ResourceStr); @@ -1232,8 +987,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static of(icon: ResourceStr | TabBarSymbol, text: ResourceStr): BottomTabBarStyle; @@ -1258,18 +1012,6 @@ declare class BottomTabBarStyle { */ labelStyle(value: LabelStyle): BottomTabBarStyle; - /** - * Set the label style of the bottom tab bar - * - * @param { TabBarLabelStyle } style - indicates the label style of the bottom tab bar - * @returns { BottomTabBarStyle } the style of the bottom tab bar - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - labelStyle(style: TabBarLabelStyle): BottomTabBarStyle; - /** * Set the padding of the bottom tab bar * @@ -1303,8 +1045,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ padding(value: Padding | Dimension | LocalizedPadding): BottomTabBarStyle; @@ -1326,8 +1067,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ layoutMode(value: LayoutMode): BottomTabBarStyle; @@ -1349,8 +1089,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ verticalAlign(value: VerticalAlign): BottomTabBarStyle; @@ -1376,8 +1115,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ symmetricExtensible(value: boolean): BottomTabBarStyle; @@ -1398,8 +1136,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id(value: string): BottomTabBarStyle; @@ -1411,8 +1148,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconStyle(style: TabBarIconStyle): BottomTabBarStyle; } @@ -1439,8 +1175,7 @@ declare class BottomTabBarStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface TabContentInterface { /** @@ -1465,8 +1200,7 @@ interface TabContentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (): TabContentAttribute; } @@ -1493,8 +1227,7 @@ interface TabContentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TabContentAttribute extends CommonMethod { /** @@ -1599,8 +1332,7 @@ declare class TabContentAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ tabBar(content: ComponentContent | SubTabBarStyle | BottomTabBarStyle | string | Resource | CustomBuilder | TabBarOptions): TabContentAttribute; @@ -1614,8 +1346,7 @@ declare class TabContentAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillShow(event: VoidCallback): TabContentAttribute; @@ -1628,8 +1359,7 @@ declare class TabContentAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillHide(event: VoidCallback): TabContentAttribute; } @@ -1654,6 +1384,7 @@ declare class TabContentAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 11 + * @noninterop */ declare const TabContent: TabContentInterface; @@ -1677,5 +1408,6 @@ declare const TabContent: TabContentInterface; * @crossplatform * @atomicservice * @since 11 + * @noninterop */ declare const TabContentInstance: TabContentAttribute; diff --git a/api/@internal/component/ets/tabs.d.ts b/api/@internal/component/ets/tabs.d.ts index a5c460d779aa0cc7f13c35c028540194c4e5ec31..ce3662c4b4b2da59c33cb232cabf4eac419554d0 100644 --- a/api/@internal/component/ets/tabs.d.ts +++ b/api/@internal/component/ets/tabs.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { BackgroundBlurStyleOptions, BackgroundEffectOptions, BlurStyle, Callback, CommonMethod, Optional, TranslateOptions, DividerStyle, Bindable } from './common'; -import { EdgeEffect, PageFlipMode } from './enums'; -import { Dimension, Length, ResourceColor } from './units'; -/*** endif */ - /** * CommonModifier * @@ -57,8 +51,7 @@ declare type CommonModifier = import('../api/arkui/CommonModifier').CommonModifi * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum BarMode { /** @@ -82,8 +75,7 @@ declare enum BarMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Scrollable = 0, @@ -107,10 +99,9 @@ declare enum BarMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - Fixed = 1, + Fixed = 1 } /** @@ -120,8 +111,7 @@ declare enum BarMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum AnimationMode { /** @@ -130,8 +120,7 @@ declare enum AnimationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CONTENT_FIRST = 0, @@ -141,8 +130,7 @@ declare enum AnimationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ACTION_FIRST = 1, @@ -152,8 +140,7 @@ declare enum AnimationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NO_ANIMATION = 2, @@ -164,8 +151,7 @@ declare enum AnimationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ CONTENT_FIRST_WITH_JUMP = 3, @@ -176,8 +162,7 @@ declare enum AnimationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ACTION_FIRST_WITH_JUMP = 4, } @@ -204,8 +189,7 @@ declare enum AnimationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum BarPosition { /** @@ -227,8 +211,7 @@ declare enum BarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Start, @@ -251,8 +234,7 @@ declare enum BarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ End, } @@ -272,8 +254,7 @@ declare enum BarPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum LayoutStyle { /** @@ -290,8 +271,7 @@ declare enum LayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ALWAYS_CENTER = 0, /** @@ -308,8 +288,7 @@ declare enum LayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ALWAYS_AVERAGE_SPLIT = 1, /** @@ -329,8 +308,7 @@ declare enum LayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ SPACE_BETWEEN_OR_CENTER = 2 } @@ -342,8 +320,7 @@ declare enum LayoutStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare enum TabsCacheMode { /** @@ -352,8 +329,7 @@ declare enum TabsCacheMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ CACHE_BOTH_SIDE = 0, @@ -363,8 +339,7 @@ declare enum TabsCacheMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ CACHE_LATEST_SWITCHED = 1 } @@ -388,8 +363,7 @@ declare enum TabsCacheMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TabsController { /** @@ -411,8 +385,7 @@ declare class TabsController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -439,8 +412,7 @@ declare class TabsController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ changeIndex(value: number): void; @@ -456,8 +428,7 @@ declare class TabsController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ preloadItems(indices: Optional>): Promise; @@ -468,8 +439,7 @@ declare class TabsController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ setTabBarTranslate(translate: TranslateOptions): void; @@ -480,8 +450,7 @@ declare class TabsController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ setTabBarOpacity(opacity: number): void; } @@ -493,8 +462,7 @@ declare class TabsController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare interface TabsOptions { /** @@ -519,8 +487,7 @@ declare interface TabsOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barPosition?: BarPosition; @@ -549,17 +516,6 @@ declare interface TabsOptions { * @since 11 */ index?: number; - /** - * Set the index of the currently displayed tab. - * - * @type { ?(number | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - index?: number | Bindable; /** * Set the Tabs controller. @@ -583,10 +539,9 @@ declare interface TabsOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - controller?: TabsController + controller?: TabsController; /** * Set common attributes to tabbar. @@ -622,8 +577,7 @@ declare interface TabsOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface TabsInterface { /** @@ -661,8 +615,7 @@ interface TabsInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ (options?: TabsOptions): TabsAttribute; } @@ -786,8 +739,7 @@ interface DividerStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TabsAnimationEvent { /** @@ -807,8 +759,7 @@ declare interface TabsAnimationEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ currentOffset: number; @@ -829,8 +780,7 @@ declare interface TabsAnimationEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ targetOffset: number; @@ -851,8 +801,7 @@ declare interface TabsAnimationEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ velocity: number; } @@ -872,8 +821,7 @@ declare interface TabsAnimationEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface BarGridColumnOptions { /** @@ -893,8 +841,7 @@ interface BarGridColumnOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ sm?: number; @@ -915,8 +862,7 @@ interface BarGridColumnOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ md?: number; @@ -937,8 +883,7 @@ interface BarGridColumnOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lg?: number; @@ -958,8 +903,7 @@ interface BarGridColumnOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ margin?: Dimension; @@ -979,8 +923,7 @@ interface BarGridColumnOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ gutter?: Dimension; } @@ -1000,8 +943,7 @@ interface BarGridColumnOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface ScrollableBarModeOptions { /** @@ -1020,8 +962,7 @@ interface ScrollableBarModeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ margin?: Dimension; @@ -1041,8 +982,7 @@ interface ScrollableBarModeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ nonScrollableLayoutStyle?: LayoutStyle; } @@ -1057,8 +997,7 @@ interface ScrollableBarModeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnTabsAnimationStartCallback = (index: number, targetIndex: number, extraInfo: TabsAnimationEvent) => void; @@ -1071,8 +1010,7 @@ declare type OnTabsAnimationStartCallback = (index: number, targetIndex: number, * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnTabsAnimationEndCallback = (index: number, extraInfo: TabsAnimationEvent) => void; @@ -1085,8 +1023,7 @@ declare type OnTabsAnimationEndCallback = (index: number, extraInfo: TabsAnimati * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnTabsGestureSwipeCallback = (index: number, extraInfo: TabsAnimationEvent) => void; @@ -1100,8 +1037,7 @@ declare type OnTabsGestureSwipeCallback = (index: number, extraInfo: TabsAnimati * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type TabsCustomContentTransitionCallback = (from: number, to: number) => TabContentAnimatedTransition | undefined; @@ -1117,8 +1053,7 @@ declare type TabsCustomContentTransitionCallback = (from: number, to: number) => * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnTabsContentWillChangeCallback = (currentIndex: number, comingIndex: number) => boolean; @@ -1144,8 +1079,7 @@ declare type OnTabsContentWillChangeCallback = (currentIndex: number, comingInde * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TabsAttribute extends CommonMethod { /** @@ -1173,8 +1107,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ vertical(value: boolean): TabsAttribute; @@ -1203,8 +1136,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barPosition(value: BarPosition): TabsAttribute; @@ -1233,8 +1165,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scrollable(value: boolean): TabsAttribute; @@ -1314,8 +1245,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barMode(value: BarMode, options?: ScrollableBarModeOptions): TabsAttribute; @@ -1357,8 +1287,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barWidth(value: Length): TabsAttribute; @@ -1400,12 +1329,11 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barHeight(value: Length): TabsAttribute; - /** + /** * Called when the height of the bar graph is set. * Notice: barHeight only supports Number type on 7, supports Length type since 8. * @@ -1418,7 +1346,7 @@ declare class TabsAttribute extends CommonMethod { * @atomicservice * @since 20 */ - barHeight(height: Length, noMinHeightLimit: boolean): TabsAttribute; + barHeight(height: Length, noMinHeightLimit: boolean): TabsAttribute; /** * Sets the animation curve @@ -1436,7 +1364,7 @@ declare class TabsAttribute extends CommonMethod { * @atomicservice * @since 20 */ - animationCurve(curve: Curve | ICurve): TabsAttribute; + animationCurve(curve: Curve | ICurve): TabsAttribute; /** * Called when the animation duration of the bar graph is set. @@ -1464,8 +1392,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ animationDuration(value: number): TabsAttribute; @@ -1479,8 +1406,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ animationMode(mode: Optional): TabsAttribute; @@ -1493,8 +1419,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ edgeEffect(edgeEffect: Optional): TabsAttribute; @@ -1542,23 +1467,21 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange(event: Callback): TabsAttribute; /** - * Called when a new tab becomes selected. Animation is not necessarily complete. + * Called when a new tab becomes unselected. Animation is not necessarily complete. * - * @param { Callback } event - callback to notify which index has been selected + * @param { Callback } event - callback to notify which index has been unselected * @returns { TabsAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ - onSelected(event: Callback): TabsAttribute; + onUnselected(event: Callback): TabsAttribute; /** * Called when the tab is clicked. @@ -1588,24 +1511,10 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onTabBarClick(event: Callback): TabsAttribute; - /** - * Called when a new tab becomes unselected. Animation is not necessarily complete. - * - * @param { Callback } event - callback to notify which index has been unselected - * @returns { TabsAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - onUnselected(event: Callback): TabsAttribute; - /** * Called when the tab content flip animation start. * @@ -1640,8 +1549,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onAnimationStart(handler: OnTabsAnimationStartCallback): TabsAttribute; @@ -1677,8 +1585,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onAnimationEnd(handler: OnTabsAnimationEndCallback): TabsAttribute; @@ -1714,8 +1621,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onGestureSwipe(handler: OnTabsGestureSwipeCallback): TabsAttribute; @@ -1742,8 +1648,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fadingEdge(value: boolean): TabsAttribute; @@ -1764,8 +1669,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ divider(value: DividerStyle | null): TabsAttribute; @@ -1785,8 +1689,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barOverlap(value: boolean): TabsAttribute; @@ -1807,8 +1710,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barBackgroundColor(value: ResourceColor): TabsAttribute; @@ -1833,8 +1735,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barGridAlign(value: BarGridColumnOptions): TabsAttribute; @@ -1892,8 +1793,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ customContentTransition(delegate: TabsCustomContentTransitionCallback): TabsAttribute; @@ -1905,8 +1805,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barBackgroundBlurStyle(value: BlurStyle): TabsAttribute; @@ -1918,8 +1817,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ pageFlipMode(mode: Optional): TabsAttribute; @@ -1932,8 +1830,7 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ barBackgroundBlurStyle(style: BlurStyle, options: BackgroundBlurStyleOptions): TabsAttribute; @@ -1945,11 +1842,23 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ barBackgroundEffect(options: BackgroundEffectOptions): TabsAttribute; + /** + * Sets the maximum number of child components to be cached. + * + * @param { number } count - the maximum number of child components to be cached. + * @param { TabsCacheMode } mode - the mode of caching child components. + * @returns { TabsAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 19 + */ + cachedMaxCount(count: number, mode: TabsCacheMode): TabsAttribute; + /** * Called when content will change. * @@ -1983,24 +1892,21 @@ declare class TabsAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onContentWillChange(handler: OnTabsContentWillChangeCallback): TabsAttribute; /** - * Sets the maximum number of child components to be cached. + * Called when a new tab becomes selected. Animation is not necessarily complete. * - * @param { number } count - the maximum number of child components to be cached. - * @param { TabsCacheMode } mode - the mode of caching child components. + * @param { Callback } event - callback to notify which index has been selected * @returns { TabsAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ - cachedMaxCount(count: number, mode: TabsCacheMode): TabsAttribute; + onSelected(event: Callback): TabsAttribute; } /** @@ -2020,8 +1926,7 @@ declare class TabsAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TabContentAnimatedTransition { /** @@ -2045,8 +1950,7 @@ declare interface TabContentAnimatedTransition { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ timeout?: number; @@ -2078,8 +1982,7 @@ declare interface TabContentAnimatedTransition { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ transition: Callback; } @@ -2101,8 +2004,7 @@ declare interface TabContentAnimatedTransition { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TabContentTransitionProxy { /** @@ -2122,8 +2024,7 @@ declare interface TabContentTransitionProxy { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ from: number; @@ -2144,8 +2045,7 @@ declare interface TabContentTransitionProxy { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ to: number; @@ -2164,8 +2064,7 @@ declare interface TabContentTransitionProxy { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ finishTransition(): void; } diff --git a/api/@internal/component/ets/text_area.d.ts b/api/@internal/component/ets/text_area.d.ts index 89c7e073de1493a3a78c99e79669c1dce7d81e52..90fefc9c455cec56d33fbc3dd410d2e399c6a06e 100644 --- a/api/@internal/component/ets/text_area.d.ts +++ b/api/@internal/component/ets/text_area.d.ts @@ -18,20 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { KeyboardOptions, PasteEvent } from './richEditor'; -import { CaretStyle, DeleteValue, EditMenuOptions, EditableTextOnChangeCallback, InsertValue, - AutoCapitalizationMode,EditableTextChangeValue,KeyboardAppearance } from './textCommon'; -import { BarState, CopyOptions, FontStyle, FontWeight, LineBreakStrategy, TextContentStyle, TextAlign, TextOverflow, - TextHeightAdaptivePolicy, WordBreak, EllipsisMode } from './enums'; -import { EnterKeyType, SubmitEvent, ContentType } from './textInput'; -import { Dimension, Font, Length, LengthMetrics, ResourceColor, ResourceStr } from './units'; -import { InputCounterOptions, TextContentControllerBase, SelectionOptions, - TextDecorationOptions, CommonMethod, Callback, Optional, Bindable } from './common'; -import { CustomBuilder } from './builder'; -import { Resource } from '../../global/resource'; -/*** endif */ - /** * Provides the method of switching the cursor position. * @@ -53,8 +39,7 @@ import { Resource } from '../../global/resource'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TextAreaController extends TextContentControllerBase { /** @@ -77,8 +62,7 @@ declare class TextAreaController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -104,8 +88,7 @@ declare class TextAreaController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ caretPosition(value: number): void; @@ -149,8 +132,7 @@ declare class TextAreaController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setTextSelection(selectionStart: number, selectionEnd: number, options?: SelectionOptions): void; @@ -167,8 +149,7 @@ declare class TextAreaController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ stopEditing(): void; } @@ -195,8 +176,7 @@ declare class TextAreaController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TextAreaOptions { /** @@ -227,8 +207,7 @@ declare interface TextAreaOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ placeholder?: ResourceStr; @@ -263,18 +242,6 @@ declare interface TextAreaOptions { */ text?: ResourceStr; - /** - * Sets the current value of TextArea. - * - * @type { ?(ResourceStr | Bindable | Bindable | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - text?: ResourceStr | Bindable | Bindable | Bindable; - /** * Called when the position of the insertion cursor is set. * @@ -297,8 +264,7 @@ declare interface TextAreaOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ controller?: TextAreaController; } @@ -325,8 +291,7 @@ declare interface TextAreaOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface TextAreaInterface { /** @@ -354,8 +319,7 @@ interface TextAreaInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value?: TextAreaOptions): TextAreaAttribute; } @@ -375,8 +339,7 @@ interface TextAreaInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum TextAreaType { /** @@ -392,8 +355,7 @@ declare enum TextAreaType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NORMAL = 0, @@ -410,8 +372,7 @@ declare enum TextAreaType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NUMBER = 2, @@ -429,8 +390,7 @@ declare enum TextAreaType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PHONE_NUMBER = 3, @@ -448,8 +408,7 @@ declare enum TextAreaType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ EMAIL = 5, @@ -459,8 +418,7 @@ declare enum TextAreaType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NUMBER_DECIMAL = 12, @@ -470,8 +428,7 @@ declare enum TextAreaType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ URL = 13, @@ -495,8 +452,7 @@ declare enum TextAreaType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare type TextAreaSubmitCallback = (enterKeyType: EnterKeyType, event?: SubmitEvent) => void; @@ -522,8 +478,7 @@ declare type TextAreaSubmitCallback = (enterKeyType: EnterKeyType, event?: Submi * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TextAreaAttribute extends CommonMethod { /** @@ -551,8 +506,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ placeholderColor(value: ResourceColor): TextAreaAttribute; @@ -582,8 +536,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ placeholderFont(value: Font): TextAreaAttribute; @@ -604,8 +557,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enterKeyType(value: EnterKeyType): TextAreaAttribute; @@ -645,8 +597,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textAlign(value: TextAlign): TextAreaAttribute; @@ -679,8 +630,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ caretColor(value: ResourceColor): TextAreaAttribute; @@ -709,8 +659,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): TextAreaAttribute; @@ -741,8 +690,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize(value: Length): TextAreaAttribute; @@ -771,8 +719,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontStyle(value: FontStyle): TextAreaAttribute; @@ -793,7 +740,7 @@ declare class TextAreaAttribute extends CommonMethod { * @crossplatform * @since 10 */ - /** + /** * Called when the font weight is set. * *

NOTE: @@ -820,7 +767,6 @@ declare class TextAreaAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ fontWeight(value: number | FontWeight | ResourceStr): TextAreaAttribute; @@ -854,8 +800,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontFamily(value: ResourceStr): TextAreaAttribute; @@ -876,8 +821,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textOverflow(value: TextOverflow): TextAreaAttribute; @@ -889,8 +833,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textIndent(value: Dimension): TextAreaAttribute; @@ -928,8 +871,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ inputFilter(value: ResourceStr, error?: (value: string) => void): TextAreaAttribute; @@ -941,8 +883,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ caretStyle(value: CaretStyle): TextAreaAttribute; @@ -955,8 +896,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ selectedBackgroundColor(value: ResourceColor): TextAreaAttribute; @@ -993,18 +933,6 @@ declare class TextAreaAttribute extends CommonMethod { * @since 14 */ onSubmit(callback: TextAreaSubmitCallback): TextAreaAttribute; - /** - * Called when submitted. - * - * @param { ((enterKey: EnterKeyType) => void) | TextAreaSubmitCallback } callback - callback of the listened event. - * @returns { TextAreaAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onSubmit(callback: ((enterKey: EnterKeyType) => void) | TextAreaSubmitCallback): TextAreaAttribute; /** * Called when the input changes. @@ -1047,8 +975,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onChange(callback: EditableTextOnChangeCallback): TextAreaAttribute; @@ -1070,8 +997,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onTextSelectionChange(callback: (selectionStart: number, selectionEnd: number) => void): TextAreaAttribute; @@ -1094,8 +1020,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onContentScroll(callback: (totalOffsetX: number, totalOffsetY: number) => void): TextAreaAttribute; @@ -1119,8 +1044,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onEditChange(callback: (isEditing: boolean) => void): TextAreaAttribute; @@ -1149,8 +1073,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onCopy(callback: (value: string) => void): TextAreaAttribute; @@ -1179,8 +1102,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onCut(callback: (value: string) => void): TextAreaAttribute; @@ -1212,8 +1134,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onPaste(callback: (value: string, event: PasteEvent) => void): TextAreaAttribute; @@ -1248,8 +1169,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ copyOption(value: CopyOptions): TextAreaAttribute; @@ -1270,8 +1190,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableKeyboardOnFocus(value: boolean): TextAreaAttribute; @@ -1297,8 +1216,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maxLength(value: number): TextAreaAttribute; @@ -1337,8 +1255,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showCounter(value: boolean, options?: InputCounterOptions): TextAreaAttribute; @@ -1362,8 +1279,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ style(value: TextContentStyle): TextAreaAttribute; @@ -1382,8 +1298,7 @@ declare class TextAreaAttribute extends CommonMethod { * @returns { TextAreaAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barState(value: BarState): TextAreaAttribute; @@ -1413,8 +1328,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectionMenuHidden(value: boolean): TextAreaAttribute; @@ -1432,8 +1346,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ minFontSize(value: number | string | Resource): TextAreaAttribute; @@ -1451,8 +1364,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ maxFontSize(value: number | string | Resource): TextAreaAttribute; @@ -1490,7 +1402,6 @@ declare class TextAreaAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ minFontScale(scale: Optional): TextAreaAttribute; @@ -1524,7 +1435,6 @@ declare class TextAreaAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ maxFontScale(scale: Optional): TextAreaAttribute; @@ -1555,8 +1465,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ heightAdaptivePolicy(value: TextHeightAdaptivePolicy): TextAreaAttribute; @@ -1588,8 +1497,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maxLines(value: number): TextAreaAttribute; @@ -1632,8 +1540,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ wordBreak(value: WordBreak): TextAreaAttribute; @@ -1649,8 +1556,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineBreakStrategy(strategy: LineBreakStrategy): TextAreaAttribute; @@ -1695,8 +1601,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ customKeyboard(value: CustomBuilder, options?: KeyboardOptions): TextAreaAttribute; @@ -1708,8 +1613,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ decoration(value: TextDecorationOptions): TextAreaAttribute; @@ -1728,8 +1632,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ letterSpacing(value: number | string | Resource): TextAreaAttribute; @@ -1745,8 +1648,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineSpacing(value: LengthMetrics): TextAreaAttribute; @@ -1776,8 +1678,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineHeight(value: number | string | Resource): TextAreaAttribute; @@ -1798,8 +1699,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type(value: TextAreaType): TextAreaAttribute; @@ -1810,8 +1710,7 @@ declare class TextAreaAttribute extends CommonMethod { * @returns { TextAreaAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableAutoFill(value: boolean): TextAreaAttribute; @@ -1822,8 +1721,7 @@ declare class TextAreaAttribute extends CommonMethod { * @returns { TextAreaAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentType(contentType: ContentType): TextAreaAttribute; @@ -1839,8 +1737,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontFeature(value: string): TextAreaAttribute; @@ -1858,8 +1755,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillInsert(callback: Callback): TextAreaAttribute; @@ -1875,8 +1771,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidInsert(callback: Callback): TextAreaAttribute; @@ -1894,8 +1789,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillDelete(callback: Callback): TextAreaAttribute; @@ -1911,8 +1805,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidDelete(callback: Callback): TextAreaAttribute; @@ -1926,8 +1819,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ editMenuOptions(editMenu: EditMenuOptions): TextAreaAttribute; @@ -1944,8 +1836,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enablePreviewText(enable: boolean): TextAreaAttribute; @@ -1969,8 +1860,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ enableHapticFeedback(isEnabled: boolean): TextAreaAttribute; @@ -1983,7 +1873,6 @@ declare class TextAreaAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ autoCapitalizationMode(mode: AutoCapitalizationMode): TextAreaAttribute; @@ -1995,8 +1884,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ halfLeading(halfLeading: Optional): TextAreaAttribute; @@ -2014,8 +1902,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ ellipsisMode(mode: Optional): TextAreaAttribute; @@ -2026,8 +1913,7 @@ declare class TextAreaAttribute extends CommonMethod { * @returns { TextAreaAttribute } returns the instance of the TextAreaAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ stopBackPress(isStopped: Optional): TextAreaAttribute; @@ -2044,8 +1930,7 @@ declare class TextAreaAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ onWillChange(callback: Callback): TextAreaAttribute; @@ -2056,8 +1941,7 @@ declare class TextAreaAttribute extends CommonMethod { * @returns { TextAreaAttribute } returns the instance of the TextAreaAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ keyboardAppearance(appearance: Optional): TextAreaAttribute; diff --git a/api/@internal/component/ets/text_clock.d.ts b/api/@internal/component/ets/text_clock.d.ts index 29a9c245dc6d74f1a14e0581a00ba86da8f24820..72059f918df764eb406996d59906dcddcb51ccc3 100644 --- a/api/@internal/component/ets/text_clock.d.ts +++ b/api/@internal/component/ets/text_clock.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonConfiguration, CommonMethod, ShadowOptions, ContentModifier, Optional, DateTimeOptions } from './common' -import { ResourceColor, Length, ResourceStr } from './units' -import { FontStyle, FontWeight } from './enums' -/*** endif */ - /** * Provides a way to control the textclock status. * @@ -44,8 +38,7 @@ import { FontStyle, FontWeight } from './enums' * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TextClockController { /** @@ -68,8 +61,7 @@ declare class TextClockController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); /** @@ -95,17 +87,6 @@ declare class TextClockController { * @since 11 */ start(); - /** - * Provides a start event for textclock. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - start(): void; /** * Provides a stop event for textclock. * @@ -129,17 +110,6 @@ declare class TextClockController { * @since 11 */ stop(); - /** - * Provides a stop event for textclock. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - stop(): void; } /** @@ -150,8 +120,7 @@ declare class TextClockController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextClockConfiguration extends CommonConfiguration { /** @@ -163,8 +132,7 @@ declare interface TextClockConfiguration extends CommonConfiguration { /** @@ -450,7 +410,6 @@ declare class TextClockAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ format(value: ResourceStr): TextClockAttribute; @@ -497,8 +456,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onDateChange(event: (value: number) => void): TextClockAttribute; @@ -528,8 +486,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): TextClockAttribute; @@ -559,8 +516,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize(value: Length): TextClockAttribute; @@ -590,8 +546,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontStyle(value: FontStyle): TextClockAttribute; @@ -621,8 +576,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontWeight(value: number | FontWeight | string): TextClockAttribute; @@ -652,8 +606,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontFamily(value: ResourceStr): TextClockAttribute; @@ -676,8 +629,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textShadow(value: ShadowOptions | Array): TextClockAttribute; @@ -706,8 +658,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontFeature(value: string): TextClockAttribute; @@ -719,8 +670,7 @@ declare class TextClockAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentModifier(modifier: ContentModifier): TextClockAttribute; @@ -733,8 +683,7 @@ declare class TextClockAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dateTimeOptions(dateTimeOptions: Optional): TextClockAttribute; } diff --git a/api/@internal/component/ets/text_common.d.ts b/api/@internal/component/ets/text_common.d.ts index 648c2676fd46995bbff903081d492554a5169895..3e09a8ca6cf04164be3ba6cd2445724522d3426e 100644 --- a/api/@internal/component/ets/text_common.d.ts +++ b/api/@internal/component/ets/text_common.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceColor, ResourceStr, Length } from './units'; -import { DecorationStyleInterface, MutableStyledString, StyledString } from './styled_string'; -import { SelectionOptions, Callback } from './common'; -import { TextDecorationType, TextDecorationStyle } from './enums'; -/*** endif */ - /** * Defines the text data detector type. * @@ -38,8 +31,7 @@ import { TextDecorationType, TextDecorationStyle } from './enums'; * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum TextDataDetectorType { /** @@ -53,8 +45,7 @@ declare enum TextDataDetectorType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PHONE_NUMBER = 0, @@ -69,8 +60,7 @@ declare enum TextDataDetectorType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ URL = 1, @@ -85,8 +75,7 @@ declare enum TextDataDetectorType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ EMAIL = 2, @@ -101,8 +90,7 @@ declare enum TextDataDetectorType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ADDRESS = 3, @@ -111,8 +99,7 @@ declare enum TextDataDetectorType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DATE_TIME = 4, } @@ -130,8 +117,7 @@ declare enum TextDataDetectorType { * @interface TextDataDetectorConfig * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextDataDetectorConfig { /** @@ -147,8 +133,7 @@ declare interface TextDataDetectorConfig { * @type { TextDataDetectorType[] } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ types: TextDataDetectorType[] @@ -159,33 +144,22 @@ declare interface TextDataDetectorConfig { * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 11 */ - /** - * Text data detect result callback. - * - * @type { ?function } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - onDetectResultUpdate?: (result: string) => void /** * Text data detect result callback. * * @type { ?Callback } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since 20 - * @arkts 1.2 + * @since 12 */ - onDetectResultUpdate?: Callback +onDetectResultUpdate?: Callback; /** * The color of AI entity. * * @type { ?ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color?: ResourceColor, @@ -195,8 +169,7 @@ declare interface TextDataDetectorConfig { * @type { ?DecorationStyleInterface } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ decoration?: DecorationStyleInterface; @@ -218,8 +191,7 @@ declare interface TextDataDetectorConfig { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextRange { /** @@ -230,8 +202,7 @@ declare interface TextRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start?: number; @@ -243,8 +214,7 @@ declare interface TextRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ end?: number; } @@ -256,8 +226,7 @@ declare interface TextRange { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface InsertValue { /** @@ -267,8 +236,7 @@ declare interface InsertValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ insertOffset: number; @@ -279,8 +247,7 @@ declare interface InsertValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ insertValue: string; } @@ -292,8 +259,7 @@ declare interface InsertValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum TextDeleteDirection { /** @@ -302,8 +268,7 @@ declare enum TextDeleteDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BACKWARD = 0, @@ -313,8 +278,7 @@ declare enum TextDeleteDirection { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FORWARD = 1, } @@ -367,8 +331,7 @@ declare enum SuperscriptStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ declare enum MenuType { /** @@ -377,8 +340,7 @@ declare enum MenuType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ SELECTION_MENU = 0, @@ -388,8 +350,7 @@ declare enum MenuType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ PREVIEW_MENU = 1, } @@ -401,8 +362,7 @@ declare enum MenuType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ declare enum AutoCapitalizationMode { /** @@ -411,8 +371,7 @@ declare enum AutoCapitalizationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ NONE = 0, @@ -422,8 +381,7 @@ declare enum AutoCapitalizationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ WORDS = 1, @@ -433,8 +391,7 @@ declare enum AutoCapitalizationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ SENTENCES = 2, @@ -444,8 +401,7 @@ declare enum AutoCapitalizationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ ALL_CHARACTERS = 3, } @@ -457,8 +413,7 @@ declare enum AutoCapitalizationMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface DeleteValue { /** @@ -468,8 +423,7 @@ declare interface DeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ deleteOffset: number; @@ -480,8 +434,7 @@ declare interface DeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ direction: TextDeleteDirection; @@ -492,8 +445,7 @@ declare interface DeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ deleteValue: string; } @@ -507,8 +459,7 @@ declare interface DeleteValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type OnDidChangeCallback = (rangeBefore: TextRange, rangeAfter: TextRange) => void; @@ -521,8 +472,7 @@ declare type OnDidChangeCallback = (rangeBefore: TextRange, rangeAfter: TextRang * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ /** * Callback when input sometimes has info of previewText. @@ -534,8 +484,7 @@ declare type OnDidChangeCallback = (rangeBefore: TextRange, rangeAfter: TextRang * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare type EditableTextOnChangeCallback = (value: string, previewText?: PreviewText, options?: TextChangeOptions) => void; @@ -546,8 +495,7 @@ declare type EditableTextOnChangeCallback = (value: string, previewText?: Previe * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextBaseController { /** @@ -559,8 +507,7 @@ declare interface TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setSelection(selectionStart: number, selectionEnd: number, options?: SelectionOptions): void; @@ -570,8 +517,7 @@ declare interface TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ closeSelectionMenu(): void; @@ -582,8 +528,7 @@ declare interface TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getLayoutManager(): LayoutManager; } @@ -596,8 +541,7 @@ declare interface TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextEditControllerEx extends TextBaseController { /** @@ -607,8 +551,7 @@ declare interface TextEditControllerEx extends TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isEditing(): boolean; @@ -618,8 +561,7 @@ declare interface TextEditControllerEx extends TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ stopEditing(): void; @@ -631,8 +573,7 @@ declare interface TextEditControllerEx extends TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setCaretOffset(offset: number): boolean; @@ -643,8 +584,7 @@ declare interface TextEditControllerEx extends TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getCaretOffset(): number; @@ -658,18 +598,6 @@ declare interface TextEditControllerEx extends TextBaseController { * @since 12 */ getPreviewText?(): PreviewText; - - /** - * Get PreviewText. - * - * @returns { PreviewText } - Return the PreviewText. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - getPreviewText(): PreviewText; } /** @@ -678,8 +606,7 @@ declare interface TextEditControllerEx extends TextBaseController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface PreviewText { /** @@ -689,8 +616,7 @@ declare interface PreviewText { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ offset: number; @@ -701,8 +627,7 @@ declare interface PreviewText { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ value: string; } @@ -714,8 +639,7 @@ declare interface PreviewText { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface StyledStringController { /** @@ -725,8 +649,7 @@ declare interface StyledStringController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setStyledString(styledString: StyledString): void; @@ -737,8 +660,7 @@ declare interface StyledStringController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getStyledString(): MutableStyledString; } @@ -750,8 +672,7 @@ declare interface StyledStringController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface StyledStringChangedListener { /** @@ -761,8 +682,7 @@ declare interface StyledStringChangedListener { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillChange?: Callback; @@ -773,8 +693,7 @@ declare interface StyledStringChangedListener { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidChange?: OnDidChangeCallback; } @@ -786,8 +705,7 @@ declare interface StyledStringChangedListener { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface StyledStringChangeValue { /** @@ -797,8 +715,7 @@ interface StyledStringChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ range: TextRange; @@ -809,8 +726,7 @@ interface StyledStringChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ replacementString: StyledString; @@ -821,8 +737,7 @@ interface StyledStringChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ previewText?: StyledString; } @@ -834,8 +749,7 @@ interface StyledStringChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface LayoutManager { /** @@ -845,8 +759,7 @@ declare interface LayoutManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getLineCount(): number; @@ -859,8 +772,7 @@ declare interface LayoutManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getGlyphPositionAtCoordinate(x: number, y: number): PositionWithAffinity; @@ -897,8 +809,7 @@ declare interface LayoutManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface PositionWithAffinity { /** @@ -908,8 +819,7 @@ interface PositionWithAffinity { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ position: number; @@ -995,8 +905,7 @@ declare type TextBox = import('../api/@ohos.graphics.text').default.TextBox; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface CaretStyle { /** @@ -1014,8 +923,7 @@ interface CaretStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ width?: Length, @@ -1034,8 +942,7 @@ interface CaretStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ color?: ResourceColor, } @@ -1046,8 +953,7 @@ interface CaretStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class TextMenuItemId { /** @@ -1059,8 +965,7 @@ declare class TextMenuItemId { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static of(id: ResourceStr): TextMenuItemId; @@ -1072,8 +977,7 @@ declare class TextMenuItemId { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ equals(id: TextMenuItemId): boolean; @@ -1085,8 +989,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static readonly CUT: TextMenuItemId; @@ -1098,8 +1001,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static readonly COPY: TextMenuItemId; @@ -1111,8 +1013,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static readonly PASTE: TextMenuItemId; @@ -1124,8 +1025,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static readonly SELECT_ALL: TextMenuItemId; @@ -1137,8 +1037,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static readonly COLLABORATION_SERVICE: TextMenuItemId; @@ -1150,8 +1049,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static readonly CAMERA_INPUT: TextMenuItemId; @@ -1163,8 +1061,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ static readonly AI_WRITER: TextMenuItemId; @@ -1176,8 +1073,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ static readonly TRANSLATE: TextMenuItemId; @@ -1189,8 +1085,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static readonly SEARCH: TextMenuItemId; @@ -1202,8 +1097,7 @@ declare class TextMenuItemId { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static readonly SHARE: TextMenuItemId; @@ -1275,8 +1169,7 @@ declare class TextMenuItemId { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextMenuItem { /** @@ -1286,8 +1179,7 @@ declare interface TextMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ content: ResourceStr; /** @@ -1297,8 +1189,7 @@ declare interface TextMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ icon?: ResourceStr; /** @@ -1308,8 +1199,7 @@ declare interface TextMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id: TextMenuItemId; /** @@ -1319,8 +1209,7 @@ declare interface TextMenuItem { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ labelInfo?: ResourceStr; } @@ -1338,35 +1227,6 @@ declare interface TextMenuItem { */ type OnPrepareMenuCallback = (menuItems: Array) => Array; -/** - * Callback function when the selection menu create. - * - * @typedef { function } OnCreateMenuCallback - * @param { Array } menuItems - currently displayed menu items. - * @returns { Array } Return the menu items will displayed after operations. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -type OnCreateMenuCallback = (menuItems: Array) => Array; - -/** - * Invoke upon clicking an item, capable of intercepting the default system menu execution behavior. - * - * @typedef { function } OnMenuItemClickCallback - * @param { TextMenuItem } menuItem - current default menu. - * @param { TextRange } range - current selected range. - * @returns { boolean } - Return True, the event is consumed, false otherwise. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -type OnMenuItemClickCallback = (menuItem: TextMenuItem, range: TextRange) => boolean - /** * EditMenuOptions * @@ -1374,8 +1234,7 @@ type OnMenuItemClickCallback = (menuItem: TextMenuItem, range: TextRange) => boo * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface EditMenuOptions { /** @@ -1411,30 +1270,6 @@ declare interface EditMenuOptions { * @since 20 */ onPrepareMenu?: OnPrepareMenuCallback; - - /** - * Passes the default menu, invokes before every display to generate a menu for triggering click events. - * - * @type { OnCreateMenuCallback } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onCreateMenu: OnCreateMenuCallback; - - /** - * Invoke upon clicking an item, capable of intercepting the default system menu execution behavior. - * - * @type { OnMenuItemClickCallback } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onMenuItemClick: OnMenuItemClickCallback; } /** @@ -1444,8 +1279,7 @@ declare interface EditMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface DecorationStyleResult { /** @@ -1455,8 +1289,7 @@ interface DecorationStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type: TextDecorationType; @@ -1467,8 +1300,7 @@ interface DecorationStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color: ResourceColor; @@ -1479,8 +1311,7 @@ interface DecorationStyleResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style?: TextDecorationStyle; @@ -1504,8 +1335,7 @@ interface DecorationStyleResult { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface FontSettingOptions { /** @@ -1516,8 +1346,7 @@ declare interface FontSettingOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableVariableFontWeight?: boolean; } @@ -1528,8 +1357,7 @@ declare interface FontSettingOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare interface TextChangeOptions { /** @@ -1539,8 +1367,7 @@ declare interface TextChangeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ rangeBefore: TextRange; @@ -1551,8 +1378,7 @@ declare interface TextChangeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ rangeAfter: TextRange; @@ -1563,8 +1389,7 @@ declare interface TextChangeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ oldContent: string; @@ -1575,8 +1400,7 @@ declare interface TextChangeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ oldPreviewText: PreviewText; } @@ -1588,8 +1412,7 @@ declare interface TextChangeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ interface EditableTextChangeValue { /** @@ -1599,8 +1422,7 @@ interface EditableTextChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ content: string; @@ -1611,8 +1433,7 @@ interface EditableTextChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ previewText?: PreviewText; @@ -1623,8 +1444,7 @@ interface EditableTextChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ options?: TextChangeOptions; } @@ -1636,8 +1456,7 @@ interface EditableTextChangeValue { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'16','1.2':'20'} - * @arkts 1.1&1.2 + * @since 16 */ declare enum TextMenuShowMode { /** @@ -1646,8 +1465,7 @@ declare enum TextMenuShowMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'16','1.2':'20'} - * @arkts 1.1&1.2 + * @since 16 */ DEFAULT = 0, @@ -1658,8 +1476,7 @@ declare enum TextMenuShowMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'16','1.2':'20'} - * @arkts 1.1&1.2 + * @since 16 */ PREFER_WINDOW = 1, } @@ -1671,8 +1488,7 @@ declare enum TextMenuShowMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'16','1.2':'20'} - * @arkts 1.1&1.2 + * @since 16 */ declare interface TextMenuOptions { /** @@ -1682,8 +1498,7 @@ declare interface TextMenuOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'16','1.2':'20'} - * @arkts 1.1&1.2 + * @since 16 */ showMode?: TextMenuShowMode; } @@ -1693,8 +1508,7 @@ declare interface TextMenuOptions { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare enum KeyboardAppearance { /** @@ -1702,8 +1516,7 @@ declare enum KeyboardAppearance { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ NONE_IMMERSIVE = 0, @@ -1712,8 +1525,7 @@ declare enum KeyboardAppearance { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ IMMERSIVE = 1, @@ -1722,8 +1534,7 @@ declare enum KeyboardAppearance { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ LIGHT_IMMERSIVE = 2, @@ -1732,8 +1543,7 @@ declare enum KeyboardAppearance { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ DARK_IMMERSIVE = 3, } diff --git a/api/@internal/component/ets/text_input.d.ts b/api/@internal/component/ets/text_input.d.ts index 0db6fdf2b3a564cf9d9b3d5df4bace7639148841..cd6888ae551923edc5f81e28ca918c82ebf51dbb 100644 --- a/api/@internal/component/ets/text_input.d.ts +++ b/api/@internal/component/ets/text_input.d.ts @@ -18,18 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CancelButtonSymbolOptions, CancelButtonOptions } from "./search"; -import { Callback, CommonMethod, TextContentControllerBase, SelectionOptions, InputCounterOptions, TextDecorationOptions, Optional, Bindable} from "./common"; -import { CustomBuilder } from './builder'; -import { BarState, LineBreakStrategy, TextAlign, FontStyle, FontWeight, WordBreak, TextOverflow, - CopyOptions, TextHeightAdaptivePolicy, TextContentStyle, EllipsisMode } from './enums'; -import { Resource, ResourceStr, ResourceColor, Dimension, Font, Length } from './units'; -import { InsertValue, DeleteValue, CaretStyle, EditableTextOnChangeCallback, EditMenuOptions, - AutoCapitalizationMode,EditableTextChangeValue,KeyboardAppearance } from "./textCommon"; -import { KeyboardOptions, PasteEvent } from "./richEditor"; -/*** endif */ - /** * Declare the type of input box * @@ -52,8 +40,7 @@ import { KeyboardOptions, PasteEvent } from "./richEditor"; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum InputType { /** @@ -75,8 +62,7 @@ declare enum InputType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Normal, @@ -99,8 +85,7 @@ declare enum InputType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Number, @@ -123,8 +108,7 @@ declare enum InputType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ PhoneNumber, @@ -152,8 +136,7 @@ declare enum InputType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Email, @@ -184,8 +167,7 @@ declare enum InputType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Password, @@ -209,8 +191,7 @@ declare enum InputType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NUMBER_PASSWORD = 8, @@ -219,8 +200,7 @@ declare enum InputType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ SCREEN_LOCK_PASSWORD = 9, @@ -239,8 +219,7 @@ declare enum InputType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ USER_NAME = 10, @@ -262,8 +241,7 @@ declare enum InputType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NEW_PASSWORD = 11, @@ -277,8 +255,7 @@ declare enum InputType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NUMBER_DECIMAL = 12, @@ -288,8 +265,7 @@ declare enum InputType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ URL = 13, @@ -309,8 +285,7 @@ declare enum InputType { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum ContentType { /** @@ -319,8 +294,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ USER_NAME = 0, @@ -330,8 +304,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PASSWORD = 1, @@ -341,8 +314,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NEW_PASSWORD = 2, @@ -353,8 +325,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FULL_STREET_ADDRESS = 3, @@ -365,8 +336,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ HOUSE_NUMBER = 4, @@ -377,8 +347,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DISTRICT_ADDRESS = 5, @@ -389,8 +358,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CITY_ADDRESS = 6, @@ -401,8 +369,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PROVINCE_ADDRESS = 7, @@ -413,8 +380,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ COUNTRY_ADDRESS = 8, @@ -425,8 +391,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PERSON_FULL_NAME = 9, @@ -437,8 +402,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PERSON_LAST_NAME = 10, @@ -449,8 +413,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PERSON_FIRST_NAME = 11, @@ -461,8 +424,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PHONE_NUMBER = 12, @@ -473,8 +435,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PHONE_COUNTRY_CODE = 13, @@ -485,8 +446,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FULL_PHONE_NUMBER = 14, @@ -497,8 +457,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ EMAIL_ADDRESS = 15, @@ -509,8 +468,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BANK_CARD_NUMBER = 16, @@ -521,8 +479,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ID_CARD_NUMBER = 17, @@ -533,8 +490,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NICKNAME = 23, @@ -545,8 +501,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DETAIL_INFO_WITHOUT_STREET = 24, @@ -557,8 +512,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FORMAT_ADDRESS = 25, @@ -569,8 +523,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ PASSPORT_NUMBER = 26, @@ -581,8 +534,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ VALIDITY = 27, @@ -593,8 +545,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ ISSUE_AT = 28, @@ -605,8 +556,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ ORGANIZATION = 29, @@ -617,8 +567,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ TAX_ID = 30, @@ -629,8 +578,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ ADDRESS_CITY_AND_STATE = 31, @@ -640,8 +588,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ FLIGHT_NUMBER = 32, @@ -651,8 +598,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ LICENSE_NUMBER = 33, @@ -662,8 +608,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ LICENSE_FILE_NUMBER = 34, @@ -674,8 +619,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ LICENSE_PLATE = 35, @@ -685,8 +629,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ ENGINE_NUMBER = 36, @@ -696,8 +639,7 @@ declare enum ContentType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ LICENSE_CHASSIS_NUMBER = 37 } @@ -724,8 +666,7 @@ declare enum ContentType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum EnterKeyType { /** @@ -747,8 +688,7 @@ declare enum EnterKeyType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Go = 2, @@ -771,8 +711,7 @@ declare enum EnterKeyType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Search = 3, @@ -795,8 +734,7 @@ declare enum EnterKeyType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Send = 4, @@ -819,8 +757,7 @@ declare enum EnterKeyType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Next = 5, @@ -843,8 +780,7 @@ declare enum EnterKeyType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Done = 6, @@ -861,8 +797,7 @@ declare enum EnterKeyType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PREVIOUS = 7, @@ -879,8 +814,7 @@ declare enum EnterKeyType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ NEW_LINE = 8, } @@ -892,8 +826,7 @@ declare enum EnterKeyType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface UnderlineColor { /** @@ -908,8 +841,7 @@ declare interface UnderlineColor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ typing?: ResourceColor | undefined; /** @@ -924,8 +856,7 @@ declare interface UnderlineColor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ normal?: ResourceColor | undefined; /** @@ -942,8 +873,7 @@ declare interface UnderlineColor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ error?: ResourceColor | undefined; /** @@ -958,8 +888,7 @@ declare interface UnderlineColor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ disable?: ResourceColor | undefined; } @@ -971,8 +900,7 @@ declare interface UnderlineColor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface SubmitEvent { /** @@ -981,8 +909,7 @@ declare interface SubmitEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ keepEditableState(): void; @@ -993,8 +920,7 @@ declare interface SubmitEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ text: string; } @@ -1020,8 +946,7 @@ declare interface SubmitEvent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TextInputController extends TextContentControllerBase { /** @@ -1044,8 +969,7 @@ declare class TextInputController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -1076,8 +1000,7 @@ declare class TextInputController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ caretPosition(value: number): void; @@ -1117,8 +1040,7 @@ declare class TextInputController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setTextSelection(selectionStart: number, selectionEnd: number, options?: SelectionOptions): void; @@ -1135,8 +1057,7 @@ declare class TextInputController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ stopEditing(): void; } @@ -1163,8 +1084,7 @@ declare class TextInputController extends TextContentControllerBase { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TextInputOptions { /** @@ -1189,8 +1109,7 @@ declare interface TextInputOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ placeholder?: ResourceStr; @@ -1227,18 +1146,6 @@ declare interface TextInputOptions { */ text?: ResourceStr; - /** - * Sets the current value of TextInput. - * - * @type { ?(ResourceStr | Bindable | Bindable | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - text?: ResourceStr | Bindable | Bindable | Bindable; - /** * Called when the position of the insertion cursor is set. * @@ -1261,8 +1168,7 @@ declare interface TextInputOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ controller?: TextInputController; } @@ -1289,8 +1195,7 @@ declare interface TextInputOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum TextInputStyle { /** @@ -1317,8 +1222,7 @@ declare enum TextInputStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Default, @@ -1349,8 +1253,7 @@ declare enum TextInputStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Inline } @@ -1377,8 +1280,7 @@ declare enum TextInputStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface TextInputInterface { /** @@ -1406,8 +1308,7 @@ interface TextInputInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value?: TextInputOptions): TextInputAttribute; } @@ -1426,8 +1327,7 @@ interface TextInputInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface PasswordIcon { /** @@ -1449,8 +1349,7 @@ interface PasswordIcon { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onIconSrc?: string | Resource; @@ -1473,8 +1372,7 @@ interface PasswordIcon { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offIconSrc?: string | Resource; } @@ -1489,8 +1387,7 @@ interface PasswordIcon { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnSubmitCallback = (enterKey: EnterKeyType, event: SubmitEvent) => void; @@ -1504,8 +1401,7 @@ declare type OnSubmitCallback = (enterKey: EnterKeyType, event: SubmitEvent) => * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnTextSelectionChangeCallback = (selectionStart: number, selectionEnd: number) => void; @@ -1519,8 +1415,7 @@ declare type OnTextSelectionChangeCallback = (selectionStart: number, selectionE * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnContentScrollCallback = (totalOffsetX: number, totalOffsetY: number) => void; @@ -1535,8 +1430,7 @@ declare type OnContentScrollCallback = (totalOffsetX: number, totalOffsetY: numb * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnPasteCallback = (content: string, event: PasteEvent) => void; @@ -1562,8 +1456,7 @@ declare type OnPasteCallback = (content: string, event: PasteEvent) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TextInputAttribute extends CommonMethod { /** @@ -1591,8 +1484,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ type(value: InputType): TextInputAttribute; @@ -1603,8 +1495,7 @@ declare class TextInputAttribute extends CommonMethod { * @returns { TextInputAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentType(value: ContentType): TextInputAttribute; @@ -1633,8 +1524,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ placeholderColor(value: ResourceColor): TextInputAttribute; @@ -1659,8 +1549,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textOverflow(value: TextOverflow): TextInputAttribute; @@ -1672,8 +1561,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textIndent(value: Dimension): TextInputAttribute; @@ -1707,8 +1595,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ placeholderFont(value?: Font): TextInputAttribute; @@ -1737,8 +1624,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enterKeyType(value: EnterKeyType): TextInputAttribute; @@ -1771,8 +1657,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ caretColor(value: ResourceColor): TextInputAttribute; @@ -1836,8 +1721,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onEditChange(callback: Callback): TextInputAttribute; @@ -1877,8 +1761,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onSubmit(callback: OnSubmitCallback): TextInputAttribute; @@ -1922,8 +1805,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onChange(callback: EditableTextOnChangeCallback): TextInputAttribute; @@ -1955,8 +1837,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onTextSelectionChange(callback: OnTextSelectionChangeCallback): TextInputAttribute; @@ -1988,8 +1869,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onContentScroll(callback: OnContentScrollCallback): TextInputAttribute; @@ -2023,8 +1903,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maxLength(value: number): TextInputAttribute; @@ -2053,8 +1932,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): TextInputAttribute; @@ -2090,8 +1968,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize(value: Length): TextInputAttribute; @@ -2120,8 +1997,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontStyle(value: FontStyle): TextInputAttribute; @@ -2145,6 +2021,15 @@ declare class TextInputAttribute extends CommonMethod { /** * Called when the font weight is set. * + *

NOTE: + *
If the value is too large, the text may be clipped depending on the font. + *
For the number type, the value range is [100, 900], at an interval of 100. + *
The default value is 400. + *
A larger value indicates a heavier font weight. + *
For the string type, only strings that represent a number, for example, "400", + * and the following enumerated values of FontWeight are supported: "bold", "bolder", "lighter", "regular", and "medium". + *

+ * * @param { number | FontWeight | string } value - Default value is FontWeight.Normal. * @returns { TextInputAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -2161,7 +2046,6 @@ declare class TextInputAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ fontWeight(value: number | FontWeight | ResourceStr): TextInputAttribute; @@ -2196,8 +2080,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontFamily(value: ResourceStr): TextInputAttribute; @@ -2250,8 +2133,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ inputFilter(value: ResourceStr, error?: Callback): TextInputAttribute; @@ -2291,8 +2173,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onCopy(callback: Callback): TextInputAttribute; @@ -2332,8 +2213,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onCut(callback: Callback): TextInputAttribute; @@ -2376,8 +2256,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onPaste(callback: OnPasteCallback): TextInputAttribute; @@ -2412,8 +2291,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ copyOption(value: CopyOptions): TextInputAttribute; @@ -2451,8 +2329,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showPasswordIcon(value: boolean): TextInputAttribute; @@ -2490,8 +2367,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textAlign(value: TextAlign): TextInputAttribute; @@ -2524,8 +2400,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ style(value: TextInputStyle | TextContentStyle): TextInputAttribute; @@ -2546,8 +2421,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ caretStyle(value: CaretStyle): TextInputAttribute; @@ -2572,8 +2446,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedBackgroundColor(value: ResourceColor): TextInputAttribute; @@ -2594,8 +2467,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ caretPosition(value: number): TextInputAttribute; @@ -2621,8 +2493,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ enableKeyboardOnFocus(value: boolean): TextInputAttribute; @@ -2648,8 +2519,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ passwordIcon(value: PasswordIcon): TextInputAttribute; @@ -2687,8 +2557,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ showError(value?: ResourceStr | undefined): TextInputAttribute; @@ -2712,8 +2581,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showUnit(value: CustomBuilder): TextInputAttribute; @@ -2738,8 +2606,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showUnderline(value: boolean): TextInputAttribute; @@ -2758,8 +2625,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ underlineColor(value: ResourceColor | UnderlineColor | undefined): TextInputAttribute; @@ -2791,8 +2657,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectionMenuHidden(value: boolean): TextInputAttribute; @@ -2811,8 +2676,7 @@ declare class TextInputAttribute extends CommonMethod { * @returns { TextInputAttribute } returns the instance of the TextInputAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ barState(value: BarState): TextInputAttribute; @@ -2833,8 +2697,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maxLines(value: number): TextInputAttribute; @@ -2853,8 +2716,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ wordBreak(value: WordBreak): TextInputAttribute; @@ -2872,8 +2734,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineBreakStrategy(strategy: LineBreakStrategy): TextInputAttribute; @@ -2919,8 +2780,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ customKeyboard(value: CustomBuilder, options?: KeyboardOptions): TextInputAttribute; @@ -2948,8 +2808,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ showCounter(value: boolean, options?: InputCounterOptions): TextInputAttribute; @@ -3006,19 +2865,6 @@ declare class TextInputAttribute extends CommonMethod { */ cancelButton(symbolOptions: CancelButtonSymbolOptions): TextInputAttribute; - /** - * Set the cancel button style - * - * @param { CancelButtonOptions | CancelButtonSymbolOptions } symbolOptions - indicates the style of the cancel button. - * @returns { TextInputAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - cancelButton(symbolOptions: CancelButtonOptions | CancelButtonSymbolOptions): TextInputAttribute; - /** * Sets selection when on focus. * @@ -3040,8 +2886,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ selectAll(value: boolean): TextInputAttribute; @@ -3061,8 +2906,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ minFontSize(value: number | string | Resource): TextInputAttribute; @@ -3082,8 +2926,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ maxFontSize(value: number | string | Resource): TextInputAttribute; @@ -3105,7 +2948,6 @@ declare class TextInputAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ minFontScale(scale: Optional): TextInputAttribute; @@ -3127,7 +2969,6 @@ declare class TextInputAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ maxFontScale(scale: Optional): TextInputAttribute; @@ -3157,8 +2998,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ heightAdaptivePolicy(value: TextHeightAdaptivePolicy): TextInputAttribute; @@ -3177,8 +3017,7 @@ declare class TextInputAttribute extends CommonMethod { * @returns { TextInputAttribute } Returns the instance of the TextInputAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableAutoFill(value: boolean): TextInputAttribute; @@ -3194,8 +3033,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ decoration(value: TextDecorationOptions): TextInputAttribute; @@ -3216,8 +3054,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ letterSpacing(value: number | string | Resource): TextInputAttribute; @@ -3235,8 +3072,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ lineHeight(value: number | string | Resource): TextInputAttribute; @@ -3259,8 +3095,7 @@ declare class TextInputAttribute extends CommonMethod { * @returns { TextInputAttribute } Returns the instance of the TextInputAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ passwordRules(value: string): TextInputAttribute; @@ -3281,8 +3116,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontFeature(value: string): TextInputAttribute; @@ -3303,8 +3137,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ showPassword(visible: boolean): TextInputAttribute; @@ -3316,8 +3149,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onSecurityStateChange(callback: Callback): TextInputAttribute; @@ -3335,8 +3167,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillInsert(callback: Callback): TextInputAttribute; @@ -3352,8 +3183,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidInsert(callback: Callback): TextInputAttribute; @@ -3371,8 +3201,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillDelete(callback: Callback): TextInputAttribute; @@ -3388,8 +3217,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidDelete(callback: Callback): TextInputAttribute; @@ -3415,8 +3243,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ editMenuOptions(editMenu: EditMenuOptions): TextInputAttribute; @@ -3433,8 +3260,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enablePreviewText(enable: boolean): TextInputAttribute; @@ -3446,8 +3272,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ enableHapticFeedback(isEnabled: boolean): TextInputAttribute; @@ -3460,7 +3285,6 @@ declare class TextInputAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ autoCapitalizationMode(mode: AutoCapitalizationMode): TextInputAttribute; @@ -3472,8 +3296,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ halfLeading(halfLeading: Optional): TextInputAttribute; @@ -3485,8 +3308,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ ellipsisMode(mode: Optional): TextInputAttribute; @@ -3497,8 +3319,7 @@ declare class TextInputAttribute extends CommonMethod { * @returns { TextInputAttribute } returns the instance of the TextInputAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ stopBackPress(isStopped: Optional): TextInputAttribute; @@ -3510,8 +3331,7 @@ declare class TextInputAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ onWillChange(callback: Callback): TextInputAttribute; @@ -3522,8 +3342,7 @@ declare class TextInputAttribute extends CommonMethod { * @returns { TextInputAttribute } returns the instance of the TextInputAttribute. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ keyboardAppearance(appearance: Optional): TextInputAttribute; diff --git a/api/@internal/component/ets/text_picker.d.ts b/api/@internal/component/ets/text_picker.d.ts index 49e7af9f00042be97a7369fbe065085f6c3e6594..4a485b811f7bd552aa30cce88a6a273f930a4497 100644 --- a/api/@internal/component/ets/text_picker.d.ts +++ b/api/@internal/component/ets/text_picker.d.ts @@ -18,14 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource, ResourceColor, Offset, Dimension, ResourceStr } from './units'; -import { CommonMethod, PickerTextStyle, PickerDialogButtonStyle, Rectangle, BlurStyle, ShadowOptions, ShadowStyle, HoverModeAreaType, BackgroundBlurStyleOptions, BackgroundEffectOptions, Optional, Callback, Bindable } from './common'; -import { DialogAlignment } from './alertDialog'; -import { CrownSensitivity, TextOverflow } from './enums'; -import { LengthMetrics } from './../Graphics'; -/*** endif */ - /** * Define the contents of each selector item. * @@ -41,8 +33,7 @@ import { LengthMetrics } from './../Graphics'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TextPickerRangeContent { /** @@ -62,8 +53,7 @@ declare interface TextPickerRangeContent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ icon: string | Resource; @@ -92,8 +82,7 @@ declare interface TextPickerRangeContent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ text?: string | Resource; } @@ -112,8 +101,7 @@ declare interface TextPickerRangeContent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TextCascadePickerRangeContent { /** @@ -138,8 +126,7 @@ declare interface TextCascadePickerRangeContent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ text: string | Resource; @@ -157,8 +144,7 @@ declare interface TextCascadePickerRangeContent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ children?: TextCascadePickerRangeContent[]; } @@ -185,8 +171,7 @@ declare interface TextCascadePickerRangeContent { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TextPickerOptions { /** @@ -213,8 +198,7 @@ declare interface TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ range: string[] | string[][] | Resource | TextPickerRangeContent[] | TextCascadePickerRangeContent[]; @@ -275,19 +259,6 @@ declare interface TextPickerOptions { */ value?: ResourceStr | ResourceStr[]; - /** - * Value of the current selection. - * Only valid when only text is displayed. - * - * @type { ?(ResourceStr | ResourceStr[] | Bindable | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - value?: ResourceStr | ResourceStr[] | Bindable | Bindable; - /** * Index of the default selected item in the array. * The index is zero-based. @@ -324,18 +295,6 @@ declare interface TextPickerOptions { */ selected?: number | number[]; - /** - * Current selected subscript. - * - * @type { ?(number | number[] | Bindable | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected?: number | number[] | Bindable | Bindable; - /** * Width of each column in the picker. * @@ -347,8 +306,7 @@ declare interface TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ columnWidths?: LengthMetrics[]; } @@ -375,8 +333,7 @@ declare interface TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface TextPickerInterface { /** @@ -404,8 +361,7 @@ interface TextPickerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options?: TextPickerOptions): TextPickerAttribute; } @@ -417,8 +373,7 @@ interface TextPickerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface DividerOptions { /** @@ -435,8 +390,7 @@ declare interface DividerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ strokeWidth?: Dimension; @@ -444,12 +398,11 @@ declare interface DividerOptions { * Color of the divider. * * @type { ?ResourceColor } - * @default "#33000000" + * @default '#33000000' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color?: ResourceColor; @@ -466,8 +419,7 @@ declare interface DividerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ startMargin?: Dimension; @@ -484,8 +436,7 @@ declare interface DividerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ endMargin?: Dimension; } @@ -498,8 +449,7 @@ declare interface DividerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ declare interface TextPickerTextStyle extends PickerTextStyle { /** @@ -513,8 +463,7 @@ declare interface TextPickerTextStyle extends PickerTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ minFontSize?: number | string | Resource; @@ -525,8 +474,7 @@ declare interface TextPickerTextStyle extends PickerTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ maxFontSize?: number | string | Resource; @@ -541,8 +489,7 @@ declare interface TextPickerTextStyle extends PickerTextStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ overflow?: TextOverflow; } @@ -589,8 +536,7 @@ declare interface PickerBackgroundStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare type TextPickerScrollStopCallback = (value: string | string[], index: number | number[]) => void; @@ -603,8 +549,7 @@ declare type TextPickerScrollStopCallback = (value: string | string[], index: nu * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnTextPickerChangeCallback = (selectItem: string | string[], index: number | number[]) => void; @@ -617,8 +562,7 @@ declare type OnTextPickerChangeCallback = (selectItem: string | string[], index: * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type TextPickerEnterSelectedAreaCallback = (value: string | string[], index: number | number[]) => void; @@ -644,8 +588,7 @@ declare type TextPickerEnterSelectedAreaCallback = (value: string | string[], in * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TextPickerAttribute extends CommonMethod { /** @@ -669,15 +612,13 @@ declare class TextPickerAttribute extends CommonMethod { * Sets the height of each item in the picker. * * @param { number | string } value - Height of each item in the picker. - *
For the number type, the value range is [0, +∞]. For the string type, - *
only numeric string values, for example, "56", are supported. + *
For the number type, the value range is [0, +∞). + *
For the string type, only numeric string values, for example, "56", are supported. * @returns { TextPickerAttribute } - * @default 56 vp (selected) and 36 vp (unselected). * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ defaultPickerItemHeight(value: number | string): TextPickerAttribute; @@ -685,15 +626,13 @@ declare class TextPickerAttribute extends CommonMethod { * Sets the height of each item in the picker. * * @param { Optional } height - Height of each item in the picker. - *
For the number type, the value range is [0, +∞]. + *
For the number type, the value range is [0, +∞). *
For the string type, only numeric string values, for example, "56", are supported. - * @default 56 vp (selected) and 36 vp (unselected). * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ defaultPickerItemHeight(height: Optional): TextPickerAttribute; @@ -701,7 +640,6 @@ declare class TextPickerAttribute extends CommonMethod { * Sets whether scrolling is loopable. * * @param { boolean } value - Whether scrolling is loopable. true: loopable; false: not loopable. - * @default true * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 @@ -710,13 +648,11 @@ declare class TextPickerAttribute extends CommonMethod { * Sets whether scrolling is loopable. * * @param { boolean } value - Whether scrolling is loopable. true: loopable; false: not loopable. - * @default true * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ canLoop(value: boolean): TextPickerAttribute; @@ -725,13 +661,11 @@ declare class TextPickerAttribute extends CommonMethod { * this API supports the undefined type for the isLoop parameter. * * @param { Optional } isLoop - Whether scrolling is loopable. true: loopable; false: not loopable. - * @default true * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ canLoop(isLoop: Optional): TextPickerAttribute; @@ -752,8 +686,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ disappearTextStyle(value: PickerTextStyle): TextPickerAttribute; @@ -766,11 +699,22 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ disappearTextStyle(style: Optional): TextPickerAttribute; + /** + * Sets the text style of disappearing items + * + * @param { Optional } style - indicates the text style of disappearing items. + * @returns { TextPickerAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + disappearTextStyle(style: Optional): TextPickerAttribute; + /** * Sets the font color, font size, and font weight for all items except the top, bottom, and selected items. * @@ -789,8 +733,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle(value: PickerTextStyle): TextPickerAttribute; @@ -804,11 +747,22 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ textStyle(style: Optional): TextPickerAttribute; + /** + * Sets the text style of normal items + * + * @param { Optional } style - indicates the text style of normal items. + * @returns { TextPickerAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + textStyle(style: Optional): TextPickerAttribute; + /** * Sets the font color, font size, and font weight for the selected item. * @@ -826,8 +780,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedTextStyle(value: PickerTextStyle): TextPickerAttribute; @@ -840,22 +793,31 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ selectedTextStyle(style: Optional): TextPickerAttribute; + /** + * Sets the text style of selected items + * + * @param { Optional } style - indicates the text style of selected items. + * @returns { TextPickerAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + selectedTextStyle(style: Optional): TextPickerAttribute; + /** * Sets whether to enable the text style change animation during the scrolling process. * * @param { boolean } disabled - * @default false * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ disableTextStyleAnimation(disabled: boolean): TextPickerAttribute; @@ -867,8 +829,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ defaultTextStyle(style: TextPickerTextStyle): TextPickerAttribute; @@ -938,8 +899,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange(callback: Optional): TextPickerAttribute; @@ -954,8 +914,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ onScrollStop(callback: TextPickerScrollStopCallback): TextPickerAttribute; @@ -970,8 +929,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onScrollStop(callback: Optional): TextPickerAttribute; @@ -986,8 +944,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onEnterSelectedArea(callback: TextPickerEnterSelectedAreaCallback): TextPickerAttribute; @@ -998,7 +955,6 @@ declare class TextPickerAttribute extends CommonMethod { * For a multi-column (linked) picker, use a value of the number[] type. * * @param { number | number[] } value - Index of the default selected item in the array. - * @default 0 * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -1011,13 +967,11 @@ declare class TextPickerAttribute extends CommonMethod { * For a multi-column (linked) picker, use a value of the number[] type. * * @param { number | number[] } value - Index of the default selected item in the array. - * @default 0 * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedIndex(value: number | number[]): TextPickerAttribute; @@ -1030,13 +984,11 @@ declare class TextPickerAttribute extends CommonMethod { * * @param { Optional } index - Index of the default selected item in the array. *
The index is zero-based.
If index is set to undefined, the default value 0 is used. - * @default 0 * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ selectedIndex(index: Optional): TextPickerAttribute; @@ -1048,8 +1000,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ divider(value: DividerOptions | null): TextPickerAttribute; @@ -1061,8 +1012,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ divider(textDivider: Optional): TextPickerAttribute; @@ -1075,13 +1025,11 @@ declare class TextPickerAttribute extends CommonMethod { *

* * @param { Dimension } value - Height of the fade effect at the top and bottom edges of the content area. - * @default 36vp * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ gradientHeight(value: Dimension): TextPickerAttribute; @@ -1089,12 +1037,10 @@ declare class TextPickerAttribute extends CommonMethod { * Specifies whether to enable haptic feedback. * * @param { Optional } enable - Whether to enable haptic feedback. - * @default true * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableHapticFeedback(enable: Optional): TextPickerAttribute; @@ -1109,13 +1055,11 @@ declare class TextPickerAttribute extends CommonMethod { * * @param { Optional } height - THeight of the fade effect at the top and bottom edges of *
the content area. - * @default 36vp * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ gradientHeight(height: Optional): TextPickerAttribute; @@ -1123,13 +1067,11 @@ declare class TextPickerAttribute extends CommonMethod { * Sets the sensitivity to the digital crown rotation. * * @param { Optional } sensitivity - Sensitivity to the digital crown rotation. - * @default CrownSensitivity.MEDIUM * @returns { TextPickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ digitalCrownSensitivity(sensitivity: Optional): TextPickerAttribute; @@ -1168,8 +1110,7 @@ declare class TextPickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TextPickerResult { /** @@ -1196,8 +1137,7 @@ declare interface TextPickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ value: string | string[]; @@ -1223,8 +1163,7 @@ declare interface TextPickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ index: number | number[]; } @@ -1254,8 +1193,7 @@ declare interface TextPickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TextPickerDialogOptions extends TextPickerOptions { /** @@ -1281,8 +1219,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ defaultPickerItemHeight?: number | string; @@ -1303,8 +1240,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ canLoop?: boolean; @@ -1323,8 +1259,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ disappearTextStyle?: PickerTextStyle; @@ -1343,8 +1278,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle?: PickerTextStyle; @@ -1361,8 +1295,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ acceptButtonStyle?: PickerDialogButtonStyle; @@ -1379,8 +1312,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ cancelButtonStyle?: PickerDialogButtonStyle; @@ -1399,8 +1331,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedTextStyle?: PickerTextStyle; @@ -1414,8 +1345,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ disableTextStyleAnimation?: boolean; @@ -1430,8 +1360,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ defaultTextStyle?: TextPickerTextStyle; @@ -1457,8 +1386,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onAccept?: (value: TextPickerResult) => void; @@ -1484,8 +1412,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onCancel?: () => void; @@ -1511,8 +1438,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onChange?: (value: TextPickerResult) => void; @@ -1523,8 +1449,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ onScrollStop?: Callback; @@ -1547,8 +1472,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onEnterSelectedArea?: Callback; @@ -1569,8 +1493,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maskRect?: Rectangle; @@ -1590,8 +1513,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignment?: DialogAlignment; @@ -1611,8 +1533,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset?: Offset; @@ -1633,8 +1554,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundColor?: ResourceColor; @@ -1655,8 +1575,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundBlurStyle?: BlurStyle; @@ -1667,8 +1586,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -1679,8 +1597,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -1701,8 +1618,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidAppear?: () => void; @@ -1718,8 +1634,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidDisappear?: () => void; @@ -1737,8 +1652,8 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * + * @since 12 */ onWillAppear?: () => void; @@ -1756,8 +1671,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillDisappear?: () => void; @@ -1770,8 +1684,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shadow?: ShadowOptions | ShadowStyle; @@ -1783,8 +1696,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableHoverMode?: boolean; @@ -1796,8 +1708,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ hoverModeArea?: HoverModeAreaType; @@ -1816,8 +1727,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableHapticFeedback?: boolean; @@ -1825,11 +1735,358 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * Background style of selected items. * * @type { ?PickerBackgroundStyle } + * @default { color: $r('sys.color.comp_background_tertiary'), borderRadius: $r('sys.float.corner_radius_level12') } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 20 + */ + selectedBackgroundStyle?: PickerBackgroundStyle; +} + +/** + * Defines the TextPickerDialogOptionsExt for Text Picker Dialog. + * + * @extends TextPickerOptions + * @interface TextPickerDialogOptionsExt + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ +declare interface TextPickerDialogOptionsExt extends TextPickerOptions { + /** + * Called when the default height of the selected element is set. + * + * @type { ?(number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + defaultPickerItemHeight?: number | string; + + /** + * Can scroll loop if true is set, on the contrary it can not. + * + * @type { ?boolean } + * @default true + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + canLoop?: boolean; + + /** + * Text style of disappearing items. + * + * @type { ?TextPickerTextStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + disappearTextStyle?: TextPickerTextStyle; + + /** + * Text style of normal items + * + * @type { ?TextPickerTextStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + textStyle?: TextPickerTextStyle; + + /** + * Style of accept button. + * + * @type { ?PickerDialogButtonStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + acceptButtonStyle?: PickerDialogButtonStyle; + + /** + * Style of cancel button. + * + * @type { ?PickerDialogButtonStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + cancelButtonStyle?: PickerDialogButtonStyle; + + /** + * Text style of selected items + * + * @type { ?TextPickerTextStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + selectedTextStyle?: TextPickerTextStyle; + + /** + * Defines whether to disable the text style animation. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + disableTextStyleAnimation?: boolean; + + /** + * Defines to set the default text style for options. + * + * @type { ?TextPickerTextStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + defaultTextStyle?: TextPickerTextStyle; + + /** + * Called when the OK button in the dialog is clicked. + * + * @type { ?Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onAccept?: Callback; + + /** + * Called when the Cancel button in the dialog is clicked. + * + * @type { ?VoidCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onCancel?: VoidCallback; + + /** + * This event is triggered when a TextPicker text is selected in dialog. + * + * @type { ?Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onChange?: Callback; + + /** + * This event is triggered when a TextPicker text is selected and scrolling has stopped in dialog. + * + * @type { ?Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onScrollStop?: Callback; + + /** + * This event is triggered when an item enters the selected area in dialog. + * + * @type { ?Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onEnterSelectedArea?: Callback; + + /** + * Mask Region of dialog. The size cannot exceed the main window. + * + * @type { ?Rectangle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + maskRect?: Rectangle; + + /** + * Defines the dialog alignment of the screen. + * + * @type { ?DialogAlignment } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + alignment?: DialogAlignment; + + /** + * Defines the dialog offset. + * + * @type { ?Offset } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + offset?: Offset; + + /** + * Defines the textPickerDialog's background color + * + * @type { ?ResourceColor } + * @default Color.Transparent + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + backgroundColor?: ResourceColor; + + /** + * Defines the textPickerDialog's background blur Style + * + * @type { ?BlurStyle } + * @default BlurStyle.COMPONENT_ULTRA_THICK + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + backgroundBlurStyle?: BlurStyle; + + /** + * Defines the textPickerDialog's background blur style with options + * + * @type { ?BackgroundBlurStyleOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; + + /** + * Defines the textPickerDialog's background effect with options + * + * @type { ?BackgroundEffectOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + backgroundEffect?: BackgroundEffectOptions; + + /** + * Callback function when the dialog appears. + * + * @type { ?VoidCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onDidAppear?: VoidCallback; + + /** + * Callback function when the dialog disappears. + * + * @type { ?VoidCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onDidDisappear?: VoidCallback; + + /** + * Callback function before the dialog openAnimation starts. + * + * @type { ?VoidCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onWillAppear?: VoidCallback; + + /** + * Callback function before the dialog closeAnimation starts. + * + * @type { ?VoidCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + onWillDisappear?: VoidCallback; + + /** + * Defines the dialog's shadow. + * + * @type { ?(ShadowOptions | ShadowStyle) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + shadow?: ShadowOptions | ShadowStyle; + + /** + * Defines whether to respond to the hover mode. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + enableHoverMode?: boolean; + + /** + * Defines the dialog's display area in hover mode. + * + * @type { ?HoverModeAreaType } + * @default HoverModeAreaType.BOTTOM_SCREEN + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 20 + */ + hoverModeArea?: HoverModeAreaType; + + /** + * Enable or disable haptic feedback. + * + * @type { ?boolean } * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 20 */ + enableHapticFeedback?: boolean; + + /** + * Background style of selected items. + * + * @type { ?PickerBackgroundStyle } + * @default { color: $r('sys.color.comp_background_tertiary'), borderRadius: $r('sys.float.corner_radius_level12') } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 20 + */ selectedBackgroundStyle?: PickerBackgroundStyle; } @@ -1852,8 +2109,7 @@ declare interface TextPickerDialogOptions extends TextPickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TextPickerDialog { /** @@ -1930,4 +2186,3 @@ declare const TextPicker: TextPickerInterface; * @since 11 */ declare const TextPickerInstance: TextPickerAttribute; - diff --git a/api/@internal/component/ets/text_timer.d.ts b/api/@internal/component/ets/text_timer.d.ts index c3a15592a95904f1087ab93a15a4ff725c17d5ea..561aae84168e89608a2054a3e48df4ca3a357538 100644 --- a/api/@internal/component/ets/text_timer.d.ts +++ b/api/@internal/component/ets/text_timer.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CommonConfiguration,CommonMethod,ShadowOptions,ContentModifier } from './common' -import { ResourceColor,Length,ResourceStr } from './units' -import { FontStyle,FontWeight } from './enums' -/*** endif */ - /** * Provides a way to control the process. * @@ -44,8 +38,7 @@ import { FontStyle,FontWeight } from './enums' * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TextTimerController { /** @@ -70,8 +63,7 @@ declare class TextTimerController { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -100,18 +92,6 @@ declare class TextTimerController { */ start(); - /** - * Provides a start event for timer. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - start():void; - /** * Provides a pause event for timer. * @@ -137,18 +117,6 @@ declare class TextTimerController { */ pause(); - /** - * Provides a pause event for timer. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - pause():void; - /** * Provides an event to reset timer. * @@ -173,18 +141,6 @@ declare class TextTimerController { * @since 11 */ reset(); - - /** - * Provides an event to reset timer. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - reset():void; } /** @@ -195,8 +151,7 @@ declare class TextTimerController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface TextTimerConfiguration extends CommonConfiguration { /** @@ -214,8 +169,7 @@ declare interface TextTimerConfiguration extends CommonConfiguration { /** @@ -510,8 +454,7 @@ declare class TextTimerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ format(value: string): TextTimerAttribute; @@ -542,8 +485,7 @@ declare class TextTimerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontColor(value: ResourceColor): TextTimerAttribute; @@ -576,8 +518,7 @@ declare class TextTimerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontSize(value: Length): TextTimerAttribute; @@ -608,8 +549,7 @@ declare class TextTimerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontStyle(value: FontStyle): TextTimerAttribute; @@ -659,7 +599,6 @@ declare class TextTimerAttribute extends CommonMethod { * @form * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ fontWeight(value: number | FontWeight | ResourceStr): TextTimerAttribute; @@ -690,8 +629,7 @@ declare class TextTimerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fontFamily(value: ResourceStr): TextTimerAttribute; @@ -724,8 +662,7 @@ declare class TextTimerAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onTimer(event: (utc: number, elapsedTime: number) => void): TextTimerAttribute; @@ -748,8 +685,7 @@ declare class TextTimerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ textShadow(value: ShadowOptions | Array): TextTimerAttribute; @@ -761,8 +697,7 @@ declare class TextTimerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentModifier(modifier: ContentModifier): TextTimerAttribute; } diff --git a/api/@internal/component/ets/time_picker.d.ts b/api/@internal/component/ets/time_picker.d.ts index 4fc274659814f7df5b5a9bf1e61eb70a2a638590..07fe2eb64eb98f651e2a2fcc47a71e1a9d30eda4 100644 --- a/api/@internal/component/ets/time_picker.d.ts +++ b/api/@internal/component/ets/time_picker.d.ts @@ -18,14 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceColor, Offset } from './units'; -import { CommonMethod, PickerTextStyle, PickerDialogButtonStyle, Rectangle, BlurStyle, ShadowOptions, ShadowStyle, HoverModeAreaType, - BackgroundBlurStyleOptions, BackgroundEffectOptions, Optional, Callback, DateTimeOptions, Bindable } from './common'; -import { DialogAlignment } from './alertDialog'; -import { CrownSensitivity } from './enums'; -/*** endif */ - /** * Defines the struct of TimePickerResult. * @@ -48,8 +40,7 @@ import { CrownSensitivity } from './enums'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TimePickerResult { /** @@ -74,8 +65,7 @@ declare interface TimePickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ hour: number; @@ -101,8 +91,7 @@ declare interface TimePickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ minute: number; @@ -113,8 +102,7 @@ declare interface TimePickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ second: number; } @@ -132,8 +120,7 @@ declare interface TimePickerResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum TimePickerFormat { /** @@ -147,8 +134,7 @@ declare enum TimePickerFormat { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ HOUR_MINUTE, @@ -163,8 +149,7 @@ declare enum TimePickerFormat { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ HOUR_MINUTE_SECOND, } @@ -191,8 +176,7 @@ declare enum TimePickerFormat { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TimePickerOptions { /** @@ -221,18 +205,6 @@ declare interface TimePickerOptions { */ selected?: Date; - /** - * Specifies the time selector check time. - * - * @type { ?(Date | Bindable) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - selected?: Date | Bindable; - /** * Specifies the format of the TimePicker that need to be displayed. * @@ -250,8 +222,7 @@ declare interface TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ format?: TimePickerFormat; @@ -262,8 +233,7 @@ declare interface TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ start?: Date; @@ -274,8 +244,7 @@ declare interface TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ end?: Date; } @@ -302,8 +271,7 @@ declare interface TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface TimePickerInterface { /** @@ -331,8 +299,7 @@ interface TimePickerInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options?: TimePickerOptions): TimePickerAttribute; } @@ -354,8 +321,7 @@ declare type DateTimeOptions = import('../api/@ohos.intl').default.DateTimeOptio * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnTimePickerChangeCallback = (result: TimePickerResult) => void; @@ -381,8 +347,7 @@ declare type OnTimePickerChangeCallback = (result: TimePickerResult) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TimePickerAttribute extends CommonMethod { /** @@ -410,8 +375,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ useMilitaryTime(value: boolean): TimePickerAttribute; @@ -423,8 +387,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ useMilitaryTime(isMilitaryTime: Optional): TimePickerAttribute; @@ -443,8 +406,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ loop(value: boolean): TimePickerAttribute; @@ -455,8 +417,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ loop(isLoop: Optional): TimePickerAttribute; @@ -477,8 +438,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ disappearTextStyle(value: PickerTextStyle): TimePickerAttribute; @@ -490,8 +450,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ disappearTextStyle(style: Optional): TimePickerAttribute; @@ -512,8 +471,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle(value: PickerTextStyle): TimePickerAttribute; @@ -525,8 +483,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ textStyle(style: Optional): TimePickerAttribute; @@ -547,8 +504,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedTextStyle(value: PickerTextStyle): TimePickerAttribute; @@ -560,8 +516,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ selectedTextStyle(style: Optional): TimePickerAttribute; @@ -573,9 +528,8 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ + * @since 12 + */ dateTimeOptions(value: DateTimeOptions): TimePickerAttribute; /** @@ -586,9 +540,8 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ + * @since 18 + */ dateTimeOptions(timeFormat: Optional): TimePickerAttribute; /** @@ -628,8 +581,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onChange(callback: Optional): TimePickerAttribute; @@ -641,8 +593,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onEnterSelectedArea(callback: Callback): TimePickerAttribute; @@ -653,8 +604,7 @@ declare class TimePickerAttribute extends CommonMethod { * @returns { TimePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableHapticFeedback(enable: boolean): TimePickerAttribute; @@ -665,8 +615,7 @@ declare class TimePickerAttribute extends CommonMethod { * @returns { TimePickerAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableHapticFeedback(enable: Optional): TimePickerAttribute; @@ -678,8 +627,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ digitalCrownSensitivity(sensitivity: Optional): TimePickerAttribute; @@ -691,8 +639,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableCascade(enabled: boolean): TimePickerAttribute; } @@ -722,8 +669,7 @@ declare class TimePickerAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface TimePickerDialogOptions extends TimePickerOptions { /** @@ -748,8 +694,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ useMilitaryTime?: boolean; @@ -768,8 +713,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ disappearTextStyle?: PickerTextStyle; @@ -788,8 +732,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ textStyle?: PickerTextStyle; @@ -800,8 +743,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ acceptButtonStyle?: PickerDialogButtonStyle; @@ -812,8 +754,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ cancelButtonStyle?: PickerDialogButtonStyle; @@ -832,8 +773,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedTextStyle?: PickerTextStyle; @@ -852,8 +792,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maskRect?: Rectangle; @@ -872,8 +811,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ alignment?: DialogAlignment; @@ -892,8 +830,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ offset?: Offset; @@ -919,8 +856,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onAccept?: (value: TimePickerResult) => void; @@ -946,8 +882,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onCancel?: () => void; @@ -973,8 +908,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onChange?: (value: TimePickerResult) => void; @@ -985,8 +919,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onEnterSelectedArea?: Callback; @@ -1007,8 +940,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundColor?: ResourceColor; @@ -1029,8 +961,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundBlurStyle?: BlurStyle; @@ -1041,8 +972,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundBlurStyleOptions?: BackgroundBlurStyleOptions; @@ -1053,8 +983,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ backgroundEffect?: BackgroundEffectOptions; @@ -1066,8 +995,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableCascade?: boolean; @@ -1078,8 +1006,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidAppear?: () => void; @@ -1090,8 +1017,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onDidDisappear?: () => void; @@ -1102,8 +1028,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillAppear?: () => void; @@ -1114,8 +1039,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onWillDisappear?: () => void; @@ -1126,8 +1050,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ shadow?: ShadowOptions | ShadowStyle; @@ -1138,11 +1061,10 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dateTimeOptions?: DateTimeOptions; - + /** * Defines whether to respond to the hover mode. * @@ -1151,8 +1073,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enableHoverMode?: boolean; @@ -1164,8 +1085,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ hoverModeArea?: HoverModeAreaType; @@ -1176,8 +1096,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @default true * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableHapticFeedback?: boolean; } @@ -1201,8 +1120,7 @@ declare interface TimePickerDialogOptions extends TimePickerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class TimePickerDialog { /** diff --git a/api/@internal/component/ets/toggle.d.ts b/api/@internal/component/ets/toggle.d.ts index 4f1a07f3087dbbb03d2c1e70df48c4d01c473a5b..3c4049268e34536f74078098f2ac7159eb03d4ad 100644 --- a/api/@internal/component/ets/toggle.d.ts +++ b/api/@internal/component/ets/toggle.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from '../../global/resource'; -import { ResourceColor } from './units'; -import { CommonConfiguration, Callback, CommonMethod, ContentModifier, Bindable } from './common'; -/*** endif */ - /** * Declare the type of status button * @@ -56,8 +50,7 @@ import { CommonConfiguration, Callback, CommonMethod, ContentModifier, Bindable * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ToggleType { /** @@ -88,8 +81,7 @@ declare enum ToggleType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Checkbox, @@ -121,8 +113,7 @@ declare enum ToggleType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Switch, @@ -154,8 +145,7 @@ declare enum ToggleType { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Button, } @@ -167,8 +157,7 @@ declare enum ToggleType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface SwitchStyle { /** @@ -178,8 +167,7 @@ declare interface SwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pointRadius?: number | Resource; @@ -190,8 +178,7 @@ declare interface SwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ unselectedColor?: ResourceColor; @@ -202,8 +189,7 @@ declare interface SwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pointColor?: ResourceColor; @@ -214,8 +200,7 @@ declare interface SwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ trackBorderRadius?: number | Resource; } @@ -228,8 +213,7 @@ declare interface SwitchStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ToggleConfiguration extends CommonConfiguration { @@ -240,8 +224,7 @@ declare interface ToggleConfiguration extends CommonConfiguration; } @@ -278,8 +259,7 @@ declare interface ToggleConfiguration extends CommonConfiguration) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - isOn?: boolean | undefined | Bindable } /** @@ -423,8 +389,8 @@ declare interface ToggleOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ interface ToggleInterface { /** @@ -475,8 +441,7 @@ interface ToggleInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ (options: ToggleOptions): ToggleAttribute; } @@ -513,8 +478,8 @@ interface ToggleInterface { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 + * @noninterop */ declare class ToggleAttribute extends CommonMethod { /** @@ -553,8 +518,7 @@ declare class ToggleAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onChange(callback: (isOn: boolean) => void): ToggleAttribute; @@ -566,8 +530,7 @@ declare class ToggleAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ contentModifier(modifier: ContentModifier): ToggleAttribute; @@ -607,8 +570,7 @@ declare class ToggleAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ selectedColor(value: ResourceColor): ToggleAttribute; @@ -648,8 +610,7 @@ declare class ToggleAttribute extends CommonMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ switchPointColor(color: ResourceColor): ToggleAttribute; @@ -661,8 +622,7 @@ declare class ToggleAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ switchStyle(value: SwitchStyle): ToggleAttribute; } diff --git a/api/@internal/component/ets/ui_extension_component.d.ts b/api/@internal/component/ets/ui_extension_component.d.ts index 7637cdeaaaa74c343b90d4093d29fa37a8b0b3e8..513a4f2058bf41b715272884688e4481d738525f 100644 --- a/api/@internal/component/ets/ui_extension_component.d.ts +++ b/api/@internal/component/ets/ui_extension_component.d.ts @@ -18,21 +18,13 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import Want from '../../@ohos.app.ability.Want' -import { Callback, ErrorCallback, BusinessError } from '../../@ohos.base' -import { CommonMethod, TerminationInfo } from './common' -import { ComponentContent } from '../ComponentContent' -/*** endif */ - /** * Enumeration of different types of DpiFollowStrategy. * * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum DpiFollowStrategy { /** @@ -40,8 +32,7 @@ declare enum DpiFollowStrategy { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FOLLOW_HOST_DPI = 0, @@ -50,8 +41,7 @@ declare enum DpiFollowStrategy { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ FOLLOW_UI_EXTENSION_ABILITY_DPI = 1, } @@ -61,25 +51,21 @@ declare enum DpiFollowStrategy { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare enum WindowModeFollowStrategy { /** * Followed the host Window Mode. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ FOLLOW_HOST_WINDOW_MODE = 0, - /** * Followed the UIExtensionAbility. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ FOLLOW_UI_EXTENSION_ABILITY_WINDOW_MODE = 1 } @@ -90,8 +76,7 @@ declare enum WindowModeFollowStrategy { * @interface UIExtensionOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface UIExtensionOptions { /** @@ -102,8 +87,7 @@ declare interface UIExtensionOptions { * @default false * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ isTransferringCaller?: boolean; @@ -114,8 +98,7 @@ declare interface UIExtensionOptions { * @type { ?ComponentContent } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ placeholder?: ComponentContent; @@ -127,8 +110,7 @@ declare interface UIExtensionOptions { * @type { ?Record } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ areaChangePlaceholder?: Record; @@ -139,8 +121,7 @@ declare interface UIExtensionOptions { * @default DpiFollowStrategy.FOLLOW_UI_EXTENSION_ABILITY_DPI * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dpiFollowStrategy?: DpiFollowStrategy; @@ -150,8 +131,7 @@ declare interface UIExtensionOptions { * @default WindowModeFollowStrategy.FOLLOW_UI_EXTENSION_ABILITY_WINDOW_MODE * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ windowModeFollowStrategy?: WindowModeFollowStrategy; } @@ -196,18 +176,6 @@ declare interface TerminationInfo { * @since 18 */ declare type ReceiveCallback = import('../api/@ohos.base').Callback>; - -/** - * Get Callback from @ohos.base. - * - * @typedef { Callback> } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since 20 - * @arkts 1.2 - */ -type ReceiveCallback = Callback>; - /** * This interface is used for send data to the UIExtensionAbility.
* It is returned from onRemoteReady callback of UIExtensionComponent
@@ -216,8 +184,7 @@ type ReceiveCallback = Callback>; * @interface UIExtensionProxy * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ declare interface UIExtensionProxy { /** @@ -235,8 +202,7 @@ declare interface UIExtensionProxy { * @param { Record } data * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ send(data: Record): void; @@ -261,8 +227,7 @@ declare interface UIExtensionProxy { * @throws { BusinessError } 100012 - Transferring data failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ sendSync(data: Record): Record; @@ -283,8 +248,7 @@ declare interface UIExtensionProxy { * @param { Callback } callback - Callback of the listened event. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ on(type: 'asyncReceiverRegister', callback: Callback): void; @@ -305,8 +269,7 @@ declare interface UIExtensionProxy { * @param { Callback } callback - Callback of the listened event. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ on(type: 'syncReceiverRegister', callback: Callback): void; @@ -327,8 +290,7 @@ declare interface UIExtensionProxy { * @param { Callback } [callback] - Callback of the listened event. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ off(type: 'asyncReceiverRegister', callback?: Callback): void; @@ -349,8 +311,7 @@ declare interface UIExtensionProxy { * @param { Callback } [callback] - Callback of the listened event. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ off(type: 'syncReceiverRegister', callback?: Callback): void; } @@ -362,8 +323,8 @@ declare interface UIExtensionProxy { * @interface UIExtensionComponentInterface * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 + * @noninterop */ interface UIExtensionComponentInterface { /** @@ -391,24 +352,6 @@ interface UIExtensionComponentInterface { want: import('../api/@ohos.app.ability.Want').default, options?: UIExtensionOptions ): UIExtensionComponentAttribute; - - /** - * Construct the UIExtensionComponent.
- * Called when the UIExtensionComponent is used. - * - * @param { Want } want - indicates the want of UIExtensionAbility - * @param { UIExtensionOptions } [options] - Construction configuration of UIExtensionComponentAttribute - * @returns { UIExtensionComponentAttribute } - * @throws { BusinessError } 202 - Non-system applications are not allowed to use system APIs. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since 20 - * @arkts 1.2 - */ - ( - want: Want, - options?: UIExtensionOptions - ): UIExtensionComponentAttribute; } /** @@ -417,8 +360,8 @@ interface UIExtensionComponentInterface { * @extends CommonMethod * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 + * @noninterop */ declare class UIExtensionComponentAttribute extends CommonMethod { /** @@ -433,21 +376,6 @@ declare class UIExtensionComponentAttribute extends CommonMethod ): UIExtensionComponentAttribute; - - /** - * callback called when remote UIExtensionAbility object is ready for receive data - * - * @param { Callback } callback - * @returns { UIExtensionComponentAttribute } - * @throws { BusinessError } 202 - Non-system applications are not allowed to use system APIs. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since 20 - * @arkts 1.2 - */ - onRemoteReady( - callback: Callback - ): UIExtensionComponentAttribute; /** * @param { import('../api/@ohos.base').Callback<{ [key: string]: Object }> } callback @@ -464,8 +392,7 @@ declare class UIExtensionComponentAttribute extends CommonMethod } callback - * @returns { UIExtensionComponentAttribute } - * @throws { BusinessError } 202 - Non-system applications are not allowed to use system APIs. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since 20 - * @arkts 1.2 - */ - onError( - callback: ErrorCallback - ): UIExtensionComponentAttribute; /** * Called when the provider of the embedded UI is terminated. @@ -535,8 +447,7 @@ declare class UIExtensionComponentAttribute extends CommonMethod): UIExtensionComponentAttribute; @@ -546,8 +457,7 @@ declare class UIExtensionComponentAttribute extends CommonMethod): UIExtensionComponentAttribute; } @@ -558,6 +468,7 @@ declare class UIExtensionComponentAttribute extends CommonMethod void; @@ -2093,19 +1903,6 @@ declare type VoidCallback = () => void; */ declare type LengthMetricsUnit = import('../api/arkui/Graphics').LengthMetricsUnit; -/** - * Defines length metrics unit. - * - * @typedef { _LengthMetricsUnit } LengthMetricsUnit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type LengthMetricsUnit = _LengthMetricsUnit; - /** * Defines LengthMetrics. * @@ -2117,18 +1914,6 @@ declare type LengthMetricsUnit = _LengthMetricsUnit; */ declare type LengthMetrics = import('../api/arkui/Graphics').LengthMetrics; -/** - * Defines LengthMetrics. - * - * @typedef { _LengthMetrics } LengthMetrics - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type LengthMetrics = _LengthMetrics; - /** * Defines ColorMetrics. * @@ -2140,18 +1925,6 @@ declare type LengthMetrics = _LengthMetrics; */ declare type ColorMetrics = import('../api/arkui/Graphics').ColorMetrics; -/** - * Defines ColorMetrics. - * - * @typedef { _ColorMetrics } ColorMetrics - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare type ColorMetrics = _ColorMetrics; - /** * Defines the font used for text. * @@ -2174,8 +1947,7 @@ declare type ColorMetrics = _ColorMetrics; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface Font { /** @@ -2200,8 +1972,7 @@ declare interface Font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ size?: Length; @@ -2227,8 +1998,7 @@ declare interface Font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ weight?: FontWeight | number | string; @@ -2254,8 +2024,7 @@ declare interface Font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ family?: string | Resource; @@ -2281,8 +2050,7 @@ declare interface Font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ style?: FontStyle; } @@ -2319,8 +2087,7 @@ declare interface Font { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface Area { /** @@ -2355,8 +2122,7 @@ declare interface Area { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ width: Length; @@ -2392,8 +2158,7 @@ declare interface Area { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ height: Length; @@ -2429,8 +2194,7 @@ declare interface Area { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ position: Position; @@ -2466,8 +2230,7 @@ declare interface Area { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ globalPosition: Position; } @@ -2504,8 +2267,7 @@ declare interface Area { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface Position { /** @@ -2540,8 +2302,7 @@ declare interface Position { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ x?: Length; @@ -2577,8 +2338,7 @@ declare interface Position { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ y?: Length; } @@ -2590,8 +2350,7 @@ declare interface Position { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface LocalizedPosition { /** @@ -2601,8 +2360,7 @@ declare interface LocalizedPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start?: LengthMetrics; @@ -2613,8 +2371,7 @@ declare interface LocalizedPosition { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ top?: LengthMetrics; } @@ -2627,8 +2384,7 @@ declare interface LocalizedPosition { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface Edges { /** @@ -2639,8 +2395,7 @@ declare interface Edges { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ top?: Dimension; @@ -2652,8 +2407,7 @@ declare interface Edges { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ left?: Dimension; @@ -2665,8 +2419,7 @@ declare interface Edges { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ bottom?: Dimension; @@ -2678,8 +2431,7 @@ declare interface Edges { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ right?: Dimension; } @@ -2691,8 +2443,7 @@ declare interface Edges { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface LocalizedEdges { /** @@ -2702,8 +2453,7 @@ declare interface LocalizedEdges { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ top?: LengthMetrics; @@ -2714,8 +2464,7 @@ declare interface LocalizedEdges { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start?: LengthMetrics; @@ -2726,8 +2475,7 @@ declare interface LocalizedEdges { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ bottom?: LengthMetrics; @@ -2738,8 +2486,7 @@ declare interface LocalizedEdges { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ end?: LengthMetrics; } @@ -2761,8 +2508,7 @@ declare interface LocalizedEdges { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface Bias { /** @@ -2784,8 +2530,7 @@ declare interface Bias { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ horizontal?: number; @@ -2808,8 +2553,7 @@ declare interface Bias { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ vertical?: number; } @@ -2846,8 +2590,7 @@ declare interface Bias { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface ConstraintSizeOptions { /** @@ -2882,8 +2625,7 @@ declare interface ConstraintSizeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ minWidth?: Length; @@ -2919,8 +2661,7 @@ declare interface ConstraintSizeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maxWidth?: Length; @@ -2956,8 +2697,7 @@ declare interface ConstraintSizeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ minHeight?: Length; @@ -2993,8 +2733,7 @@ declare interface ConstraintSizeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ maxHeight?: Length; } @@ -3031,8 +2770,7 @@ declare interface ConstraintSizeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface SizeOptions { /** @@ -3067,8 +2805,7 @@ declare interface SizeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ width?: Length; @@ -3104,8 +2841,7 @@ declare interface SizeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ height?: Length; } @@ -3152,8 +2888,7 @@ declare interface SizeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface BorderOptions { /** @@ -3198,8 +2933,7 @@ declare interface BorderOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width?: EdgeWidths | Length | LocalizedEdgeWidths; @@ -3245,8 +2979,7 @@ declare interface BorderOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color?: EdgeColors | ResourceColor | LocalizedEdgeColors; @@ -3292,8 +3025,7 @@ declare interface BorderOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radius?: BorderRadiuses | Length | LocalizedBorderRadiuses; @@ -3329,8 +3061,7 @@ declare interface BorderOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ style?: EdgeStyles | BorderStyle; @@ -3341,8 +3072,7 @@ declare interface BorderOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dashGap?: EdgeWidths | LengthMetrics | LocalizedEdgeWidths; @@ -3353,8 +3083,7 @@ declare interface BorderOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dashWidth?: EdgeWidths | LengthMetrics | LocalizedEdgeWidths; } @@ -3376,8 +3105,7 @@ declare interface BorderOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface OutlineOptions { /** @@ -3397,8 +3125,7 @@ declare interface OutlineOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width?: EdgeOutlineWidths | Dimension; @@ -3419,8 +3146,7 @@ declare interface OutlineOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color?: EdgeColors | ResourceColor | LocalizedEdgeColors; @@ -3441,8 +3167,7 @@ declare interface OutlineOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radius?: OutlineRadiuses | Dimension; @@ -3463,8 +3188,7 @@ declare interface OutlineOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ style?: EdgeOutlineStyles | OutlineStyle; } @@ -3484,8 +3208,7 @@ declare interface OutlineOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface MarkStyle { /** @@ -3503,8 +3226,7 @@ declare interface MarkStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeColor?: ResourceColor; @@ -3523,8 +3245,7 @@ declare interface MarkStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ size?: Length; @@ -3543,8 +3264,7 @@ declare interface MarkStyle { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ strokeWidth?: Length; } @@ -3571,8 +3291,7 @@ declare interface MarkStyle { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class ColorFilter { /** @@ -3600,8 +3319,7 @@ declare class ColorFilter { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(value: number[]); } @@ -3628,8 +3346,7 @@ declare class ColorFilter { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface TouchPoint { /** @@ -3654,8 +3371,7 @@ declare interface TouchPoint { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ x: Dimension; @@ -3681,8 +3397,7 @@ declare interface TouchPoint { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ y: Dimension; } @@ -3695,8 +3410,7 @@ declare interface TouchPoint { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface DirectionalEdgesT { /** @@ -3707,8 +3421,7 @@ declare interface DirectionalEdgesT { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start: T; @@ -3720,8 +3433,7 @@ declare interface DirectionalEdgesT { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ end: T; @@ -3733,8 +3445,7 @@ declare interface DirectionalEdgesT { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ top: T; @@ -3746,8 +3457,7 @@ declare interface DirectionalEdgesT { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ bottom: T; } @@ -3759,8 +3469,7 @@ declare interface DirectionalEdgesT { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface DividerStyleOptions { /** @@ -3770,8 +3479,7 @@ declare interface DividerStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ strokeWidth?: LengthMetrics; @@ -3782,8 +3490,7 @@ declare interface DividerStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ color?: ResourceColor; @@ -3794,8 +3501,7 @@ declare interface DividerStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ startMargin?: LengthMetrics; @@ -3806,8 +3512,7 @@ declare interface DividerStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ endMargin?: LengthMetrics; @@ -3818,8 +3523,7 @@ declare interface DividerStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ mode?: DividerMode; } @@ -3831,8 +3535,7 @@ declare interface DividerStyleOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare interface ChainWeightOptions { /** @@ -3842,8 +3545,7 @@ declare interface ChainWeightOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ horizontal?: number; @@ -3854,8 +3556,7 @@ declare interface ChainWeightOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ vertical?: number; } @@ -3867,8 +3568,7 @@ declare interface ChainWeightOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ declare interface AccessibilityOptions { /** @@ -3878,8 +3578,7 @@ declare interface AccessibilityOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ accessibilityPreferred?: boolean; } diff --git a/api/@internal/component/ets/video.d.ts b/api/@internal/component/ets/video.d.ts index 29a25dc16743033c5824d1d324b695d0ff27076b..36dc4bd16b815f143a39c2fd3d01397f271e1a79 100644 --- a/api/@internal/component/ets/video.d.ts +++ b/api/@internal/component/ets/video.d.ts @@ -18,14 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from '../../global/resource'; -import { ImageAIOptions, ImageAnalyzerConfig } from './imageCommon'; -import { ImageFit } from './enums'; -import { CommonMethod, Callback, PixelMap } from './common'; -import { VoidCallback, ColorMetrics } from './units'; -/*** endif */ - /** * Seek mode. * @@ -48,8 +40,7 @@ import { VoidCallback, ColorMetrics } from './units'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum SeekMode { /** @@ -71,8 +62,7 @@ declare enum SeekMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ PreviousKeyframe, @@ -95,8 +85,7 @@ declare enum SeekMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NextKeyframe, @@ -119,8 +108,7 @@ declare enum SeekMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ClosestKeyframe, @@ -143,8 +131,7 @@ declare enum SeekMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Accurate, } @@ -171,8 +158,7 @@ declare enum SeekMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum PlaybackSpeed { /** @@ -194,8 +180,7 @@ declare enum PlaybackSpeed { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Speed_Forward_0_75_X, @@ -218,8 +203,7 @@ declare enum PlaybackSpeed { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Speed_Forward_1_00_X, @@ -242,8 +226,7 @@ declare enum PlaybackSpeed { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Speed_Forward_1_25_X, @@ -266,8 +249,7 @@ declare enum PlaybackSpeed { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Speed_Forward_1_75_X, @@ -290,8 +272,7 @@ declare enum PlaybackSpeed { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ Speed_Forward_2_00_X, } @@ -303,8 +284,7 @@ declare enum PlaybackSpeed { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface FullscreenInfo { /** @@ -331,8 +311,7 @@ interface FullscreenInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ fullscreen: boolean; } @@ -344,8 +323,7 @@ interface FullscreenInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface PreparedInfo { /** @@ -372,8 +350,7 @@ interface PreparedInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ duration: number; } @@ -385,8 +362,7 @@ interface PreparedInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface PlaybackInfo { /** @@ -413,8 +389,7 @@ interface PlaybackInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ time: number; } @@ -425,8 +400,7 @@ interface PlaybackInfo { * @interface PosterOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface PosterOptions { /** @@ -436,8 +410,7 @@ declare interface PosterOptions { * @default false * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ showFirstFrame?: boolean; } @@ -473,8 +446,7 @@ declare interface PosterOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface VideoOptions { /** @@ -499,8 +471,7 @@ declare interface VideoOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ src?: string | Resource; @@ -526,8 +497,7 @@ declare interface VideoOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ currentProgressRate?: number | string | PlaybackSpeed; @@ -553,8 +523,7 @@ declare interface VideoOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ previewUri?: string | PixelMap | Resource; @@ -580,8 +549,7 @@ declare interface VideoOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ controller?: VideoController; @@ -591,8 +559,7 @@ declare interface VideoOptions { * @type { ?ImageAIOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ imageAIOptions?: ImageAIOptions; @@ -602,8 +569,7 @@ declare interface VideoOptions { * @type { ?PosterOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ posterOptions?: PosterOptions; } @@ -627,8 +593,7 @@ declare interface VideoOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class VideoController { /** @@ -650,8 +615,7 @@ declare class VideoController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ constructor(); @@ -678,17 +642,6 @@ declare class VideoController { */ start(); - /** - * Provides events to play. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - start(): void; - /** * Provides a pause event for playback. * @@ -712,17 +665,6 @@ declare class VideoController { */ pause(); - /** - * Provides a pause event for playback. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - pause(): void; - /** * Provides an event to stop playback. * @@ -746,17 +688,6 @@ declare class VideoController { */ stop(); - /** - * Provides an event to stop playback. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - stop(): void; - /** * Provide the progress method of video playback. * @@ -783,18 +714,6 @@ declare class VideoController { */ setCurrentTime(value: number); - /** - * Provide the progress method of video playback. - * - * @param { number } value - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - setCurrentTime(value: number): void; - /** * Provides a full screen playback method. * @@ -821,18 +740,6 @@ declare class VideoController { */ requestFullscreen(value: boolean); - /** - * Provides a full screen playback method. - * - * @param { boolean } value - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - requestFullscreen(value: boolean): void; - /** * Provides a method to exit full screen playback. * @@ -856,17 +763,6 @@ declare class VideoController { */ exitFullscreen(); - /** - * Provides a method to exit full screen playback. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - exitFullscreen(): void; - /** * Provide the progress method of video playback. * @@ -896,26 +792,12 @@ declare class VideoController { */ setCurrentTime(value: number, seekMode: SeekMode); - /** - * Provide the progress method of video playback. - * - * @param { number } value - * @param { SeekMode } seekMode - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - setCurrentTime(value: number, seekMode: SeekMode): void; - /** * Provide the reset method of video playback. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ reset(): void; } @@ -942,8 +824,7 @@ declare class VideoController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface VideoInterface { /** @@ -971,8 +852,7 @@ interface VideoInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (value: VideoOptions): VideoAttribute; } @@ -999,8 +879,7 @@ interface VideoInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class VideoAttribute extends CommonMethod { /** @@ -1028,8 +907,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ muted(value: boolean): VideoAttribute; @@ -1058,8 +936,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ autoPlay(value: boolean): VideoAttribute; @@ -1088,8 +965,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ controls(value: boolean): VideoAttribute; @@ -1118,8 +994,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ loop(value: boolean): VideoAttribute; @@ -1148,8 +1023,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ objectFit(value: ImageFit): VideoAttribute; @@ -1189,8 +1063,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onStart(event: VoidCallback): VideoAttribute; @@ -1230,8 +1103,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onPause(event: VoidCallback): VideoAttribute; @@ -1271,8 +1143,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onFinish(event: VoidCallback): VideoAttribute; @@ -1312,8 +1183,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onFullscreenChange(callback: Callback): VideoAttribute; @@ -1353,8 +1223,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onPrepared(callback: Callback): VideoAttribute; @@ -1394,8 +1263,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onSeeking(callback: Callback): VideoAttribute; @@ -1435,8 +1303,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onSeeked(callback: Callback): VideoAttribute; @@ -1476,8 +1343,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onUpdate(callback: Callback): VideoAttribute; @@ -1519,19 +1385,6 @@ declare class VideoAttribute extends CommonMethod { * @since 20 */ onError(event: VoidCallback | import('../api/@ohos.base').ErrorCallback): VideoAttribute; - - /** - * Called when playback fails. - * - * @param { function } event - * @returns { VideoAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onError(event: () => void): VideoAttribute; /** * Called when the video is stopped. @@ -1541,8 +1394,7 @@ declare class VideoAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onStop(event: Callback): VideoAttribute; @@ -1553,8 +1405,7 @@ declare class VideoAttribute extends CommonMethod { * @returns { VideoAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableAnalyzer(enable: boolean): VideoAttribute; @@ -1565,8 +1416,7 @@ declare class VideoAttribute extends CommonMethod { * @returns { VideoAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ analyzerConfig(config: ImageAnalyzerConfig): VideoAttribute; @@ -1577,8 +1427,7 @@ declare class VideoAttribute extends CommonMethod { * @returns { VideoAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ surfaceBackgroundColor(color: ColorMetrics): VideoAttribute; @@ -1593,8 +1442,7 @@ declare class VideoAttribute extends CommonMethod { * @returns { VideoAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ enableShortcutKey(enabled: boolean): VideoAttribute; } diff --git a/api/@internal/component/ets/water_flow.d.ts b/api/@internal/component/ets/water_flow.d.ts index 05823f127d14451bde0c7822aa389ccb91a70e29..f39fb55bc8339232c03e08db30fd7fda1f6d6bee 100644 --- a/api/@internal/component/ets/water_flow.d.ts +++ b/api/@internal/component/ets/water_flow.d.ts @@ -18,16 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ScrollableCommonMethod, NestedScrollOptions, CommonMethod, Optional, OnWillScrollCallback, OnScrollCallback } from './common'; -import { CustomBuilder } from './builder' -import { Length, Dimension, Margin, ConstraintSizeOptions, Resource } from './units'; -import { Scroller, OnScrollFrameBeginCallback } from './scroll'; -import { ScrollState } from './list' -import { FlexDirection } from './enums' -import { ComponentContent } from '../../arkui/ComponentContent' -/*** endif */ - /** * function that returns item main size by index. * @@ -37,8 +27,7 @@ import { ComponentContent } from '../../arkui/ComponentContent' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare type GetItemMainSizeByIndex = (index: number) => number; @@ -48,20 +37,19 @@ declare type GetItemMainSizeByIndex = (index: number) => number; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class SectionOptions { /** * The number of FlowItems in this section. * * @type { number } itemsCount - Number of water flow items in the section. The value must be a positive integer. - * If the splice, push, or update APIs receive a section where the itemsCount value is less than 0, these APIs will not be executed. + * If the splice, push, or update APIs receive a section + * where the itemsCount value is less than 0, these APIs will not be executed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ itemsCount: number; @@ -74,8 +62,7 @@ declare class SectionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ crossCount?: number; @@ -96,8 +83,7 @@ declare class SectionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onGetItemMainSizeByIndex?: GetItemMainSizeByIndex; @@ -110,8 +96,7 @@ declare class SectionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ columnsGap?: Dimension; @@ -124,8 +109,7 @@ declare class SectionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ rowsGap?: Dimension; @@ -137,8 +121,7 @@ declare class SectionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ margin?: Margin | Dimension; } @@ -149,8 +132,7 @@ declare class SectionOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class WaterFlowSections { /** @@ -159,8 +141,7 @@ declare class WaterFlowSections { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(); @@ -169,7 +150,8 @@ declare class WaterFlowSections { * * @param { number } start - Zero-based index at which the changing starts. The value is converted to an integer. *
NOTE - *
1. A negative index counts back from the end of the section list. If -WaterFlowSections.length() <= start < 0, start + array.length is used. + *
1. A negative index counts back from the end of the section list. + * If -WaterFlowSections.length() <= start < 0, start + array.length is used. *
2. If start < -WaterFlowSections.length(), 0 is used. *
3. If start >= WaterFlowSections.length(), a new section is added at the end. * @param { number } [deleteCount] - Number of sections to be deleted from the position specified by start. @@ -184,8 +166,7 @@ declare class WaterFlowSections { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ splice(start: number, deleteCount?: number, sections?: Array): boolean; @@ -197,8 +178,7 @@ declare class WaterFlowSections { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ push(section: SectionOptions): boolean; @@ -207,15 +187,16 @@ declare class WaterFlowSections { * * @param { number } sectionIndex - Zero-based index of the water flow item section to update. The value is converted to an integer. *
NOTE - *
1. A negative index counts back from the end of the section list. If -WaterFlowSections.length() <= sectionIndex < 0, sectionIndex + array.length is used. - *
2. If sectionIndex < -WaterFlowSections.length(), 0 is used.
3. If sectionIndex >= WaterFlowSections.length(), a new section is added at the end. + *
1. A negative index counts back from the end of the section list. + * If -WaterFlowSections.length() <= sectionIndex < 0, sectionIndex + array.length is used. + *
2. If sectionIndex < -WaterFlowSections.length(), 0 is used.
+ * 3. If sectionIndex >= WaterFlowSections.length(), a new section is added at the end. * @param { SectionOptions } section - New section configuration. * @returns { boolean } Whether the update was successful. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ update(sectionIndex:number, section: SectionOptions): boolean; @@ -226,8 +207,7 @@ declare class WaterFlowSections { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ values(): Array; @@ -238,8 +218,7 @@ declare class WaterFlowSections { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ length(): number; } @@ -251,8 +230,7 @@ declare class WaterFlowSections { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare enum WaterFlowLayoutMode { /** @@ -262,8 +240,7 @@ declare enum WaterFlowLayoutMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ALWAYS_TOP_DOWN = 0, @@ -275,9 +252,11 @@ declare enum WaterFlowLayoutMode { *
1. During a non-animated redirection to a distant location, water flow items are laid out forward or backward based on the target position. * If the user then swipes back to the position prior to the redirection, the layout of the content may not be consistent with its previous state. * This can lead to misalignment of the top nodes when the user swipes back to the top after the redirection. - * To counteract this issue, in this layout mode, the layout will be automatically adjusted after reaching the top of the viewport to ensure that the top is aligned. + * To counteract this issue, in this layout mode, the layout will be automatically adjusted after reaching the top of + * the viewport to ensure that the top is aligned. * If there are multiple sections, adjustments will be made to the sections within the viewport when scrolling ends. - *
2. The total offset returned by the currentOffset API of scroller is inaccurate after a redirection or data update. This offset will be recalibrated when the user swipes back to the top. + *
2. The total offset returned by the currentOffset API of scroller is inaccurate after a redirection or data update. + * This offset will be recalibrated when the user swipes back to the top. *
3. If a jump action (for example, by calling scrollToIndex without animation or scrollEdge) and * an input offset (such as from a swipe gesture or a scrolling animation) are both initiated within the same frame, both will be executed. *
4. If the scrollToIndex API is called without animation to jump to a distant position (beyond the range of visible water flow items in the window), @@ -287,8 +266,7 @@ declare enum WaterFlowLayoutMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SLIDING_WINDOW = 1, } @@ -315,8 +293,7 @@ declare enum WaterFlowLayoutMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare interface WaterFlowOptions { /** @@ -341,8 +318,7 @@ declare interface WaterFlowOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ footer?: CustomBuilder; @@ -353,8 +329,7 @@ declare interface WaterFlowOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ footerContent?: ComponentContent; @@ -384,8 +359,7 @@ declare interface WaterFlowOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scroller?: Scroller; @@ -401,8 +375,7 @@ declare interface WaterFlowOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ sections?: WaterFlowSections; @@ -414,8 +387,7 @@ declare interface WaterFlowOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ layoutMode?: WaterFlowLayoutMode; } @@ -501,8 +473,7 @@ declare type OnWaterFlowScrollIndexCallback = (first: number, last: number) => v * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ interface WaterFlowInterface { /** @@ -530,8 +501,7 @@ interface WaterFlowInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ (options?: WaterFlowOptions): WaterFlowAttribute; } @@ -558,8 +528,7 @@ interface WaterFlowInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare class WaterFlowAttribute extends ScrollableCommonMethod { /** @@ -587,8 +556,7 @@ declare class WaterFlowAttribute extends ScrollableCommonMethod void): WaterFlowAttribute; - - /** - * Called when the scrollable will scroll. - * - * @param { Optional } handler - callback of scrollable. - * @returns { WaterFlowAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onWillScroll(handler: Optional): WaterFlowAttribute; - - /** - * Called when the scrollable did scroll. - * - * @param { OnScrollCallback } handler - callback of scrollable, - * scrollOffset is offset this frame did scroll, scrollState is current scroll state. - * @returns { WaterFlowAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - onDidScroll(handler: OnScrollCallback): WaterFlowAttribute; } /** diff --git a/api/@internal/component/ets/web.d.ts b/api/@internal/component/ets/web.d.ts index 7f4241f710c9ecaf5972197766f3f72f7058bc57..fcc45b9eab7767378eff1a40fbdef5acb5baf9f7 100644 --- a/api/@internal/component/ets/web.d.ts +++ b/api/@internal/component/ets/web.d.ts @@ -21,7 +21,7 @@ /*** if arkts 1.2 */ import webview from '../../@ohos.web.webview'; import image from '../../@ohos.multimedia.image'; -import { CommonMethod, Callback, TouchEvent, NestedScrollOptions, KeyEvent } from './common'; +import { CommonMethod, Callback, TouchEvent, NestedScrollOptions, KeyEvent, HapticFeedbackMode} from './common'; import { CustomBuilder } from './builder' import { Resource } from '../../global/resource'; import { Position, ResourceStr } from './units'; @@ -71,8 +71,7 @@ declare type WebviewController = import('../api/@ohos.web.webview').default.Webv * @param { LoadCommittedDetails } loadCommittedDetails - callback information of onNavigationEntryCommitted. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ type OnNavigationEntryCommittedCallback = (loadCommittedDetails: LoadCommittedDetails) => void; @@ -83,8 +82,7 @@ type OnNavigationEntryCommittedCallback = (loadCommittedDetails: LoadCommittedDe * @param { SslErrorEvent } sslErrorEvent - callback information of onSslErrorEvent. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type OnSslErrorEventCallback = (sslErrorEvent: SslErrorEvent) => void; @@ -134,8 +132,7 @@ type OnOverrideUrlLoadingCallback = (webResourceRequest: WebResourceRequest) => * @param { IntelligentTrackingPreventionDetails } details - callback information of onIntelligentTrackingPrevention. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type OnIntelligentTrackingPreventionCallback = (details: IntelligentTrackingPreventionDetails) => void; @@ -227,8 +224,7 @@ type OnViewportFitChangedCallback = (viewportFit: ViewportFit) => void; * @param { AdsBlockedDetails } details - details of OnAdsBlockedCallback. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type OnAdsBlockedCallback = (details: AdsBlockedDetails) => void; @@ -238,8 +234,7 @@ type OnAdsBlockedCallback = (details: AdsBlockedDetails) => void; * @interface AdsBlockedDetails * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface AdsBlockedDetails { /** @@ -248,8 +243,7 @@ declare interface AdsBlockedDetails { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ url: string; @@ -259,8 +253,7 @@ declare interface AdsBlockedDetails { * @type { Array } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ adsBlocked: Array; } @@ -634,8 +627,7 @@ declare enum MixedMode { * @param { ThreatType } threatType - callback information of onSafeBrowsingCheckResult. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ type OnSafeBrowsingCheckResultCallback = (threatType: ThreatType) => void; @@ -807,8 +799,7 @@ declare enum HitTestType { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare enum CacheMode { /** @@ -830,8 +821,7 @@ declare enum CacheMode { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ Default = 0, @@ -854,8 +844,7 @@ declare enum CacheMode { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ None = 1, @@ -878,8 +867,7 @@ declare enum CacheMode { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ Online = 2, @@ -902,8 +890,7 @@ declare enum CacheMode { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ Only = 3 } @@ -1074,8 +1061,7 @@ declare enum WebCaptureMode { * @enum { number } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum ThreatType { /** @@ -1083,8 +1069,7 @@ declare enum ThreatType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ THREAT_ILLEGAL = 0, @@ -1093,8 +1078,7 @@ declare enum ThreatType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ THREAT_FRAUD = 1, @@ -1103,8 +1087,7 @@ declare enum ThreatType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ THREAT_RISK = 2, @@ -1114,8 +1097,7 @@ declare enum ThreatType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ THREAT_WARNING = 3 } @@ -1176,6 +1158,7 @@ declare interface WebMediaOptions { * Whether the audio of multiple Web instances in an application is exclusive. * * @type { ?boolean } + * {@code true} means audio exclusivity for multiple web instances within the application, {@code false} otherwise. * @syscap SystemCapability.Web.Webview.Core * @atomicservice * @since arkts {'1.1':'11', '1.2':'20'} @@ -2064,8 +2047,7 @@ declare class HttpAuthHandler { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ confirm(userName: string, password: string): boolean; @@ -2081,8 +2063,7 @@ declare class HttpAuthHandler { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ cancel(): void; @@ -2230,8 +2211,7 @@ declare class ClientAuthenticationHandler { * @param { string } certChainFile - The file that store client certificate chain. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ confirm(priKeyFile: string, certChainFile: string): void; @@ -2248,8 +2228,7 @@ declare class ClientAuthenticationHandler { * @param { string } authUri is the key of credentials.The credentials contain sign info and client certificates info. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ confirm(authUri: string): void; @@ -2280,8 +2259,7 @@ declare class ClientAuthenticationHandler { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ ignore(): void; } @@ -2777,22 +2755,6 @@ declare enum ContextMenuMediaType { * @arkts 1.1&1.2 */ Image = 1 - - /** - * Video. - * - * @syscap SystemCapability.Web.Webview.Core - * @since 20 - */ - VIDEO = 2, - - /** - * Audio. - * - * @syscap SystemCapability.Web.Webview.Core - * @since 20 - */ - AUDIO = 3 } /** @@ -3077,8 +3039,7 @@ declare enum ContextMenuEditStateFlags { * @enum { number } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare enum WebNavigationType { /** @@ -3086,8 +3047,7 @@ declare enum WebNavigationType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ UNKNOWN = 0, @@ -3099,8 +3059,7 @@ declare enum WebNavigationType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ MAIN_FRAME_NEW_ENTRY = 1, @@ -3113,8 +3072,7 @@ declare enum WebNavigationType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ MAIN_FRAME_EXISTING_ENTRY = 2, @@ -3123,8 +3081,7 @@ declare enum WebNavigationType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NAVIGATION_TYPE_NEW_SUBFRAME = 4, @@ -3133,8 +3090,7 @@ declare enum WebNavigationType { * * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ NAVIGATION_TYPE_AUTO_SUBFRAME = 5 } @@ -3746,14 +3702,14 @@ declare class ConsoleMessage { /** * Gets the line number of a console message. * - * @returns { number } Return the line number of a console message. + * @returns { int } Return the line number of a console message. * @syscap SystemCapability.Web.Webview.Core * @since 8 */ /** * Gets the line number of a console message. * - * @returns { number } Return the line number of a console message. + * @returns { int } Return the line number of a console message. * @syscap SystemCapability.Web.Webview.Core * @atomicservice * @since 11 @@ -3761,14 +3717,14 @@ declare class ConsoleMessage { /** * Gets the line number of a console message. * - * @returns { number } Return the line number of a console message. + * @returns { int } Return the line number of a console message. * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'18', '1.2':'20'} * @arkts 1.1&1.2 */ - getLineNumber(): number; + getLineNumber(): int; /** * Gets the message level of a console message. @@ -4069,28 +4025,27 @@ declare class WebResourceResponse { /** * Gets the response data. * - * @returns { string | number | ArrayBuffer | Resource | undefined } Return the response data. - * string type indicate string in HTML format. - * number type indicate file handle. - * Resource type indicate $rawfile resource. - * ArrayBuffer type indicate binary data. + * @returns { string | int | ArrayBuffer | Resource | undefined } Return the response data. + * string type indicate string in HTML format. + * number type indicate file handle. + * Resource type indicate $rawfile resource. + * ArrayBuffer type indicate binary data. * @syscap SystemCapability.Web.Webview.Core * @since 13 */ /** * Gets the response data. * - * @returns { string | number | ArrayBuffer | Resource | undefined } Return the response data. - * string type indicate string in HTML format. - * number type indicate file handle. - * Resource type indicate $rawfile resource. - * ArrayBuffer type indicate binary data. + * @returns { string | int | ArrayBuffer | Resource | undefined } Return the response data. + * string type indicate string in HTML format. + * number type indicate file handle. + * Resource type indicate $rawfile resource. + * ArrayBuffer type indicate binary data. * @syscap SystemCapability.Web.Webview.Core * @crossplatform - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ - getResponseDataEx(): string | number | ArrayBuffer | Resource | undefined; + getResponseDataEx(): string | int | ArrayBuffer | Resource | undefined; /** * Gets the response encoding. @@ -4179,61 +4134,60 @@ declare class WebResourceResponse { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getResponseHeader(): Array
; /** * Gets the response code. * - * @returns { number } Return the response code. + * @returns { int } Return the response code. * @syscap SystemCapability.Web.Webview.Core * @since 8 */ /** * Gets the response code. * - * @returns { number } Return the response code. + * @returns { int } Return the response code. * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - getResponseCode(): number; + getResponseCode(): int; /** * Sets the response data. * - * @param { string | number | Resource } data - the response data. + * @param { string | int | Resource } data - the response data. * @syscap SystemCapability.Web.Webview.Core * @since 9 */ /** * Sets the response data. * - * @param { string | number | Resource } data - the response data. - * string type indicate strings in HTML format. - * number type indicate file handle. - * Resource type indicate $rawfile resource. + * @param { string | int | Resource } data - the response data. + * string type indicate strings in HTML format. + * number type indicate file handle. + * Resource type indicate $rawfile resource. * @syscap SystemCapability.Web.Webview.Core * @since 10 */ /** * Sets the response data. * - * @param { string | number | Resource | ArrayBuffer } data - the response data. - * string type indicate strings in HTML format. - * number type indicate file handle. - * Resource type indicate $rawfile resource. - * ArrayBuffer type indicate binary data. + * @param { string | int | Resource | ArrayBuffer } data - the response data. + * string type indicate strings in HTML format. + * number type indicate file handle. + * Resource type indicate $rawfile resource. + * ArrayBuffer type indicate binary data. * @syscap SystemCapability.Web.Webview.Core * @atomicservice * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - setResponseData(data: string | number | Resource | ArrayBuffer): void; + setResponseData(data: string | int | Resource | ArrayBuffer): void; /** * Sets the response encoding. @@ -4334,22 +4288,21 @@ declare class WebResourceResponse { * @param { Array
} header the response headers. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setResponseHeader(header: Array
): void; /** * Sets the response code. * - * @param { number } code the response code. + * @param { int } code the response code. * @syscap SystemCapability.Web.Webview.Core * @since 9 */ /** * Sets the response code. * - * @param { number } code the response code. + * @param { int } code the response code. * @syscap SystemCapability.Web.Webview.Core * @atomicservice * @since 11 @@ -4357,13 +4310,13 @@ declare class WebResourceResponse { /** * Sets the response code. * - * @param { number } code the response code. + * @param { int } code the response code. * @syscap SystemCapability.Web.Webview.Core * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - setResponseCode(code: number): void; + setResponseCode(code: int): void; /** * Sets the response is ready or not. @@ -4386,8 +4339,7 @@ declare class WebResourceResponse { * @param { boolean } IsReady whether the response is ready. * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setResponseIsReady(IsReady: boolean): void; @@ -4404,8 +4356,7 @@ declare class WebResourceResponse { * @returns { boolean } True indicates the response data is ready and false is not ready. * @syscap SystemCapability.Web.Webview.Core * @crossplatform - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getResponseIsReady(): boolean; } @@ -4576,14 +4527,14 @@ declare class WebResourceError { /** * Gets the code of the Web resource error. * - * @returns { number } Return the code of the Web resource error. + * @returns { int } Return the code of the Web resource error. * @syscap SystemCapability.Web.Webview.Core * @since 8 */ /** * Gets the code of the Web resource error. * - * @returns { number } Return the code of the Web resource error. + * @returns { int } Return the code of the Web resource error. * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @since 10 @@ -4591,14 +4542,14 @@ declare class WebResourceError { /** * Gets the code of the Web resource error. * - * @returns { number } Return the code of the Web resource error. + * @returns { int } Return the code of the Web resource error. * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - getErrorCode(): number; + getErrorCode(): int; } /** @@ -4737,7 +4688,7 @@ declare class EventResult { constructor(); /** - * Set whether the event is consumed. + * Sets the event consumption result. * * @param { boolean } result - Whether to consume the gesture event. * {@code true} Indicates the consumption of the gesture event. @@ -5194,8 +5145,7 @@ declare interface WebOptions { * @typedef ScriptItem * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface ScriptItem { /** @@ -5204,8 +5154,7 @@ declare interface ScriptItem { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ script: string; @@ -5215,8 +5164,7 @@ declare interface ScriptItem { * @type { Array } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scriptRules: Array; } @@ -5235,8 +5183,7 @@ declare interface ScriptItem { * @typedef LoadCommittedDetails * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface LoadCommittedDetails { /** @@ -5245,8 +5192,7 @@ declare interface LoadCommittedDetails { * @type { boolean } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ isMainFrame: boolean; @@ -5260,8 +5206,7 @@ declare interface LoadCommittedDetails { * @type { boolean } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ isSameDocument: boolean; @@ -5273,8 +5218,7 @@ declare interface LoadCommittedDetails { * @type { boolean } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ didReplaceEntry: boolean; @@ -5284,8 +5228,7 @@ declare interface LoadCommittedDetails { * @type { WebNavigationType } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ navigationType: WebNavigationType; @@ -5295,8 +5238,7 @@ declare interface LoadCommittedDetails { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ url: string; } @@ -5307,8 +5249,7 @@ declare interface LoadCommittedDetails { * @typedef IntelligentTrackingPreventionDetails * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface IntelligentTrackingPreventionDetails { /** @@ -5317,8 +5258,7 @@ declare interface IntelligentTrackingPreventionDetails { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ host: string; @@ -5328,8 +5268,7 @@ declare interface IntelligentTrackingPreventionDetails { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ trackerHost: string; } @@ -6439,14 +6378,14 @@ declare interface OnDownloadStartEvent { /** * The contentLength of page. * - * @type { number } + * @type { long } * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - contentLength: number; + contentLength: long; } /** @@ -6464,8 +6403,7 @@ declare interface OnDownloadStartEvent { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare interface OnRefreshAccessedHistoryEvent { /** @@ -6483,8 +6421,7 @@ declare interface OnRefreshAccessedHistoryEvent { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ url: string; @@ -6503,8 +6440,7 @@ declare interface OnRefreshAccessedHistoryEvent { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ isRefreshed: boolean; } @@ -6573,8 +6509,7 @@ declare interface OnShowFileSelectorEvent { * @typedef OnResourceLoadEvent * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface OnResourceLoadEvent { /** @@ -6583,8 +6518,7 @@ declare interface OnResourceLoadEvent { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ url: string; } @@ -6782,8 +6716,7 @@ declare interface OnContextMenuShowEvent { * @typedef OnSearchResultReceiveEvent * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface OnSearchResultReceiveEvent { /** @@ -6792,8 +6725,7 @@ declare interface OnSearchResultReceiveEvent { * @type { number } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ activeMatchOrdinal: number; @@ -6803,8 +6735,7 @@ declare interface OnSearchResultReceiveEvent { * @type { number } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ numberOfMatches: number; @@ -6814,8 +6745,7 @@ declare interface OnSearchResultReceiveEvent { * @type { boolean } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isDoneCounting: boolean; } @@ -6934,13 +6864,13 @@ declare interface OnClientAuthenticationEvent { /** * The port number of the request certificate server. * - * @type { number } + * @type { int } * @syscap SystemCapability.Web.Webview.Core * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - port : number; + port : int; /** * Acceptable asymmetric key types. @@ -7026,8 +6956,7 @@ declare interface OnWindowNewEvent { * @typedef OnTouchIconUrlReceivedEvent * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface OnTouchIconUrlReceivedEvent { /** @@ -7036,8 +6965,7 @@ declare interface OnTouchIconUrlReceivedEvent { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ url: string; @@ -7047,8 +6975,7 @@ declare interface OnTouchIconUrlReceivedEvent { * @type { boolean } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ precomposed: boolean; } @@ -7059,8 +6986,7 @@ declare interface OnTouchIconUrlReceivedEvent { * @typedef OnFaviconReceivedEvent * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface OnFaviconReceivedEvent { /** @@ -7260,7 +7186,6 @@ declare interface OnOverScrollEvent { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ declare interface JavaScriptProxy { /** @@ -7279,7 +7204,6 @@ declare interface JavaScriptProxy { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ object: object; @@ -7301,7 +7225,6 @@ declare interface JavaScriptProxy { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ name: string; @@ -7323,7 +7246,6 @@ declare interface JavaScriptProxy { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ methodList: Array; @@ -7346,17 +7268,6 @@ declare interface JavaScriptProxy { */ controller: WebController | WebviewController; - /** - * Controller. - * - * @type { WebviewController } - * @syscap SystemCapability.Web.Webview.Core - * @crossplatform - * @since 20 - * @arkts 1.2 - */ - controller: WebviewController; - /** * The async method of the application side JavaScript object participating in the registration. * @@ -7373,7 +7284,6 @@ declare interface JavaScriptProxy { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ asyncMethodList?: Array; @@ -7384,8 +7294,7 @@ declare interface JavaScriptProxy { * @type { ?string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ permission?: string; } @@ -7455,6 +7364,7 @@ declare enum WebElementType { * * @syscap SystemCapability.Web.Webview.Core * @since 20 + * @arkts 1.1&1.2 */ LINK = 2 } @@ -7529,6 +7439,7 @@ declare enum AudioSessionType { * @interface PreviewMenuOptions * @syscap SystemCapability.Web.Webview.Core * @since 20 + * @arkts 1.1&1.2 */ declare interface PreviewMenuOptions { /** @@ -7537,6 +7448,7 @@ declare interface PreviewMenuOptions { * @type { ?HapticFeedbackMode } * @syscap SystemCapability.Web.Webview.Core * @since 20 + * @arkts 1.1&1.2 */ hapticFeedbackMode?: HapticFeedbackMode; } @@ -7596,6 +7508,7 @@ declare interface SelectionMenuOptionsExt { * @type { ?PreviewMenuOptions } * @syscap SystemCapability.Web.Webview.Core * @since 20 + * @arkts 1.1&1.2 */ previewMenuOptions?: PreviewMenuOptions; } @@ -7952,7 +7865,6 @@ declare class WebAttribute extends CommonMethod { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ javaScriptProxy(javaScriptProxy: JavaScriptProxy): WebAttribute; @@ -7992,8 +7904,7 @@ declare class WebAttribute extends CommonMethod { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ cacheMode(cacheMode: CacheMode): WebAttribute; @@ -8299,6 +8210,7 @@ declare class WebAttribute extends CommonMethod { * @since 11 */ /** + * Triggered at the end of web page loading. * This callback is only invoked for the main frame and not for subframes. * * @param { Callback } callback The triggered function at the end of web page loading. @@ -8831,8 +8743,7 @@ declare class WebAttribute extends CommonMethod { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onRefreshAccessedHistory(callback: Callback): WebAttribute; @@ -8976,8 +8887,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onResourceLoad(callback: Callback): WebAttribute; @@ -9297,8 +9207,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onSearchResultReceive(callback: Callback): WebAttribute; @@ -9371,8 +9280,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onSslErrorEvent(callback: OnSslErrorEventCallback): WebAttribute; @@ -9773,8 +9681,7 @@ declare class WebAttribute extends CommonMethod { * @syscap SystemCapability.Web.Webview.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ blockNetwork(block: boolean): WebAttribute; @@ -9861,8 +9768,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onTouchIconUrlReceived(callback: Callback): WebAttribute; @@ -9893,8 +9799,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onFaviconReceived(callback: Callback): WebAttribute; @@ -10196,8 +10101,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onSafeBrowsingCheckResult(callback: OnSafeBrowsingCheckResultCallback): WebAttribute; @@ -10208,8 +10112,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ onNavigationEntryCommitted(callback: OnNavigationEntryCommittedCallback): WebAttribute; @@ -10220,8 +10123,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onIntelligentTrackingPreventionResult(callback: OnIntelligentTrackingPreventionCallback): WebAttribute; @@ -10242,8 +10144,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ javaScriptOnDocumentStart(scripts: Array): WebAttribute; @@ -10264,8 +10165,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ javaScriptOnDocumentEnd(scripts: Array): WebAttribute; @@ -10283,7 +10183,7 @@ declare class WebAttribute extends CommonMethod { * - Frequent changes to the page width and height will trigger a re-layout of the Web component, * which can affect the user experience. * - Waterfall web pages are not supported (drop down to the bottom to load more). - * - Only height adaptation is supported(VH units are not supported). Width adaptation is not supported. + * - Only height adaptation is supported. Width adaptation is not supported. * - Because the height is adaptive to the web page height, * the component height cannot be changed by modifying the component height attribute. *

@@ -10574,8 +10474,7 @@ declare class WebAttribute extends CommonMethod { * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onAdsBlocked(callback: OnAdsBlockedCallback): WebAttribute; @@ -10686,8 +10585,7 @@ declare class WebAttribute extends CommonMethod { * @param { Array } scripts - The JavaScripts executed in array order. * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ runJavaScriptOnDocumentStart(scripts: Array): WebAttribute; @@ -10697,8 +10595,7 @@ declare class WebAttribute extends CommonMethod { * @param { Array } scripts - The JavaScripts executed in array order. * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ runJavaScriptOnDocumentEnd(scripts: Array): WebAttribute; @@ -10708,8 +10605,7 @@ declare class WebAttribute extends CommonMethod { * @param { Array } scripts - The JavaScripts executed in array order. * @returns { WebAttribute } * @syscap SystemCapability.Web.Webview.Core - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ runJavaScriptOnHeadEnd(scripts: Array): WebAttribute; @@ -10836,8 +10732,7 @@ declare const WebInstance: WebAttribute; * @typedef SslErrorEvent * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface SslErrorEvent { /** @@ -10846,8 +10741,7 @@ declare interface SslErrorEvent { * @type { SslErrorHandler } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ handler: SslErrorHandler; @@ -10857,8 +10751,7 @@ declare interface SslErrorEvent { * @type { SslError } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ error: SslError; @@ -10868,8 +10761,7 @@ declare interface SslErrorEvent { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ url: string; @@ -10879,8 +10771,7 @@ declare interface SslErrorEvent { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ originalUrl: string; @@ -10890,8 +10781,7 @@ declare interface SslErrorEvent { * @type { string } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ referrer: string; @@ -10901,8 +10791,7 @@ declare interface SslErrorEvent { * @type { boolean } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isFatalError: boolean; @@ -10912,8 +10801,7 @@ declare interface SslErrorEvent { * @type { boolean } * @syscap SystemCapability.Web.Webview.Core * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ isMainFrame: boolean; } @@ -11075,3 +10963,4 @@ declare enum GestureFocusMode { */ GESTURE_TAP_AND_LONG_PRESS = 1 } + diff --git a/api/@internal/component/ets/with_theme.d.ts b/api/@internal/component/ets/with_theme.d.ts index f79a48b6433b5c5d3f5c52c02f4710e5c31d37a4..a4e1de4455c4964b537b3fe4f3495eac7f3759eb 100644 --- a/api/@internal/component/ets/with_theme.d.ts +++ b/api/@internal/component/ets/with_theme.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CustomTheme } from '../../@ohos.arkui.theme'; -import { ThemeColorMode } from './common'; -/*** endif */ - /** * CustomTheme. * @@ -41,8 +36,7 @@ declare type CustomTheme = import('../api/@ohos.arkui.theme').CustomTheme; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare interface WithThemeOptions { /** @@ -52,8 +46,7 @@ declare interface WithThemeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ theme?: CustomTheme; @@ -64,8 +57,7 @@ declare interface WithThemeOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ colorMode?: ThemeColorMode; } @@ -83,39 +75,13 @@ declare interface WithThemeOptions { */ declare type WithThemeInterface = (options: WithThemeOptions) => WithThemeAttribute; -/** - * Define WithThemeInterface. - * - * @interface WithThemeInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface WithThemeInterface { - /** - * The withTheme options. - * - * @param { WithThemeOptions } options - * @returns { WithThemeAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (options: WithThemeOptions): WithThemeAttribute; -} - /** * Defines the WithTheme attribute functions.. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice -* @since arkts {'1.1':'12','1.2':'20'} -* @arkts 1.1&1.2 +* @since 12 */ declare class WithThemeAttribute { } diff --git a/api/@internal/component/ets/xcomponent.d.ts b/api/@internal/component/ets/xcomponent.d.ts index 422c84bc0c951bed4ec61f806ba0175985351843..c49c461306c743e3d4e427a355eb5de5c7529e38 100644 --- a/api/@internal/component/ets/xcomponent.d.ts +++ b/api/@internal/component/ets/xcomponent.d.ts @@ -18,13 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ImageAIOptions, ImageAnalyzerConfig } from './imageCommon'; -import { CommonMethod } from './common'; -import { XComponentType } from './enums'; -import { VoidCallback } from './units'; -/*** endif */ - /** * Describes the rectangle of the surface held by the XComponent. * @@ -40,8 +33,7 @@ import { VoidCallback } from './units'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ declare interface SurfaceRect { /** @@ -61,8 +53,7 @@ declare interface SurfaceRect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ offsetX?: number; @@ -83,8 +74,7 @@ declare interface SurfaceRect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ offsetY?: number; @@ -104,8 +94,7 @@ declare interface SurfaceRect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ surfaceWidth: number; @@ -125,8 +114,7 @@ declare interface SurfaceRect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ surfaceHeight: number; } @@ -146,8 +134,7 @@ declare interface SurfaceRect { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ declare interface SurfaceRotationOptions { /** @@ -166,8 +153,7 @@ declare interface SurfaceRotationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ lock?: boolean; } @@ -186,8 +172,7 @@ declare interface SurfaceRotationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class XComponentController { /** @@ -202,8 +187,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(); @@ -223,8 +207,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getXComponentSurfaceId(): string; @@ -246,8 +229,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getXComponentContext(): Object; @@ -282,8 +264,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ setXComponentSurfaceRect(rect: SurfaceRect): void; @@ -303,8 +284,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ getXComponentSurfaceRect(): SurfaceRect; @@ -324,8 +304,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ setXComponentSurfaceRotation(rotationOptions: SurfaceRotationOptions): void; @@ -345,8 +324,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ getXComponentSurfaceRotation(): Required; @@ -366,8 +344,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ onSurfaceCreated(surfaceId: string): void; @@ -389,8 +366,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ onSurfaceChanged(surfaceId: string, rect: SurfaceRect): void; @@ -410,8 +386,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ onSurfaceDestroyed(surfaceId: string): void; @@ -428,8 +403,7 @@ declare class XComponentController { * @throws { BusinessError } 110003 - Image analysis is stopped. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ startImageAnalyzer(config: ImageAnalyzerConfig): Promise; @@ -439,8 +413,7 @@ declare class XComponentController { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ stopImageAnalyzer(): void; @@ -481,8 +454,7 @@ declare class XComponentController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ declare interface XComponentOptions { /** @@ -500,8 +472,7 @@ declare interface XComponentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ type: XComponentType; @@ -521,8 +492,7 @@ declare interface XComponentOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'20','1.2':'20'} - * @arkts 1.1&1.2 + * @since 20 */ controller: XComponentController; @@ -533,8 +503,7 @@ declare interface XComponentOptions { * @type { ?ImageAIOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ imageAIOptions?: ImageAIOptions; @@ -544,8 +513,7 @@ declare interface XComponentOptions { * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'17','1.2':'20'} - * @arkts 1.1&1.2 + * @since 17 */ screenId?: number; } @@ -556,8 +524,7 @@ declare interface XComponentOptions { * @interface NativeXComponentParameters * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ declare interface NativeXComponentParameters { /** @@ -566,8 +533,7 @@ declare interface NativeXComponentParameters { * @type { XComponentType } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ type: XComponentType; @@ -577,8 +543,7 @@ declare interface NativeXComponentParameters { * @type { ?ImageAIOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ imageAIOptions?: ImageAIOptions; } @@ -673,8 +638,7 @@ interface XComponentInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare type OnNativeLoadCallback = (event?: object) => void; @@ -692,8 +656,7 @@ declare type OnNativeLoadCallback = (event?: object) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class XComponentAttribute extends CommonMethod { /** @@ -723,8 +686,7 @@ declare class XComponentAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onLoad(callback: OnNativeLoadCallback): XComponentAttribute; @@ -755,8 +717,7 @@ declare class XComponentAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ onDestroy(event: VoidCallback): XComponentAttribute; @@ -770,8 +731,7 @@ declare class XComponentAttribute extends CommonMethod { * @returns { XComponentAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enableAnalyzer(enable: boolean): XComponentAttribute; @@ -782,8 +742,7 @@ declare class XComponentAttribute extends CommonMethod { * @returns { XComponentAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ enableSecure(isSecure: boolean): XComponentAttribute; @@ -804,7 +763,6 @@ declare class XComponentAttribute extends CommonMethod { * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ hdrBrightness(brightness: number): XComponentAttribute; @@ -815,8 +773,7 @@ declare class XComponentAttribute extends CommonMethod { * @returns { XComponentAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enableTransparentLayer(enabled: boolean): XComponentAttribute; } @@ -852,109 +809,3 @@ declare const XComponent: XComponentInterface; * @since 12 */ declare const XComponentInstance: XComponentAttribute; - -/** - * Defines the XComponent parameter interface. - * - * @interface XComponentParameter - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -declare interface XComponentParameter { - /** - * The id of xcomponent - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - id: string; - /** - * The type of xcomponent - * - * @type { XComponentType } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - type: XComponentType; - /** - * The name of the dynamic library compiled and output by the native layer. - * - * @type { ?string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - libraryname?: string; - /** - * The controller of xcomponent. - * - * @type { ?XComponentController } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - controller?: XComponentController; -} - -/** - * Defines XComponent. - * - * @interface XComponentInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -interface XComponentInterface { - /** - * Constructor parameters - * - * @param { XComponentParameter } value - Indicates the options of the xcomponent. - * @returns { XComponentAttribute } The attribute of the xcomponent. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (value: XComponentParameter): XComponentAttribute; - - /** - * Constructor parameters - * - * @param { XComponentOptions } options - Indicates the options of the xcomponent. - * @returns { XComponentAttribute } The attribute of the xcomponent. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (options: XComponentOptions): XComponentAttribute; - - /** - * Constructor parameters - * - * @param { NativeXComponentParameters } params - Indicates the constructor parameters of the xcomponent for native developing. - * @returns { XComponentAttribute } The attribute of the xcomponent. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - (params: NativeXComponentParameters): XComponentAttribute; -} \ No newline at end of file diff --git a/api/@ohos.UiTest.d.ts b/api/@ohos.UiTest.d.ts index e6d1bcd5093efa56b22dec98af80759a6dd0412a..5d8b1069b0130a9ee1028b6cd14722b481ddd1cb 100755 --- a/api/@ohos.UiTest.d.ts +++ b/api/@ohos.UiTest.d.ts @@ -20,17 +20,6 @@ import { Callback } from './@ohos.base'; -/** - * Used to initialize the uitest environment at the start of the test - * - * @throws { BusinessError } 17000001 - Initialization failed. - * @syscap SystemCapability.Test.UiTest - * @since 20 - * @arkts 1.2 - * @test -*/ -export function loadAndSetUpUiTest(): void {}; - /** * Enumerates the string value match pattern. * diff --git a/api/@ohos.WorkSchedulerExtensionAbility.d.ts b/api/@ohos.WorkSchedulerExtensionAbility.d.ts index 832b0c443ee1f79d757538c29cb6be4b5045b6b7..0a25692c33baa13de11a37d1d88ac0b778868505 100644 --- a/api/@ohos.WorkSchedulerExtensionAbility.d.ts +++ b/api/@ohos.WorkSchedulerExtensionAbility.d.ts @@ -28,8 +28,7 @@ import _WorkSchedulerExtensionContext from './application/WorkSchedulerExtension * @typedef { _WorkSchedulerExtensionContext } * @syscap SystemCapability.ResourceSchedule.WorkScheduler * @StageModelOnly - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ export type WorkSchedulerExtensionContext = _WorkSchedulerExtensionContext; @@ -37,8 +36,7 @@ export type WorkSchedulerExtensionContext = _WorkSchedulerExtensionContext; * Class of the work scheduler extension ability. * * @syscap SystemCapability.ResourceSchedule.WorkScheduler - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ declare class WorkSchedulerExtensionAbility { /** @@ -47,8 +45,7 @@ declare class WorkSchedulerExtensionAbility { * @type { WorkSchedulerExtensionContext } * @syscap SystemCapability.ResourceSchedule.WorkScheduler * @StageModelOnly - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ context: WorkSchedulerExtensionContext; @@ -58,8 +55,7 @@ declare class WorkSchedulerExtensionAbility { * @param {workScheduler.WorkInfo} work - The info of work. * @syscap SystemCapability.ResourceSchedule.WorkScheduler * @StageModelOnly - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onWorkStart(work: workScheduler.WorkInfo): void; @@ -69,8 +65,7 @@ declare class WorkSchedulerExtensionAbility { * @param {workScheduler.WorkInfo} work - The info of work. * @syscap SystemCapability.ResourceSchedule.WorkScheduler * @StageModelOnly - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onWorkStop(work: workScheduler.WorkInfo): void; } @@ -80,7 +75,6 @@ declare class WorkSchedulerExtensionAbility { * * @syscap SystemCapability.ResourceSchedule.WorkScheduler * @StageModelOnly - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ export default WorkSchedulerExtensionAbility; \ No newline at end of file diff --git a/api/@ohos.ability.screenLockFileManager.d.ts b/api/@ohos.ability.screenLockFileManager.d.ts index 4f7ac113b16bcf9df35d62055bcd4dab5a63f021..df22688c859b54fbd876a7898c7100f3462169a3 100644 --- a/api/@ohos.ability.screenLockFileManager.d.ts +++ b/api/@ohos.ability.screenLockFileManager.d.ts @@ -23,8 +23,7 @@ * * @namespace screenLockFileManager * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare namespace screenLockFileManager { /** @@ -32,16 +31,14 @@ declare namespace screenLockFileManager { * * @enum { number } * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum DataType { /** * Media photo and video data. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ MEDIA_DATA = 0x00000001, @@ -49,8 +46,7 @@ declare namespace screenLockFileManager { * All data type. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ALL_DATA = 0xffffffff } @@ -60,16 +56,14 @@ declare namespace screenLockFileManager { * * @enum { number } * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum AccessStatus { /** * Acquire the access of data failed. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ACCESS_DENIED = -1, @@ -77,8 +71,7 @@ declare namespace screenLockFileManager { * Acquire the access of data success. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ACCESS_GRANTED = 0 } @@ -88,16 +81,14 @@ declare namespace screenLockFileManager { * * @enum { number } * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum ReleaseStatus { /** * Release the access of data failed. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ RELEASE_DENIED = -1, @@ -105,8 +96,7 @@ declare namespace screenLockFileManager { * Release the access of data success. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ RELEASE_GRANTED = 0 } @@ -116,16 +106,14 @@ declare namespace screenLockFileManager { * * @enum { number } * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ export enum KeyStatus { /** * The application is not enabled the data protection under lock screen. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ KEY_NOT_EXIST = -2, @@ -133,8 +121,7 @@ declare namespace screenLockFileManager { * AppKey has been released. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ KEY_RELEASED = -1, @@ -142,8 +129,7 @@ declare namespace screenLockFileManager { * AppKey exists. * * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ KEY_EXIST = 0 } @@ -157,8 +143,7 @@ declare namespace screenLockFileManager { * @throws { BusinessError } 29300003 - The application is not enabled the data protection under lock screen. * @throws { BusinessError } 29300004 - File access is denied. * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function acquireAccess(): AccessStatus; @@ -178,8 +163,7 @@ declare namespace screenLockFileManager { * @throws { BusinessError } 29300004 - File access is denied. * @syscap SystemCapability.Security.ScreenLockFileManager * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function acquireAccess(dataType: DataType): AccessStatus; @@ -192,8 +176,7 @@ declare namespace screenLockFileManager { * @throws { BusinessError } 29300003 - The application is not enabled the data protection under lock screen. * @throws { BusinessError } 29300005 - File access was not acquired. * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function releaseAccess(): ReleaseStatus; @@ -213,8 +196,7 @@ declare namespace screenLockFileManager { * @throws { BusinessError } 29300005 - File access was not acquired. * @syscap SystemCapability.Security.ScreenLockFileManager * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function releaseAccess(dataType: DataType): ReleaseStatus; @@ -225,8 +207,7 @@ declare namespace screenLockFileManager { * @throws { BusinessError } 801 - The specified SystemCapability name was not found. * @throws { BusinessError } 29300002 - The system ability work abnormally. * @syscap SystemCapability.Security.ScreenLockFileManager - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ function queryAppKeyState(): KeyStatus; @@ -244,8 +225,7 @@ declare namespace screenLockFileManager { * @throws { BusinessError } 29300002 - The system ability work abnormally. * @syscap SystemCapability.Security.ScreenLockFileManager * @systemapi - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ function queryAppKeyState(dataType: DataType): KeyStatus; } diff --git a/api/@ohos.abilityAccessCtrl.d.ts b/api/@ohos.abilityAccessCtrl.d.ts index 748d6fbfb8cf7a78b68aa2209cc66ccddb117053..68b61bb3c84d360ff28f155bc0df3d0408367d52 100644 --- a/api/@ohos.abilityAccessCtrl.d.ts +++ b/api/@ohos.abilityAccessCtrl.d.ts @@ -311,8 +311,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ grantUserGrantedPermission(tokenID: int, permissionName: Permissions, permissionFlags: int): Promise; @@ -336,8 +335,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ grantUserGrantedPermission( tokenID: int, @@ -366,8 +364,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ revokeUserGrantedPermission(tokenID: int, permissionName: Permissions, permissionFlags: int): Promise; @@ -391,8 +388,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ revokeUserGrantedPermission( tokenID: int, @@ -418,8 +414,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ getPermissionFlags(tokenID: int, permissionName: Permissions): Promise; @@ -439,8 +434,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setPermissionRequestToggleStatus(permissionName: Permissions, status: PermissionRequestToggleStatus): Promise; @@ -458,8 +452,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getPermissionRequestToggleStatus(permissionName: Permissions): Promise; @@ -470,8 +463,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 202 - Not System App. Interface caller is not a system app. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getVersion(): Promise; @@ -490,8 +482,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getPermissionsStatus(tokenID: int, permissionList: Array): Promise>; @@ -518,8 +509,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ on( type: 'permissionStateChange', @@ -548,8 +538,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ on( type: 'selfPermissionStateChange', @@ -576,8 +565,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ off( type: 'permissionStateChange', @@ -599,8 +587,7 @@ declare namespace abilityAccessCtrl { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ off( type: 'selfPermissionStateChange', @@ -643,8 +630,7 @@ declare namespace abilityAccessCtrl { * @syscap SystemCapability.Security.AccessToken * @stagemodelonly * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ requestGlobalSwitch(context: Context, type: SwitchType): Promise; @@ -659,8 +645,7 @@ declare namespace abilityAccessCtrl { * @syscap SystemCapability.Security.AccessToken * @systemapi * @stagemodelonly - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ requestPermissionOnApplicationSetting(tokenID: int): Promise; @@ -758,8 +743,7 @@ declare namespace abilityAccessCtrl { * @enum { int } * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ export enum PermissionStateChangeType { /** @@ -767,8 +751,7 @@ declare namespace abilityAccessCtrl { * * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ PERMISSION_REVOKED_OPER = 0, /** @@ -776,8 +759,7 @@ declare namespace abilityAccessCtrl { * * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ PERMISSION_GRANTED_OPER = 1 } @@ -788,8 +770,7 @@ declare namespace abilityAccessCtrl { * @enum { int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum PermissionRequestToggleStatus { /** @@ -797,8 +778,7 @@ declare namespace abilityAccessCtrl { * * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CLOSED = 0, /** @@ -806,8 +786,7 @@ declare namespace abilityAccessCtrl { * * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ OPEN = 1, } @@ -818,8 +797,7 @@ declare namespace abilityAccessCtrl { * @interface PermissionStateChangeInfo * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 * @name PermissionStateChangeInfo */ interface PermissionStateChangeInfo { @@ -829,8 +807,7 @@ declare namespace abilityAccessCtrl { * @type { PermissionStateChangeType } * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ change: PermissionStateChangeType; @@ -840,8 +817,7 @@ declare namespace abilityAccessCtrl { * @type { int } * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ tokenID: int; @@ -851,8 +827,7 @@ declare namespace abilityAccessCtrl { * @type { Permissions } * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ permissionName: Permissions; } @@ -864,7 +839,6 @@ declare namespace abilityAccessCtrl { * @syscap SystemCapability.Security.AccessToken * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ export enum PermissionStatus { /** @@ -873,7 +847,6 @@ declare namespace abilityAccessCtrl { * @syscap SystemCapability.Security.AccessToken * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ DENIED = -1, /** @@ -882,7 +855,6 @@ declare namespace abilityAccessCtrl { * @syscap SystemCapability.Security.AccessToken * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ GRANTED = 0, /** @@ -891,7 +863,6 @@ declare namespace abilityAccessCtrl { * @syscap SystemCapability.Security.AccessToken * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ NOT_DETERMINED = 1, /** @@ -900,7 +871,6 @@ declare namespace abilityAccessCtrl { * @syscap SystemCapability.Security.AccessToken * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ INVALID = 2, /** @@ -909,7 +879,6 @@ declare namespace abilityAccessCtrl { * @syscap SystemCapability.Security.AccessToken * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ RESTRICTED = 3 } @@ -920,8 +889,7 @@ declare namespace abilityAccessCtrl { * @enum { int } * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum SwitchType { /** @@ -929,8 +897,7 @@ declare namespace abilityAccessCtrl { * * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CAMERA = 0, /** @@ -938,8 +905,7 @@ declare namespace abilityAccessCtrl { * * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ MICROPHONE = 1, /** @@ -947,8 +913,7 @@ declare namespace abilityAccessCtrl { * * @syscap SystemCapability.Security.AccessToken * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ LOCATION = 2, } diff --git a/api/@ohos.account.appAccount.d.ts b/api/@ohos.account.appAccount.d.ts index cf053c516802fca3c9d82dcf0dfc68cc10bc4f9f..36be5ec3bfc2b39dcb636eef7e5c146b83059661 100644 --- a/api/@ohos.account.appAccount.d.ts +++ b/api/@ohos.account.appAccount.d.ts @@ -27,8 +27,7 @@ import type rpc from './@ohos.rpc'; * * @namespace appAccount * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ declare namespace appAccount { /** @@ -36,8 +35,7 @@ declare namespace appAccount { * * @returns { AppAccountManager } Returns the instance of the AppAccountManager. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ function createAppAccountManager(): AppAccountManager; @@ -46,8 +44,7 @@ declare namespace appAccount { * * @interface AppAccountManager * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ interface AppAccountManager { /** @@ -110,8 +107,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300004 - Account already exists. * @throws { BusinessError } 12300007 - The number of accounts reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ createAccount(name: string, callback: AsyncCallback): void; @@ -131,8 +127,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300004 - Account already exists. * @throws { BusinessError } 12300007 - The number of accounts reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ createAccount(name: string, options: CreateAccountOptions, callback: AsyncCallback): void; @@ -152,8 +147,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300004 - Account already exists. * @throws { BusinessError } 12300007 - The number of accounts reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ createAccount(name: string, options?: CreateAccountOptions): Promise; @@ -190,8 +184,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ createAccountImplicitly(owner: string, callback: AuthCallback): void; @@ -210,8 +203,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ createAccountImplicitly(owner: string, options: CreateAccountImplicitlyOptions, callback: AuthCallback): void; @@ -256,8 +248,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ removeAccount(name: string, callback: AsyncCallback): void; @@ -274,8 +265,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ removeAccount(name: string): Promise; @@ -369,8 +359,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400005 - The size of authorization list reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ setAppAccess(name: string, bundleName: string, isAccessible: boolean, callback: AsyncCallback): void; @@ -406,8 +395,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400005 - The size of authorization list reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ setAppAccess(name: string, bundleName: string, isAccessible: boolean): Promise; @@ -424,8 +412,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name or bundleName. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkAppAccess(name: string, bundleName: string, callback: AsyncCallback): void; @@ -442,8 +429,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name or bundleName. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkAppAccess(name: string, bundleName: string): Promise; @@ -501,8 +487,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkDataSyncEnabled(name: string, callback: AsyncCallback): void; @@ -524,8 +509,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkDataSyncEnabled(name: string): Promise; @@ -570,8 +554,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name, credentialType or credential. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setCredential(name: string, credentialType: string, credential: string, callback: AsyncCallback): void; @@ -589,8 +572,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name, credentialType or credential. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setCredential(name: string, credentialType: string, credential: string): Promise; @@ -707,8 +689,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setDataSyncEnabled(name: string, isEnabled: boolean, callback: AsyncCallback): void; @@ -739,8 +720,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setDataSyncEnabled(name: string, isEnabled: boolean): Promise; @@ -786,8 +766,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400003 - The number of custom data reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setCustomData(name: string, key: string, value: string, callback: AsyncCallback): void; @@ -805,8 +784,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400003 - The number of custom data reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setCustomData(name: string, key: string, value: string): Promise; @@ -855,8 +833,7 @@ declare namespace appAccount { *
2. Incorrect parameter types. * @throws { BusinessError } 12300001 - System service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAllAccounts(callback: AsyncCallback>): void; @@ -871,8 +848,7 @@ declare namespace appAccount { * @returns { Promise> } Returns a list of application accounts. * @throws { BusinessError } 12300001 - System service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAllAccounts(): Promise>; @@ -943,8 +919,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300001 - System service exception. * @throws { BusinessError } 12300002 - Invalid owner. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ getAccountsByOwner(owner: string, callback: AsyncCallback>): void; @@ -981,8 +956,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300001 - System service exception. * @throws { BusinessError } 12300002 - Invalid owner. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ getAccountsByOwner(owner: string): Promise>; @@ -1025,8 +999,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300102 - Credential not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getCredential(name: string, credentialType: string, callback: AsyncCallback): void; @@ -1043,8 +1016,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300102 - Credential not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getCredential(name: string, credentialType: string): Promise; @@ -1114,8 +1086,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400002 - Custom data not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getCustomData(name: string, key: string, callback: AsyncCallback): void; @@ -1132,8 +1103,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400002 - Custom data not found * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getCustomData(name: string, key: string): Promise; @@ -1150,8 +1120,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400002 - Custom data not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getCustomDataSync(name: string, key: string): string; @@ -1205,8 +1174,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300001 - System service exception. * @throws { BusinessError } 12300002 - Invalid type or owners. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ on(type: 'accountChange', owners: Array, callback: Callback>): void; @@ -1232,8 +1200,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300001 - System service exception. * @throws { BusinessError } 12300002 - Invalid type. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ off(type: 'accountChange', callback?: Callback>): void; @@ -1274,8 +1241,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ auth(name: string, owner: string, authType: string, callback: AuthCallback): void; @@ -1296,8 +1262,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ auth( name: string, @@ -1349,8 +1314,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300107 - AuthType not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAuthToken(name: string, owner: string, authType: string, callback: AsyncCallback): void; @@ -1368,8 +1332,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300107 - AuthType not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAuthToken(name: string, owner: string, authType: string): Promise; @@ -1421,8 +1384,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400004 - The number of tokens reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setAuthToken(name: string, authType: string, token: string, callback: AsyncCallback): void; @@ -1442,8 +1404,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12400004 - The number of tokens reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setAuthToken(name: string, authType: string, token: string): Promise; @@ -1498,8 +1459,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300107 - AuthType not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ deleteAuthToken(name: string, owner: string, authType: string, token: string, callback: AsyncCallback): void; @@ -1520,8 +1480,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300107 - AuthType not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ deleteAuthToken(name: string, owner: string, authType: string, token: string): Promise; @@ -1604,8 +1563,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300107 - AuthType not found. * @throws { BusinessError } 12400005 - The size of authorization list reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ setAuthTokenVisibility( name: string, @@ -1654,8 +1612,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300107 - AuthType not found. * @throws { BusinessError } 12400005 - The size of authorization list reaches the upper limit. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ setAuthTokenVisibility(name: string, authType: string, bundleName: string, isVisible: boolean): Promise; @@ -1712,8 +1669,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300107 - AuthType not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkAuthTokenVisibility(name: string, authType: string, bundleName: string, callback: AsyncCallback): void; @@ -1733,8 +1689,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300107 - AuthType not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkAuthTokenVisibility(name: string, authType: string, bundleName: string): Promise; @@ -1777,8 +1732,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name or owner. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAllAuthTokens(name: string, owner: string, callback: AsyncCallback>): void; @@ -1794,8 +1748,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid name or owner. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAllAuthTokens(name: string, owner: string): Promise>; @@ -1846,8 +1799,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300107 - AuthType not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAuthList(name: string, authType: string, callback: AsyncCallback>): void; @@ -1866,8 +1818,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300107 - AuthType not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAuthList(name: string, authType: string): Promise>; @@ -1914,8 +1865,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid sessionId. * @throws { BusinessError } 12300108 - Session not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAuthCallback(sessionId: string, callback: AsyncCallback): void; @@ -1932,8 +1882,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid sessionId. * @throws { BusinessError } 12300108 - Session not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getAuthCallback(sessionId: string): Promise; @@ -1974,8 +1923,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid owner. * @throws { BusinessError } 12300113 - Authenticator service not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ queryAuthenticatorInfo(owner: string, callback: AsyncCallback): void; @@ -1990,8 +1938,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300002 - Invalid owner. * @throws { BusinessError } 12300113 - Authenticator service not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ queryAuthenticatorInfo(owner: string): Promise; @@ -2011,8 +1958,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkAccountLabels(name: string, owner: string, labels: Array, callback: AsyncCallback): void; @@ -2032,8 +1978,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkAccountLabels(name: string, owner: string, labels: Array): Promise; @@ -2050,8 +1995,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300102 - Credential not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ deleteCredential(name: string, credentialType: string, callback: AsyncCallback): void; @@ -2068,8 +2012,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300003 - Account not found. * @throws { BusinessError } 12300102 - Credential not found. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ deleteCredential(name: string, credentialType: string): Promise; @@ -2085,8 +2028,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300010 - Account service busy. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ selectAccountsByOptions(options: SelectAccountsOptions, callback: AsyncCallback>): void; @@ -2102,8 +2044,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300010 - Account service busy. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ selectAccountsByOptions(options: SelectAccountsOptions): Promise>; @@ -2122,8 +2063,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ verifyCredential(name: string, owner: string, callback: AuthCallback): void; /** @@ -2142,8 +2082,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ verifyCredential(name: string, owner: string, options: VerifyCredentialOptions, callback: AuthCallback): void; @@ -2163,8 +2102,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setAuthenticatorProperties(owner: string, callback: AuthCallback): void; /** @@ -2184,8 +2122,7 @@ declare namespace appAccount { * @throws { BusinessError } 12300113 - Authenticator service not found. * @throws { BusinessError } 12300114 - Authenticator service exception. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setAuthenticatorProperties(owner: string, options: SetPropertiesOptions, callback: AuthCallback): void; } @@ -2195,8 +2132,7 @@ declare namespace appAccount { * * @interface AppAccountInfo * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ interface AppAccountInfo { /** @@ -2204,8 +2140,7 @@ declare namespace appAccount { * * @type { string } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ owner: string; @@ -2214,8 +2149,7 @@ declare namespace appAccount { * * @type { string } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ name: string; } @@ -2256,8 +2190,7 @@ declare namespace appAccount { * * @interface AuthTokenInfo * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface AuthTokenInfo { /** @@ -2265,8 +2198,7 @@ declare namespace appAccount { * * @type { string } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ authType: string; @@ -2275,8 +2207,7 @@ declare namespace appAccount { * * @type { string } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ token: string; @@ -2285,8 +2216,7 @@ declare namespace appAccount { * * @type { ?AppAccountInfo } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ account?: AppAccountInfo; } @@ -2296,8 +2226,7 @@ declare namespace appAccount { * * @interface AuthenticatorInfo * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ interface AuthenticatorInfo { /** @@ -2305,8 +2234,7 @@ declare namespace appAccount { * * @type { string } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ owner: string; @@ -2315,8 +2243,7 @@ declare namespace appAccount { * * @type { long } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ iconId: long; @@ -2325,8 +2252,7 @@ declare namespace appAccount { * * @type { long } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ labelId: long; } @@ -2336,8 +2262,7 @@ declare namespace appAccount { * * @interface AuthResult * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface AuthResult { /** @@ -2345,8 +2270,7 @@ declare namespace appAccount { * * @type { ?AppAccountInfo } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ account?: AppAccountInfo; @@ -2355,8 +2279,7 @@ declare namespace appAccount { * * @type { ?AuthTokenInfo } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ tokenInfo?: AuthTokenInfo; } @@ -2366,8 +2289,7 @@ declare namespace appAccount { * * @interface CreateAccountOptions * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface CreateAccountOptions { /** @@ -2376,8 +2298,7 @@ declare namespace appAccount { * * @type { ?Record } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ customData?: Record; } @@ -2387,8 +2308,7 @@ declare namespace appAccount { * * @interface CreateAccountImplicitlyOptions * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface CreateAccountImplicitlyOptions { /** @@ -2396,8 +2316,7 @@ declare namespace appAccount { * * @type { ?Array } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ requiredLabels?: Array; @@ -2406,8 +2325,7 @@ declare namespace appAccount { * * @type { ?string } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ authType?: string; @@ -2419,8 +2337,7 @@ declare namespace appAccount { * * @type { ?Record } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ parameters?: Record; } @@ -2430,8 +2347,7 @@ declare namespace appAccount { * * @interface SelectAccountsOptions * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface SelectAccountsOptions { /** @@ -2439,8 +2355,7 @@ declare namespace appAccount { * * @type { ?Array } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ allowedAccounts?: Array; @@ -2449,8 +2364,7 @@ declare namespace appAccount { * * @type { ?Array } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ allowedOwners?: Array; @@ -2459,8 +2373,7 @@ declare namespace appAccount { * * @type { ?Array } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ requiredLabels?: Array; } @@ -2470,8 +2383,7 @@ declare namespace appAccount { * * @interface VerifyCredentialOptions * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface VerifyCredentialOptions { /** @@ -2479,8 +2391,7 @@ declare namespace appAccount { * * @type { ?string } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ credentialType?: string; @@ -2489,8 +2400,7 @@ declare namespace appAccount { * * @type { ?string } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ credential?: string; @@ -2502,8 +2412,7 @@ declare namespace appAccount { * * @type { ?Record } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ parameters?: Record; } @@ -2513,8 +2422,7 @@ declare namespace appAccount { * * @interface SetPropertiesOptions * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface SetPropertiesOptions { /** @@ -2522,8 +2430,7 @@ declare namespace appAccount { * * @type { ?Record } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ properties?: Record; @@ -2535,8 +2442,7 @@ declare namespace appAccount { * * @type { ?Record } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ parameters?: Record; } @@ -2546,8 +2452,7 @@ declare namespace appAccount { * * @enum { string } Constants * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ enum Constants { /** @@ -2574,8 +2479,7 @@ declare namespace appAccount { * Indicates the action for creating account implicitly. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ ACTION_CREATE_ACCOUNT_IMPLICITLY = 'createAccountImplicitly', @@ -2583,8 +2487,7 @@ declare namespace appAccount { * Indicates the action for authenticating. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ ACTION_AUTH = 'auth', @@ -2592,8 +2495,7 @@ declare namespace appAccount { * Indicates the action for verifying credential. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ ACTION_VERIFY_CREDENTIAL = 'verifyCredential', @@ -2601,8 +2503,7 @@ declare namespace appAccount { * Indicates the action for set authenticator properties. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ ACTION_SET_AUTHENTICATOR_PROPERTIES = 'setAuthenticatorProperties', @@ -2610,8 +2511,7 @@ declare namespace appAccount { * Indicates the key of name. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_NAME = 'name', @@ -2619,8 +2519,7 @@ declare namespace appAccount { * Indicates the key of owner. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_OWNER = 'owner', @@ -2628,8 +2527,7 @@ declare namespace appAccount { * Indicates the key of token. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_TOKEN = 'token', @@ -2637,8 +2535,7 @@ declare namespace appAccount { * Indicates the key of action. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_ACTION = 'action', @@ -2646,8 +2543,7 @@ declare namespace appAccount { * Indicates the key of authentication type. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_AUTH_TYPE = 'authType', @@ -2655,8 +2551,7 @@ declare namespace appAccount { * Indicates the key of session id. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_SESSION_ID = 'sessionId', @@ -2664,8 +2559,7 @@ declare namespace appAccount { * Indicates the key of caller pid. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_CALLER_PID = 'callerPid', @@ -2673,8 +2567,7 @@ declare namespace appAccount { * Indicates the key of caller uid. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_CALLER_UID = 'callerUid', @@ -2682,8 +2575,7 @@ declare namespace appAccount { * Indicates the key of caller bundle name. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ KEY_CALLER_BUNDLE_NAME = 'callerBundleName', @@ -2691,8 +2583,7 @@ declare namespace appAccount { * Indicates the key of required labels. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ KEY_REQUIRED_LABELS = 'requiredLabels', @@ -2700,8 +2591,7 @@ declare namespace appAccount { * Indicates the key of boolean result. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ KEY_BOOLEAN_RESULT = 'booleanResult' } @@ -2923,8 +2813,7 @@ declare namespace appAccount { * * @interface AuthCallback * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface AuthCallback { /** @@ -2932,8 +2821,7 @@ declare namespace appAccount { * * @type { function } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onResult: (code: int, result?: AuthResult) => void; @@ -2942,8 +2830,7 @@ declare namespace appAccount { * * @type { function } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onRequestRedirected: (request: Want) => void; @@ -2952,8 +2839,7 @@ declare namespace appAccount { * * @type { ?function } * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onRequestContinued?: () => void; } @@ -2962,8 +2848,7 @@ declare namespace appAccount { * Provides methods for authenticator. * * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 * @name Authenticator */ class Authenticator { @@ -2992,8 +2877,7 @@ declare namespace appAccount { * @param { CreateAccountImplicitlyOptions } options - Indicates the authenticator-specific options for the request. * @param { AuthCallback } callback - Indicates the authenticator callback. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ createAccountImplicitly(options: CreateAccountImplicitlyOptions, callback: AuthCallback): void; @@ -3026,8 +2910,7 @@ declare namespace appAccount { * @param { Record } options - Indicates the authenticator-specific options for the request. * @param { AuthCallback } callback - Indicates the authenticator callback. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ auth(name: string, authType: string, options: Record, callback: AuthCallback): void; @@ -3041,8 +2924,7 @@ declare namespace appAccount { * @param { VerifyCredentialOptions } options - Indicates the options for verifying credential. * @param { AuthCallback } callback - Indicates the authenticator callback. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ verifyCredential(name: string, options: VerifyCredentialOptions, callback: AuthCallback): void; @@ -3052,8 +2934,7 @@ declare namespace appAccount { * @param { SetPropertiesOptions } options - Indicates the options for setting properties. * @param { AuthCallback } callback - Indicates the authenticator callback. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setProperties(options: SetPropertiesOptions, callback: AuthCallback): void; @@ -3064,8 +2945,7 @@ declare namespace appAccount { * @param { Array } labels - Indicates an array of labels to check. * @param { AuthCallback } callback - Indicates the authenticator callback. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkAccountLabels(name: string, labels: Array, callback: AuthCallback): void; @@ -3075,8 +2955,7 @@ declare namespace appAccount { * @param { string } name - Indicates the account name. * @param { AuthCallback } callback - Indicates the authenticator callback. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkAccountRemovable(name: string, callback: AuthCallback): void; @@ -3085,8 +2964,7 @@ declare namespace appAccount { * * @returns { rpc.RemoteObject } Returns a remote object. * @syscap SystemCapability.Account.AppAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getRemoteObject(): rpc.RemoteObject; } diff --git a/api/@ohos.account.distributedAccount.d.ts b/api/@ohos.account.distributedAccount.d.ts index 330a3bd34159176dbf6faf97860ab04df69bd235..88d87d6fdf8a2661adfc9f1b85cb439ccaa93009 100644 --- a/api/@ohos.account.distributedAccount.d.ts +++ b/api/@ohos.account.distributedAccount.d.ts @@ -130,7 +130,6 @@ declare namespace distributedAccount { * @syscap SystemCapability.Account.OsAccount * @systemapi * @since 20 - * @arkts 1.1&1.2 */ getOsAccountDistributedInfoByLocalId(localId: int, callback: AsyncCallback): void; @@ -164,7 +163,6 @@ declare namespace distributedAccount { * @syscap SystemCapability.Account.OsAccount * @systemapi * @since 20 - * @arkts 1.1&1.2 */ getOsAccountDistributedInfoByLocalId(localId: int): Promise; @@ -208,8 +206,7 @@ declare namespace distributedAccount { * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount * This API can be called only by system applications. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setOsAccountDistributedInfo(accountInfo: DistributedInfo, callback: AsyncCallback): void; @@ -227,8 +224,7 @@ declare namespace distributedAccount { * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount * This API can be called only by system applications. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ setOsAccountDistributedInfo(accountInfo: DistributedInfo): Promise; @@ -249,8 +245,7 @@ declare namespace distributedAccount { * @throws { BusinessError } 12300008 - Restricted OS account. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ setOsAccountDistributedInfoByLocalId(localId: int, distributedInfo: DistributedInfo, callback: AsyncCallback): void; @@ -271,8 +266,7 @@ declare namespace distributedAccount { * @throws { BusinessError } 12300008 - Restricted OS account. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ setOsAccountDistributedInfoByLocalId(localId: int, distributedInfo: DistributedInfo): Promise; } diff --git a/api/@ohos.account.osAccount.d.ts b/api/@ohos.account.osAccount.d.ts index 3f18073538e9030e367cf2aa2d6ef4bc00b9f4a1..7a2e2f67ac7211d87aee59c0136b54c62957533b 100644 --- a/api/@ohos.account.osAccount.d.ts +++ b/api/@ohos.account.osAccount.d.ts @@ -204,8 +204,7 @@ declare namespace osAccount { *
2. Incorrect parameter types. * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkMultiOsAccountEnabled(callback: AsyncCallback): void; @@ -215,8 +214,7 @@ declare namespace osAccount { * @returns { Promise } Returns {@code true} if this function is enabled; returns {@code false} otherwise. * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkMultiOsAccountEnabled(): Promise; @@ -296,8 +294,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ isOsAccountActivated(localId: int): Promise; @@ -402,8 +399,7 @@ declare namespace osAccount { *
2. Incorrect parameter types. * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ isOsAccountConstraintEnabled(constraint: string): Promise; @@ -427,8 +423,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ isOsAccountConstraintEnabled(localId: int, constraint: string): Promise; @@ -462,8 +457,7 @@ declare namespace osAccount { *
2. Incorrect parameter types. * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkOsAccountTestable(callback: AsyncCallback): void; @@ -473,8 +467,7 @@ declare namespace osAccount { * @returns { Promise } Returns {@code true} if this account is testable; returns {@code false} otherwise. * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ checkOsAccountTestable(): Promise; @@ -626,8 +619,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300010 - Service busy. Possible causes: The target account is being operated. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ removeOsAccount(localId: int, callback: AsyncCallback): void; @@ -648,8 +640,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300010 - Service busy. Possible causes: The target account is being operated. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ removeOsAccount(localId: int): Promise; @@ -676,8 +667,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300008 - Restricted Account. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ setOsAccountConstraints(localId: int, constraints: Array, enable: boolean, callback: AsyncCallback): void; @@ -705,8 +695,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300008 - Restricted Account. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ setOsAccountConstraints(localId: int, constraints: Array, enable: boolean): Promise; @@ -727,8 +716,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300008 - Restricted Account. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ setOsAccountName(localId: int, localName: string, callback: AsyncCallback): void; @@ -749,8 +737,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300008 - Restricted Account. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ setOsAccountName(localId: int, localName: string): Promise; @@ -760,8 +747,7 @@ declare namespace osAccount { * @returns { Promise } The promise returned by the function. * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getOsAccountName(): Promise; @@ -800,8 +786,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount * This API can be called only by system applications. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getOsAccountCount(callback: AsyncCallback): void; @@ -814,8 +799,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount * This API can be called only by system applications. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getOsAccountCount(): Promise; @@ -973,8 +957,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid domainInfo. * @syscap SystemCapability.Account.OsAccount * This API can be called only by system applications. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getOsAccountLocalIdForDomain(domainInfo: DomainAccountInfo, callback: AsyncCallback): void; @@ -991,8 +974,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid domainInfo. * @syscap SystemCapability.Account.OsAccount * This API can be called only by system applications. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getOsAccountLocalIdForDomain(domainInfo: DomainAccountInfo): Promise; @@ -1006,8 +988,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ queryMaxOsAccountNumber(callback: AsyncCallback): void; @@ -1019,8 +1000,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ queryMaxOsAccountNumber(): Promise; @@ -1113,8 +1093,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ getEnabledOsAccountConstraints(localId: int): Promise>; @@ -1344,8 +1323,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300007 - The number of accounts has reached the upper limit. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ createOsAccountForDomain( type: OsAccountType, @@ -1398,8 +1376,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300015 - The short name already exists. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ createOsAccountForDomain(type: OsAccountType, domainInfo: DomainAccountInfo, options?: CreateOsAccountForDomainOptions): Promise; @@ -1546,8 +1523,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300001 - The system service works abnormally. * @throws { BusinessError } 12300003 - OS account not found. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ getOsAccountDomainInfo(localId: int): Promise; @@ -1672,8 +1648,7 @@ declare namespace osAccount { *
2. Incorrect parameter types. * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ queryDistributedVirtualDeviceId(callback: AsyncCallback): void; @@ -1691,8 +1666,7 @@ declare namespace osAccount { * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 12300001 - The system service works abnormally. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ queryDistributedVirtualDeviceId(): Promise; @@ -1755,8 +1729,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300008 - Restricted Account. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ setOsAccountProfilePhoto(localId: int, photo: string, callback: AsyncCallback): void; @@ -1777,8 +1750,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300008 - Restricted Account. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'7', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 7 */ setOsAccountProfilePhoto(localId: int, photo: string): Promise; @@ -1817,8 +1789,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid serialNumber. * @throws { BusinessError } 12300003 - The account indicated by serialNumber dose not exist. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getOsAccountLocalIdForSerialNumber(serialNumber: long, callback: AsyncCallback): void; @@ -1833,8 +1804,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid serialNumber. * @throws { BusinessError } 12300003 - The account indicated by serialNumber dose not exist. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getOsAccountLocalIdForSerialNumber(serialNumber: long): Promise; @@ -1873,8 +1843,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid localId. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getSerialNumberForOsAccountLocalId(localId: int, callback: AsyncCallback): void; @@ -1889,8 +1858,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid localId. * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getSerialNumberForOsAccountLocalId(localId: int): Promise; @@ -2025,8 +1993,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid uid. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getBundleIdForUid(uid: int, callback: AsyncCallback): void; @@ -2042,8 +2009,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid uid. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getBundleIdForUid(uid: int): Promise; @@ -2058,8 +2024,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid uid. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ getBundleIdForUidSync(uid: int): int; @@ -2114,8 +2079,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getOsAccountConstraintSourceTypes(localId: int, constraint: string, callback: AsyncCallback>): void; @@ -2135,34 +2099,9 @@ declare namespace osAccount { * @throws { BusinessError } 12300003 - Account not found. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ getOsAccountConstraintSourceTypes(localId: int, constraint: string): Promise>; - - /** - * Binds the specified domain account to the target OS account. - * - * @permission ohos.permission.MANAGE_LOCAL_ACCOUNTS - * @param { number } localId - Indicates the local Id of the OS account. - * @param { DomainAccountInfo } domainAccountInfo - Indicates the domain account information. - * @returns { Promise } The promise returned by the function. - * @throws { BusinessError } 201 - Permission denied. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 801 - Capability not supported. - * @throws { BusinessError } 12300001 - The system service works abnormally. - * @throws { BusinessError } 12300002 - Invalid domain account information. - * @throws { BusinessError } 12300003 - The OS account not found. - * @throws { BusinessError } 12300008 - Restricted OS account. Possible causes: The OS account cannot be bound. - * @throws { BusinessError } 12300010 - Service busy. Possible causes: The target OS account or domain account is being operated. - * @throws { BusinessError } 12300021 - The OS account is already bound. - * @throws { BusinessError } 12300022 - The domain account is already bound. - * @syscap SystemCapability.Account.OsAccount - * @systemapi - * @since 20 - * @arkts 1.1&1.2 - */ - bindDomainAccount(localId: number, domainAccountInfo: DomainAccountInfo): Promise; } /** @@ -2409,8 +2348,7 @@ declare namespace osAccount { * @type { ?Array } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'19', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ disallowedPreinstalledBundles?: Array; @@ -2420,8 +2358,7 @@ declare namespace osAccount { * @type { ?Array } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'19', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ allowedPreinstalledBundles?: Array; } @@ -2433,8 +2370,7 @@ declare namespace osAccount { * @interface CreateOsAccountForDomainOptions * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface CreateOsAccountForDomainOptions extends CreateOsAccountOptions {} @@ -2575,8 +2511,7 @@ declare namespace osAccount { * @throws { BusinessError } 202 - Not system application. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ getVersion(): int; @@ -2595,8 +2530,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid authType or authTrustLevel. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ getAvailableStatus(authType: AuthType, authTrustLevel: AuthTrustLevel): int; @@ -2688,8 +2622,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300102 - The credential does not exist. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ getPropertyByCredentialId(credentialId: Uint8Array, keys: Array): Promise; @@ -2762,7 +2695,6 @@ declare namespace osAccount { * @syscap SystemCapability.Account.OsAccount * @systemapi * @since 20 - * @arkts 1.1&1.2 */ prepareRemoteAuth(remoteNetworkId: string): Promise; @@ -3043,7 +2975,6 @@ declare namespace osAccount { * @syscap SystemCapability.Account.OsAccount * @systemapi * @since 20 - * @arkts 1.1&1.2 */ authUser( userId: int, @@ -3183,8 +3114,7 @@ declare namespace osAccount { * @interface AuthStatusInfo * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ interface AuthStatusInfo { /** @@ -3193,8 +3123,7 @@ declare namespace osAccount { * @type { int } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ remainTimes: int; @@ -3204,8 +3133,7 @@ declare namespace osAccount { * @type { int } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ freezingTime: int; } @@ -3216,8 +3144,7 @@ declare namespace osAccount { * @typedef GetDomainAccessTokenOptions * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ interface GetDomainAccessTokenOptions { /** @@ -3226,8 +3153,7 @@ declare namespace osAccount { * @type { DomainAccountInfo } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ domainAccountInfo: DomainAccountInfo; @@ -3237,8 +3163,7 @@ declare namespace osAccount { * @type { Uint8Array } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ domainAccountToken: Uint8Array; @@ -3248,8 +3173,7 @@ declare namespace osAccount { * @type { Record } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ businessParams: Record; @@ -3259,8 +3183,7 @@ declare namespace osAccount { * @type { int } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ callerUid: int; } @@ -3271,8 +3194,7 @@ declare namespace osAccount { * @typedef GetDomainAccountInfoOptions * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ interface GetDomainAccountInfoOptions { /** @@ -3281,8 +3203,7 @@ declare namespace osAccount { * @type { string } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ accountName: string; @@ -3292,8 +3213,7 @@ declare namespace osAccount { * @type { ?string } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ domain?: string; @@ -3303,8 +3223,7 @@ declare namespace osAccount { * @type { ?string } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ serverConfigId?: string; } @@ -3316,8 +3235,7 @@ declare namespace osAccount { * @extends GetDomainAccountInfoOptions * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ interface GetDomainAccountInfoPluginOptions extends GetDomainAccountInfoOptions { /** @@ -3326,12 +3244,27 @@ declare namespace osAccount { * @type { int } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ callerUid: int; } + /** + * Authenticates the specified domain account. + * + * @typedef { function } DomainPluginAuthFunc + * @param { DomainAccountInfo } domainAccountInfo - + * Indicates the domain account information for authentication. + * @param { Uint8Array } credential - Indicates the credential for authentication. + * @param { IUserAuthCallback } callback - Indicates the authentication callback. + * @syscap SystemCapability.Account.OsAccount + * @systemapi + * @since 20 + * @arkts 1.1&1.2 + */ + type DomainPluginAuthFunc = (domainAccountInfo: DomainAccountInfo, + credential: Uint8Array, callback: IUserAuthCallback) => void; + /** * Provides the definition of domain plugin. * @@ -3350,10 +3283,18 @@ declare namespace osAccount { * @param { IUserAuthCallback } callback - Indicates the authentication callback. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} + * @since 9 + */ + /** + * Authenticates the specified domain account. + * + * @type { DomainPluginAuthFunc } + * @syscap SystemCapability.Account.OsAccount + * @systemapi + * @since 20 * @arkts 1.1&1.2 */ - auth(domainAccountInfo: DomainAccountInfo, credential: Uint8Array, callback: IUserAuthCallback): void; + auth: DomainPluginAuthFunc; /** * Authenticates the specified domain account with a popup. @@ -3362,8 +3303,7 @@ declare namespace osAccount { * @param { IUserAuthCallback } callback - Indicates the callback for notifying the authentication result. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ authWithPopup(domainAccountInfo: DomainAccountInfo, callback: IUserAuthCallback): void; @@ -3375,8 +3315,7 @@ declare namespace osAccount { * @param { IUserAuthCallback } callback - Indicates the callback for notifying the authentication result. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ authWithToken(domainAccountInfo: DomainAccountInfo, token: Uint8Array, callback: IUserAuthCallback): void; @@ -3387,8 +3326,7 @@ declare namespace osAccount { * @param { AsyncCallback } callback - Indicates the callback for notifying the domain account information. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ getAccountInfo(options: GetDomainAccountInfoPluginOptions, callback: AsyncCallback): void; @@ -3399,8 +3337,7 @@ declare namespace osAccount { * @param { AsyncCallback } callback - Indicates the callback for notifying the domain authentication status information. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ getAuthStatusInfo(domainAccountInfo: DomainAccountInfo, callback: AsyncCallback): void; @@ -3412,8 +3349,7 @@ declare namespace osAccount { * @param { AsyncCallback } callback - Indicates the callback for notifying the binding result. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ bindAccount(domainAccountInfo: DomainAccountInfo, localId: int, callback: AsyncCallback): void; @@ -3424,8 +3360,7 @@ declare namespace osAccount { * @param { AsyncCallback } callback - Indicates the callback for notifying the unbinding result. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ unbindAccount(domainAccountInfo: DomainAccountInfo, callback: AsyncCallback): void; @@ -3437,8 +3372,7 @@ declare namespace osAccount { * @param { AsyncCallback } callback - Indicates the callback for notifying the checking result. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ isAccountTokenValid( domainAccountInfo: DomainAccountInfo, @@ -3453,8 +3387,7 @@ declare namespace osAccount { * @param { AsyncCallback } callback - Indicates the callback for returning the access token. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ getAccessToken(options: GetDomainAccessTokenOptions, callback: AsyncCallback): void; } @@ -3496,8 +3429,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static registerPlugin(plugin: DomainPlugin): void; @@ -3522,8 +3454,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static unregisterPlugin(): void; @@ -3605,8 +3536,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ static authWithPopup(callback: IUserAuthCallback): void; @@ -3661,8 +3591,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ static authWithPopup(localId: int, callback: IUserAuthCallback): void; @@ -3687,8 +3616,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ static hasAccount(domainAccountInfo: DomainAccountInfo, callback: AsyncCallback): void; @@ -3713,8 +3641,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ static hasAccount(domainAccountInfo: DomainAccountInfo): Promise; @@ -3737,8 +3664,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ static updateAccountToken( domainAccountInfo: DomainAccountInfo, @@ -3765,8 +3691,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ static updateAccountToken(domainAccountInfo: DomainAccountInfo, token: Uint8Array): Promise; @@ -3785,8 +3710,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300004 - The new account already exists. * @static * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static updateAccountInfo(oldAccountInfo: DomainAccountInfo, newAccountInfo: DomainAccountInfo): Promise; @@ -3811,8 +3735,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ static getAccountInfo(options: GetDomainAccountInfoOptions, callback: AsyncCallback): void; @@ -3837,8 +3760,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ static getAccountInfo(options: GetDomainAccountInfoOptions): Promise; @@ -3862,8 +3784,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ static getAccessToken(businessParams: Record, callback: AsyncCallback): void; @@ -3887,8 +3808,7 @@ declare namespace osAccount { * @static * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ static getAccessToken(businessParams: Record): Promise; @@ -3919,8 +3839,7 @@ declare namespace osAccount { * * @typedef DomainServerConfig * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface DomainServerConfig { /** @@ -3928,8 +3847,7 @@ declare namespace osAccount { * * @type { Record } * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ parameters: Record; @@ -3938,8 +3856,7 @@ declare namespace osAccount { * * @type { string } * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ id: string; @@ -3948,8 +3865,7 @@ declare namespace osAccount { * * @type { string } * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ domain: string; } @@ -3958,8 +3874,7 @@ declare namespace osAccount { * Provides abilities for managing domain server config. * * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ class DomainServerConfigManager { /** @@ -3977,8 +3892,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300215 - The number of server config reaches the upper limit. * @static * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static addServerConfig(parameters: Record): Promise; @@ -3995,8 +3909,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300214 - Server config has been associated with an account. * @static * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static removeServerConfig(configId: string): Promise; @@ -4017,8 +3930,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300214 - Server config has been associated with an account. * @static * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static updateServerConfig(configId: string, parameters: Record): Promise; @@ -4034,8 +3946,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300212 - Server config not found. * @static * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static getServerConfig(configId: string): Promise; @@ -4049,8 +3960,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300001 - The system service works abnormally. * @static * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static getAllServerConfigs(): Promise>; @@ -4066,8 +3976,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300003 - Domain account not found. * @static * @syscap SystemCapability.Account.OsAccount - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static getAccountServerConfig(domainAccountInfo: DomainAccountInfo): Promise; } @@ -4298,8 +4207,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300002 - Invalid challenge. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ cancel(challenge: Uint8Array): void; @@ -4339,8 +4247,7 @@ declare namespace osAccount { * @throws { BusinessError } 12300102 - The credential does not exist. * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ delCred(credentialId: Uint8Array, token: Uint8Array, callback: IIdmCallback): void; @@ -4522,7 +4429,6 @@ declare namespace osAccount { * @syscap SystemCapability.Account.OsAccount * @systemapi * @since 20 - * @arkts 1.1&1.2 */ getEnrolledId(authType: AuthType, accountId?: int): Promise; } @@ -5627,8 +5533,7 @@ declare namespace osAccount { * @enum { int } Module * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ enum Module { /** @@ -5636,8 +5541,7 @@ declare namespace osAccount { * * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'8', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ FACE_AUTH = 1 } @@ -5981,8 +5885,7 @@ declare namespace osAccount { * @enum { int } ConstraintSourceType * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ enum ConstraintSourceType { /** @@ -5990,8 +5893,7 @@ declare namespace osAccount { * * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ CONSTRAINT_NOT_EXIST = 0, @@ -6000,8 +5902,7 @@ declare namespace osAccount { * * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ CONSTRAINT_TYPE_BASE = 1, @@ -6010,8 +5911,7 @@ declare namespace osAccount { * * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ CONSTRAINT_TYPE_DEVICE_OWNER = 2, @@ -6020,8 +5920,7 @@ declare namespace osAccount { * * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ CONSTRAINT_TYPE_PROFILE_OWNER = 3 } @@ -6032,8 +5931,7 @@ declare namespace osAccount { * @interface ConstraintSourceTypeInfo * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface ConstraintSourceTypeInfo { /** @@ -6043,8 +5941,7 @@ declare namespace osAccount { * @type { int } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ localId: int; @@ -6054,8 +5951,7 @@ declare namespace osAccount { * @type { ConstraintSourceType } * @syscap SystemCapability.Account.OsAccount * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ type: ConstraintSourceType; } diff --git a/api/@ohos.animation.windowAnimationManager.d.ts b/api/@ohos.animation.windowAnimationManager.d.ts index e7cdf9c7c396a62f0f1726f9f85639f2bd1089ba..2b2c5ac64eced0f2012abbd0281a7283645e6d78 100644 --- a/api/@ohos.animation.windowAnimationManager.d.ts +++ b/api/@ohos.animation.windowAnimationManager.d.ts @@ -26,8 +26,7 @@ import { AsyncCallback } from './@ohos.base'; * @namespace windowAnimationManager * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ declare namespace windowAnimationManager { /** @@ -36,8 +35,7 @@ declare namespace windowAnimationManager { * @param { WindowAnimationController } controller - Window animation controller. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function setController(controller: WindowAnimationController): void; @@ -48,8 +46,7 @@ declare namespace windowAnimationManager { * @param { AsyncCallback } callback - Returns the animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function minimizeWindowWithAnimation(windowTarget: WindowAnimationTarget, callback: AsyncCallback): void; @@ -61,8 +58,7 @@ declare namespace windowAnimationManager { * @returns { Promise } Promise used to return the animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function minimizeWindowWithAnimation(windowTarget: WindowAnimationTarget): Promise; @@ -72,59 +68,53 @@ declare namespace windowAnimationManager { * @interface RRect * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ export interface RRect { /** * The X-axis coordinate of the upper left vertex of the round rect, in pixels. - * @type { double } + * @type { number } * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ - left: double; + left: number; /** * The Y-axis coordinate of the upper left vertex of the round rect, in pixels. - * @type { double } + * @type { number } * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ - top: double; + top: number; /** * Width of the round rect, in pixels. - * @type { double } + * @type { number } * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ - width: double; + width: number; /** * Height of the round rect, in pixels. - * @type { double } + * @type { number } * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ - height: double; + height: number; /** * Radius of the round corner of the round rect, in pixels. - * @type { double } + * @type { number } * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ - radius: double; + radius: number; } /** @@ -133,8 +123,7 @@ declare namespace windowAnimationManager { * @interface WindowAnimationTarget * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ export interface WindowAnimationTarget { /** @@ -143,8 +132,7 @@ declare namespace windowAnimationManager { * @readonly * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ readonly bundleName: string; @@ -154,8 +142,7 @@ declare namespace windowAnimationManager { * @readonly * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ readonly abilityName: string; @@ -165,21 +152,19 @@ declare namespace windowAnimationManager { * @readonly * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ readonly windowBounds: RRect; /** /* The mission id of the window animation target. - * @type { int } + * @type { number } * @readonly * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ - readonly missionId: int; + readonly missionId: number; } /** @@ -188,8 +173,7 @@ declare namespace windowAnimationManager { * @interface WindowAnimationFinishedCallback * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ export interface WindowAnimationFinishedCallback { /** @@ -197,8 +181,7 @@ declare namespace windowAnimationManager { * * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onAnimationFinish(): void; } @@ -209,8 +192,7 @@ declare namespace windowAnimationManager { * @interface WindowAnimationController * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ export interface WindowAnimationController { /** @@ -220,8 +202,7 @@ declare namespace windowAnimationManager { * @param { WindowAnimationFinishedCallback } finishCallback - Animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onStartAppFromLauncher(startingWindowTarget: WindowAnimationTarget, finishCallback: WindowAnimationFinishedCallback): void; @@ -233,8 +214,7 @@ declare namespace windowAnimationManager { * @param { WindowAnimationFinishedCallback } finishCallback - Animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onStartAppFromRecent(startingWindowTarget: WindowAnimationTarget, finishCallback: WindowAnimationFinishedCallback): void; @@ -246,8 +226,7 @@ declare namespace windowAnimationManager { * @param { WindowAnimationFinishedCallback } finishCallback - Animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onStartAppFromOther(startingWindowTarget: WindowAnimationTarget, finishCallback: WindowAnimationFinishedCallback): void; @@ -260,8 +239,7 @@ declare namespace windowAnimationManager { * @param { WindowAnimationFinishedCallback } finishCallback - Animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onAppTransition(fromWindowTarget: WindowAnimationTarget, toWindowTarget: WindowAnimationTarget, finishCallback: WindowAnimationFinishedCallback): void; @@ -273,8 +251,7 @@ declare namespace windowAnimationManager { * @param { WindowAnimationFinishedCallback } finishCallback - Animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onMinimizeWindow(minimizingWindowTarget: WindowAnimationTarget, finishCallback: WindowAnimationFinishedCallback): void; @@ -286,8 +263,7 @@ declare namespace windowAnimationManager { * @param { WindowAnimationFinishedCallback } finishCallback - Animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onCloseWindow(closingWindowTarget: WindowAnimationTarget, finishCallback: WindowAnimationFinishedCallback): void; @@ -297,8 +273,7 @@ declare namespace windowAnimationManager { * @param {WindowAnimationFinishedCallback } finishCallback - Animation finished callback. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onScreenUnlock(finishCallback: WindowAnimationFinishedCallback): void; @@ -310,8 +285,7 @@ declare namespace windowAnimationManager { * @param { Array } floatingWindowTargets - All the floating window targets. * @syscap SystemCapability.WindowManager.WindowManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onWindowAnimationTargetsUpdate(fullScreenWindowTarget: WindowAnimationTarget, floatingWindowTargets: Array): void; diff --git a/api/@ohos.animator.d.ts b/api/@ohos.animator.d.ts index 7b40c6e1ec838c62541ade25dc2380d6f1021b24..296ec868c8fe17df89b1d98cdb927b1f1e069910 100644 --- a/api/@ohos.animator.d.ts +++ b/api/@ohos.animator.d.ts @@ -18,11 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { FillMode, PlayMode } from './arkui/component/enums'; -import { ExpectedFrameRateRange } from './arkui/component/common'; -/*** endif */ - /** * Defines the animator options. * @interface AnimatorOptions @@ -42,8 +37,7 @@ import { ExpectedFrameRateRange } from './arkui/component/common'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ export interface AnimatorOptions { /** @@ -68,8 +62,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ duration: number; @@ -141,8 +134,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ easing: string; @@ -168,8 +160,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ delay: number; @@ -198,8 +189,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ fill: "none" | "forwards" | "backwards" | "both"; @@ -225,8 +215,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ direction: "normal" | "reverse" | "alternate" | "alternate-reverse"; @@ -252,8 +241,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ iterations: number; @@ -279,8 +267,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ begin: number; @@ -306,8 +293,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ end: number; } @@ -318,8 +304,7 @@ export interface AnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ export declare class SimpleAnimatorOptions { /** @@ -330,8 +315,7 @@ export declare class SimpleAnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ constructor(begin: number, end: number); @@ -343,8 +327,7 @@ export declare class SimpleAnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ duration(duration: number): SimpleAnimatorOptions; @@ -370,8 +353,7 @@ export declare class SimpleAnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ easing(curve: string): SimpleAnimatorOptions; @@ -383,8 +365,7 @@ export declare class SimpleAnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ delay(delay: number): SimpleAnimatorOptions; @@ -396,8 +377,7 @@ export declare class SimpleAnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ fill(fillMode: FillMode): SimpleAnimatorOptions; @@ -409,8 +389,7 @@ export declare class SimpleAnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ direction(direction: PlayMode): SimpleAnimatorOptions; @@ -422,8 +401,7 @@ export declare class SimpleAnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ iterations(iterations: number): SimpleAnimatorOptions; } @@ -447,8 +425,7 @@ export declare class SimpleAnimatorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ export interface AnimatorResult { /** @@ -495,8 +472,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ reset(options: AnimatorOptions): void; @@ -511,8 +487,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ reset(options: AnimatorOptions | SimpleAnimatorOptions): void; @@ -532,8 +507,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ play(): void; @@ -553,8 +527,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ finish(): void; @@ -574,8 +547,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ pause(): void; @@ -595,8 +567,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ cancel(): void; @@ -617,8 +588,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ reverse(): void; @@ -651,8 +621,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onFrame: (progress: number) => void; @@ -685,8 +654,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onFinish: () => void; @@ -719,8 +687,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onCancel: () => void; @@ -753,8 +720,7 @@ export interface AnimatorResult { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ onRepeat: () => void; @@ -763,8 +729,7 @@ export interface AnimatorResult { * @param { ExpectedFrameRateRange } rateRange - Indicates ExpectedFrameRateRange. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setExpectedFrameRateRange(rateRange: ExpectedFrameRateRange): void; } @@ -787,15 +752,7 @@ export interface AnimatorResult { * @atomicservice * @since 11 */ -/** - * Defines the Animator class. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ -declare class Animator { +export default class Animator { /** * Create an animator object for custom animation. * @param { AnimatorOptions } options - Options. @@ -858,10 +815,7 @@ declare class Animator { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ static create(options: AnimatorOptions | SimpleAnimatorOptions): AnimatorResult; } - -export default Animator; diff --git a/api/@ohos.animator.static.d.ets b/api/@ohos.animator.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..9873823603558a3b5dd85d8b2f57e84158e7c75b --- /dev/null +++ b/api/@ohos.animator.static.d.ets @@ -0,0 +1,363 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +import { FillMode, PlayMode } from './arkui/component/enums'; +import { ExpectedFrameRateRange } from './arkui/component/common'; + + +/** + * Defines the animator options. + * @interface AnimatorOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface AnimatorOptions { + + + /** + * Duration of the animation, in milliseconds. + * The default value is 0. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + duration: number; + + + /** + * Time curve of the animation. For details about the supported types. + * linear The animation speed keeps unchanged. + * ease The animation starts and ends at a low speed, cubic-bezier(0.25, 0.1, 0.25, 1.0). + * ease-in The animation starts at a low speed, cubic-bezier(0.42, 0.0, 1.0, 1.0). + * ease-out The animation ends at a low speed, cubic-bezier(0.0, 0.0, 0.58, 1.0). + * ease-in-out The animation starts and ends at a low speed, cubic-bezier(0.42, 0.0, 0.58, 1.0). + * fast-out-slow-in Standard curve, cubic-bezier(0.4, 0.0, 0.2, 1.0). + * linear-out-slow-in Deceleration curve, cubic-bezier(0.0, 0.0, 0.2, 1.0). + * fast-out-linear-in Acceleration curve, cubic-bezier(0.4, 0.0, 1.0, 1.0). + * friction Damping curve, cubic-bezier(0.2, 0.0, 0.2, 1.0). + * extreme-deceleration Extreme deceleration curve, cubic-bezier(0.0, 0.0, 0.0, 1.0). + * sharp Sharp curve, cubic-bezier(0.33, 0.0, 0.67, 1.0). + * rhythm Rhythm curve, cubic-bezier(0.7, 0.0, 0.2, 1.0). + * smooth Smooth curve, cubic-bezier(0.4, 0.0, 0.4, 1.0). + * cubic-bezier(x1, y1, x2, y2) You can customize an animation speed curve in the cubic-bezier() function. + * The x and y values of each input parameter must be between 0 and 1. + * Step curve. The number must be set and only an integer is supported, step-position is optional. + * It can be set to start or end. The default value is end. + * interpolating-spring(velocity, mass, stiffness, damping), interpolating spring curve. + * The default value is ease. + * @type {string} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + easing: string; + + + /** + * Delay for the animation start. The default value indicates no delay. + * The default value is 0. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + delay: number; + + + /** + * Whether to resume to the initial state after the animation is executed. + * none: The initial state is restored after the animation is executed. + * forwards: The state at the end of the animation (defined in the last key frame) + * is retained after the animation is executed. + * @type {"none" | "forwards" | "backwards" | "both"} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fill: "none" | "forwards" | "backwards" | "both"; + + + /** + * The animation playback mode. + * The default value is "normal". + * @type {"normal" | "reverse" | "alternate" | "alternate-reverse"} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + direction: "normal" | "reverse" | "alternate" | "alternate-reverse"; + + + /** + * Number of times the animation will be played. + * Number indicates a fixed number of playback operations, and -1 an unlimited number of playback operations. + * The default value is 1. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iterations: number; + + + /** + * Starting point of animator interpolation. + * The default value is 0. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + begin: number; + + + /** + * Ending point of Dynamic Interpolation + * The default value is 1. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + end: number; +} +/** + * Defines the SimpleAnimatorOptions class. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class SimpleAnimatorOptions { + /** + * constructor. + * + * @param { number } begin - Starting point of animator interpolation. + * @param { number } end - Ending point of animator interpolation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(begin: number, end: number); + /** + * Set duration of the animation, in milliseconds. + * + * @param { number } duration - if not set, default is 1000. + * @returns { SimpleAnimatorOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + duration(duration: number): SimpleAnimatorOptions; + /** + * Set time curve of the animation. For details about the supported types. + * linear The animation speed keeps unchanged. + * ease The animation starts and ends at a low speed, cubic-bezier(0.25, 0.1, 0.25, 1.0). + * ease-in The animation starts at a low speed, cubic-bezier(0.42, 0.0, 1.0, 1.0). + * ease-out The animation ends at a low speed, cubic-bezier(0.0, 0.0, 0.58, 1.0). + * ease-in-out The animation starts and ends at a low speed, cubic-bezier(0.42, 0.0, 0.58, 1.0). + * fast-out-slow-in Standard curve, cubic-bezier(0.4, 0.0, 0.2, 1.0). + * linear-out-slow-in Deceleration curve, cubic-bezier(0.0, 0.0, 0.2, 1.0). + * fast-out-linear-in Acceleration curve, cubic-bezier(0.4, 0.0, 1.0, 1.0). + * friction Damping curve, cubic-bezier(0.2, 0.0, 0.2, 1.0). + * extreme-deceleration Extreme deceleration curve, cubic-bezier(0.0, 0.0, 0.0, 1.0). + * sharp Sharp curve, cubic-bezier(0.33, 0.0, 0.67, 1.0). + * rhythm Rhythm curve, cubic-bezier(0.7, 0.0, 0.2, 1.0). + * smooth Smooth curve, cubic-bezier(0.4, 0.0, 0.4, 1.0). + * cubic-bezier(x1, y1, x2, y2) You can customize an animation speed curve in the cubic-bezier() function. + * The x and y values of each input parameter must be between 0 and 1. + * Step curve. The number must be set and only an integer is supported, step-position is optional. + * It can be set to start or end. The default value is end. + * @param { string } curve - if not set, default is ease. + * @returns { SimpleAnimatorOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + easing(curve: string): SimpleAnimatorOptions; + /** + * Set delay for the animation start. The default value indicates no delay. + * + * @param { number } delay - if not set, default is 0. + * @returns { SimpleAnimatorOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + delay(delay: number): SimpleAnimatorOptions; + /** + * Set FillMode of animation. + * FillMode indicates whether to resume to the initial state after the animation is executed. + * + * @param { FillMode } fillMode - if not set, default is FillMode.Forwards. + * @returns { SimpleAnimatorOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fill(fillMode: FillMode): SimpleAnimatorOptions; + /** + * Set the animation playback mode. + * + * @param { PlayMode } direction - if not set, default is PlayMode.Normal. + * @returns { SimpleAnimatorOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + direction(direction: PlayMode): SimpleAnimatorOptions; + /** + * Set number of times the animation will be played. + * Number indicates a fixed number of playback operations, and -1 an unlimited number of playback operations. + * + * @param { number } iterations - if not set, default is 1. + * @returns { SimpleAnimatorOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iterations(iterations: number): SimpleAnimatorOptions; +} + + +/** + * Defines the Animator result interface. + * @interface AnimatorResult + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface AnimatorResult { + + + /** + * Reset the options for current animator. + * @param { AnimatorOptions } options - Options. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The specified page is not found or the object property list is not obtained. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + reset(options: AnimatorOptions): void; + /** + * Reset the options for current animator. + * @param { AnimatorOptions | SimpleAnimatorOptions } options - Options. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The specified page is not found or the object property list is not obtained. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + reset(options: AnimatorOptions | SimpleAnimatorOptions): void; + + + /** + * Starts the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + play(): void; + + + /** + * Ends the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + finish(): void; + + + /** + * Pauses the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pause(): void; + + + /** + * Cancels the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + cancel(): void; + + + /** + * Plays the animation in reverse direction. + * Invalid when using interpolating-spring curve. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + reverse(): void; + /** + * Trigger when vSync callback. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onFrame: (progress: number) => void; + /** + * The animation is finished. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onFinish: () => void; + /** + * The animation is canceled. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onCancel: () => void; + /** + * The animation is repeated. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onRepeat: () => void; + /** + * The expected frame rate of dynamical of rate range. + * @param { ExpectedFrameRateRange } rateRange - Indicates ExpectedFrameRateRange. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setExpectedFrameRateRange(rateRange: ExpectedFrameRateRange): void; +} + + + +/** + * Defines the Animator class. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare class Animator { + /** + * Create an animator object for custom animation. + * @param { AnimatorOptions | SimpleAnimatorOptions } options - Options. + * @returns { AnimatorResult } animator result + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + static create(options: AnimatorOptions | SimpleAnimatorOptions): AnimatorResult; +} +export default Animator; diff --git a/api/@ohos.app.ability.AbilityConstant.d.ts b/api/@ohos.app.ability.AbilityConstant.d.ts index 574ba2bd5ec01256bf678937b2f6f9c8461a957a..00326a454d379829cb4550e34f2dbd31997d1c6c 100644 --- a/api/@ohos.app.ability.AbilityConstant.d.ts +++ b/api/@ohos.app.ability.AbilityConstant.d.ts @@ -1184,72 +1184,72 @@ declare namespace AbilityConstant { } /** - * Enumerates the collaboration request results. - * This enum is used in multi-device collaboration scenarios to specify whether the target application accepts the - * collaboration request from the caller application. - * It is used in onCollaborate(wantParam) of the UIAbility. + * Enumerates the actions triggered when an application is closed by the user. It must be used together with + * onPrepareTermination or onPrepareTerminationAsync of AbilityStage. * * @enum { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since arkts {'1.1':'18', '1.2':'20'} + * @atomicservice + * @since arkts {'1.1':'15', '1.2':'20'} * @arkts 1.1&1.2 */ - export enum CollaborateResult { + export enum PrepareTermination { /** - * Accepts the collaboration request. + * Executes the termination action immediately. This is the default behavior. * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since arkts {'1.1':'18', '1.2':'20'} + * @atomicservice + * @since arkts {'1.1':'15', '1.2':'20'} * @arkts 1.1&1.2 */ - ACCEPT = 0, + TERMINATE_IMMEDIATELY = 0, /** - * Rejects the collaboration request. + * Cancels the termination action. * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since arkts {'1.1':'18', '1.2':'20'} + * @atomicservice + * @since arkts {'1.1':'15', '1.2':'20'} * @arkts 1.1&1.2 */ - REJECT = 1, + CANCEL = 1 } - + /** - * Enumerates the actions triggered when an application is closed by the user. It must be used together with - * onPrepareTermination or onPrepareTerminationAsync of AbilityStage. + * Enumerates the collaboration request results. + * This enum is used in multi-device collaboration scenarios to specify whether the target application accepts the + * collaboration request from the caller application. + * It is used in onCollaborate(wantParam) of the UIAbility. * * @enum { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @atomicservice - * @since arkts {'1.1':'15', '1.2':'20'} + * @since arkts {'1.1':'18', '1.2':'20'} * @arkts 1.1&1.2 */ - export enum PrepareTermination { + export enum CollaborateResult { /** - * Executes the termination action immediately. This is the default behavior. + * Accepts the collaboration request. * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @atomicservice - * @since arkts {'1.1':'15', '1.2':'20'} + * @since arkts {'1.1':'18', '1.2':'20'} * @arkts 1.1&1.2 */ - TERMINATE_IMMEDIATELY = 0, - + ACCEPT = 0, + /** - * Cancels the termination action. + * Rejects the collaboration request. * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @atomicservice - * @since arkts {'1.1':'15', '1.2':'20'} + * @since arkts {'1.1':'18', '1.2':'20'} * @arkts 1.1&1.2 */ - CANCEL = 1 + REJECT = 1, } } diff --git a/api/@ohos.app.ability.Configuration.d.ts b/api/@ohos.app.ability.Configuration.d.ts index 94322a7f338c7a43467efbac407e0cfaded4da79..1a47592fffcc5d987a341429ba64ee828a58ab4a 100644 --- a/api/@ohos.app.ability.Configuration.d.ts +++ b/api/@ohos.app.ability.Configuration.d.ts @@ -196,7 +196,8 @@ export interface Configuration { * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ fontId?: string; diff --git a/api/@ohos.app.ability.InsightIntentDecorator.d.ts b/api/@ohos.app.ability.InsightIntentDecorator.d.ts index 120ed65cf65c540e8dc9c0bf28a127dfc23142af..c350606ca9a9d8fdc86b12a1327a2f1af1cdc068 100644 --- a/api/@ohos.app.ability.InsightIntentDecorator.d.ts +++ b/api/@ohos.app.ability.InsightIntentDecorator.d.ts @@ -205,7 +205,6 @@ declare interface LinkIntentDecoratorInfo extends IntentDecoratorInfo { * * @enum { string } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @systemapi * @stagemodelonly * @atomicservice * @since 20 @@ -215,7 +214,6 @@ declare enum LinkParamCategory { * The parameter will added to the end of link uri. * * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @systemapi * @stagemodelonly * @atomicservice * @since 20 @@ -226,7 +224,6 @@ declare enum LinkParamCategory { * The parameter will transferred to the application as parameters of want. * * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @systemapi * @stagemodelonly * @atomicservice * @since 20 diff --git a/api/@ohos.app.ability.PrintExtensionAbility.d.ts b/api/@ohos.app.ability.PrintExtensionAbility.d.ts index ce61e8acfe75d3998a57998e116ab941b20678b4..eccc0acff539fd91680913cd8ff4b5e873e4bae9 100644 --- a/api/@ohos.app.ability.PrintExtensionAbility.d.ts +++ b/api/@ohos.app.ability.PrintExtensionAbility.d.ts @@ -18,7 +18,7 @@ * @kit BasicServicesKit */ -import type Want from './@ohos.application.Want'; +import type Want from './@ohos.app.ability.Want'; import type print from './@ohos.print'; /** @@ -26,16 +26,18 @@ import type print from './@ohos.print'; * * @syscap SystemCapability.Print.PrintFramework * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ -export default class PrintExtensionAbility { +declare class PrintExtensionAbility { /** * Called once to initialize the extensionAbility. * @param { Want } want - call print page want params. * @syscap SystemCapability.Print.PrintFramework * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ onCreate(want: Want): void; @@ -43,7 +45,8 @@ export default class PrintExtensionAbility { * Called once to start to discover the printers connected with the device. * @syscap SystemCapability.Print.PrintFramework * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ onStartDiscoverPrinter(): void; @@ -51,7 +54,8 @@ export default class PrintExtensionAbility { * Called once to stop discovering the printer. * @syscap SystemCapability.Print.PrintFramework * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ onStopDiscoverPrinter(): void; @@ -60,7 +64,8 @@ export default class PrintExtensionAbility { * @param { number } printerId - connect the printerId. * @syscap SystemCapability.Print.PrintFramework * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ onConnectPrinter(printerId: number): void; @@ -69,7 +74,8 @@ export default class PrintExtensionAbility { * @param { number } printerId - connect the printerId. * @syscap SystemCapability.Print.PrintFramework * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ onDisconnectPrinter(printerId: number): void; @@ -80,7 +86,8 @@ export default class PrintExtensionAbility { * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ onStartPrintJob(jobInfo: print.PrintJob): void; @@ -91,7 +98,8 @@ export default class PrintExtensionAbility { * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ onCancelPrintJob(jobInfo: print.PrintJob): void; @@ -103,7 +111,8 @@ export default class PrintExtensionAbility { * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ onRequestPrinterCapability(printerId: number): print.PrinterCapability; @@ -115,7 +124,8 @@ export default class PrintExtensionAbility { * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ onRequestPreview(jobInfo: print.PrintJob): string; @@ -123,7 +133,10 @@ export default class PrintExtensionAbility { * Called once to finalize the extensionAbility. * @syscap SystemCapability.Print.PrintFramework * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ onDestroy(): void; } + +export default PrintExtensionAbility; \ No newline at end of file diff --git a/api/@ohos.app.ability.ServiceExtensionAbility.d.ts b/api/@ohos.app.ability.ServiceExtensionAbility.d.ts index b2b3fff73c6773abdbb9de305a194b47c49bf4e8..629008d5de06919f6e35f57c408b5d7651cad393 100644 --- a/api/@ohos.app.ability.ServiceExtensionAbility.d.ts +++ b/api/@ohos.app.ability.ServiceExtensionAbility.d.ts @@ -113,27 +113,14 @@ declare class ServiceExtensionAbility { * Called back when all abilities connected to a service extension are disconnected. * * @param { Want } want - Indicates disconnection information about the service extension. - * @returns { void } the promise returned by the function. + * @returns { Promise | undefined } the promise returned by the function. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly * @since 20 * @arkts 1.2 */ - onDisconnect(want: Want): void; - - /** - * Called back when all abilities connected to a service extension are disconnected. - * - * @param { Want } want - Indicates disconnection information about the service extension. - * @returns { Promise } the promise returned by the function. - * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @systemapi - * @stagemodelonly - * @since 20 - * @arkts 1.2 - */ - onDisconnectAsync(want: Want): Promise; + onDisconnect(want: Want): Promise | undefined; /** * Called when a new client attempts to connect to a service extension after all previous client connections to it diff --git a/api/@ohos.app.ability.UIAbility.d.ts b/api/@ohos.app.ability.UIAbility.d.ts index 164845cbb154b6ec5c88d2c72b261fd2298e7bbf..8c714ff6a6fd0e094e456ad65490ad5b0ac675f0 100644 --- a/api/@ohos.app.ability.UIAbility.d.ts +++ b/api/@ohos.app.ability.UIAbility.d.ts @@ -25,105 +25,43 @@ import window from './@ohos.window'; import UIAbilityContext from './application/UIAbilityContext'; import rpc from './@ohos.rpc'; -/** - * The prototype of the listener function interface registered by the Caller. - * - * @typedef OnReleaseCallback - * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore - * @stagemodelonly - * @since 9 - */ -export interface OnReleaseCallback { -/** - * Defines the callback that is invoked when the stub on the target UIAbility is disconnected. - * - * @param { string } msg - Message used for disconnection. - * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore - * @stagemodelonly - * @since 9 - */ - (msg: string): void; -} - /** * The prototype of the listener function interface registered by the Caller. * Defines the callback of OnRelease. * - * @typedef OnReleaseCallback + * @typedef { function } OnReleaseCallback * @param { string } msg - The notification event string listened to by the OnRelease. * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly - * @since 20 - * @arkts 1.2 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export type OnReleaseCallback = (msg: string) => void; - -/** - * The prototype of the listener function interface registered by the Caller. - * - * @typedef OnRemoteStateChangeCallback - * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore - * @stagemodelonly - * @since 10 - */ -export interface OnRemoteStateChangeCallback { -/** - * Defines the callback that is invoked when the remote UIAbility state changes in the collaboration scenario. - * - * @param { string } msg - Message used for disconnection. - * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore - * @stagemodelonly - * @since 10 - */ - (msg: string): void; -} - /** * The prototype of the listener function interface registered by the Caller. * Defines the callback of OnRemoteStateChange. * - * @typedef OnRemoteStateChangeCallback + * @typedef { function } OnRemoteStateChangeCallback * @param { string } msg - The notification event string listened to by the OnRemoteStateChange. * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly - * @since 20 - * @arkts 1.2 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ export type OnRemoteStateChangeCallback = (msg: string) => void; /** * The prototype of the message listener function interface registered by the Callee. + * Defines the callback of Callee. * - * @typedef CalleeCallback + * @typedef { function } CalleeCallback + * @param { rpc.MessageSequence } indata - Notification indata to the callee. + * @returns { rpc.Parcelable } Returns the callee's notification result indata. * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly - * @since 9 - */ -export interface CalleeCallback { -/** - * Defines the callback of the registration message notification of the UIAbility. - * - * @param { rpc.MessageSequence } indata - Data to be transferred. - * @returns { rpc.Parcelable } Returned data object. - * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore - * @stagemodelonly - * @since 9 - */ - (indata: rpc.MessageSequence): rpc.Parcelable; -} - -/** - * The prototype of the message listener function interface registered by the Callee. - * Defines the callback of the registration message notification of the UIAbility. - * - * @typedef CalleeCallback - * @param { rpc.MessageSequence } indata - Data to be transferred. - * @returns { rpc.Parcelable } Returned data object. - * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore - * @stagemodelonly - * @since 20 - * @arkts 1.2 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export type CalleeCallback = (indata: rpc.MessageSequence) => rpc.Parcelable; @@ -662,15 +600,7 @@ declare class UIAbility extends Ability { onForeground(): void; /** - * Triggered just before the application transitions to the foreground. - * It is called before onForeground. - * It can be used to capture the moment when the application starts to transition to the foreground. - * When paired with onDidForeground, it can also measure the duration from the application's initial - * foreground entry to its full transition into the foreground state. - * - *

**NOTE**: - *
This API returns the result synchronously and does not support asynchronous callback. - *

+ * Called back when the state of an ability will changes to foreground. * * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly @@ -680,15 +610,7 @@ declare class UIAbility extends Ability { onWillForeground(): void; /** - * Triggered after the application has transitioned to the foreground. - * It is called after onForeground. - * It can be used to capture the moment when the application fully transitions to the foreground. - * When paired with onWillForeground, it can also measure the duration from the application's initial foreground - * entry to its full transition into the foreground state. - * - *

**NOTE**: - *
This API returns the result synchronously and does not support asynchronous callback. - *

+ * Called back when the state of an ability changed to foreground. * * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly @@ -727,14 +649,7 @@ declare class UIAbility extends Ability { onBackground(): void; /** - * Triggered just when the application transitions to the background. - * It is called before onBackground. - * It can be used to log various types of data, such as faults, statistics, security information, and user behavior - * that occur during application running. - * - *

**NOTE**: - *
This API returns the result synchronously and does not support asynchronous callback. - *

+ * Called back when the state of an ability will changes to background. * * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly @@ -744,14 +659,7 @@ declare class UIAbility extends Ability { onWillBackground(): void; /** - * Triggered after the application has transitioned to the background. - * It is called after onBackground. - * It can be used to release resources after the application has entered the background, for example, stopping - * audio playback. - * - *

**NOTE**: - *
This API returns the result synchronously and does not support asynchronous callback. - *

+ * Called back when the state of an ability changed to background. * * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly @@ -902,7 +810,7 @@ declare class UIAbility extends Ability { * @since 20 */ onSaveStateAsync(stateType: AbilityConstant.StateType, wantParam: Record): Promise; - + /** * Called back when an ability shares data. * diff --git a/api/@ohos.app.ability.UIExtensionAbility.d.ts b/api/@ohos.app.ability.UIExtensionAbility.d.ts index 4b7de8200f33f98922164bf11b34d6ebeef1321f..616c210e8d1902b1a659299f14e150c92bd3aee0 100755 --- a/api/@ohos.app.ability.UIExtensionAbility.d.ts +++ b/api/@ohos.app.ability.UIExtensionAbility.d.ts @@ -119,24 +119,13 @@ declare class UIExtensionAbility extends ExtensionAbility { /** * Called back before an UI extension is destroyed. * - * @returns { void } the promise returned by the function. + * @returns { Promise | undefined } the promise returned by the function. * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @StageModelOnly - * @since 20 - * @arkts 1.2 - */ - onDestroy(): void; - - /** - * Called back before an UI extension is destroyed. - * - * @returns { Promise } the promise returned by the function. - * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @StageModelOnly + * @stagemodelonly * @since 20 * @arkts 1.2 */ - onDestroyAsync(): Promise; + onDestroy(): Promise | undefined; } export default UIExtensionAbility; \ No newline at end of file diff --git a/api/@ohos.app.ability.Want.d.ts b/api/@ohos.app.ability.Want.d.ts index 3f97d2f34cfd195d3061e8bc90abcce50481422e..fdf0bec5f4d23904fcd141008b9f9caf495b18d6 100644 --- a/api/@ohos.app.ability.Want.d.ts +++ b/api/@ohos.app.ability.Want.d.ts @@ -193,7 +193,8 @@ export default class Want { * @type { ?int } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ flags?: int; diff --git a/api/@ohos.app.ability.abilityManager.d.ts b/api/@ohos.app.ability.abilityManager.d.ts index 5059b1ead8260538fbf2854f9ab4908075b50e4d..62726632ab6797fb2339af7a52bcea035c1be726 100644 --- a/api/@ohos.app.ability.abilityManager.d.ts +++ b/api/@ohos.app.ability.abilityManager.d.ts @@ -570,7 +570,7 @@ declare namespace abilityManager { * * @typedef { _AbilityRunningInfo } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since arkts {'1.1':'9', '1.2':'20'} + * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ export type AbilityRunningInfo = _AbilityRunningInfo; diff --git a/api/@ohos.app.ability.appManager.d.ts b/api/@ohos.app.ability.appManager.d.ts index b56c5932d8829250c3ff91675ef214cb54f8434e..9b320b1b12ee819b0ef4549a77b77fbaacc466f8 100644 --- a/api/@ohos.app.ability.appManager.d.ts +++ b/api/@ohos.app.ability.appManager.d.ts @@ -725,7 +725,7 @@ declare namespace appManager { * @permission ohos.permission.KILL_APP_PROCESSES or ohos.permission.CLEAN_BACKGROUND_PROCESSES * @param { string } bundleName - bundle name. * @param { boolean } clearPageStack - The flag that indicates whether the page stack need to be cleared. - * @param { int } [appIndex] - The index of clone app. + * @param { int } [appIndex] - The application index. * @returns { Promise } The promise returned by the function. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 401 - If the input parameter is not valid parameter. @@ -1355,14 +1355,14 @@ declare namespace appManager { */ export type AbilityStateData = _AbilityStateData.default; - /** - * The ability or extension state data. +/** + * The ability state data. * * @typedef { _AbilityStateData } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @since 20 * @arkts 1.2 - */ + */ export type AbilityStateData = _AbilityStateData; /** diff --git a/api/@ohos.app.ability.appRecovery.d.ts b/api/@ohos.app.ability.appRecovery.d.ts index 517fb27763a386c37f5d788ca1e44fbf9b7d9a2e..3a430e8e4d0345ce550428bddab6ebf5688148c3 100644 --- a/api/@ohos.app.ability.appRecovery.d.ts +++ b/api/@ohos.app.ability.appRecovery.d.ts @@ -55,7 +55,7 @@ declare namespace appRecovery { /** * The flag that determines when to restart you app. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} @@ -141,7 +141,7 @@ declare namespace appRecovery { * When start saving ability state, the { ohos.app.ability.UiAbility.onSaveState } will be called and * the page stack of current ability will be saved automatically. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} @@ -195,7 +195,7 @@ declare namespace appRecovery { /** * The flag that determines how to save the ability state. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} diff --git a/api/@ohos.app.ability.autoFillManager.d.ts b/api/@ohos.app.ability.autoFillManager.d.ts index b18eefefd3606a8973afdb32f5ae66dde94f22d6..3ac07c8c84161de8e949b704e4a4b85d9dc8dca4 100644 --- a/api/@ohos.app.ability.autoFillManager.d.ts +++ b/api/@ohos.app.ability.autoFillManager.d.ts @@ -46,6 +46,30 @@ import { PopupPlacement } from './application/AutoFillPopupConfig'; * @since 12 */ declare namespace autoFillManager { + /** + * Called when auto save request is successfully handled. + * + * @typedef { function } + * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore + * @stagemodelonly + * @atomicservice + * @since 20 + * @arkts 1.1&1.2 + */ + type OnSuccessFn = () => void; + + /** + * Called when auto save request is failed to be handled. + * + * @typedef { function } + * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore + * @stagemodelonly + * @atomicservice + * @since 20 + * @arkts 1.1&1.2 + */ + type OnFailureFn = () => void; + /** * Auto save callback. * @@ -74,12 +98,13 @@ declare namespace autoFillManager { /** * Called when auto save request is successfully handled. * + * @type { OnSuccessFn } * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly * @atomicservice * @since 12 */ - onSuccess(): void; + onSuccess: OnSuccessFn; /** * Called when auto save request is failed to be handled. @@ -91,12 +116,13 @@ declare namespace autoFillManager { /** * Called when auto save request is failed to be handled. * + * @type { OnFailureFn } * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly * @atomicservice * @since 12 */ - onFailure(): void; + onFailure: OnFailureFn; } /** diff --git a/api/@ohos.app.ability.common.d.ts b/api/@ohos.app.ability.common.d.ts index aa0bd3d5e2a10c790ab96924d6876e29f6b0df5e..bb9e83c5dde709bf703d1c0c9fc69c43da6b78cb 100644 --- a/api/@ohos.app.ability.common.d.ts +++ b/api/@ohos.app.ability.common.d.ts @@ -39,6 +39,7 @@ import * as _UIServiceExtensionContext from './application/UIServiceExtensionCon import * as _UIServiceProxy from './application/UIServiceProxy'; import * as _UIServiceHostProxy from './application/UIServiceHostProxy'; import * as _UIServiceExtensionConnectCallback from './application/UIServiceExtensionConnectCallback'; +import * as _AppServiceExtensionContext from './application/AppServiceExtensionContext'; import { PacMap as _PacMap } from './ability/dataAbilityHelper'; /*** endif */ /*** if arkts 1.2 */ @@ -49,7 +50,6 @@ import _ApplicationContext from './application/ApplicationContext'; import _BaseContext from './application/BaseContext'; import _Context from './application/Context'; import _ExtensionContext from './application/ExtensionContext'; -import _FormExtensionContext from './application/FormExtensionContext'; import _ServiceExtensionContext from './application/ServiceExtensionContext'; import _EventHub from './application/EventHub'; /*** endif */ @@ -239,7 +239,6 @@ declare namespace common { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @crossplatform - * @atomicservice * @since 20 * @arkts 1.2 */ @@ -339,19 +338,6 @@ declare namespace common { */ export type FormExtensionContext = _FormExtensionContext.default; - /** - * The context of form extension. It allows access to - * formExtension-specific resources. - * - * @typedef { _FormExtensionContext } - * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @stagemodelonly - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - export type FormExtensionContext = _FormExtensionContext; - /** * The context of service extension. It allows access to * serviceExtension-specific resources. @@ -411,7 +397,6 @@ declare namespace common { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @crossplatform - * @atomicservice * @since 20 * @arkts 1.2 */ diff --git a/api/@ohos.app.ability.kioskManager.d.ts b/api/@ohos.app.ability.kioskManager.d.ts index 6003ad9dfa5d557ac5c1278314168d68311bbed7..5b7350d02570cdace872f26626a178a038d29ce3 100644 --- a/api/@ohos.app.ability.kioskManager.d.ts +++ b/api/@ohos.app.ability.kioskManager.d.ts @@ -28,7 +28,6 @@ import { KioskStatus as _KioskStatus } from './application/KioskStatus'; * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ declare namespace kioskManager { /** @@ -44,7 +43,6 @@ declare namespace kioskManager { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ function enterKioskMode(context: UIAbilityContext): Promise; @@ -60,7 +58,6 @@ declare namespace kioskManager { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ function exitKioskMode(context: UIAbilityContext): Promise; @@ -75,7 +72,6 @@ declare namespace kioskManager { * @systemapi * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ function getKioskStatus(): Promise; @@ -86,7 +82,6 @@ declare namespace kioskManager { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ export type KioskStatus = _KioskStatus; } diff --git a/api/@ohos.app.ability.wantAgent.d.ts b/api/@ohos.app.ability.wantAgent.d.ts index 4d624aae511c428ac4c6c6618aac4f11b371a892..c06e02e9fb1616b147e9c5ff6c813ad855eefd23 100644 --- a/api/@ohos.app.ability.wantAgent.d.ts +++ b/api/@ohos.app.ability.wantAgent.d.ts @@ -134,7 +134,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getUid(agent: WantAgent, callback: AsyncCallback): void; @@ -162,7 +163,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getUid(agent: WantAgent): Promise; @@ -889,7 +891,8 @@ declare namespace wantAgent { * @type { WantAgent } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ info: WantAgent; @@ -906,7 +909,8 @@ declare namespace wantAgent { * @type { Want } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ want: Want; @@ -923,7 +927,8 @@ declare namespace wantAgent { * @type { int } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ finalCode: int; @@ -940,7 +945,8 @@ declare namespace wantAgent { * @type { string } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ finalData: string; @@ -964,7 +970,8 @@ declare namespace wantAgent { * @type { ?Record } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ extraInfo?: Record; } diff --git a/api/@ohos.app.ability.wantConstant.d.ts b/api/@ohos.app.ability.wantConstant.d.ts index 3d81cfacb4f5681852bcce9e84e4a5d57125b781..97b6fe495017051e29ac687fa029287ecef09e04 100644 --- a/api/@ohos.app.ability.wantConstant.d.ts +++ b/api/@ohos.app.ability.wantConstant.d.ts @@ -375,21 +375,23 @@ declare namespace wantConstant { LAUNCH_REASON_MESSAGE = 'ohos.params.launchReasonMessage', /** - * Indicates the dest ability refers to a plugin ability. + * Indicates the param of the appIdentifier trustlist when implicitly launching applications. * * @syscap SystemCapability.Ability.AbilityBase - * @since 19 + * @atomicservice + * @since arkts {'1.1':'17', '1.2':'20'} + * @arkts 1.1&1.2 */ - DESTINATION_PLUGIN_ABILITY = 'ohos.params.pluginAbility', + APP_LAUNCH_TRUSTLIST = 'ohos.params.appLaunchTrustList', /** - * Indicates the param of the appIdentifier trustlist when implicitly launching applications. + * Indicates the dest ability refers to a plugin ability. * * @syscap SystemCapability.Ability.AbilityBase - * @atomicservice - * @since 17 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ - APP_LAUNCH_TRUSTLIST = 'ohos.params.appLaunchTrustList', + DESTINATION_PLUGIN_ABILITY = 'ohos.params.pluginAbility', /** * Indicates the unified data key used to share file uri. @@ -402,12 +404,13 @@ declare namespace wantConstant { /** * Indicates the key of the page route upon sharing atomic service. - * + * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ - ATOMIC_SERVICE_SHARE_ROUTER = 'ohos.params.atomicservice.shareRouter', + ATOMIC_SERVICE_SHARE_ROUTER = 'ohos.params.atomicservice.shareRouter' } /** diff --git a/api/@ohos.app.form.FormExtensionAbility.d.ts b/api/@ohos.app.form.FormExtensionAbility.d.ts index 268b20c6439ec085f442822b934e581167dae718..f5890e340d23ba44409f450d245a6ee70cf27b57 100644 --- a/api/@ohos.app.form.FormExtensionAbility.d.ts +++ b/api/@ohos.app.form.FormExtensionAbility.d.ts @@ -314,7 +314,7 @@ declare class FormExtensionAbility { * @since 20 * @arkts 1.2 */ - onAcquireFormState?: OnAcquireFormStateFn; + onAcquireFormState?: OnAcquireFormStateFn; /** * Called when the system shares the form. @@ -390,6 +390,7 @@ declare class FormExtensionAbility { * * @syscap SystemCapability.Ability.Form * @stagemodelonly + * @atomicservice * @since 20 */ onFormLocationChanged(formId: string, newFormLocation: formInfo.FormLocation): void; diff --git a/api/@ohos.app.form.LiveFormExtensionAbility.d.ts b/api/@ohos.app.form.LiveFormExtensionAbility.d.ts index 8a47a1405c87d992c52837c2f560b3e4fbf8e2b4..07d19b487dc7b74e0950f6b6acc5306290e588c2 100644 --- a/api/@ohos.app.form.LiveFormExtensionAbility.d.ts +++ b/api/@ohos.app.form.LiveFormExtensionAbility.d.ts @@ -33,7 +33,7 @@ import formInfo from './@ohos.app.form.formInfo'; */ export interface LiveFormInfo { /** - * The form id. + * The form id of the live form. * * @type { string } * @syscap SystemCapability.Ability.Form diff --git a/api/@ohos.app.form.formProvider.d.ts b/api/@ohos.app.form.formProvider.d.ts index 02cf9ea01f3c56d0ee78677ad9452993c014fc1f..62eedd9b0c75d3b97ffd862163dd53d2079be8c5 100644 --- a/api/@ohos.app.form.formProvider.d.ts +++ b/api/@ohos.app.form.formProvider.d.ts @@ -380,6 +380,24 @@ declare namespace formProvider { */ function isRequestPublishFormSupported(): Promise; + /** + * Open the form edit ability + * + * @param { string } abilityName - Indicates the form edit ability name. + * @param { string } formId - Indicates the edit form ID. + * @param { boolean } isMainPage - Indicates open the main edit page, default is true + * + * @throws { BusinessError } 801 - Capability not supported.function openFormEditAbility can not work correctly due to limited device capabilities. + * @throws { BusinessError } 16500050 - IPC connection error. + * @throws { BusinessError } 16500100 - Failed to obtain the configuration information. + * @throws { BusinessError } 16501000 - An internal functional error occurred. + * @throws { BusinessError } 16501003 - The form cannot be operated by the current application. + * @throws { BusinessError } 16501007 - Form is not trust. + * @syscap SystemCapability.Ability.Form + * @since 18 + */ + function openFormEditAbility(abilityName: string, formId: string, isMainPage?: boolean): void; + /** * Get infos of the published form belonging to current bundle. * Client to communicate with FormManagerService. @@ -439,24 +457,6 @@ declare namespace formProvider { */ function openFormManagerCrossBundle(want: Want): void - /** - * Open the form edit ability - * - * @param { string } abilityName - Indicates the form edit ability name. - * @param { string } formId - Indicates the edit form ID. - * @param { boolean } isMainPage - Indicates open the main edit page, default is true - * - * @throws { BusinessError } 801 - Capability not supported.function openFormEditAbility can not work correctly due to limited device capabilities. - * @throws { BusinessError } 16500050 - IPC connection error. - * @throws { BusinessError } 16500100 - Failed to obtain the configuration information. - * @throws { BusinessError } 16501000 - An internal functional error occurred. - * @throws { BusinessError } 16501003 - The form cannot be operated by the current application. - * @throws { BusinessError } 16501007 - Form is not trust. - * @syscap SystemCapability.Ability.Form - * @since 18 - */ - function openFormEditAbility(abilityName: string, formId: string, isMainPage?: boolean): void; - /** * Activate scene animation * diff --git a/api/@ohos.application.DataShareExtensionAbility.d.ts b/api/@ohos.application.DataShareExtensionAbility.d.ts index 177444235a8ba5937c47d633a39bc6fcd262bd7b..108a0e824f0db3ed050d0e43e3366b16cc9d6ec2 100644 --- a/api/@ohos.application.DataShareExtensionAbility.d.ts +++ b/api/@ohos.application.DataShareExtensionAbility.d.ts @@ -26,15 +26,125 @@ import { ValuesBucket } from './@ohos.data.ValuesBucket'; import dataShare from './@ohos.data.dataShare'; /** - * Struct for a batch update operation. - * - * @typedef { dataShare.UpdateOperation } - * @syscap SystemCapability.DistributedDataManager.DataShare.Provider - * @systemapi - * @stagemodelonly - * @since 12 - */ -type UpdateOperation = dataShare.UpdateOperation; + * Struct for a batch update operation. + * + * @typedef { dataShare.UpdateOperation } + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @stagemodelonly + * @since 12 + */ +export type UpdateOperation = dataShare.UpdateOperation; + +/** + * Called back when a datashare extension ability is started for initialization. + * + * @typedef { function } + * @param { Want } want - Indicates connection information about the datashare extension ability. + * @param { AsyncCallback } callback - callback function, no return value. + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ +type OnCreateFn = (want: Want, callback: AsyncCallback) => void; + +/** + * Inserts a data record into the database. This method should be implemented by a data share. + * + * @typedef { function } + * @param { string } uri - Indicates the position where the data is to insert. + * @param { ValuesBucket } valueBucket - Indicates the data to insert. + * @param { AsyncCallback } callback - Returns the index of the newly inserted data record. + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ +type InsertFn = (uri: string, valueBucket: ValuesBucket, callback: AsyncCallback) => void; + +/** + * Updates one or more data records in the database. This method should be implemented by a data share. + * + * @typedef { function } + * @param { string } uri - Indicates the database table storing the data to update. + * @param { dataSharePredicates.DataSharePredicates } predicates - Indicates filter criteria. If this parameter is + * null, all data records will be updated by default. + * @param { ValuesBucket } valueBucket - Indicates the data to update. This parameter can be null. + * @param { AsyncCallback } callback - Returns the number of data records updated. + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ +type UpdateFn = ( + uri: string, + predicates: dataSharePredicates.DataSharePredicates, + valueBucket: ValuesBucket, + callback: AsyncCallback +) => void; + +/** + * Deletes one or more data records. This method should be implemented by a data share. + * + * @typedef { function } + * @param { string } uri - Indicates the database table storing the data to delete. + * @param { dataSharePredicates.DataSharePredicates } predicates - Indicates filter criteria. If this parameter is + * null, all data records will be deleted by default. + * @param { AsyncCallback } callback - Returns the number of data records deleted. + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ +type DeleteFn = ( + uri: string, + predicates: dataSharePredicates.DataSharePredicates, + callback: AsyncCallback +) => void; + +/** + * Queries one or more data records in the database. This method should be implemented by a data share. + * Only RDB and distributed KVDB resultsets are supported. The current version does not support custom resultsets. + * + * @typedef { function } + * @param { string } uri - Indicates the database table storing the data to query. + * @param { dataSharePredicates.DataSharePredicates } predicates - Indicates filter criteria. If this parameter is + * null, all data records will be queried by default. + * @param { Array } columns - Indicates the columns to be queried, in array, for example, {"name","age"}. + * You should define the processing logic when this parameter is null. + * @param { AsyncCallback } callback - Returns the queried data, only support result set of rdb or kvstore. + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ +type QueryFn = ( + uri: string, + predicates: dataSharePredicates.DataSharePredicates, + columns: Array, + callback: AsyncCallback +) => void; + +/** + * Inserts multiple data records into the database. This method should be implemented by a data share. + * + * @typedef { function } + * @param { string } uri - Indicates the position where the data is to insert. + * @param { Array } valueBuckets - Indicates the data to insert. + * @param { AsyncCallback } callback - Returns the number of data records inserted. + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ +type BatchInsertFn = (uri: string, valueBuckets: Array, callback: AsyncCallback) => void; /** * This module provides data sharing and expansion capabilities. @@ -45,7 +155,7 @@ type UpdateOperation = dataShare.UpdateOperation; * @since arkts {'1.1':'9', '1.2':'20'} * @arkts 1.1&1.2 */ -export default class DataShareExtensionAbility { +declare class DataShareExtensionAbility { /** * Indicates datashare extension ability context. * @@ -66,11 +176,22 @@ export default class DataShareExtensionAbility { * @syscap SystemCapability.DistributedDataManager.DataShare.Provider * @systemapi * @StageModelOnly - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ onCreate?(want: Want, callback: AsyncCallback): void; + /** + * Called back when a datashare extension ability is started for initialization. + * + * @type { ?OnCreateFn } + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ + onCreate?: OnCreateFn; + /** * Inserts a data record into the database. This method should be implemented by a data share. * @@ -84,6 +205,18 @@ export default class DataShareExtensionAbility { */ insert?(uri: string, valueBucket: ValuesBucket, callback: AsyncCallback): void; + /** + * Inserts a data record into the database. This method should be implemented by a data share. + * + * @type { ?InsertFn } + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ + insert?: InsertFn; + /** * Updates one or more data records in the database. This method should be implemented by a data share. * @@ -95,8 +228,7 @@ export default class DataShareExtensionAbility { * @syscap SystemCapability.DistributedDataManager.DataShare.Provider * @systemapi * @StageModelOnly - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ update?( uri: string, @@ -105,6 +237,18 @@ export default class DataShareExtensionAbility { callback: AsyncCallback ): void; + /** + * Updates one or more data records in the database. This method should be implemented by a data share. + * + * @type { ?UpdateFn } + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ + update?: UpdateFn; + /** * Updates data records in the database. * @@ -130,11 +274,22 @@ export default class DataShareExtensionAbility { * @syscap SystemCapability.DistributedDataManager.DataShare.Provider * @systemapi * @StageModelOnly - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ delete?(uri: string, predicates: dataSharePredicates.DataSharePredicates, callback: AsyncCallback): void; + /** + * Deletes one or more data records. This method should be implemented by a data share. + * + * @type { ?DeleteFn } + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ + delete?: DeleteFn; + /** * Queries one or more data records in the database. This method should be implemented by a data share. * Only RDB and distributed KVDB resultsets are supported. The current version does not support custom resultsets. @@ -148,8 +303,7 @@ export default class DataShareExtensionAbility { * @syscap SystemCapability.DistributedDataManager.DataShare.Provider * @systemapi * @StageModelOnly - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ query?( uri: string, @@ -158,6 +312,19 @@ export default class DataShareExtensionAbility { callback: AsyncCallback ): void; + /** + * Queries one or more data records in the database. This method should be implemented by a data share. + * Only RDB and distributed KVDB resultsets are supported. The current version does not support custom resultsets. + * + * @type { ?QueryFn } + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ + query?: QueryFn; + /** * Inserts multiple data records into the database. This method should be implemented by a data share. * @@ -167,11 +334,22 @@ export default class DataShareExtensionAbility { * @syscap SystemCapability.DistributedDataManager.DataShare.Provider * @systemapi * @StageModelOnly - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ batchInsert?(uri: string, valueBuckets: Array, callback: AsyncCallback): void; + /** + * Inserts multiple data records into the database. This method should be implemented by a data share. + * + * @type { ?BatchInsertFn } + * @syscap SystemCapability.DistributedDataManager.DataShare.Provider + * @systemapi + * @StageModelOnly + * @since 20 + * @arkts 1.2 + */ + batchInsert?: BatchInsertFn; + /** * Converts the given {@code uri} that refer to the data share into a normalized URI. A normalized URI can be * used across devices, persisted, backed up, and restored. It can refer to the same item in the data share @@ -202,3 +380,5 @@ export default class DataShareExtensionAbility { */ denormalizeUri?(uri: string, callback: AsyncCallback): void; } + +export default DataShareExtensionAbility; diff --git a/api/@ohos.application.testRunner.d.ts b/api/@ohos.application.testRunner.d.ts index ea86d1c15bdffb3c8d6cba4fe063a05a8d754121..3490343ff7720ac73dc7ff564606df4fb60d5274 100644 --- a/api/@ohos.application.testRunner.d.ts +++ b/api/@ohos.application.testRunner.d.ts @@ -18,6 +18,28 @@ * @kit TestKit */ +/** + * Prepare the unit testing environment for running test cases. + * + * @typedef { Function } + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @atomicservice + * @since 20 + * @arkts 1.1&1.2 + */ +type OnPrepareFn = () => void; + +/** + * Run all test cases. + * + * @typedef { Function } + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @atomicservice + * @since 20 + * @arkts 1.1&1.2 + */ +type OnRunFn = () => void; + /** * Base class for the test framework. * If you want to implement your own unit test framework, you must inherit this class and overrides all its methods. @@ -48,10 +70,18 @@ interface TestRunner { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Prepare the unit testing environment for running test cases. + * + * @type { OnPrepareFn } + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @atomicservice + * @since 20 * @arkts 1.1&1.2 */ - onPrepare(): void; + onPrepare: OnPrepareFn; /** * Run all test cases. @@ -64,10 +94,18 @@ interface TestRunner { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Run all test cases. + * + * @typedef { OnRunFn } + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @atomicservice + * @since 20 * @arkts 1.1&1.2 */ - onRun(): void; + onRun: OnRunFn; } /*** if arkts 1.1 */ diff --git a/api/@ohos.arkui.ArcAlphabetIndexer.d.ts b/api/@ohos.arkui.ArcAlphabetIndexer.d.ts index d8561313e21dd5a07ef7928df922a4c686f209f0..c5a76f313d523eaea4592b5c46dbacbbcc3c5449 100755 --- a/api/@ohos.arkui.ArcAlphabetIndexer.d.ts +++ b/api/@ohos.arkui.ArcAlphabetIndexer.d.ts @@ -1,6 +1,6 @@ /* * Copyright (c) 2024 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); + * Licensed under the Apache License, Version 2.0 (the "License"), * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * @@ -27,7 +27,7 @@ * @atomicservice * @since 18 */ -declare interface ArcAlphabetIndexerInitInfo { +declare interface ArcAlphabetIndexerInitInfo { /** * Array of alphabetic indexed strings, cannot be set to empty. * @@ -60,7 +60,7 @@ declare interface ArcAlphabetIndexerInitInfo { * @atomicservice * @since 18 */ -declare type OnSelectCallback = (index: number) => void; +declare type OnSelectCallback = (index: number) => void; /** * Arc Alphabet index bar. @@ -275,6 +275,15 @@ declare class ArcAlphabetIndexerAttribute extends CommonMethod void; - -/** - * Provide methods for controlling ArcSwiper component. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -export class ArcSwiperController { - /** - * A constructor used to create a ArcSwiperController object. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - constructor(); - - /** - * Show next subcomponent. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - showNext(); - - /** - * Show previous subcomponent. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - showPrevious(); - - /** - * Finish the swiper animation. - * - * @param { FinishAnimationHandler } handler - The handler is used to listen for the end of the animation. - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - finishAnimation(handler?: FinishAnimationHandler); -} - -/** - * Declare the direction of arc indicator. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -export enum ArcDirection { - /** - * 3 o'clock direction. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - THREE_CLOCK_DIRECTION = 0, - - /** - * 6 o'clock direction. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - SIX_CLOCK_DIRECTION = 1, - - /** - * 9 o'clock direction. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - NINE_CLOCK_DIRECTION = 2, -} - -/** - * Define ArcDotIndicator, the indicator type is arc dot. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -export class ArcDotIndicator { - /** - * A constructor used to create a ArcDotIndicator object. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - constructor(); - - /** - * Set the direction of arc indicator. - * - * @param { Optional } direction - the direction of arc indicator, default value is { ArcDirection.SIX_CLOCK_DIRECTION }. - * @returns { ArcDotIndicator } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - arcDirection(direction: Optional): ArcDotIndicator; - - /** - * Set the navigation point color. - * - * @param { Optional } color - the indicator item color, default value is { #A9FFFFFF }. - * @returns { ArcDotIndicator } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - itemColor(color: Optional): ArcDotIndicator; - - /** - * Set the selected navigation point color. - * - * @param { Optional } color - the indicator item when selected, default value is { #FF5EA1FF }. - * @returns { ArcDotIndicator } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - selectedItemColor(color: Optional): ArcDotIndicator; - - /** - * Set the background color. - * - * @param { Optional } color - the background color, default value is { #FF404040 }. - * @returns { ArcDotIndicator } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - backgroundColor(color: Optional): ArcDotIndicator; - - /** - * Set the gradient color for the mask. - * - * @param { Optional } color - the gradient color, default start color is { #00000000 }, default end color is { #FF000000 }. - * @returns { ArcDotIndicator } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - maskColor(color: Optional): ArcDotIndicator; -} - -/** - * Provide an interface for ArcSwiper. - * - * @interface ArcSwiperInterface - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -interface ArcSwiperInterface { - /** - * Create ArcSwiper component. - * - * @param { ArcSwiperController } controller - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - (controller?: ArcSwiperController): ArcSwiperAttribute; -} - -/** - * Handler of swiper, used in OnChange. - * - * @typedef { function } IndexChangedHandler - * @param { number } index - The index of the current swiper. - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -declare type IndexChangedHandler = (index: number) => void; - -/** - * Handler of swiper, used in OnAnimationStart. - * - * @typedef { function } AnimationStartHandler - * @param { number } index - The index of the current swiper. - * @param { number } targetIndex - The index of the target swiper. - * @param { SwiperAnimationEvent } event - The extra information of the animation. - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -declare type AnimationStartHandler = (index: number, targetIndex: number, event: SwiperAnimationEvent) => void; - -/** - * Handler of swiper, used in OnAnimationEnd. - * - * @typedef { function } AnimationEndHandler - * @param { number } index - The index of the current swiper. - * @param { SwiperAnimationEvent } event - The extra information of the animation. - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -declare type AnimationEndHandler = (index: number, event: SwiperAnimationEvent) => void; - -/** - * Handler of swiper, used in OnGestureSwipe. - * - * @typedef { function } GestureSwipeHandler - * @param { number } index - The index of the current swiper. - * @param { SwiperAnimationEvent } event - The extra information of the animation. - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -declare type GestureSwipeHandler = (index: number, event: SwiperAnimationEvent) => void; - - -/** - * Defines the swiper content animated transition options. - * - * @interface SwiperContentAnimatedTransition - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -declare interface SwiperContentAnimatedTransition { - /** - * Defines the timeout of custom content transition animation after the page is moved out of the swiper. The unit is ms. - * If SwiperContentTransitionProxy.finishTransition() is not invoked, use the timeout as animation end time. - * - * @type { ?number } - * @default 0 ms - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - timeout?: number; - - /** - * Called when custom content transition animation start. - * - * @type { Callback } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - transition: Callback; -} - -/** - *The proxy object returned to the developer during the execution of the Swiper custom content transition animation. - * - * @interface SwiperContentTransitionProxy - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -declare interface SwiperContentTransitionProxy { - /** - * the index value of the swiper content selected before animation start. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - selectedIndex: number; - - /** - * The index value of the swiper content. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - index: number; - - /** - * the moving ratio of the swiper content from the start position of the swiper main axis. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - position: number; - - /** - * the swiper main axis length for calculating position. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - mainAxisLength: number; - - /** - * Notifies Swiper page the custom content transition animation is complete. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - finishTransition(): void; -} - -/** - * Defines the Arc swiper attribute functions. - * - * @extends CommonMethod - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -declare class ArcSwiperAttribute extends CommonMethod { - /** - * Set the index value of the displayed subcomponent. - * - * @param { Optional } index - The index value of the subcomponents to be displayed, default value is { 0 }. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - index(index: Optional): ArcSwiperAttribute; - - /** - * Set whether the indicator is available or set the indicator style. - * - * @param { Optional } style - The style information of the indicator or whether to - * display the indicator, default value is { true }. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - indicator(style: Optional): ArcSwiperAttribute; - - /** - * Set the animation duration of the switch in ms. - * - * @param { Optional } duration - Duration of animation, default value is { 400ms }. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - duration(duration: Optional): ArcSwiperAttribute; - - /** - * Set whether to slide vertically. - * - * @param { Optional } isVertical - The value indicates whether to slide vertically, default value is { false }. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - vertical(isVertical: Optional): ArcSwiperAttribute; - - /** - * Set whether to disable sliding function. - * - * @param { Optional } disabled - The value indicates whether the sliding function is enabled, default value is { false }. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - disableSwipe(disabled: Optional): ArcSwiperAttribute; - - /** - * Set the sensitivity of rotating crown. - * - * @param { Optional } sensitivity - The sensitivity of rotating crown, default value is { MEDIUM }. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - digitalCrownSensitivity(sensitivity: Optional): ArcSwiperAttribute; - - /** - * Called when the index value has changed. - * - * @param { Optional } handler - The handler is used to listen for index values that have changed. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - onChange(handler: Optional): ArcSwiperAttribute; - - /** - * Called when the swiper animation has started. - * - * @param { Optional } handler - The handler is used to listen for the animation has started. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - onAnimationStart(handler: Optional): ArcSwiperAttribute; - - /** - * Called when the swiper animation has ended. - * - * @param { Optional } handler - The handler is used to listen for the animation has ended. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - onAnimationEnd(handler: Optional): ArcSwiperAttribute; - - /** - * Called when swiping the switch using gestures. - * - * @param { Optional } handler - The handler is used to listen for swiping through gestures. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - onGestureSwipe(handler: Optional): ArcSwiperAttribute; - - /** - * Set effect when scrolling over edge. - * - * @param { Optional } edgeEffect - scrolling effect over edge, default value is { EdgeEffect.Spring }. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - effectMode(edgeEffect: Optional): ArcSwiperAttribute; - - /** - * Custom swiper content transition animation. - * - * @param { Optional } transition - custom content transition animation. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - customContentTransition(transition: Optional): ArcSwiperAttribute; - - /** - * Custom swiper content transition animation. - * - * @param { Optional } disabled - the value indicates whether to disable the transition animation, default value is { false }. - * @returns { ArcSwiperAttribute } - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ - disableTransitionAnimation(disabled: Optional): ArcSwiperAttribute; -} - -/** - * Defines the ArcSwiper Component that can provide the ability for sub components to swipe and display. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ -declare let ArcSwiper: ArcSwiperInterface; - -/** - * Defines ArcSwiper Component instance. - * - * @syscap SystemCapability.ArkUI.ArkUI.Circle - * @crossplatform - * @atomicservice - * @since 18 - */ +/* + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + */ +/** + * Handler of swiper controller, used in finishAnimation. + * + * @typedef { function } FinishAnimationHandler + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +declare type FinishAnimationHandler = () => void; + +/** + * Provide methods for controlling ArcSwiper component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +export class ArcSwiperController { + /** + * A constructor used to create a ArcSwiperController object. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + constructor(); + + /** + * Show next subcomponent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + showNext(); + + /** + * Show previous subcomponent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + showPrevious(); + + /** + * Finish the swiper animation. + * + * @param { FinishAnimationHandler } handler - The handler is used to listen for the end of the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + finishAnimation(handler?: FinishAnimationHandler); +} + +/** + * Declare the direction of arc indicator. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +export enum ArcDirection { + /** + * 3 o'clock direction. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + THREE_CLOCK_DIRECTION = 0, + + /** + * 6 o'clock direction. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + SIX_CLOCK_DIRECTION = 1, + + /** + * 9 o'clock direction. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + NINE_CLOCK_DIRECTION = 2, +} + +/** + * Define ArcDotIndicator, the indicator type is arc dot. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +export class ArcDotIndicator { + /** + * A constructor used to create a ArcDotIndicator object. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + constructor(); + + /** + * Set the direction of arc indicator. + * + * @param { Optional } direction - the direction of arc indicator, default value is { ArcDirection.SIX_CLOCK_DIRECTION }. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + arcDirection(direction: Optional): ArcDotIndicator; + + /** + * Set the navigation point color. + * + * @param { Optional } color - the indicator item color, default value is { #A9FFFFFF }. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + itemColor(color: Optional): ArcDotIndicator; + + /** + * Set the selected navigation point color. + * + * @param { Optional } color - the indicator item when selected, default value is { #FF5EA1FF }. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + selectedItemColor(color: Optional): ArcDotIndicator; + + /** + * Set the background color. + * + * @param { Optional } color - the background color, default value is { #FF404040 }. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + backgroundColor(color: Optional): ArcDotIndicator; + + /** + * Set the gradient color for the mask. + * + * @param { Optional } color - the gradient color, default start color is { #00000000 }, default end color is { #FF000000 }. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + maskColor(color: Optional): ArcDotIndicator; +} + +/** + * Provide an interface for ArcSwiper. + * + * @interface ArcSwiperInterface + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +interface ArcSwiperInterface { + /** + * Create ArcSwiper component. + * + * @param { ArcSwiperController } controller + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + (controller?: ArcSwiperController): ArcSwiperAttribute; +} + +/** + * Handler of swiper, used in OnChange. + * + * @typedef { function } IndexChangedHandler + * @param { number } index - The index of the current swiper. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +declare type IndexChangedHandler = (index: number) => void; + +/** + * Handler of swiper, used in OnAnimationStart. + * + * @typedef { function } AnimationStartHandler + * @param { number } index - The index of the current swiper. + * @param { number } targetIndex - The index of the target swiper. + * @param { SwiperAnimationEvent } event - The extra information of the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +declare type AnimationStartHandler = (index: number, targetIndex: number, event: SwiperAnimationEvent) => void; + +/** + * Handler of swiper, used in OnAnimationEnd. + * + * @typedef { function } AnimationEndHandler + * @param { number } index - The index of the current swiper. + * @param { SwiperAnimationEvent } event - The extra information of the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +declare type AnimationEndHandler = (index: number, event: SwiperAnimationEvent) => void; + +/** + * Handler of swiper, used in OnGestureSwipe. + * + * @typedef { function } GestureSwipeHandler + * @param { number } index - The index of the current swiper. + * @param { SwiperAnimationEvent } event - The extra information of the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +declare type GestureSwipeHandler = (index: number, event: SwiperAnimationEvent) => void; + + +/** + * Defines the swiper content animated transition options. + * + * @interface SwiperContentAnimatedTransition + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +declare interface SwiperContentAnimatedTransition { + /** + * Defines the timeout of custom content transition animation after the page is moved out of the swiper. The unit is ms. + * If SwiperContentTransitionProxy.finishTransition() is not invoked, use the timeout as animation end time. + * + * @type { ?number } + * @default 0 ms + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + timeout?: number; + + /** + * Called when custom content transition animation start. + * + * @type { Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + transition: Callback; +} + +/** + *The proxy object returned to the developer during the execution of the Swiper custom content transition animation. + * + * @interface SwiperContentTransitionProxy + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +declare interface SwiperContentTransitionProxy { + /** + * the index value of the swiper content selected before animation start. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + selectedIndex: number; + + /** + * The index value of the swiper content. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + index: number; + + /** + * the moving ratio of the swiper content from the start position of the swiper main axis. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + position: number; + + /** + * the swiper main axis length for calculating position. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + mainAxisLength: number; + + /** + * Notifies Swiper page the custom content transition animation is complete. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + finishTransition(): void; +} + +/** + * Defines the Arc swiper attribute functions. + * + * @extends CommonMethod + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +declare class ArcSwiperAttribute extends CommonMethod { + /** + * Set the index value of the displayed subcomponent. + * + * @param { Optional } index - The index value of the subcomponents to be displayed, default value is { 0 }. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + index(index: Optional): ArcSwiperAttribute; + + /** + * Set whether the indicator is available or set the indicator style. + * + * @param { Optional } style - The style information of the indicator or whether to + * display the indicator, default value is { true }. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + indicator(style: Optional): ArcSwiperAttribute; + + /** + * Set the animation duration of the switch in ms. + * + * @param { Optional } duration - Duration of animation, default value is { 400ms }. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + duration(duration: Optional): ArcSwiperAttribute; + + /** + * Set whether to slide vertically. + * + * @param { Optional } isVertical - The value indicates whether to slide vertically, default value is { false }. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + vertical(isVertical: Optional): ArcSwiperAttribute; + + /** + * Set whether to disable sliding function. + * + * @param { Optional } disabled - The value indicates whether the sliding function is enabled, default value is { false }. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + disableSwipe(disabled: Optional): ArcSwiperAttribute; + + /** + * Set the sensitivity of rotating crown. + * + * @param { Optional } sensitivity - The sensitivity of rotating crown, default value is { MEDIUM }. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + digitalCrownSensitivity(sensitivity: Optional): ArcSwiperAttribute; + + /** + * Called when the index value has changed. + * + * @param { Optional } handler - The handler is used to listen for index values that have changed. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + onChange(handler: Optional): ArcSwiperAttribute; + + /** + * Called when the swiper animation has started. + * + * @param { Optional } handler - The handler is used to listen for the animation has started. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + onAnimationStart(handler: Optional): ArcSwiperAttribute; + + /** + * Called when the swiper animation has ended. + * + * @param { Optional } handler - The handler is used to listen for the animation has ended. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + onAnimationEnd(handler: Optional): ArcSwiperAttribute; + + /** + * Called when swiping the switch using gestures. + * + * @param { Optional } handler - The handler is used to listen for swiping through gestures. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + onGestureSwipe(handler: Optional): ArcSwiperAttribute; + + /** + * Set effect when scrolling over edge. + * + * @param { Optional } edgeEffect - scrolling effect over edge, default value is { EdgeEffect.Spring }. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + effectMode(edgeEffect: Optional): ArcSwiperAttribute; + + /** + * Custom swiper content transition animation. + * + * @param { Optional } transition - custom content transition animation. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + customContentTransition(transition: Optional): ArcSwiperAttribute; + + /** + * Custom swiper content transition animation. + * + * @param { Optional } disabled - the value indicates whether to disable the transition animation, default value is { false }. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ + disableTransitionAnimation(disabled: Optional): ArcSwiperAttribute; +} + +/** + * Defines the ArcSwiper Component that can provide the ability for sub components to swipe and display. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ +/** + * Defines the ArcSwiper Component that can provide the ability for sub components to swipe and display. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @uicomponent + * @since 19 + */ +declare let ArcSwiper: ArcSwiperInterface; + +/** + * Defines ArcSwiper Component instance. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @crossplatform + * @atomicservice + * @since 18 + */ declare let ArcSwiperInstance: ArcSwiperAttribute; \ No newline at end of file diff --git a/api/@ohos.arkui.ArcSwiper.static.d.ets b/api/@ohos.arkui.ArcSwiper.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..1f0d638f95a4164abf62e97504836c2cfa5fcdf5 --- /dev/null +++ b/api/@ohos.arkui.ArcSwiper.static.d.ets @@ -0,0 +1,479 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { SwiperAnimationEvent } from './arkui/component/swiper'; +import { CrownSensitivity, EdgeEffect } from './arkui/component/enums'; +import { LinearGradient } from './arkui/component/dataPanel'; +import { ResourceColor } from './arkui/component/units'; +import { CommonMethod, Callback } from './arkui/component/common'; +import { memo, ComponentBuilder } from './arkui/stateManagement/runtime'; +/** + * Handler of swiper controller, used in finishAnimation. + * + * @typedef { function } FinishAnimationHandler + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export type FinishAnimationHandler = () => void; + +/** + * Provide methods for controlling ArcSwiper component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export declare class ArcSwiperController { + /** + * A constructor used to create a ArcSwiperController object. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + constructor(); + + /** + * Show next subcomponent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + showNext(): void; + + /** + * Show previous subcomponent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + showPrevious(): void; + + /** + * Finish the swiper animation. + * + * @param { FinishAnimationHandler } [handler] - The handler is used to listen for the end of the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + finishAnimation(handler?: FinishAnimationHandler): void; +} + +/** + * Declare the direction of arc indicator. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export declare enum ArcDirection { + /** + * 3 o'clock direction. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + THREE_CLOCK_DIRECTION = 0, + + /** + * 6 o'clock direction. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + SIX_CLOCK_DIRECTION = 1, + + /** + * 9 o'clock direction. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + NINE_CLOCK_DIRECTION = 2, +} + +/** + * Define ArcDotIndicator, the indicator type is arc dot. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export declare class ArcDotIndicator { + /** + * A constructor used to create a ArcDotIndicator object. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + constructor(); + + /** + * Set the direction of arc indicator. + * + * @param { ArcDirection | undefined } direction - the direction of arc indicator, + * default value is { ArcDirection.SIX_CLOCK_DIRECTION }, + * undefined means setting to default value. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + arcDirection(direction: ArcDirection | undefined): ArcDotIndicator; + + /** + * Set the navigation point color. + * + * @param { ResourceColor | undefined } color - the indicator item color, + * default value is { #A9FFFFFF }, undefined means setting to default value. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + itemColor(color: ResourceColor | undefined): ArcDotIndicator; + + /** + * Set the selected navigation point color. + * + * @param { ResourceColor | undefined } color - the indicator item when selected, + * default value is { #FF5EA1FF }, undefined means setting to default value. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + selectedItemColor(color: ResourceColor | undefined): ArcDotIndicator; + + /** + * Set the background color. + * + * @param { ResourceColor | undefined } color - the background color, default value is { #FF404040 }, + * undefined means setting to default value. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + backgroundColor(color: ResourceColor | undefined): ArcDotIndicator; + + /** + * Set the gradient color for the mask. + * + * @param { LinearGradient | undefined } color - the gradient color, default start color is { #00000000 }, + * default end color is { #FF000000 }, undefined means setting to default value. + * @returns { ArcDotIndicator } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + maskColor(color: LinearGradient | undefined): ArcDotIndicator; +} + +/** + * Handler of swiper, used in OnChange. + * + * @typedef { function } IndexChangedHandler + * @param { number } index - The index of the current swiper. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export type IndexChangedHandler = (index: number) => void; + +/** + * Handler of swiper, used in OnAnimationStart. + * + * @typedef { function } AnimationStartHandler + * @param { number } index - The index of the current swiper. + * @param { number } targetIndex - The index of the target swiper. + * @param { SwiperAnimationEvent } event - The extra information of the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export type AnimationStartHandler = (index: number, targetIndex: number, event: SwiperAnimationEvent) => void; + +/** + * Handler of swiper, used in OnAnimationEnd. + * + * @typedef { function } AnimationEndHandler + * @param { number } index - The index of the current swiper. + * @param { SwiperAnimationEvent } event - The extra information of the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export type AnimationEndHandler = (index: number, event: SwiperAnimationEvent) => void; + +/** + * Handler of swiper, used in OnGestureSwipe. + * + * @typedef { function } GestureSwipeHandler + * @param { number } index - The index of the current swiper. + * @param { SwiperAnimationEvent } event - The extra information of the animation. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export type GestureSwipeHandler = (index: number, event: SwiperAnimationEvent) => void; + + +/** + * Defines the swiper content animated transition options. + * + * @interface ArcSwiperContentAnimatedTransition + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export declare interface ArcSwiperContentAnimatedTransition { + /** + * Defines the timeout of custom content transition animation after the page is moved out of the swiper. + * The unit is ms. + * If ArcSwiperContentTransitionProxy.finishTransition() is not invoked, use the timeout as animation end time. + * + * @type { ?number } + * @default 0 ms + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + timeout?: number; + + /** + * Called when custom content transition animation start. + * + * @type { Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + transition: Callback; +} + +/** + *The proxy object returned to the developer during the execution of the Swiper custom content transition animation. + * + * @interface ArcSwiperContentTransitionProxy + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export declare interface ArcSwiperContentTransitionProxy { + /** + * the index value of the swiper content selected before animation start. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + selectedIndex: number; + + /** + * The index value of the swiper content. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + index: number; + + /** + * the moving ratio of the swiper content from the start position of the swiper main axis. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + position: number; + + /** + * the swiper main axis length for calculating position. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + mainAxisLength: number; + + /** + * Notifies Swiper page the custom content transition animation is complete. + * + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + finishTransition(): void; +} + +/** + * Defines the Arc swiper attribute functions. + * + * @extends CommonMethod + * @typedef ArcSwiperAttribute + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ +export declare interface ArcSwiperAttribute extends CommonMethod { + /** + * Set the index value of the displayed subcomponent. + * + * @param { number | undefined } index - The index value of the subcomponents to be displayed, + * default value is { 0 }, undefined means setting to default value. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default index(index: number | undefined): this; + + /** + * Set whether the indicator is available or set the indicator style. + * + * @param { ArcDotIndicator | boolean | undefined } style - The style information of the indicator or whether to + * display the indicator, default value is { true }, undefined means setting to default value. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default indicator(style: ArcDotIndicator | boolean | undefined): this; + + /** + * Set the animation duration of the switch in ms. + * + * @param { number | undefined } duration - Duration of animation, default value is { 400ms }, + * undefined means setting to default value. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default duration(duration: number | undefined): this; + + /** + * Set whether to slide vertically. + * + * @param { boolean | undefined } isVertical - The value indicates whether to slide vertically, + * default value is { false }, undefined means setting to default value. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default vertical(isVertical: boolean | undefined): this; + + /** + * Set whether to disable sliding function. + * + * @param { boolean | undefined } disabled - The value indicates whether the sliding function is enabled, + * default value is { false }, undefined means setting to default value. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default disableSwipe(disabled: boolean | undefined): this; + + /** + * Set the sensitivity of rotating crown. + * + * @param { CrownSensitivity | undefined } sensitivity - The sensitivity of rotating crown, + * default value is { MEDIUM }, undefined means setting to default value. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default digitalCrownSensitivity(sensitivity: CrownSensitivity | undefined): this; + + /** + * Called when the index value has changed. + * + * @param { IndexChangedHandler | undefined } handler - The handler is used to listen for index + * values that have changed, undefined means clear handler. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default onChange(handler: IndexChangedHandler | undefined): this; + + /** + * Called when the swiper animation has started. + * + * @param { AnimationStartHandler | undefined } handler - The handler is used to listen for + * the animation has started, undefined means clear handler. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default onAnimationStart(handler: AnimationStartHandler | undefined): this; + + /** + * Called when the swiper animation has ended. + * + * @param { AnimationEndHandler | undefined } handler - The handler is used to listen for the animation has ended, + * undefined means clear handler. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default onAnimationEnd(handler: AnimationEndHandler | undefined): this; + + /** + * Called when swiping the switch using gestures. + * + * @param { GestureSwipeHandler | undefined } handler - The handler is used to listen for swiping through gestures, + * undefined means clear handler. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default onGestureSwipe(handler: GestureSwipeHandler | undefined): this; + + /** + * Set effect when scrolling over edge. + * + * @param { EdgeEffect | undefined } edgeEffect - scrolling effect over edge, + * default value is { EdgeEffect.Spring }, undefined means setting to default value. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default effectMode(edgeEffect: EdgeEffect | undefined): this; + + /** + * Custom swiper content transition animation. + * + * @param { ArcSwiperContentAnimatedTransition | undefined } transition - custom content transition animation, + * undefined means clear transition. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default customContentTransition(transition: ArcSwiperContentAnimatedTransition | undefined): this; + + /** + * Custom swiper content transition animation. + * + * @param { boolean | undefined } disabled - the value indicates whether to disable the transition animation, + * default value is { false }, undefined means setting to default value. + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + default disableTransitionAnimation(disabled: boolean | undefined): this; +} + +/** + * Defines ArcSwiper Component + * + * @param { ArcSwiperController } [controller] - ArcSwiper constructor options + * @param { function } [content_] - container + * @returns { ArcSwiperAttribute } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +@memo +@ComponentBuilder +export declare function ArcSwiper( + controller?: ArcSwiperController, + @memo + content_?: () => void, +): ArcSwiperAttribute \ No newline at end of file diff --git a/api/@ohos.arkui.StateManagement.d.ts b/api/@ohos.arkui.StateManagement.d.ts index 1b53279d976244bc51cb7de750e2316115561823..ef703280fd678365d3598dc9777b77b41fb53de8 100644 --- a/api/@ohos.arkui.StateManagement.d.ts +++ b/api/@ohos.arkui.StateManagement.d.ts @@ -18,7 +18,7 @@ * @kit ArkUI */ -import contextConstant from '@ohos.app.ability.contextConstant' +import contextConstant from '@ohos.app.ability.contextConstant'; /** * Function that returns default creator. @@ -430,5 +430,5 @@ export declare class MutableBinding { * @atomicservice * @since 20 */ - set value(newValue: T): void; + set value(newValue: T); } \ No newline at end of file diff --git a/api/@ohos.arkui.UIContext.d.ts b/api/@ohos.arkui.UIContext.d.ts index cba990663f4ffad21ec4a2a3d59be81170fc0c6c..648a6a9a5a32841f78380828463e4104282daf9b 100755 --- a/api/@ohos.arkui.UIContext.d.ts +++ b/api/@ohos.arkui.UIContext.d.ts @@ -25,11 +25,9 @@ import type inspector from './@ohos.arkui.inspector'; import promptAction, { LevelOrder } from './@ohos.promptAction'; import router from './@ohos.router'; import type componentUtils from './@ohos.arkui.componentUtils'; -/*** if arkts 1.1 */ import { ComponentContent, FrameNode, Frame } from './@ohos.arkui.node'; import type { AnimatorOptions, AnimatorResult } from './@ohos.animator'; import type observer from './@ohos.arkui.observer'; -/*** endif */ import { SimpleAnimatorOptions } from './@ohos.animator'; import type { Callback, AsyncCallback } from './@ohos.base'; import { MeasureOptions } from './@ohos.measure'; @@ -39,29 +37,6 @@ import image from './@ohos.multimedia.image'; import type common from './@ohos.app.ability.common'; import type pointer from './@ohos.multimodalInput.pointer'; -/*** if arkts 1.2 */ -import { ComponentContent, FrameNode, Frame } from '@ohos.arkui.node'; -import type observer from '@ohos.arkui.observer'; -import { AnimatorOptions, AnimatorResult } from './@ohos.animator'; -import { - ClickEvent, ExpectedFrameRateRange, DragItemInfo, AnimateParam, KeyframeAnimateParam, - KeyframeState, SheetOptions, PopupCommonOptions, MenuOptions, KeyEvent, Optional -} from './arkui/component/common'; -import { CustomBuilder } from './arkui/component/builder'; -import { GestureEvent, GestureRecognizer } from './arkui/component/gesture'; -import { ResourceStr, SizeOptions, VoidCallback } from './arkui/component/units'; -import { Nullable, Color, FontStyle, WidthBreakpoint, HeightBreakpoint, PixelRoundMode } from './arkui/component/enums'; -import { TimePickerDialogOptions } from './arkui/component/timePicker'; -import { AlertDialogParamWithConfirm, AlertDialogParamWithButtons, AlertDialogParamWithOptions } from './arkui/component/alertDialog'; -import { ActionSheetOptions } from './arkui/component/actionSheet'; -import { TextPickerDialogOptions } from './arkui/component/textPicker'; -import { LocalStorage } from './arkui/stateManagement/storage/localStorage'; -import { DatePickerDialogOptions } from './arkui/component/datePicker'; -import { TabsController } from './arkui/component/tabs'; -import { Scroller } from './arkui/component/scroll'; -import { KeyProcessingMode } from './arkui/component/focus'; -import { TextMenuOptions } from './arkui/component/textCommon'; -/*** endif */ /** * class Font * @@ -80,10 +55,9 @@ import { TextMenuOptions } from './arkui/component/textCommon'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ -export declare class Font { +export class Font { /** * Register a customized font in the FontManager. * @@ -99,8 +73,7 @@ export declare class Font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ registerFont(options: font.FontOptions): void; @@ -120,8 +93,7 @@ export declare class Font { * @returns { Array } A list of font names * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getSystemFontList(): Array; @@ -138,8 +110,7 @@ export declare class Font { * @returns { font.FontInfo } Returns the font info * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getFontByName(fontName: string): font.FontInfo; } @@ -157,10 +128,9 @@ export declare class Font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ -export declare class MediaQuery { +export class MediaQuery { /** * Sets the media query criteria and returns the corresponding listening handle * @@ -178,8 +148,7 @@ export declare class MediaQuery { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ matchMediaSync(condition: string): mediaQuery.MediaQueryListener; } @@ -195,10 +164,9 @@ export declare class MediaQuery { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ -export declare class UIInspector { +export class UIInspector { /** * Sets the component after layout or draw criteria and returns the corresponding listening handle * @param { string } id - component id. @@ -214,8 +182,7 @@ export declare class UIInspector { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ createComponentObserver(id: string): inspector.ComponentObserver; } @@ -241,10 +208,9 @@ export declare class UIInspector { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -export declare class Router { +export class Router { /** * Navigates to a specified page in the application. * @@ -276,8 +242,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ pushUrl(options: router.RouterOptions, callback: AsyncCallback): void; @@ -312,8 +277,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ pushUrl(options: router.RouterOptions): Promise; @@ -350,8 +314,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ pushUrl(options: router.RouterOptions, mode: router.RouterMode, callback: AsyncCallback): void; @@ -388,8 +351,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ pushUrl(options: router.RouterOptions, mode: router.RouterMode): Promise; @@ -422,8 +384,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ replaceUrl(options: router.RouterOptions, callback: AsyncCallback): void; @@ -456,8 +417,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ replaceUrl(options: router.RouterOptions): Promise; @@ -492,8 +452,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ replaceUrl(options: router.RouterOptions, mode: router.RouterMode, callback: AsyncCallback): void; @@ -528,8 +487,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ replaceUrl(options: router.RouterOptions, mode: router.RouterMode): Promise; @@ -556,8 +514,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ back(options?: router.RouterOptions): void; @@ -569,8 +526,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ back(index: number, params?: Object): void; @@ -587,8 +543,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ clear(): void; @@ -607,8 +562,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getLength(): string; @@ -627,8 +581,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getState(): router.RouterState; @@ -640,8 +593,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getStateByIndex(index: number): router.RouterState | undefined; @@ -653,8 +605,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getStateByUrl(url: string): Array; @@ -683,8 +634,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showAlertBeforeBackPage(options: router.EnableAlertOptions): void; @@ -701,8 +651,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ hideAlertBeforeBackPage(): void; @@ -721,8 +670,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getParams(): Object; @@ -755,8 +703,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ pushNamedRoute(options: router.NamedRouterOptions, callback: AsyncCallback): void; @@ -789,8 +736,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ pushNamedRoute(options: router.NamedRouterOptions): Promise; @@ -825,8 +771,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ pushNamedRoute(options: router.NamedRouterOptions, mode: router.RouterMode, callback: AsyncCallback): void; @@ -861,8 +806,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ pushNamedRoute(options: router.NamedRouterOptions, mode: router.RouterMode): Promise; @@ -893,8 +837,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ replaceNamedRoute(options: router.NamedRouterOptions, callback: AsyncCallback): void; @@ -922,8 +865,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ replaceNamedRoute(options: router.NamedRouterOptions): Promise; @@ -953,8 +895,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ replaceNamedRoute(options: router.NamedRouterOptions, mode: router.RouterMode, callback: AsyncCallback): void; @@ -987,8 +928,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ replaceNamedRoute(options: router.NamedRouterOptions, mode: router.RouterMode): Promise; } @@ -1000,8 +940,7 @@ export declare class Router { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ declare type CustomBuilderWithId = (id: number) => void; @@ -1012,8 +951,7 @@ declare type CustomBuilderWithId = (id: number) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ export interface TargetInfo { /** @@ -1023,8 +961,7 @@ export interface TargetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ id: string | number; @@ -1035,8 +972,7 @@ export interface TargetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ componentId?: number; } @@ -1054,10 +990,9 @@ export interface TargetInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ -export declare class PromptAction { +export class PromptAction { /** * Displays the notification text. * @@ -1083,8 +1018,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showToast(options: promptAction.ShowToastOptions): void; @@ -1101,8 +1035,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ openToast(options: promptAction.ShowToastOptions): Promise; @@ -1119,8 +1052,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ closeToast(toastId: number): void; @@ -1167,8 +1099,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ showDialog(options: promptAction.ShowDialogOptions, callback: AsyncCallback): void; @@ -1200,8 +1131,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showDialog(options: promptAction.ShowDialogOptions): Promise; @@ -1238,8 +1168,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showActionMenu(options: promptAction.ActionMenuOptions, callback: AsyncCallback): void; @@ -1271,8 +1200,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showActionMenu(options: promptAction.ActionMenuOptions): Promise; @@ -1291,8 +1219,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ openCustomDialog(dialogContent: ComponentContent, options?: promptAction.BaseDialogOptions): Promise; @@ -1314,8 +1241,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ openCustomDialogWithController(dialogContent: ComponentContent, controller: promptAction.DialogController, options?: promptAction.BaseDialogOptions): Promise; @@ -1336,8 +1262,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ updateCustomDialog(dialogContent: ComponentContent, options: promptAction.BaseDialogOptions): Promise; @@ -1355,8 +1280,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ closeCustomDialog(dialogContent: ComponentContent): Promise; @@ -1375,8 +1299,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ openCustomDialog(options: promptAction.CustomDialogOptions): Promise; @@ -1397,8 +1320,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ presentCustomDialog(builder: CustomBuilder | CustomBuilderWithId, controller?: promptAction.DialogController, options?: promptAction.DialogOptions): Promise; @@ -1415,8 +1337,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ closeCustomDialog(dialogId: number): void; @@ -1427,8 +1348,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ getTopOrder(): LevelOrder; @@ -1439,8 +1359,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ getBottomOrder(): LevelOrder; @@ -1462,8 +1381,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ openPopup(content: ComponentContent, target: TargetInfo, options?: PopupCommonOptions): Promise; @@ -1485,8 +1403,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ updatePopup(content: ComponentContent, options: PopupCommonOptions, partialUpdate?: boolean): Promise; @@ -1504,8 +1421,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ closePopup(content: ComponentContent): Promise; @@ -1527,8 +1443,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ openMenu(content: ComponentContent, target: TargetInfo, options?: MenuOptions): Promise; @@ -1550,8 +1465,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ updateMenu(content: ComponentContent, options: MenuOptions, partialUpdate?: boolean): Promise; @@ -1569,8 +1483,7 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ closeMenu(content: ComponentContent): Promise; } @@ -1586,10 +1499,9 @@ export declare class PromptAction { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -type ClickEventListenerCallback = (event: ClickEvent, node?: FrameNode) => void; +declare type ClickEventListenerCallback = (event: ClickEvent, node?: FrameNode) => void; /** * Defines the callback type used in UIObserver watch pan event. @@ -1603,10 +1515,9 @@ type ClickEventListenerCallback = (event: ClickEvent, node?: FrameNode) => void; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ -type PanListenerCallback = (event: GestureEvent, current: GestureRecognizer, node?: FrameNode) => void; +declare type PanListenerCallback = (event: GestureEvent, current: GestureRecognizer, node?: FrameNode) => void; /** * Defines the callback type used in UIObserver watch gesture. @@ -1619,10 +1530,9 @@ type PanListenerCallback = (event: GestureEvent, current: GestureRecognizer, nod * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -type GestureEventListenerCallback = (event: GestureEvent, node?: FrameNode) => void; +declare type GestureEventListenerCallback = (event: GestureEvent, node?: FrameNode) => void; /** * Defines the type can be used for identiting the node, for the string type, it's the inspector id @@ -1674,8 +1584,7 @@ export declare type GestureListenerCallback = (info: GestureTriggerInfo) => void * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export interface PageInfo { /** @@ -1684,8 +1593,7 @@ export interface PageInfo { * @type { ?observer.RouterPageInfo } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ routerPageInfo?: observer.RouterPageInfo; @@ -1695,8 +1603,7 @@ export interface PageInfo { * @type { ?observer.NavDestinationInfo } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ navDestinationInfo?: observer.NavDestinationInfo; } @@ -1708,8 +1615,7 @@ export interface PageInfo { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ export interface OverlayManagerOptions { /** @@ -1720,12 +1626,11 @@ export interface OverlayManagerOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ renderRootOverlay?: boolean; -/** + /** * Set whether support backPressed event or not. * * @type { ?boolean } @@ -1743,7 +1648,6 @@ export interface OverlayManagerOptions { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ enableBackPressedEvent?: boolean; } @@ -1767,16 +1671,7 @@ export interface OverlayManagerOptions { * @atomicservice * @since 12 */ -/** - * Register callbacks to observe ArkUI behavior. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ -export declare class UIObserver { +export class UIObserver { /** * Subscribes to status changes of this **NavDestination** component. * @@ -1806,24 +1701,6 @@ export declare class UIObserver { */ on(type: 'navDestinationUpdate', options: { navigationId: ResourceStr }, callback: Callback): void; - /** - * Registers a callback function to be called when the navigation destination is updated. - * - * @param { 'navDestinationUpdate' } type - The type of event to listen for. Must be 'navDestinationUpdate'. - * @param { observer.NavDestinationSwitchObserverOptions } options - The options object. - * @param { Callback } callback - The callback function to be called when the navigation destination is updated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - on( - type: 'navDestinationUpdate', - options: observer.NavDestinationSwitchObserverOptions, - callback: Callback - ): void; - /** * Removes a callback function that was previously registered with `on()`. * @@ -1848,25 +1725,6 @@ export declare class UIObserver { * @since 12 */ off(type: 'navDestinationUpdate', options: { navigationId: ResourceStr }, callback?: Callback): void; - - /** - * Removes a callback function that was previously registered with `on()`. - * - * @param { 'navDestinationUpdate' } type - The type of event to remove the listener for. Must be 'navDestinationUpdate'. - * @param { observer.NavDestinationSwitchObserverOptions } options - The options object. - * @param { Callback } callback - The callback function to remove. If not provided, all callbacks for the given event type and - * navigation ID will be removed. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - off( - type: 'navDestinationUpdate', - options: observer.NavDestinationSwitchObserverOptions, - callback?: Callback - ): void; /** * Subscribes to status changes of this **NavDestination** component. @@ -1891,8 +1749,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'navDestinationUpdate', callback: Callback): void; @@ -1915,8 +1772,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'navDestinationUpdate', callback?: Callback): void; @@ -1956,8 +1812,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'scrollEvent', options: observer.ObserverOptions, callback: Callback): void; @@ -1971,8 +1826,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'scrollEvent', options: observer.ObserverOptions, callback?: Callback): void; @@ -1984,8 +1838,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'scrollEvent', callback: Callback): void; @@ -1998,8 +1851,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'scrollEvent', callback?: Callback): void; @@ -2022,8 +1874,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'routerPageUpdate', callback: Callback): void; @@ -2046,8 +1897,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'routerPageUpdate', callback?: Callback): void; @@ -2059,8 +1909,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'densityUpdate', callback: Callback): void; @@ -2073,8 +1922,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'densityUpdate', callback?: Callback): void; @@ -2086,8 +1934,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'willDraw', callback: Callback): void; @@ -2100,8 +1947,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'willDraw', callback?: Callback): void; @@ -2113,8 +1959,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'didLayout', callback: Callback): void; @@ -2127,8 +1972,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'didLayout', callback?: Callback): void; @@ -2141,8 +1985,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on( type: 'navDestinationSwitch', @@ -2158,8 +2001,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off( type: 'navDestinationSwitch', @@ -2176,8 +2018,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on( type: 'navDestinationSwitch', @@ -2195,8 +2036,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off( type: 'navDestinationSwitch', @@ -2213,8 +2053,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'willClick', callback: ClickEventListenerCallback): void; @@ -2227,8 +2066,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'willClick', callback?: ClickEventListenerCallback): void; @@ -2241,8 +2079,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'didClick', callback: ClickEventListenerCallback): void; @@ -2255,8 +2092,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'didClick', callback?: ClickEventListenerCallback): void; @@ -2269,8 +2105,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'willClick', callback: GestureEventListenerCallback): void; @@ -2283,8 +2118,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'willClick', callback?: GestureEventListenerCallback): void; @@ -2297,8 +2131,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'didClick', callback: GestureEventListenerCallback): void; @@ -2311,8 +2144,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'didClick', callback?: GestureEventListenerCallback): void; @@ -2325,8 +2157,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ on(type: 'beforePanStart', callback: PanListenerCallback): void; @@ -2339,8 +2170,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ off(type: 'beforePanStart', callback?: PanListenerCallback): void; @@ -2353,8 +2183,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ on(type: 'beforePanEnd', callback: PanListenerCallback): void; @@ -2367,8 +2196,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ off(type: 'beforePanEnd', callback?: PanListenerCallback): void; @@ -2381,8 +2209,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ on(type: 'afterPanStart', callback: PanListenerCallback): void; @@ -2395,8 +2222,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ off(type: 'afterPanStart', callback?: PanListenerCallback): void; @@ -2409,8 +2235,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ on(type: 'afterPanEnd', callback: PanListenerCallback): void; @@ -2423,8 +2248,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'19','1.2':'20' } - * @arkts 1.1&1.2 + * @since 19 */ off(type: 'afterPanEnd', callback?: PanListenerCallback): void; @@ -2438,8 +2262,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'tabContentUpdate', options: observer.ObserverOptions, callback: Callback): void; @@ -2453,8 +2276,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'tabContentUpdate', options: observer.ObserverOptions, callback?: Callback): void; @@ -2467,8 +2289,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'tabContentUpdate', callback: Callback): void; @@ -2481,8 +2302,7 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'tabContentUpdate', callback?: Callback): void; @@ -2574,10 +2394,9 @@ export declare class UIObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ -export declare class ComponentUtils { +export class ComponentUtils { /** * Provide the ability to obtain the coordinates and size of component drawing areas. * @@ -2595,8 +2414,7 @@ export declare class ComponentUtils { * @throws { BusinessError } 100001 - UI execution context not found. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getRectangleById(id: string): componentUtils.ComponentInfo; } @@ -2606,10 +2424,9 @@ export declare class ComponentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -export declare class OverlayManager { +export class OverlayManager { /** * Adds a specified ComponentContent node to the OverlayManager. * @@ -2629,8 +2446,7 @@ export declare class OverlayManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ addComponentContent(content: ComponentContent, index?: number): void; @@ -2648,8 +2464,7 @@ export declare class OverlayManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ addComponentContentWithOrder(content: ComponentContent, levelOrder?: LevelOrder): void; @@ -2660,8 +2475,7 @@ export declare class OverlayManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ removeComponentContent(content: ComponentContent): void; @@ -2672,8 +2486,7 @@ export declare class OverlayManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ showComponentContent(content: ComponentContent): void; @@ -2684,8 +2497,7 @@ export declare class OverlayManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ hideComponentContent(content: ComponentContent): void; @@ -2695,8 +2507,7 @@ export declare class OverlayManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ showAllComponentContents(): void; @@ -2706,8 +2517,7 @@ export declare class OverlayManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ hideAllComponentContents(): void; } @@ -2725,8 +2535,7 @@ export declare class OverlayManager { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export interface AtomicServiceBar { /** @@ -2735,8 +2544,7 @@ export interface AtomicServiceBar { * @param { boolean } visible - whether this bar is visible. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ setVisible(visible: boolean): void; @@ -2753,8 +2561,7 @@ export interface AtomicServiceBar { * @param { Nullable< Color | number | string> } color - the color to set, undefined indicates using default. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ setBackgroundColor(color: Nullable< Color | number | string>): void; @@ -2771,8 +2578,7 @@ export interface AtomicServiceBar { * @param { string } content - the content of the bar. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ setTitleContent(content: string): void; @@ -2789,8 +2595,7 @@ export interface AtomicServiceBar { * @param { FontStyle } font - the font style of the bar's title. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ setTitleFontStyle(font: FontStyle): void; @@ -2807,8 +2612,7 @@ export interface AtomicServiceBar { * @param { Nullable< Color | number | string> } color - the color to set to icon, undefined indicates using default. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ setIconColor(color: Nullable< Color | number | string>): void; @@ -2819,8 +2623,7 @@ export interface AtomicServiceBar { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ getBarRect(): Frame; } @@ -2906,18 +2709,16 @@ export interface GestureObserverConfigs { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -export declare class DynamicSyncScene { +export class DynamicSyncScene { /** * Sets the FrameRateRange of the DynamicSyncScene. * * @param { ExpectedFrameRateRange } range - The range of frameRate. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ setFrameRateRange(range: ExpectedFrameRateRange): void; @@ -2927,8 +2728,7 @@ export declare class DynamicSyncScene { * @returns { ExpectedFrameRateRange } The range of frameRate. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getFrameRateRange(): ExpectedFrameRateRange; } @@ -2939,18 +2739,16 @@ export declare class DynamicSyncScene { * @extends DynamicSyncScene * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -export declare class SwiperDynamicSyncScene extends DynamicSyncScene { +export class SwiperDynamicSyncScene extends DynamicSyncScene { /** * Type of the SwiperDynamicSyncSceneType. * @type { SwiperDynamicSyncSceneType } * @readonly * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ readonly type: SwiperDynamicSyncSceneType; } @@ -2961,8 +2759,7 @@ export declare class SwiperDynamicSyncScene extends DynamicSyncScene { * @extends DynamicSyncScene * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ export class MarqueeDynamicSyncScene extends DynamicSyncScene { /** @@ -2971,8 +2768,7 @@ export class MarqueeDynamicSyncScene extends DynamicSyncScene { * @readonly * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ readonly type: MarqueeDynamicSyncSceneType; } @@ -2993,8 +2789,7 @@ export class MarqueeDynamicSyncScene extends DynamicSyncScene { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ export declare class DragController { /** @@ -3040,8 +2835,7 @@ export declare class DragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ executeDrag(custom: CustomBuilder | DragItemInfo, dragInfo: dragController.DragInfo, callback: AsyncCallback): void; @@ -3086,8 +2880,7 @@ export declare class DragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ executeDrag(custom: CustomBuilder | DragItemInfo, dragInfo: dragController.DragInfo) : Promise; @@ -3132,8 +2925,7 @@ export declare class DragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ createDragAction(customArray: Array, dragInfo: dragController.DragInfo): dragController.DragAction; @@ -3156,8 +2948,7 @@ export declare class DragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ getDragPreview(): dragController.DragPreview; @@ -3173,8 +2964,7 @@ export declare class DragController { * @param { boolean } enable - Indicating enable drag event strict reporting or not. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ setDragEventStrictReportingEnabled(enable: boolean): void; @@ -3183,8 +2973,7 @@ export declare class DragController { * @param { dragController.DragStartRequestStatus } requestStatus - Status about the drag start behavior. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ notifyDragStartRequest(requestStatus: dragController.DragStartRequestStatus): void; @@ -3196,8 +2985,7 @@ export declare class DragController { * @throws { BusinessError } 190004 - Operation failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ cancelDataLoading(key: string): void; @@ -3235,10 +3023,9 @@ export declare class DragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -export declare class MeasureUtils { +export class MeasureUtils { /** * Obtains the width of the specified text in a single line layout. * @@ -3247,8 +3034,7 @@ export declare class MeasureUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ measureText(options: MeasureOptions): number; @@ -3260,8 +3046,7 @@ export declare class MeasureUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ measureTextSize(options: MeasureOptions): SizeOptions; @@ -3281,16 +3066,14 @@ export declare class MeasureUtils { * class FocusController * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -export declare class FocusController { +export class FocusController { /** * clear focus to the root container. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ clearFocus(): void; @@ -3302,8 +3085,7 @@ export declare class FocusController { * @throws { BusinessError } 150003 - the component is not on tree or does not exist. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ requestFocus(key: string): void; @@ -3314,8 +3096,7 @@ export declare class FocusController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ activate(isActive: boolean, autoInactive?: boolean): void; @@ -3327,7 +3108,7 @@ export declare class FocusController { * @atomicservice * @since 20 */ - isActive(): boolean + isActive(): boolean; /** * Set whether to enable autofocus transfer. @@ -3335,8 +3116,7 @@ export declare class FocusController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ setAutoFocusTransfer(isAutoFocusTransfer: boolean): void; @@ -3346,8 +3126,7 @@ export declare class FocusController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ setKeyProcessingMode(mode: KeyProcessingMode): void; } @@ -3358,8 +3137,7 @@ export declare class FocusController { * @typedef {pointer.PointerStyle} PointerStyle * @syscap SystemCapability.MultimodalInput.Input.Pointer * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export type PointerStyle = pointer.PointerStyle; @@ -3369,18 +3147,16 @@ export type PointerStyle = pointer.PointerStyle; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ -export declare class CursorController { +export class CursorController { /** * Restore default cursor. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ restoreDefault(): void; /** @@ -3390,8 +3166,7 @@ export declare class CursorController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ setCursor(value: PointerStyle): void; } @@ -3402,8 +3177,7 @@ export declare class CursorController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export declare class ContextMenuController { /** @@ -3412,8 +3186,7 @@ export declare class ContextMenuController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ close(): void; } @@ -3426,16 +3199,7 @@ export declare class ContextMenuController { * @atomicservice * @since 12 */ -/** - * Class FrameCallback - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ -export declare abstract class FrameCallback { +export abstract class FrameCallback { /** * Call when a new display frame is being rendered. * @@ -3444,8 +3208,7 @@ export declare abstract class FrameCallback { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ onFrame(frameTimeInNano: number): void; @@ -3457,8 +3220,7 @@ export declare abstract class FrameCallback { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ onIdle(timeLeftInNano: number): void; } @@ -3472,8 +3234,7 @@ export declare abstract class FrameCallback { * @StageModelOnly * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export type Context = common.Context; @@ -3481,8 +3242,7 @@ export type Context = common.Context; * class ComponentSnapshot * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export declare class ComponentSnapshot { /** @@ -3499,8 +3259,7 @@ export declare class ComponentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ get(id: string, callback: AsyncCallback, options?: componentSnapshot.SnapshotOptions): void; @@ -3518,8 +3277,7 @@ export declare class ComponentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ get(id: string, options?: componentSnapshot.SnapshotOptions): Promise; @@ -3541,8 +3299,7 @@ export declare class ComponentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ createFromBuilder(builder: CustomBuilder, callback: AsyncCallback, delay?: number, checkImageStatus?: boolean, options?: componentSnapshot.SnapshotOptions): void; @@ -3565,8 +3322,7 @@ export declare class ComponentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ createFromBuilder(builder: CustomBuilder, delay?: number, checkImageStatus?: boolean, options?: componentSnapshot.SnapshotOptions): Promise; @@ -3588,8 +3344,7 @@ export declare class ComponentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getSync(id: string, options?: componentSnapshot.SnapshotOptions): image.PixelMap; @@ -3607,8 +3362,7 @@ export declare class ComponentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ getWithUniqueId(uniqueId: number, options?: componentSnapshot.SnapshotOptions): Promise; @@ -3629,8 +3383,7 @@ export declare class ComponentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ getSyncWithUniqueId(uniqueId: number, options?: componentSnapshot.SnapshotOptions): image.PixelMap; @@ -3652,8 +3405,7 @@ export declare class ComponentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ createFromComponent(content: ComponentContent, delay?: number, checkImageStatus?: boolean, options?: componentSnapshot.SnapshotOptions): Promise; @@ -3694,16 +3446,7 @@ export declare class ComponentSnapshot { * @atomicservice * @since 11 */ -/** - * class UIContext - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ -export declare class UIContext { +export class UIContext { /** * Checks whether the UiContext object ia available. * @@ -3730,8 +3473,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getFont(): Font; @@ -3750,8 +3492,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getMediaQuery(): MediaQuery; @@ -3768,8 +3509,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getUIInspector(): UIInspector; @@ -3784,8 +3524,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getFilteredInspectorTree(filters?: Array): string; @@ -3802,8 +3541,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getFilteredInspectorTreeById(id: string, depth: number, filters?: Array): string; @@ -3822,8 +3560,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getRouter(): Router; @@ -3842,8 +3579,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getPromptAction(): PromptAction; @@ -3860,8 +3596,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getComponentUtils(): ComponentUtils; @@ -3880,8 +3615,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getUIObserver(): UIObserver; @@ -3892,8 +3626,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getOverlayManager(): OverlayManager; @@ -3905,8 +3638,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ setOverlayManagerOptions(options: OverlayManagerOptions): boolean; @@ -3917,8 +3649,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ getOverlayManagerOptions(): OverlayManagerOptions; @@ -3947,8 +3678,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ createAnimator(options: AnimatorOptions): AnimatorResult; @@ -3964,8 +3694,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ createAnimator(options: AnimatorOptions | SimpleAnimatorOptions): AnimatorResult; @@ -3986,8 +3715,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ animateTo(value: AnimateParam, event: () => void): void; @@ -4007,8 +3735,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showAlertDialog(options: AlertDialogParamWithConfirm | AlertDialogParamWithButtons | AlertDialogParamWithOptions): void; @@ -4027,8 +3754,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showActionSheet(value: ActionSheetOptions): void; @@ -4047,8 +3773,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showDatePickerDialog(options: DatePickerDialogOptions): void; @@ -4067,8 +3792,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showTimePickerDialog(options: TimePickerDialogOptions): void; @@ -4087,8 +3811,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ showTextPickerDialog(options: TextPickerDialogOptions): void; @@ -4107,8 +3830,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ runScopedTask(callback: () => void): void; @@ -4120,8 +3842,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ setKeyboardAvoidMode(value: KeyboardAvoidMode): void; @@ -4131,8 +3852,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getKeyboardAvoidMode(): KeyboardAvoidMode; @@ -4143,8 +3863,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ setPixelRoundMode(mode: PixelRoundMode): void; @@ -4155,8 +3874,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ getPixelRoundMode(): PixelRoundMode; @@ -4168,8 +3886,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'15','1.2':'20' } - * @arkts 1.1&1.2 + * @since 15 */ dispatchKeyEvent(node: number | string, event: KeyEvent): boolean; @@ -4179,8 +3896,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ getAtomicServiceBar(): Nullable; @@ -4203,8 +3919,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ getDragController(): DragController; @@ -4214,8 +3929,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getMeasureUtils(): MeasureUtils; @@ -4236,8 +3950,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ keyframeAnimateTo(param: KeyframeAnimateParam, keyframes: Array): void; @@ -4246,8 +3959,7 @@ export declare class UIContext { * @returns { FocusController } the FocusController * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getFocusController(): FocusController; @@ -4259,8 +3971,7 @@ export declare class UIContext { * and the system will automatically insert transition animations for state changes caused by the closure function. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ animateToImmediately(param: AnimateParam, event: Callback): void; @@ -4272,8 +3983,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getFrameNodeById(id: string): FrameNode | null; @@ -4285,8 +3995,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getAttachedFrameNodeById(id: string): FrameNode | null; @@ -4305,8 +4014,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getFrameNodeByUniqueId(id: number): FrameNode | null; @@ -4320,8 +4028,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getPageInfoByUniqueId(id: number): PageInfo; @@ -4334,8 +4041,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getNavigationInfoByUniqueId(id: number): observer.NavigationInfo | undefined; @@ -4347,8 +4053,7 @@ export declare class UIContext { * set values less than 0 to 0 and values greater than 1 to 1. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ setDynamicDimming(id: string, value: number): void; @@ -4359,8 +4064,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getCursorController(): CursorController; @@ -4371,8 +4075,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getContextMenuController(): ContextMenuController; @@ -4381,8 +4084,7 @@ export declare class UIContext { * @returns { ComponentSnapshot } the ComponentSnapshot * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getComponentSnapshot(): ComponentSnapshot; @@ -4392,8 +4094,7 @@ export declare class UIContext { * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ vp2px(value: number): number; @@ -4403,8 +4104,7 @@ export declare class UIContext { * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ px2vp(value: number): number; @@ -4414,8 +4114,7 @@ export declare class UIContext { * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ fp2px(value: number): number; @@ -4425,8 +4124,7 @@ export declare class UIContext { * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ px2fp(value: number): number; @@ -4436,8 +4134,7 @@ export declare class UIContext { * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ lpx2px(value: number): number; @@ -4447,8 +4144,7 @@ export declare class UIContext { * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ px2lpx(value: number): number; @@ -4460,8 +4156,7 @@ export declare class UIContext { * @stagemodelonly * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getSharedLocalStorage(): LocalStorage | undefined; @@ -4473,8 +4168,7 @@ export declare class UIContext { * @stagemodelonly * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getHostContext(): Context | undefined; @@ -4485,8 +4179,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ getWindowName(): string | undefined; @@ -4496,8 +4189,7 @@ export declare class UIContext { * @returns { WidthBreakpoint } The width breakpoint of current window. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ getWindowWidthBreakpoint(): WidthBreakpoint; @@ -4507,8 +4199,7 @@ export declare class UIContext { * @returns { HeightBreakpoint } The height breakpoint of current window. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ getWindowHeightBreakpoint(): HeightBreakpoint; @@ -4539,8 +4230,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ openBindSheet(bindSheetContent: ComponentContent, sheetOptions?: SheetOptions, targetId?: number): Promise; @@ -4562,8 +4252,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ updateBindSheet(bindSheetContent: ComponentContent, sheetOptions: SheetOptions, partialUpdate?: boolean): Promise; @@ -4584,8 +4273,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ closeBindSheet(bindSheetContent: ComponentContent): Promise; @@ -4595,8 +4283,7 @@ export declare class UIContext { * @param { FrameCallback } frameCallback - The frame callback to run on the next frame. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ postFrameCallback(frameCallback: FrameCallback): void; @@ -4607,8 +4294,7 @@ export declare class UIContext { * @param { number } delayTime - The delay time in milliseconds, * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ postDelayedFrameCallback(frameCallback: FrameCallback, delayTime: number): void; @@ -4619,8 +4305,7 @@ export declare class UIContext { * @returns { Array} The instance of SwiperDynamicSyncScene. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ requireDynamicSyncScene(id: string): Array; @@ -4641,8 +4326,7 @@ export declare class UIContext { * @throws { BusinessError } 202 - The caller is not a system application. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ clearResourceCache(): void; @@ -4653,8 +4337,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ isFollowingSystemFontScale(): boolean; @@ -4665,8 +4348,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ getMaxFontScale(): number; @@ -4678,8 +4360,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ bindTabsToScrollable(tabsController: TabsController, scroller: Scroller): void; @@ -4691,8 +4372,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ unbindTabsFromScrollable(tabsController: TabsController, scroller: Scroller): void; @@ -4705,8 +4385,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ bindTabsToNestedScrollable(tabsController: TabsController, parentScroller: Scroller, childScroller: Scroller): void; @@ -4719,8 +4398,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'13','1.2':'20' } - * @arkts 1.1&1.2 + * @since 13 */ unbindTabsFromNestedScrollable(tabsController: TabsController, parentScroller: Scroller, childScroller: Scroller): void; @@ -4730,8 +4408,7 @@ export declare class UIContext { * @param { Optional } enabled - enable or disable swipe to back event. * @syscap SystemCapability.ArkUI.ArkUI.Circle * @atomicservice - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ enableSwipeBack(enabled: Optional): void; @@ -4743,8 +4420,7 @@ export declare class UIContext { * @throws { BusinessError } 202 - The caller is not a system application. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ freezeUINode(id: string, isFrozen: boolean): void; @@ -4756,8 +4432,7 @@ export declare class UIContext { * @throws { BusinessError } 202 - The caller is not a system application. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts { '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ freezeUINode(uniqueId: number, isFrozen: boolean): void; @@ -4768,8 +4443,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'16','1.2':'20' } - * @arkts 1.1&1.2 + * @since 16 */ getTextMenuController(): TextMenuController; @@ -4797,8 +4471,7 @@ export declare class UIContext { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'17','1.2':'20' } - * @arkts 1.1&1.2 + * @since 17 */ static createUIContextWithoutWindow(context: common.UIAbilityContext | common.ExtensionContext) : UIContext | undefined; @@ -4808,36 +4481,9 @@ export declare class UIContext { * @static * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'17','1.2':'20' } - * @arkts 1.1&1.2 + * @since 17 */ static destroyUIContextWithoutWindow(): void; - - /** - * Thread-safe UI state variables updates interface. - * - * @param { VoidCallback } callback - The callback function to be executed in the UI thread. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - setUIStates(callback: VoidCallback): void; - - /** - * Retrieves the UIContext corresponding to the UI instance of the currently focused window. - * Returns undefined if it does not exist. - * - * @returns { UIContext | undefined } The focused UIContext, or undefined if it does not exist. - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - static getFocusedUIContext(): UIContext | undefined; } /** @@ -4847,8 +4493,7 @@ export declare class UIContext { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ export const enum KeyboardAvoidMode { @@ -4857,8 +4502,7 @@ export const enum KeyboardAvoidMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ OFFSET = 0, @@ -4867,8 +4511,7 @@ export const enum KeyboardAvoidMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ RESIZE = 1, @@ -4877,8 +4520,7 @@ export const enum KeyboardAvoidMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ OFFSET_WITH_CARET = 2, @@ -4887,8 +4529,7 @@ export const enum KeyboardAvoidMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ RESIZE_WITH_CARET = 3, @@ -4897,10 +4538,9 @@ export const enum KeyboardAvoidMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ - NONE = 4, + NONE = 4 } /** @@ -4909,8 +4549,7 @@ export const enum KeyboardAvoidMode { * @enum { number } SwiperDynamicSyncSceneType * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export const enum SwiperDynamicSyncSceneType { /** @@ -4918,8 +4557,7 @@ export const enum SwiperDynamicSyncSceneType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ GESTURE = 0, @@ -4928,8 +4566,7 @@ export const enum SwiperDynamicSyncSceneType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ ANIMATION = 1 } @@ -4940,8 +4577,7 @@ export const enum SwiperDynamicSyncSceneType { * @enum { number } MarqueeDynamicSyncSceneType * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ export const enum MarqueeDynamicSyncSceneType { /** @@ -4949,8 +4585,7 @@ export const enum MarqueeDynamicSyncSceneType { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts { '1.1':'14','1.2':'20' } - * @arkts 1.1&1.2 + * @since 14 */ ANIMATION = 1 } @@ -4961,10 +4596,9 @@ export const enum MarqueeDynamicSyncSceneType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'16','1.2':'20' } - * @arkts 1.1&1.2 + * @since 16 */ -export declare class TextMenuController { +export class TextMenuController { /** * Set text menu options. * @@ -4972,8 +4606,7 @@ export declare class TextMenuController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'16','1.2':'20' } - * @arkts 1.1&1.2 + * @since 16 */ setMenuOptions(options: TextMenuOptions): void; diff --git a/api/@ohos.arkui.UIContext.static.d.ets b/api/@ohos.arkui.UIContext.static.d.ets new file mode 100755 index 0000000000000000000000000000000000000000..6735757391f3205fc9473c25f12343327446eb94 --- /dev/null +++ b/api/@ohos.arkui.UIContext.static.d.ets @@ -0,0 +1,3395 @@ +'use static'; +/* + * Copyright (c) 2023-2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import font from './@ohos.font'; +import mediaQuery from './@ohos.mediaquery'; +import type inspector from './@ohos.arkui.inspector'; +import type observer from '@ohos.arkui.observer'; +import promptAction from './@ohos.promptAction'; +import { LevelOrder } from './@ohos.promptAction'; +import router from './@ohos.router'; +import type componentUtils from './@ohos.arkui.componentUtils'; +import { SimpleAnimatorOptions } from './@ohos.animator'; +import type { Callback, AsyncCallback } from './@ohos.base'; +import { MeasureOptions } from './@ohos.measure'; +import type componentSnapshot from './@ohos.arkui.componentSnapshot'; +import type dragController from './@ohos.arkui.dragController'; +import image from './@ohos.multimedia.image'; +import type common from './@ohos.app.ability.common'; +import type pointer from './@ohos.multimodalInput.pointer'; +import { ComponentContent, FrameNode, Frame } from '@ohos.arkui.node'; +import { AnimatorOptions, AnimatorResult } from './@ohos.animator'; +import { ClickEvent, ExpectedFrameRateRange, DragItemInfo, AnimateParam, KeyframeAnimateParam, KeyframeState, + SheetOptions, PopupCommonOptions, MenuOptions, KeyEvent, Optional, + ContentCoverOptions } from './arkui/component/common'; +import { CustomBuilder, CustomBuilderT } from './arkui/component/builder'; +import { GestureEvent, GestureRecognizer } from './arkui/component/gesture'; +import { ResourceStr, SizeOptions, VoidCallback } from './arkui/component/units'; +import { Nullable, Color, FontStyle, WidthBreakpoint, HeightBreakpoint, PixelRoundMode } from './arkui/component/enums'; +import { TimePickerDialogOptions } from './arkui/component/timePicker'; +import { AlertDialogParamWithConfirm, AlertDialogParamWithButtons, AlertDialogParamWithOptions } from './arkui/component/alertDialog'; +import { ActionSheetOptions } from './arkui/component/actionSheet'; +import { TextPickerDialogOptions } from './arkui/component/textPicker'; +import { LocalStorage } from './arkui/stateManagement/storage/localStorage'; +import { DatePickerDialogOptions } from './arkui/component/datePicker'; +import { TabsController } from './arkui/component/tabs'; +import { Scroller } from './arkui/component/scroll'; +import { KeyProcessingMode } from './arkui/component/focus'; +import { TextMenuOptions } from './arkui/component/textCommon'; + +/** + * class Font + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class Font { + /** + * Register a customized font in the FontManager. + * + * @param { font.FontOptions } options - FontOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + registerFont(options: font.FontOptions): void; + + /** + * Gets a list of fonts supported by system. + * @returns { Array } A list of font names + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getSystemFontList(): Array; + + /** + * Get font details according to the font name. + * @param { string } fontName - font name + * @returns { font.FontInfo } Returns the font info + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getFontByName(fontName: string): font.FontInfo; +} + +/** + * class MediaQuery + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class MediaQuery { + /** + * Sets the media query criteria and returns the corresponding listening handle + * + * @param { string } condition - media conditions + * @returns { mediaQuery.MediaQueryListener } the corresponding listening handle + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + matchMediaSync(condition: string): mediaQuery.MediaQueryListener; +} + +/** + * class UIInspector + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class UIInspector { + /** + * Sets the component after layout or draw criteria and returns the corresponding listening handle + * @param { string } id - component id. + * @returns { inspector.ComponentObserver | undefined } create listener for observer component event. + * If unable to obtain current ui context, the function will return undefined. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + createComponentObserver(id: string): inspector.ComponentObserver | undefined; +} + +/** + * class Router + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class Router { + /** + * Navigates to a specified page in the application based on the page URL and parameters. + * + * @param { router.RouterOptions } options - Options. + * @param { AsyncCallback } callback - the callback of pushUrl. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 100002 - Uri error. The URI of the page to redirect is incorrect or does not exist + * @throws { BusinessError } 100003 - Page stack error. Too many pages are pushed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pushUrl(options: router.RouterOptions, callback: AsyncCallback): void; + + /** + * Navigates to a specified page in the application based on the page URL and parameters. + * + * @param { router.RouterOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 100002 - Uri error. The URI of the page to redirect is incorrect or does not exist + * @throws { BusinessError } 100003 - Page stack error. Too many pages are pushed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pushUrl(options: router.RouterOptions): Promise; + + /** + * Navigates to a specified page in the application based on the page URL and parameters. + * + * @param { router.RouterOptions } options - Options. + * @param { router.RouterMode } mode - RouterMode. + * @param { AsyncCallback } callback - the callback of pushUrl. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 100002 - Uri error. The URI of the page to redirect is incorrect or does not exist + * @throws { BusinessError } 100003 - Page stack error. Too many pages are pushed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pushUrl(options: router.RouterOptions, mode: router.RouterMode, callback: AsyncCallback): void; + + /** + * Navigates to a specified page in the application based on the page URL and parameters. + * + * @param { router.RouterOptions } options - Options. + * @param { router.RouterMode } mode - RouterMode. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 100002 - Uri error. The URI of the page to redirect is incorrect or does not exist + * @throws { BusinessError } 100003 - Page stack error. Too many pages are pushed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pushUrl(options: router.RouterOptions, mode: router.RouterMode): Promise; + + /** + * Replaces the current page with another one in the application. The current page is destroyed after replacement. + * + * @param { router.RouterOptions } options - Options. + * @param { AsyncCallback } callback - the callback of replaceUrl. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The UI execution context is not found. This error code is thrown only in the + * standard system. + * @throws { BusinessError } 200002 - Uri error. The URI of the page to be used for replacement is incorrect or does + * not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + replaceUrl(options: router.RouterOptions, callback: AsyncCallback): void; + + /** + * Replaces the current page with another one in the application. The current page is destroyed after replacement. + * + * @param { router.RouterOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The UI execution context is not found. This error code is thrown only in the + * standard system. + * @throws { BusinessError } 200002 - Uri error. The URI of the page to be used for replacement is incorrect or does + * not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + replaceUrl(options: router.RouterOptions): Promise; + + /** + * Replaces the current page with another one in the application. The current page is destroyed after replacement. + * + * @param { router.RouterOptions } options - Options. + * @param { router.RouterMode } mode - RouterMode. + * @param { AsyncCallback } callback - the callback of replaceUrl. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The UI execution context is not found. This error code is thrown only in the + * standard system. + * @throws { BusinessError } 200002 - Uri error. The URI of the page to be used for replacement is incorrect or does + * not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + replaceUrl(options: router.RouterOptions, mode: router.RouterMode, callback: AsyncCallback): void; + + /** + * Replaces the current page with another one in the application. The current page is destroyed after replacement. + * + * @param { router.RouterOptions } options - Options. + * @param { router.RouterMode } mode - RouterMode. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Failed to get the delegate. This error code is thrown only in the standard + * system. + * @throws { BusinessError } 200002 - Uri error. The URI of the page to be used for replacement is incorrect or does + * not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + replaceUrl(options: router.RouterOptions, mode: router.RouterMode): Promise; + + /** + * Returns to the previous page or a specified page. + * + * @param { router.RouterOptions } options - Options. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + back(options?: router.RouterOptions): void; + + /** + * Returns to the specified page. + * + * @param { number } index - index of page. + * @param { Object } [params] - params of page. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + back(index: number, params?: Object): void; + + /** + * Clears all historical pages and retains only the current page at the top of the stack. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + clear(): void; + + /** + * Obtains the number of pages in the current stack. + * + * @returns { string } Number of pages in the stack. The maximum value is 32. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getLength(): string; + + /** + * Obtains information about the current page state. + * + * @returns { router.RouterState } Page state. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getState(): router.RouterState; + + /** + * Obtains page information by index. + * + * @param { number } index - Index of page. + * @returns { router.RouterState | undefined } Page state. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getStateByIndex(index: number): router.RouterState | undefined; + + /** + * Obtains page information by url. + * + * @param { string } url - URL of page. + * @returns { Array } Page state. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getStateByUrl(url: string): Array; + + /** + * Pop up alert dialog to ask whether to back. + * + * @param { router.EnableAlertOptions } options - Options. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showAlertBeforeBackPage(options: router.EnableAlertOptions): void; + + /** + * Hide alert before back page. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + hideAlertBeforeBackPage(): void; + + /** + * Obtains information about the current page params. + * + * @returns { Object } Page params. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getParams(): Object; + + /** + * Navigates to a specified page in the application based on the page URL and parameters. + * @param { router.NamedRouterOptions } options - Options. + * @param { AsyncCallback } callback - the callback of pushNamedRoute. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 100003 - Page stack error. Too many pages are pushed. + * @throws { BusinessError } 100004 - Named route error. The named route does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pushNamedRoute(options: router.NamedRouterOptions, callback: AsyncCallback): void; + + /** + * Navigates to a specified page in the application based on the page URL and parameters. + * @param { router.NamedRouterOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 100003 - Page stack error. Too many pages are pushed. + * @throws { BusinessError } 100004 - Named route error. The named route does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pushNamedRoute(options: router.NamedRouterOptions): Promise; + + /** + * Navigates to a specified page in the application based on the page URL and parameters. + * @param { router.NamedRouterOptions } options - Options. + * @param { router.RouterMode } mode - RouterMode. + * @param { AsyncCallback } callback - the callback of pushNamedRoute. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 100003 - Page stack error. Too many pages are pushed. + * @throws { BusinessError } 100004 - Named route error. The named route does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pushNamedRoute(options: router.NamedRouterOptions, mode: router.RouterMode, callback: AsyncCallback): void; + + /** + * Navigates to a specified page in the application based on the page URL and parameters. + * @param { router.NamedRouterOptions } options - Options. + * @param { router.RouterMode } mode - RouterMode. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 100003 - Page stack error. Too many pages are pushed. + * @throws { BusinessError } 100004 - Named route error. The named route does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pushNamedRoute(options: router.NamedRouterOptions, mode: router.RouterMode): Promise; + + /** + * Replaces the current page with another one in the application. The current page is destroyed after replacement. + * @param { router.NamedRouterOptions } options - Options. + * @param { AsyncCallback } callback - the callback of replaceNamedRoute. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The UI execution context is not found. This error code is thrown only in the + * standard system. + * @throws { BusinessError } 100004 - Named route error. The named route does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + replaceNamedRoute(options: router.NamedRouterOptions, callback: AsyncCallback): void; + + /** + * Replaces the current page with another one in the application. The current page is destroyed after replacement. + * @param { router.NamedRouterOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - if the number of parameters is less than 1 or the type of the url parameter is not + * string. + * @throws { BusinessError } 100001 - The UI execution context is not found. This error code is thrown only in the + * standard system. + * @throws { BusinessError } 100004 - Named route error. The named route does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + replaceNamedRoute(options: router.NamedRouterOptions): Promise; + + /** + * Replaces the current page with another one in the application. The current page is destroyed after replacement. + * @param { router.NamedRouterOptions } options - Options. + * @param { router.RouterMode } mode - RouterMode. + * @param { AsyncCallback } callback - the callback of replaceNamedRoute. + * @throws { BusinessError } 401 - if the number of parameters is less than 1 or the type of the url parameter is not + * string. + * @throws { BusinessError } 100001 - The UI execution context is not found. This error code is thrown only in the + * standard system. + * @throws { BusinessError } 100004 - Named route error. The named route does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + replaceNamedRoute(options: router.NamedRouterOptions, mode: router.RouterMode, callback: AsyncCallback): void; + + /** + * Replaces the current page with another one in the application. The current page is destroyed after replacement. + * @param { router.NamedRouterOptions } options - Options. + * @param { router.RouterMode } mode - RouterMode. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Failed to get the delegate. This error code is thrown only in the standard + * system. + * @throws { BusinessError } 100004 - Named route error. The named route does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + replaceNamedRoute(options: router.NamedRouterOptions, mode: router.RouterMode): Promise; +} + +/** + * Defines the custom builder with id. + * + * @typedef { function } CustomBuilderWithId + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare type CustomBuilderWithId = (id: number) => void; + +/** + * Defines the target info. + * + * @interface TargetInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface TargetInfo { + /** + * ID of target node. + * + * @type { string | number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + id: string | number; + + /** + * Unique ID that generated by framework. This ID used to constrain range of target. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + componentId?: number; +} + +/** + * class PromptAction + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class PromptAction { + /** + * Displays the notification text. + * + * @param { promptAction.ShowToastOptions } options - Options. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showToast(options: promptAction.ShowToastOptions): void; + + /** + * Displays the notification text. + * + * @param { promptAction.ShowToastOptions } options - Options. + * @returns { Promise } return the toast id that will be used by closeToast. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + openToast(options: promptAction.ShowToastOptions): Promise; + + /** + * Close the notification text. + * + * @param { number } toastId - the toast id that returned by openToast. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @throws { BusinessError } 103401 - Cannot find the toast. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + closeToast(toastId: number): void; + + /** + * Displays the dialog box. + * + * @param { promptAction.ShowDialogOptions } options - Options. + * @param { AsyncCallback } callback - the callback of showDialog. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showDialog(options: promptAction.ShowDialogOptions, + callback: AsyncCallback): void; + + /** + * Displays the dialog box. + * + * @param { promptAction.ShowDialogOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showDialog(options: promptAction.ShowDialogOptions): Promise; + + /** + * Displays the menu. + * + * @param { promptAction.ActionMenuOptions } options - Options. + * @param { AsyncCallback } callback - the callback of showActionMenu. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showActionMenu(options: promptAction.ActionMenuOptions, + callback: AsyncCallback): void; + + /** + * Displays the menu. + * + * @param { promptAction.ActionMenuOptions } options - Options. + * @returns { Promise } callback - the callback of showActionMenu. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showActionMenu(options: promptAction.ActionMenuOptions): Promise; + + /** + * Open the custom dialog with frameNode. + * + * @param { ComponentContent } dialogContent - the content of custom dialog. + * @param { promptAction.BaseDialogOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The ComponentContent is incorrect. + * @throws { BusinessError } 103302 - Dialog content already exists. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + openCustomDialog(dialogContent: ComponentContent, + options?: promptAction.BaseDialogOptions): Promise; + + /** + * Open the custom dialog with frameNode and controller. + * + * @param { ComponentContent } dialogContent - the content of custom dialog. + * @param { promptAction.DialogController } controller - Dialog controller. + * @param { promptAction.BaseDialogOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The ComponentContent is incorrect. + * @throws { BusinessError } 103302 - Dialog content already exists. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + openCustomDialogWithController(dialogContent: ComponentContent, + controller: promptAction.DialogController, + options?: promptAction.BaseDialogOptions): Promise; + + /** + * Update the custom dialog with frameNode. + * + * @param { ComponentContent } dialogContent - the content of custom dialog. + * @param { promptAction.BaseDialogOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The ComponentContent is incorrect. + * @throws { BusinessError } 103303 - The ComponentContent cannot be found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + updateCustomDialog(dialogContent: ComponentContent, + options: promptAction.BaseDialogOptions): Promise; + + /** + * Close the custom dialog with frameNode. + * + * @param { ComponentContent } dialogContent - the content of custom dialog. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The ComponentContent is incorrect. + * @throws { BusinessError } 103303 - The ComponentContent cannot be found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + closeCustomDialog(dialogContent: ComponentContent): Promise; + + /** + * Open the custom dialog. + * + * @param { promptAction.CustomDialogOptions } options - Options. + * @returns { Promise } return the dialog id that will be used by closeCustomDialog. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + openCustomDialog(options: promptAction.CustomDialogOptions): Promise; + + /** + * Present the custom dialog with controller. + * + * @param { CustomBuilder | CustomBuilderT } builder - Dialog builder. + * @param { promptAction.DialogController } [controller] - Dialog controller. + * @param { promptAction.DialogOptions } [options] - Options. + * @returns { Promise } return the dialog id that will be used by closeCustomDialog. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + presentCustomDialog(builder: CustomBuilder | CustomBuilderT, controller?: promptAction.DialogController, + options?: promptAction.DialogOptions): Promise; + + /** + * Close the custom dialog. + * + * @param { number } dialogId - the dialog id that returned by openCustomDialog. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal error. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + closeCustomDialog(dialogId: number): void; + + /** + * Get order value of top dialog. + * + * @returns { LevelOrder | undefined } the display order, or undefined if there is no dialog. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getTopOrder(): LevelOrder | undefined; + + /** + * Get order value of bottom dialog. + * + * @returns { LevelOrder | undefined } the display order, or undefined if there is no dialog. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getBottomOrder(): LevelOrder | undefined; + + /** + * Open popup with frameNode. + * + * @param { ComponentContent } content - The content of popup. + * @param { TargetInfo } target - The target of popup. + * @param { PopupCommonOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The content is incorrect. + * @throws { BusinessError } 103302 - The content already exists. + * @throws { BusinessError } 103304 - The target does not exist. + * @throws { BusinessError } 103305 - The target node is not in the component tree. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + openPopup(content: ComponentContent, target: TargetInfo, + options?: PopupCommonOptions): Promise; + + /** + * Update popup with frameNode. + * + * @param { ComponentContent } content - The content of popup. + * @param { PopupCommonOptions } options - Options. + * @param { boolean } partialUpdate - If true, only the specified properties in the options are updated, + * otherwise the rest of the properties are overwritten with the default values. + * Default value is false. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The ComponentContent is incorrect. + * @throws { BusinessError } 103303 - The ComponentContent cannot be found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + updatePopup(content: ComponentContent, options: PopupCommonOptions, + partialUpdate?: boolean): Promise; + + /** + * Close popup with frameNode. + * + * @param { ComponentContent } content - The content of popup. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The ComponentContent is incorrect. + * @throws { BusinessError } 103303 - The ComponentContent cannot be found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + closePopup(content: ComponentContent): Promise; + + /** + * Open menu with frameNode. + * + * @param { ComponentContent } content - The content of menu. + * @param { TargetInfo } target - The target of menu. + * @param { MenuOptions } options - Options. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The content is incorrect. + * @throws { BusinessError } 103302 - The content already exists. + * @throws { BusinessError } 103304 - The target does not exist. + * @throws { BusinessError } 103305 - The target node is not in the component tree. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + openMenu(content: ComponentContent, target: TargetInfo, options?: MenuOptions): Promise; + + /** + * Update menu with frameNode. + * + * @param { ComponentContent } content - The content of menu. + * @param { MenuOptions } options - Options. + * @param { boolean } partialUpdate - If true, only the specified properties in the MenuOptions are updated, + * otherwise the rest of the properties are overwritten with the default values. + * Default value is false. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The ComponentContent is incorrect. + * @throws { BusinessError } 103303 - The ComponentContent cannot be found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + updateMenu(content: ComponentContent, options: MenuOptions, + partialUpdate?: boolean): Promise; + + /** + * Close menu with frameNode. + * + * @param { ComponentContent } content - The content of menu. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 103301 - The ComponentContent is incorrect. + * @throws { BusinessError } 103303 - The ComponentContent cannot be found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + closeMenu(content: ComponentContent): Promise; +} + +/** + * Defines the callback type used in UIObserver watch click event. + * The value of event indicates the information of ClickEvent. + * The value of node indicates the frameNode which will receive the event. + * + * @typedef { function } ClickEventListenerCallback + * @param { ClickEvent } event - the information of ClickEvent + * @param { FrameNode } [node] - the information of frameNode + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +type ClickEventListenerCallback = (event: ClickEvent, node?: FrameNode) => void; +/** + * Defines the callback type used in UIObserver watch pan event. + * The value of event indicates the information of pan event. + * The value of node indicates the frameNode which will receive the event. + * + * @typedef { function } PanListenerCallback + * @param { GestureEvent } event - the information of pan event + * @param { GestureRecognizer } current - the information of panRecognizer + * @param { FrameNode } [node] - the information of frameNode + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +type PanListenerCallback = (event: GestureEvent, current: GestureRecognizer, node?: FrameNode) => void; +/** + * Defines the callback type used in UIObserver watch gesture. + * The value of event indicates the information of gesture. + * The value of node indicates the frameNode which will receive the event. + * + * @typedef { function } GestureEventListenerCallback + * @param { GestureEvent } event - the information of GestureEvent + * @param { FrameNode } [node] - the information of frameNode + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +type GestureEventListenerCallback = (event: GestureEvent, node?: FrameNode) => void; +/** + * Defines the PageInfo type. + * The value of routerPageInfo indicates the information of the router page, or undefined if the + * frameNode does not have router page information. And the value of navDestinationInfo indicates + * the information of the navDestination, or undefined if the frameNode does not have navDestination + * information. + * + * @interface PageInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface PageInfo { + /** + * the property of router page information. + * + * @type { ?observer.RouterPageInfo } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + routerPageInfo?: observer.RouterPageInfo; + + /** + * the property of navDestination information. + * + * @type { ?observer.NavDestinationInfo } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + navDestinationInfo?: observer.NavDestinationInfo; +} + +/** + * the property of OverlayManager. + * + * @interface OverlayManagerOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface OverlayManagerOptions { + /** + * the render property of overlay node. + * + * @type { ?boolean } + * @default true + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + renderRootOverlay?: boolean; + + /** + * Set whether support backPressed event or not. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + enableBackPressedEvent?: boolean; +} + +/** + * Defines the type can be used for identiting the node, for the string type, it's the inspector id + * set through .id attribute, and for the number type, it's the unique ID got from the FrameNode by + * getUniqueID method. + * + * @typedef { string | number } NodeIdentity + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare type NodeIdentity = string | number; + +/** + * An enumeration type that identifies the current node's rendering state. The UI components used in + * the application are automatically managed by the system and controlled for participation in graphical + * rendering by either mounting them onto the render tree or removing them from it. Only nodes that + * participate in graphical rendering have the potential to be displayed. However, participating in + * rendering does not equal to the node's visibility, as there may be many occlusion scenarios in the + * actual implementation of the application. Nevertheless, if a node does not participate in rendering, + * it will definitely not be visible. + * + * @enum { number } NodeRenderState + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const enum NodeRenderState { + /** + * The node has been mount on to the render tree and will soon be rendered. Generally, after the next frame, + * the user will be able to see this node. However, this is not always the case, as in reality, the node may be + * occluded by other nodes, meaning it is rendered but not be visible. + * When registering a listener for the render state using the UIObserver interface, the system will immediately + * trigger the callback once, and the state notified at this time typically represents the current state. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ABOUT_TO_RENDER_IN = 0, + + /** + * The node has been removed from the render tree and will no longer be rendered shortly. Generally speaking, + * after the next frame, the user will no longer be able to see this node. + * When registering a listener for the render state using the UIObserver interface, the system will immediately + * trigger the callback once, and the state notified at this time typically represents the current state. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ABOUT_TO_RENDER_OUT = 1 +} + +/** + * Defines the callback type used in UIObserver to monitor one specific node's render state. + * + * @typedef { function } NodeRenderStateChangeCallback + * @param { NodeRenderState } state - the node's render state + * @param { FrameNode } [node] - the information of frameNode + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare type NodeRenderStateChangeCallback = (state: NodeRenderState, node?: FrameNode) => void; + +/** + * This is an enumeration type representing the gesture callback phases to be triggered, corresponding to + * the action callbacks defined in gesture.d.ts. Therefore, not all gesture types have all the following + * phase definitions. For example, SwipeGesture only has one callback named onAction, so it also only has + * one enumeration type, which is WILL_START. + * + * @enum { number } GestureActionPhase + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const enum GestureActionPhase { + /** + * The gesture has been successfully recognized by the system, and the action-start/action callback will be + * executed immediately. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + WILL_START = 0, + + /** + * This indicates the gesture has been determined to be an end, which usually happens when the user lifts their + * fingers, ending the entire interaction, and the action-end callback will be executed immediately. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + WILL_END = 1 +} + +/** + * This is an enumeration type indicating what kind of gesture you want to monitor for. + * + * @enum { number } GestureListenerType + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const enum GestureListenerType { + /** + * The tap gesture. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + TAP = 0, + + /** + * The long press gesture. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + LONG_PRESS = 1, + + /** + * The pan gesture. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + PAN = 2, + + /** + * The pinch gesture. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + PINCH = 3, + + /** + * The swipe gesture. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + SWIPE = 4, + + /** + * The rotation gesture. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ROTATION = 5 +} + +/** + * The information when one gesture specific callback is triggered. + * + * @interface GestureTriggerInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface GestureTriggerInfo { + /** + * The gesture event object. + * + * @type { GestureEvent } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + event: GestureEvent; + + /** + * The gesture recognizer object. You can obtain the detailed information of the gesture from it, + * but please do not keep this object locally, as it might be unavailable when the node is released. + * + * @type { GestureRecognizer } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + current: GestureRecognizer; + + /** + * The gesture action callback phase. + * + * @type { GestureActionPhase } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + currentPhase: GestureActionPhase; + + /** + * The node which the gesture is being triggered on. + * + * @type { ?FrameNode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + node?: FrameNode; +} + +/** + * The observer options for global gesture listener. + * + * @interface GestureObserverConfigs + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface GestureObserverConfigs { + /** + * The gesture callback phases want to monitor. Only the specific action phases can be notified when the gesture is + * triggered. + * If empty array provided, the register will has no any effect. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + actionPhases: Array; +} + +/** + * Defines the callback type used in UIObserver to monitor specific gesture triggered information. + * + * @typedef { function } GestureListenerCallback + * @param { GestureTriggerInfo } info - the gesture details triggered with user interaction + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare type GestureListenerCallback = (info: GestureTriggerInfo) => void; + +/** + * Register callbacks to observe ArkUI behavior. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class UIObserver { + /** + * Registers a callback function to be called when the navigation destination is updated. + * + * @param { 'navDestinationUpdate' } type - The type of event to listen for. Must be 'navDestinationUpdate'. + * @param { observer.NavDestinationSwitchObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to be called when the navigation + * destination is updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'navDestinationUpdate', + options: observer.NavDestinationSwitchObserverOptions, + callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'navDestinationUpdate' } type - The type of event to remove the listener for. Must be + * 'navDestinationUpdate'. + * @param { observer.NavDestinationSwitchObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to remove. If not provided, + * all callbacks for the given event type and navigation ID will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'navDestinationUpdate', + options: observer.NavDestinationSwitchObserverOptions, + callback?: Callback): void; + + /** + * Registers a callback function to be called when the navigation destination is updated. + * + * @param { 'navDestinationUpdate' } type - The type of event to listen for. Must be 'navDestinationUpdate'. + * @param { Callback } callback - The callback function to be called when the navigation + * destination is updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'navDestinationUpdate', callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'navDestinationUpdate'} type - The type of event to remove the listener for. Must be + * 'navDestinationUpdate'. + * @param { Callback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'navDestinationUpdate', callback?: Callback): void; + + /** + * Registers a callback function to be called when the scroll event start or stop. + * + * @param { 'scrollEvent' } type - The type of event to listen for. Must be 'scrollEvent'. + * @param { observer.ObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to be called when the scroll event + * start or stop. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'scrollEvent', options: observer.ObserverOptions, callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'scrollEvent' } type - The type of event to remove the listener for. Must be 'scrollEvent'. + * @param { observer.ObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to remove. If not provided, all + * callbacks for the given event type and + * scroll ID will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'scrollEvent', options: observer.ObserverOptions, callback?: Callback): void; + + /** + * Registers a callback function to be called when the scroll event start or stop. + * + * @param { 'scrollEvent' } type - The type of event to listen for. Must be 'scrollEvent'. + * @param { Callback } callback - The callback function to be called when the scroll event + * start or stop. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'scrollEvent', callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'scrollEvent'} type - The type of event to remove the listener for. Must be 'scrollEvent'. + * @param { Callback } [callback] - The callback function to remove. If not provided, all + * callbacks for the given event type + * will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'scrollEvent', callback?: Callback): void; + + /** + * Registers a callback function to be called when the router page in a ui context is updated. + * + * @param { 'routerPageUpdate' } type - The type of event to listen for. Must be 'routerPageUpdate'. + * @param { Callback } callback - The callback function to be called when the router page is + * updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'routerPageUpdate', callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'routerPageUpdate' } type - The type of event to remove the listener for. Must be 'routerPageUpdate'. + * @param { Callback } [callback] - The callback function to remove. If not provided, all + * callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'routerPageUpdate', callback?: Callback): void; + + /** + * Registers a callback function to be called when the screen density in a ui context is updated. + * + * @param { 'densityUpdate' } type - The type of event to listen for. Must be 'densityUpdate'. + * @param { Callback } callback - The callback function to be called when the screen density is + * updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'densityUpdate', callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'densityUpdate' } type - The type of event to remove the listener for. Must be 'densityUpdate'. + * @param { Callback } [callback] - The callback function to remove. If not provided, all + * callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'densityUpdate', callback?: Callback): void; + + /** + * Registers a callback function to be called when the draw command will be drawn. + * + * @param { 'willDraw' } type - The type of event to listen for. Must be 'willDraw'. + * @param { Callback } callback - The callback function to be called when the draw command will be drawn. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'willDraw', callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'willDraw' } type - The type of event to remove the listener for. Must be 'willDraw'. + * @param { Callback } [callback] - The callback function to remove. If not provided, all callbacks for the + * given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'willDraw', callback?: Callback): void; + + /** + * Registers a callback function to be called when the layout is done. + * + * @param { 'didLayout' } type - The type of event to listen for. Must be 'didLayout'. + * @param { Callback } callback - The callback function to be called when the layout is done. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'didLayout', callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'didLayout' } type - The type of event to remove the listener for. Must be 'didLayout'. + * @param { Callback } [callback] - The callback function to remove. If not provided, all callbacks for the + * given event type + * will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'didLayout', callback?: Callback): void; + + /** + * Registers a callback function to be called when the navigation switched to a new navDestination. + * + * @param { 'navDestinationSwitch' } type - The type of event to listen for. Must be 'navDestinationSwitch'. + * @param { Callback } callback - The callback function to be called when + * the navigation switched to a new navDestination. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on( + type: 'navDestinationSwitch', + callback: Callback + ): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'navDestinationSwitch' } type - The type of event to remove the listener for. Must be + * 'navDestinationSwitch'. + * @param { Callback } [callback] - The callback function to remove. + * If not provided, all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off( + type: 'navDestinationSwitch', + callback?: Callback + ): void; + + /** + * Registers a callback function to be called when the navigation switched to a new navDestination. + * + * @param { 'navDestinationSwitch' } type - The type of event to listen for. Must be 'navDestinationSwitch'. + * @param { observer.NavDestinationSwitchObserverOptions } observerOptions - Options. + * @param { Callback } callback - The callback function to be called when the + * navigation switched to a new navDestination. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on( + type: 'navDestinationSwitch', + observerOptions: observer.NavDestinationSwitchObserverOptions, + callback: Callback + ): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'navDestinationSwitch' } type - The type of event to remove the listener for. Must be + * 'navDestinationSwitch'. + * @param { observer.NavDestinationSwitchObserverOptions } observerOptions - Options. + * @param { Callback } [callback] - The callback function to remove. If not + * provided, all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off( + type: 'navDestinationSwitch', + observerOptions: observer.NavDestinationSwitchObserverOptions, + callback?: Callback + ): void; + + /** + * Registers a callback function to be called before clickEvent is called. + * + * @param { 'willClick' } type - The type of event to listen for. + * @param { ClickEventListenerCallback } callback - The callback function to be called + * when the clickEvent will be trigger or after. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'willClick', callback: ClickEventListenerCallback): void; + + /** + * Removes a callback function to be called before clickEvent is called. + * + * @param { 'willClick' } type - The type of event to remove the listener for. + * @param { ClickEventListenerCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'willClick', callback?: ClickEventListenerCallback): void; + + /** + * Registers a callback function to be called after clickEvent is called. + * + * @param { 'didClick' } type - The type of event to listen for. + * @param { ClickEventListenerCallback } callback - The callback function to be called + * when the clickEvent will be trigger or after. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'didClick', callback: ClickEventListenerCallback): void; + + /** + * Removes a callback function to be called after clickEvent is called. + * + * @param { 'didClick' } type - The type of event to remove the listener for. + * @param { ClickEventListenerCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'didClick', callback?: ClickEventListenerCallback): void; + + /** + * Registers a callback function to be called before tapGesture is called. + * + * @param { 'willClick' } type - The type of event to listen for. + * @param { GestureEventListenerCallback } callback - The callback function to be called + * when the clickEvent will be trigger or after. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'willClick', callback: GestureEventListenerCallback): void; + + /** + * Removes a callback function to be called before tapGesture is called. + * + * @param { 'willClick' } type - The type of event to remove the listener for. + * @param { GestureEventListenerCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'willClick', callback?: GestureEventListenerCallback): void; + + /** + * Registers a callback function to be called after tapGesture is called. + * + * @param { 'didClick' } type - The type of event to listen for. + * @param { GestureEventListenerCallback } callback - The callback function to be called + * when the clickEvent will be trigger or after. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'didClick', callback: GestureEventListenerCallback): void; + + /** + * Removes a callback function to be called after tapGesture is called. + * + * @param { 'didClick' } type - The type of event to remove the listener for. + * @param { GestureEventListenerCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'didClick', callback?: GestureEventListenerCallback): void; + + /** + * Registers a callback function to be called before panGesture onActionStart is called. + * + * @param { 'beforePanStart' } type - The type of event to listen for. + * @param { PanListenerCallback } callback - The callback function to be called + * when the panGesture will be trigger or after. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'beforePanStart', callback: PanListenerCallback): void; + + /** + * Removes a callback function to be called before panGesture onActionStart is called. + * + * @param { 'beforePanStart' } type - The type of event to remove the listener for. + * @param { PanListenerCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'beforePanStart', callback?: PanListenerCallback): void; + + /** + * Registers a callback function to be called before panGesture onActionEnd is called. + * + * @param { 'beforePanEnd' } type - The type of event to listen for. + * @param { PanListenerCallback } callback - The callback function to be called + * when the panGesture will be trigger or after. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'beforePanEnd', callback: PanListenerCallback): void; + + /** + * Removes a callback function to be called before panGesture onActionEnd is called. + * + * @param { 'beforePanEnd' } type - The type of event to remove the listener for. + * @param { PanListenerCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'beforePanEnd', callback?: PanListenerCallback): void; + + /** + * Registers a callback function to be called after panGesture onActionStart is called. + * + * @param { 'afterPanStart' } type - The type of event to listen for. + * @param { PanListenerCallback } callback - The callback function to be called + * when the panGesture will be trigger or after. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'afterPanStart', callback: PanListenerCallback): void; + + /** + * Removes a callback function to be called after panGesture onActionStart is called. + * + * @param { 'afterPanStart' } type - The type of event to remove the listener for. + * @param { PanListenerCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'afterPanStart', callback?: PanListenerCallback): void; + + /** + * Registers a callback function to be called after panGesture onActionEnd is called. + * + * @param { 'afterPanEnd' } type - The type of event to listen for. + * @param { PanListenerCallback } callback - The callback function to be called + * when the panGesture will be trigger or after. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'afterPanEnd', callback: PanListenerCallback): void; + + /** + * Removes a callback function to be called after panGesture onActionEnd is called. + * + * @param { 'afterPanEnd' } type - The type of event to remove the listener for. + * @param { PanListenerCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'afterPanEnd', callback?: PanListenerCallback): void; + + /** + * Registers a callback function to be called when the specific node's render state changed. + * This callback will be executed once immediately when the register is successful. + * [Notes]: + * 1. Be aware of the limit on the number of nodes: + * For performance considerations, the system has imposed a limit on the number of + * nodes that can be registered for monitoring in a single UI instance, exception will be thrown + * if overmuch. Please use this interface with caution. + * 2. Understanding scenarios where notifications may not occur: + * In general, within container components that have view or page switching functionality, + * when a view or page within the screen is moved outside the screen, the components previously + * within the screen should be removed from the render tree and should receive a RENDER_OUT + * notification. However, this is not always the case, as some scenarios involve views or components + * being moved outside the screen's display range without triggering a RENDER_OUT notification. + * For example, some components with caching capabilities may affect this behavior, and swiper is one + * such component. The cacheCount property of the swiper component allows you to force, via its second + * parameter isShow, that even if the current page is moved outside the display range, it remains in the + * render tree. This can be useful in scenarios where multiple pages are displayed on the screen simultaneously. + * Another example is scrolling components like list or scroll, where their internal content remains in the + * render tree even if it is scrolled outside the screen's display range, provided that lazyForEach/Repeat is + * not used. As a result, there will be no changes to the render state. Once you understand the principles + * behind the triggers for render state changes, these scenarios will become easier to comprehend. + * + * @param { 'nodeRenderState' } type - The type of event to listen for. + * @param { NodeIdentity } nodeIdentity - The identity of the target node + * @param { NodeRenderStateChangeCallback } callback - The callback function to be called + * when the clickEvent will be trigger or after. + * @throws { BusinessError } 161001 - The count of nodes monitoring render state is over the limitation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'nodeRenderState', nodeIdentity: NodeIdentity, callback: NodeRenderStateChangeCallback): void; + + /** + * Removes a callback function to be called before tapGesture is called. + * + * @param { 'nodeRenderState' } type - The type of event to remove the listener for. + * @param { NodeIdentity } nodeIdentity - The identity of the target node + * @param { NodeRenderStateChangeCallback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'nodeRenderState', nodeIdentity: NodeIdentity, callback?: NodeRenderStateChangeCallback): void; + + /** + * Registers a callback function to be called when the tabContent is showed or hidden. + * + * @param { 'tabContentUpdate' } type - The type of event to listen for. Must be 'tabContentUpdate'. + * @param { observer.ObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to be called + * when the tabContent show or hide. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'tabContentUpdate', options: observer.ObserverOptions, callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'tabContentUpdate' } type - The type of event to remove the listener for. Must be 'tabContentUpdate'. + * @param { observer.ObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to remove. If not provided, + * all callbacks for the given event type and Tabs ID will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'tabContentUpdate', options: observer.ObserverOptions, callback?: Callback): void; + + /** + * Registers a callback function to be called when the tabContent is showed or hidden. + * + * @param { 'tabContentUpdate' } type - The type of event to listen for. Must be 'tabContentUpdate'. + * @param { Callback } callback - The callback function to be called + * when the tabContent is showed or hidden. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'tabContentUpdate', callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'tabContentUpdate'} type - The type of event to remove the listener for. Must be 'tabContentUpdate'. + * @param { Callback } callback - The callback function to remove. If not provided, + * all callbacks for the given event type and Tabs ID will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'tabContentUpdate', callback?: Callback): void; + + /** + * Registers a callback to monitor the gesture trigger information. + * + * @param { GestureListenerType } type - The type of gesture to monitor. + * @param { GestureObserverConfigs } option - The options when bind the global listener. + * @param { GestureListenerCallback } callback - The callback function to be called when any gesture's state + * is updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + addGlobalGestureListener(type: GestureListenerType, + option: GestureObserverConfigs, callback: GestureListenerCallback): void; + + /** + * Removes a callback function for one gesture listener type. + * + * @param { GestureListenerType } type - The type of event to remove the listener for. + * @param { GestureListenerCallback } [callback] - The callback function to be removed. If not provided, + * all callbacks for the given gesture type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + removeGlobalGestureListener(type: GestureListenerType, callback?: GestureListenerCallback): void; +} + +/** + * class ComponentUtils + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class ComponentUtils { + /** + * Provide the ability to obtain the coordinates and size of component drawing areas. + * + * @param { string } id - ID of the component whose attributes are to be obtained. + * @returns { componentUtils.ComponentInfo } the object of ComponentInfo. + * @throws { BusinessError } 100001 - UI execution context not found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getRectangleById(id: string): componentUtils.ComponentInfo; +} + +/** + * class OverlayManager + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class OverlayManager { + /** + * Add the ComponentContent to the OverlayManager. + * + * @param { ComponentContent } content - The content will be added to the OverlayManager. + * @param { number } [ index ] - The index at which to add the ComponentContent. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + addComponentContent(content: ComponentContent, index?: number): void; + + /** + * Add the ComponentContent to the OverlayManager with order. + * + * @param { ComponentContent } content - The content will be added to the OverlayManager. + * @param { LevelOrder } [ levelOrder ] - The display order of the ComponentContent. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + addComponentContentWithOrder(content: ComponentContent, levelOrder?: LevelOrder): void; + + /** + * Remove the ComponentContent from the OverlayManager. + * + * @param { ComponentContent } content - The content will be removed from the OverlayManager. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + removeComponentContent(content: ComponentContent): void; + + /** + * Show the ComponentContent. + * + * @param { ComponentContent } content - The content will be shown. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showComponentContent(content: ComponentContent): void; + + /** + * Hide the ComponentContent. + * + * @param { ComponentContent } content - The content will be hidden. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + hideComponentContent(content: ComponentContent): void; + + /** + * Show all ComponentContents on the OverlayManager. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showAllComponentContents(): void; + + /** + * Hide all ComponentContents on the OverlayManager. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + hideAllComponentContents(): void; +} + +/** + * interface AtomicServiceBar + * @interface AtomicServiceBar + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface AtomicServiceBar { + /** + * Set the visibility of the bar, except the icon. + * + * @param { boolean } visible - whether this bar is visible. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setVisible(visible: boolean): void; + + /** + * Set the background color of the bar. + * + * @param { Nullable< Color | number | string> } color - the color to set, undefined indicates using default. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setBackgroundColor(color: Nullable< Color | number | string>): void; + + /** + * Set the title of the bar. + * + * @param { string } content - the content of the bar. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setTitleContent(content: string): void; + + /** + * Set the font style of the bar's title. + * + * @param { FontStyle } font - the font style of the bar's title. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setTitleFontStyle(font: FontStyle): void; + + /** + * Set the color of the icon on the bar. + * + * @param { Nullable< Color | number | string> } color - the color to set to icon, undefined indicates using default. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setIconColor(color: Nullable< Color | number | string>): void; + + /** + * Get size and position of the bar. + * + * @returns { Frame } The size and position of bar in vp relative to window. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getBarRect(): Frame; +} + +/** + * Represents a dynamic synchronization scene. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class DynamicSyncScene { + /** + * Sets the FrameRateRange of the DynamicSyncScene. + * + * @param { ExpectedFrameRateRange } range - The range of frameRate. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setFrameRateRange(range: ExpectedFrameRateRange): void; + + /** + * Gets the FrameRateRange of the DynamicSyncScene. + * + * @returns { ExpectedFrameRateRange } The range of frameRate. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getFrameRateRange(): ExpectedFrameRateRange; +} + +/** + * Represents a dynamic synchronization scene of Swiper. + * + * @extends DynamicSyncScene + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class SwiperDynamicSyncScene extends DynamicSyncScene { + /** + * Type of the SwiperDynamicSyncSceneType. + * @type { SwiperDynamicSyncSceneType } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + readonly type: SwiperDynamicSyncSceneType; +} + +/** + * Represents a dynamic synchronization scene of Marquee. + * + * @extends DynamicSyncScene + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class MarqueeDynamicSyncScene extends DynamicSyncScene { + /** + * Type of the MarqueeDynamicSyncSceneType. + * @type { MarqueeDynamicSyncSceneType } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + readonly type: MarqueeDynamicSyncSceneType; +} + +/** + * class DragController + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class DragController { + /** + * Execute a drag event. + * @param { CustomBuilder | DragItemInfo | undefined } custom - Object used for prompts displayed when the object + * is dragged. + * @param { dragController.DragInfo } dragInfo - Information about the drag event. + * @param { AsyncCallback } callback - Callback that contains + * the drag event information. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal handling failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + executeDrag(custom: CustomBuilder | DragItemInfo | undefined, dragInfo: dragController.DragInfo, + callback: AsyncCallback): void; + + /** + * Execute a drag event. + * @param { CustomBuilder | DragItemInfo | undefined } custom - Object used for prompts displayed when the object + * is dragged. + * @param { dragController.DragInfo } dragInfo - Information about the drag event. + * @returns { Promise } A Promise with the drag event information. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal handling failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + executeDrag(custom: CustomBuilder | DragItemInfo | undefined, dragInfo: dragController.DragInfo) + : Promise; + + /** + * Create one drag action object, which can be used for starting drag later or monitoring the drag status after + * drag started. + * @param { Array | undefined } customArray - Objects used for prompts + * displayed when the objects are dragged. + * @param { dragController.DragInfo } dragInfo - Information about the drag event. + * @returns { dragController.DragAction } one drag action object + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Internal handling failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + createDragAction(customArray: Array | undefined, + dragInfo: dragController.DragInfo): dragController.DragAction; + + /** + * Get a drag preview object. + * @returns { dragController.DragPreview } A drag preview object. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getDragPreview(): dragController.DragPreview; + + /** + * Enable drag event strict reporting for drag enter and leave notification in nested situation. + * For example, the parent and child both register the onDragEnter/onDragLeave events, if this + * flag is enabled, the parent will be notified with leave event, and the child will notified with + * enter event at the same time, when user drag action is passing through the parent and enter the + * scope of the child. + * Please be noted, the default value of the flag is false, it means, for the same situation, the + * parent will not receive the leave notification, just the child can get the enter event, which is + * not fully strict. + * @param { boolean } enable - Indicating enable drag event strict reporting or not. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setDragEventStrictReportingEnabled(enable: boolean): void; + + /** + * Notify the drag start request to specific pending or continue. + * @param { dragController.DragStartRequestStatus } requestStatus - Status about the drag start behavior. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + notifyDragStartRequest(requestStatus: dragController.DragStartRequestStatus): void; + + /** + * Cancel the UDMF data sync process by passing in the data key as the identify, can only be used after the drop. + * + * @param { string } key - The data key returned by startDataLoading method. + * @throws { BusinessError } 401 - Parameter error. + * @throws { BusinessError } 190004 - Operation failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + cancelDataLoading(key: string): void; + + /** + * Sets whether to enable the disallow badge icon show. + * + * Typically, when a component can receive or process data dragged by the user, or when it declares to the + * system that data should be processed in COPY way by returning DragBehavior.COPY, the system will display + * a plus sign together with the data number on the upper-left corner of the dragged object; if returning + * DragBehavior.MOVE to the system to declare that data should be processed in CUT way, the system will only + * display the data number on the upper-left corner of the dragged object. + * + * In some cases, when the system determines or the component explicitly declares that it cannot handle the + * data that the user is dragging, the system displays a badge icon in the same way as it does for DragBehavior.MOVE. + * So if you want to show the more clearly status, you can call this method on the UI instance in advance to force + * the system to display a clear prohibition icon on the upper left corner in such cases, and the user can clearly + * know that data cannot be dropped here. + * + * @param { boolean } enabled - Indicating enable the disallow status showing or not. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + enableDropDisallowedBadge(enabled: boolean): void; +} + +/** + * class MeasureUtils + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class MeasureUtils { + /** + * Obtains the width of the specified text in a single line layout. + * + * @param { MeasureOptions } options - Options. + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + measureText(options: MeasureOptions): number; + + /** + * Obtains the width and height of the specified text in a single line layout. + * + * @param { MeasureOptions } options - Options of measure area occupied by text. + * @returns { SizeOptions } width and height for text to display + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + measureTextSize(options: MeasureOptions): SizeOptions; +} + +/** + * class FocusController + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class FocusController { + /** + * clear focus to the root container. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + clearFocus(): void; + + /** + * request focus to the specific component. + * @param { string } key - the inspector key of the component. + * @throws { BusinessError } 150001 - the component cannot be focused. + * @throws { BusinessError } 150002 - This component has an unfocusable ancestor. + * @throws { BusinessError } 150003 - the component is not on tree or does not exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + requestFocus(key: string): void; + + /** + * Activate focus style. + * @param { boolean } isActive - activate/deactivate the focus style. + * @param { boolean } [autoInactive] - deactivate the focus style when touch event or mouse event triggers, + * the default value is true. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + activate(isActive: boolean, autoInactive?: boolean): void; + + /** + * Get whether the focus style is active. + * @returns { boolean } Whether the focus style is active. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + isActive(): boolean; + + /** + * Set whether to enable autofocus transfer. + * @param { boolean } isAutoFocusTransfer - A Boolean value that indicates whether autofocus transfer is enabled. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setAutoFocusTransfer(isAutoFocusTransfer: boolean): void; + + /** + * Set the priority of key event processing when component cannot handle the key event.. + * @param { KeyProcessingMode } mode - Key processing mode. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setKeyProcessingMode(mode: KeyProcessingMode): void; +} + +/** + * Pointer style. + * + * @typedef {pointer.PointerStyle} PointerStyle + * @syscap SystemCapability.MultimodalInput.Input.Pointer + * @since 20 + */ +export type PointerStyle = pointer.PointerStyle; + +/** + * class CursorController + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class CursorController { + /** + * Restore default cursor. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + restoreDefault(): void; + /** + * Set cursor style. + * + * @param { PointerStyle } value - cursor style enum. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setCursor(value: PointerStyle): void; +} + +/** + * class ContextMenuController + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class ContextMenuController { + /** + * Close context menu. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + close(): void; +} + +/** + * Class FrameCallback + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare abstract class FrameCallback { + /** + * Call when a new display frame is being rendered. + * + * @param { number } frameTimeInNano - The frame time in nanoseconds. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onFrame(frameTimeInNano: number): void; + + /** + * Called at the end of the next idle frame. If there is no next frame, will request one automatically. + * + * @param { number } timeLeftInNano - The remaining time from the deadline for this frame. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onIdle(timeLeftInNano: number): void; +} + +/** + * The base context of an ability or an application. It allows access to + * application-specific resources. + * + * @typedef { common.Context } Context + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @StageModelOnly + * @since 20 + */ +export type Context = common.Context; + +/** + * class ComponentSnapshot + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class ComponentSnapshot { + /** + * Get a component snapshot by component id. + * + * @param { string } id - Target component ID, set by developer through .id attribute. + * @param { AsyncCallback } callback - Callback that contains the snapshot in PixelMap format. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Invalid ID. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + get(id: string, callback: AsyncCallback, options?: componentSnapshot.SnapshotOptions): void; + + /** + * Get a component snapshot by component id. + * + * @param { string } id - Target component ID, set by developer through .id attribute. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @returns { Promise } A Promise with the snapshot in PixelMap format. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Invalid ID. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + get(id: string, options?: componentSnapshot.SnapshotOptions): Promise; + + /** + * Generate a snapshot from a custom component builder. + * + * @param { CustomBuilder } builder - Builder function of a custom component. + * @param { AsyncCallback } callback - Callback that contains the snapshot in PixelMap format. + * @param { number } [delay] - Defines the delay time to render the snapshot. + * @param { boolean } [checkImageStatus] - Defines if check the image decoding status before taking snapshot. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The builder is not a valid build function. + * @throws { BusinessError } 160001 - An image component in builder is not ready for taking a snapshot. The check for + * the ready state is required when the checkImageStatus option is enabled. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + createFromBuilder(builder: CustomBuilder, callback: AsyncCallback, + delay?: number, checkImageStatus?: boolean, options?: componentSnapshot.SnapshotOptions): void; + + /** + * Generate a snapshot from a custom component builder. + * + * @param { CustomBuilder } builder - Builder function of a custom component. + * @param { number } [delay] - Defines the delay time to render the snapshot. + * @param { boolean } [checkImageStatus] - Defines if check the image decoding status before taking snapshot. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @returns { Promise } A Promise with the snapshot in PixelMap format. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The builder is not a valid build function. + * @throws { BusinessError } 160001 - An image component in builder is not ready for taking a snapshot. The check for + * the ready state is required when the checkImageStatus option is enabled. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + createFromBuilder(builder: CustomBuilder, delay?: number, + checkImageStatus?: boolean, options?: componentSnapshot.SnapshotOptions): Promise; + + /** + * Take a screenshot of the specified component in synchronous mode, + * this mode will block the main thread, please use it with caution, the maximum + * waiting time of the interface is 3s, if it does not return after 3s, an exception will be thrown. + * + * @param { string } id - Target component ID, set by developer through .id attribute. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @returns { image.PixelMap } The snapshot result in PixelMap format. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Invalid ID. + * @throws { BusinessError } 160002 - Timeout. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getSync(id: string, options?: componentSnapshot.SnapshotOptions): image.PixelMap; + + /** + * Get a component snapshot by uniqueId. + * + * @param { number } uniqueId - The uniqueId of the node, can get through getUniqueId. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @returns { Promise } A Promise with the snapshot in PixelMap format. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Invalid ID. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getWithUniqueId(uniqueId: number, options?: componentSnapshot.SnapshotOptions): Promise; + + /** + * Take a screenshot of the specified component in synchronous mode, + * this mode will block the main thread, please use it with caution, the maximum + * waiting time of the interface is 3s, if it does not return after 3s, an exception will be thrown. + * + * @param { number } uniqueId - The uniqueId of the node, can get through getUniqueId. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @returns { image.PixelMap } The snapshot result in PixelMap format. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Invalid ID. + * @throws { BusinessError } 160002 - Timeout. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getSyncWithUniqueId(uniqueId: number, options?: componentSnapshot.SnapshotOptions): image.PixelMap; + + /** + * Generate a snapshot from a custom component content. + * + * @param { ComponentContent } content - The content to be taken snapshot. + * @param { number } [delay] - Defines the delay time to render the snapshot. + * @param { boolean } [checkImageStatus] - Defines if check the image decoding status before taking snapshot. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @returns { Promise } A Promise with the snapshot in PixelMap format. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - The builder is not a valid build function. + * @throws { BusinessError } 160001 - An image component in builder is not ready for taking a snapshot. The check for + * the ready state is required when the checkImageStatus option is enabled. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + createFromComponent(content: ComponentContent, delay?: number, + checkImageStatus?: boolean, options?: componentSnapshot.SnapshotOptions): Promise; + + /** + * Get a component snapshot by component range. + * + * @param { NodeIdentity } start - the start component ID, set by developer through .id attribute or the unique ID + * get from FrameNode. + * @param { NodeIdentity } end - the end component ID, set by developer through.id attribute or the unique ID + * get from FrameNode. + * @param { boolean } isStartRect - indicating the snapshot rect to use, true for using the + * rect of the start component, false for using the rect of the end component. + * @param { componentSnapshot.SnapshotOptions } [options] - Define the snapshot options. + * @returns { Promise } A Promise with the snapshot in PixelMap format. + * @throws { BusinessError } 202 - The caller is not a system application. + * @throws { BusinessError } 100001 - Invalid ID detected. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + getWithRange(start: NodeIdentity, end: NodeIdentity, isStartRect: boolean, + options?: componentSnapshot.SnapshotOptions): Promise; +} + +/** + * class UIContext + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class UIContext { + /** + * get object font. + * + * @returns { Font } object Font. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getFont(): Font; + + /** + * Check whether the UIContext object is available. + * + * @returns { boolean } Returns true if the UIContext object is available. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + isAvailable(): boolean; + + /** + * get object mediaQuery. + * + * @returns { MediaQuery } object MediaQuery. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getMediaQuery(): MediaQuery; + + /** + * get object UIInspector. + * @returns { UIInspector } object UIInspector. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getUIInspector(): UIInspector; + + /** + * get the filtered attributes of the component tree. + * @param { Array } [filters] - the list of filters used to filter out component tree to be obtained. + * @returns { string } the specified attributes of the component tree in json string. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getFilteredInspectorTree(filters?: Array): string; + + /** + * get the filtered attributes of the component tree with the specified id and depth + * @param { string } id - ID of the specified component tree to be obtained. + * @param { number } depth - depth of the component tree to be obtained. + * @param { Array } [filters] - the list of filters used to filter out component tree to be obtained. + * @returns { string } the specified attributes of the component tree in json string. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getFilteredInspectorTreeById(id: string, depth: number, filters?: Array): string; + + /** + * get object router. + * + * @returns { Router } object Router. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getRouter(): Router; + + /** + * get object PromptAction. + * + * @returns { PromptAction } object PromptAction. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getPromptAction(): PromptAction; + + /** + * get object ComponentUtils. + * @returns { ComponentUtils } object ComponentUtils. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getComponentUtils(): ComponentUtils; + + /** + * Get the UI observer. + * + * @returns { UIObserver } The UI observer. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getUIObserver(): UIObserver; + + /** + * Get object OverlayManager. + * + * @returns { OverlayManager } object OverlayManager. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getOverlayManager(): OverlayManager; + + /** + * Init OverlayManager. + * + * @param { OverlayManagerOptions } options - Options. + * @returns { boolean } Returns true if it is called first and before getting an OverlayManager instance; returns + * false otherwise. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setOverlayManagerOptions(options: OverlayManagerOptions): boolean; + + /** + * Get object OverlayManagerOptions. + * + * @returns { OverlayManagerOptions } object OverlayManagerOptions. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getOverlayManagerOptions(): OverlayManagerOptions; + + /** + * Create an animator object for custom animation. + * + * @param { AnimatorOptions } options - Options. + * @returns { AnimatorResult } + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + createAnimator(options: AnimatorOptions): AnimatorResult; + + /** + * Create an animator object for custom animation. + * + * @param { AnimatorOptions | SimpleAnimatorOptions } options - Options. + * @returns { AnimatorResult } + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + createAnimator(options: AnimatorOptions | SimpleAnimatorOptions): AnimatorResult; + + /** + * Defining animation function + * + * @param { AnimateParam } value - parameters for animation. + * @param { function } event - the closure base on which, the system will create animation automatically + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + animateTo(value: AnimateParam, event: () => void): void; + + /** + * alertDialog display. + * + * @param { AlertDialogParamWithConfirm | AlertDialogParamWithButtons | AlertDialogParamWithOptions } options - + * Options. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showAlertDialog( + options: AlertDialogParamWithConfirm | AlertDialogParamWithButtons | AlertDialogParamWithOptions): void; + + /** + * actionSheet display. + * + * @param { ActionSheetOptions } value - Options. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showActionSheet(value: ActionSheetOptions): void; + + /** + * datePickerDialog display. + * + * @param { DatePickerDialogOptions } options - Options. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showDatePickerDialog(options: DatePickerDialogOptions): void; + + /** + * timePickerDialog display. + * + * @param { TimePickerDialogOptions } options - Options. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showTimePickerDialog(options: TimePickerDialogOptions): void; + + /** + * textPickerDialog display. + * + * @param { TextPickerDialogOptions } options - Options. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showTextPickerDialog(options: TextPickerDialogOptions): void; + + /** + * Run custom functions inside the UIContext scope. + * + * @param { function } callback - The function called through UIContext. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + runScopedTask(callback: () => void): void; + + /** + * Set KeyboardAvoidMode. The default mode is KeyboardAvoidMode.OFFSET + * + * @param { KeyboardAvoidMode } value - The mode of keyboard avoid. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setKeyboardAvoidMode(value: KeyboardAvoidMode): void; + + /** + * Get KeyboardAvoidMode. + * @returns { KeyboardAvoidMode } The mode of keyboard avoid. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getKeyboardAvoidMode(): KeyboardAvoidMode; + + /** + * Set the pixel round mode of the system. The default mode is PixelRoundMode.PIXEL_ROUND_ON_LAYOUT_FINISH. + * + * @param { PixelRoundMode } mode - The mode of pixel round. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setPixelRoundMode(mode: PixelRoundMode): void; + + /** + * Get the pixel round mode of the system. + * + * @returns { PixelRoundMode } the mode of pixel round. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getPixelRoundMode(): PixelRoundMode; + + /** + * Dispach keyboard event to the frameNode with inspector key. + * + * @param { number | string } node - The uniqueId or inspector key of the target FrameNode. + * @returns { boolean } Returns whether the key event is consumed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + dispatchKeyEvent(node: number | string, event: KeyEvent): boolean; + + /** + * Get AtomicServiceBar. + * @returns { Nullable } The atomic service bar. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getAtomicServiceBar(): Nullable; + + /** + * Get DragController. + * @returns { DragController } the DragController + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getDragController(): DragController; + + /** + * Get MeasureUtils. + * @returns { MeasureUtils } the MeasureUtils + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getMeasureUtils(): MeasureUtils; + + /** + * Defining keyframe animation function. + * + * @param { KeyframeAnimateParam } param - overall animation parameters + * @param { Array } keyframes - all keyframe states + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + keyframeAnimateTo(param: KeyframeAnimateParam, keyframes: Array): void; + + /** + * Get FocusController. + * @returns { FocusController } the FocusController + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getFocusController(): FocusController; + + /** + * Define animation functions for immediate distribution. + * + * @param { AnimateParam } param - Set animation effect parameters. + * @param { Callback } event - Specify the closure function that displays dynamic effects, + * and the system will automatically insert transition animations for state changes caused by the closure function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + animateToImmediately(param: AnimateParam, event: Callback): void; + + /** + * Get FrameNode by id. + * + * @param { string } id - The id of FrameNode. + * @returns { FrameNode | null } The instance of FrameNode. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getFrameNodeById(id: string): FrameNode | null; + + /** + * Get the FrameNode attached to current window by id. + * + * @param { string } id - The id of FrameNode. + * @returns { FrameNode | null } The instance of FrameNode. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getAttachedFrameNodeById(id: string): FrameNode | null; + + /** + * Get FrameNode by uniqueId. + * + * @param { number } id - The uniqueId of the FrameNode. + * @returns { FrameNode | null } - The FrameNode with the target uniqueId, or null if the frameNode is not existed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getFrameNodeByUniqueId(id: number): FrameNode | null; + + /** + * Get page information of the frameNode with uniqueId. + * + * @param { number } id - The uniqueId of the target FrameNode. + * @returns { PageInfo } - The page information of the frameNode with the target uniqueId, includes + * navDestination and router page information. If the frame node does not have navDestination and + * router page information, it will return an empty object. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getPageInfoByUniqueId(id: number): PageInfo; + + /** + * Get navigation information of the frameNode with uniqueId. + * + * @param { number } id - The uniqueId of the target FrameNode. + * @returns { observer.NavigationInfo | undefined } - The navigation information of the frameNode with the + * target uniqueId, or undefined if the frameNode is not existed or does not have navigation information. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getNavigationInfoByUniqueId(id: number): observer.NavigationInfo | undefined; + + /** + * Dynamic dimming. + * + * @param { string } id - The id of FrameNode. + * @param { number } value - Compared to the original level of dimming.value range [0,1], + * set values less than 0 to 0 and values greater than 1 to 1. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + setDynamicDimming(id: string, value: number): void; + + /** + * Get object cursor controller. + * + * @returns { CursorController } object cursor controller. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getCursorController(): CursorController; + + /** + * Get object context menu controller. + * + * @returns { ContextMenuController } object context menu controller. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getContextMenuController(): ContextMenuController; + + /** + * Get ComponentSnapshot. + * @returns { ComponentSnapshot } the ComponentSnapshot + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getComponentSnapshot(): ComponentSnapshot; + + /** + * Converts a value in vp units to a value in px. + * @param { number } value + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + vp2px(value: number): number; + + /** + * Converts a value in px units to a value in vp. + * @param { number } value + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + px2vp(value: number): number; + + /** + * Converts a value in fp units to a value in px. + * @param { number } value + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fp2px(value: number): number; + + /** + * Converts a value in px units to a value in fp. + * @param { number } value + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + px2fp(value: number): number; + + /** + * Converts a value in lpx units to a value in px. + * @param { number } value + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + lpx2px(value: number): number; + + /** + * Converts a value in px units to a value in lpx. + * @param { number } value + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + px2lpx(value: number): number; + + /** + * Get current LocalStorage shared from stage. + * + * @returns { LocalStorage | undefined } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @stagemodelonly + * @since 20 + */ + getSharedLocalStorage(): LocalStorage | undefined; + + /** + * Obtains context of the ability. + * + * @returns { Context | undefined } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @stagemodelonly + * @since 20 + */ + getHostContext(): Context | undefined; + + /** + * Get the name of current window. + * + * @returns { string | undefined } The name of current window, or undefined if the window doesn't exist. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getWindowName(): string | undefined; + + /** + * Get the width breakpoint of current window. + * + * @returns { WidthBreakpoint } The width breakpoint of current window. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getWindowWidthBreakpoint(): WidthBreakpoint; + + /** + * Get the height breakpoint of current window. + * + * @returns { HeightBreakpoint } The height breakpoint of current window. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getWindowHeightBreakpoint(): HeightBreakpoint; + + /** + * Open the BindSheet. + * + * @param { ComponentContent } bindSheetContent - The content of BindSheet. + * @param { SheetOptions } sheetOptions - The options of sheet. + * @param { number } targetId - The uniqueId of the FrameNode to which BindSheet is attached. + * @returns { Promise } The promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 120001 - The bindSheetContent is incorrect. + * @throws { BusinessError } 120002 - The bindSheetContent already exists. + * @throws { BusinessError } 120004 - The targetId does not exist. + * @throws { BusinessError } 120005 - The node of targetId is not in the component tree. + * @throws { BusinessError } 120006 - The node of targetId is not a child of the page node or NavDestination node. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + openBindSheet(bindSheetContent: ComponentContent, sheetOptions?: SheetOptions, + targetId?: number): Promise; + + /** + * Update the BindSheet with sheetOptions. + * + * @param { ComponentContent } bindSheetContent - The content of BindSheet. + * @param { SheetOptions } sheetOptions - The update options of sheet. + * @param { boolean } partialUpdate - If true, only the specified properties in the sheetOptions are updated, + * otherwise the rest of the properties are overwritten with the default values. + * Default value is false. + * @returns { Promise } The promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 120001 - The bindSheetContent is incorrect. + * @throws { BusinessError } 120003 - The bindSheetContent cannot be found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + updateBindSheet(bindSheetContent: ComponentContent, sheetOptions: SheetOptions, + partialUpdate?: boolean): Promise; + + /** + * Close the BindSheet. + * + * @param { ComponentContent } bindSheetContent - The content of BindSheet. + * @returns { Promise } The promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 120001 - The bindSheetContent is incorrect. + * @throws { BusinessError } 120003 - The bindSheetContent cannot be found. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + closeBindSheet(bindSheetContent: ComponentContent): Promise; + + /** + * Post a frame callback to run on the next frame. + * + * @param { FrameCallback } frameCallback - The frame callback to run on the next frame. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + postFrameCallback(frameCallback: FrameCallback): void; + + /** + * Post a frame callback to run on the next frame after the specified delay. + * + * @param { FrameCallback } frameCallback - The frame callback to run on the next frame. + * @param { number } delayTime - The delay time in milliseconds, + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + postDelayedFrameCallback(frameCallback: FrameCallback, delayTime: number): void; + + /** + * Require DynamicSyncScene by id. + * + * @param { string } id - The id of DynamicSyncScene. + * @returns { Array} The instance of SwiperDynamicSyncScene. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + requireDynamicSyncScene(id: string): Array; + + /** + * Clear the cache generated by using $r/$rawfile to retrieve resources. This cache is used to accelerate the process + * of repeatedly loading resources. Clearing this cache may slow down the loading speed of resources during page + * overload. + * + * @throws { BusinessError } 202 - The caller is not a system application. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + clearResourceCache(): void; + + /** + * Checks whether current font scale follows the system. + * + * @returns { boolean } Returns true if current font scale follows the system; returns false otherwise. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + isFollowingSystemFontScale(): boolean; + + /** + * Get the max font scale. + * + * @returns { double } The max font scale. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getMaxFontScale(): double; + + /** + * Bind tabs to scrollable container component to automatically hide tab bar. + * + * @param { TabsController } tabsController - The controller of the tabs. + * @param { Scroller } scroller - The controller of the scrollable container component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + bindTabsToScrollable(tabsController: TabsController, scroller: Scroller): void; + + /** + * Unbind tabs from scrollable container component. + * + * @param { TabsController } tabsController - The controller of the tabs. + * @param { Scroller } scroller - The controller of the scrollable container component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + unbindTabsFromScrollable(tabsController: TabsController, scroller: Scroller): void; + + /** + * Bind tabs to nested scrollable container components to automatically hide tab bar. + * + * @param { TabsController } tabsController - The controller of the tabs. + * @param { Scroller } parentScroller - The controller of the parent scrollable container component. + * @param { Scroller } childScroller - The controller of the child scrollable container component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + bindTabsToNestedScrollable(tabsController: TabsController, parentScroller: Scroller, childScroller: Scroller): void; + + /** + * Unbind tabs from nested scrollable container components. + * + * @param { TabsController } tabsController - The controller of the tabs. + * @param { Scroller } parentScroller - The controller of the parent scrollable container component. + * @param { Scroller } childScroller - The controller of the child scrollable container component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + unbindTabsFromNestedScrollable(tabsController: TabsController, parentScroller: Scroller, + childScroller: Scroller): void; + + /** + * whether to enable or disable swipe to back event. + * + * @param { Optional } enabled - enable or disable swipe to back event. + * @syscap SystemCapability.ArkUI.ArkUI.Circle + * @since 20 + */ + enableSwipeBack(enabled: Optional): void; + + /** + * Open the BindContentCover. + * + * @param { ComponentContent } content - The content of BindContentCover. + * @param { ContentCoverController } controller - ContentCover controller. + * @param { ContentCoverOptions } [contentCoverOptions] - The options of contentCover. + * @param { number } [targetId] - The uniqueId of the FrameNode to which BindContentCover is attached. + * @returns { Promise } The promise returned by the function. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 120301 - The BindContentCover is incorrect. + * @throws { BusinessError } 120302 - The BindContentCover already exists. + * @throws { BusinessError } 120304 - The targetId does not exist. + * @throws { BusinessError } 120305 - The node of targetId is not in the component tree. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + openBindContentCover(content: ComponentContent, controller: ContentCoverController, + contentCoverOptions?: ContentCoverOptions, targetId?: number): Promise; + + /** + * Sets the component freezing flag based on the component id to prevent the + * UI component from marking and updating dirty areas. + * @param { string } id - Id of the frame node. + * @param { boolean } isFrozen - whether the component is frozen. + * @throws { BusinessError } 202 - The caller is not a system application. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + freezeUINode(id: string, isFrozen: boolean): void; + + /** + * Sets the component freezing flag based on the component uniqueId to prevent the + * UI component from marking and updating dirty areas. + * @param { number } uniqueId - Unique Id of the frame node. + * @param { boolean } isFrozen - whether the component is frozen. + * @throws { BusinessError } 202 - The caller is not a system application. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + freezeUINode(uniqueId: number, isFrozen: boolean): void; + + /** + * Get object text menu controller. + * + * @returns { TextMenuController } object text menu controller. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getTextMenuController(): TextMenuController; + + /** + * Create a UI instance singleton without window and get its UIContext object. + * + * @param { common.UIAbilityContext | common.ExtensionContext } context - UIAbilityContext or ExtensionContext. + * @returns { UIContext | undefined } object UIContext, or undefined when failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. The number of parameters is incorrect. + *
2. Invalid parameter type of context. + * @throws { BusinessError } 100001 - Internal error. + * @static + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + static createUIContextWithoutWindow( + context: common.UIAbilityContext | common.ExtensionContext): UIContext | undefined; + + /** + * Destroy the UI instance singleton without window. + * + * @static + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + static destroyUIContextWithoutWindow(): void; + + /** + * Thread-safe UI state variables updates interface. + * + * @param { VoidCallback } callback - The callback function to be executed in the UI thread. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setUIStates(callback: VoidCallback): void; + + /** + * Retrieves the UIContext corresponding to the UI instance of the currently focused window. + * Returns undefined if it does not exist. + * + * @returns { UIContext | undefined } The focused UIContext, or undefined if it does not exist. + * @static + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + static getFocusedUIContext(): UIContext | undefined; +} + +/** + * Enum of KeyBoardAvoidMethodType + * + * @enum { number } KeyBoardAvoidMethodType + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const enum KeyboardAvoidMode { + /** + * Default Type, offset the whole page when keyBoard height changed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + OFFSET = 0, + + /** + * Resize Type, resize the page when keyBoard height changed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + RESIZE = 1, + + /** + * Offset Type, offset the whole page when caret position or keyboard height changed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + OFFSET_WITH_CARET = 2, + + /** + * Resize Type, resize the whole page when when caret position or keyboard height changed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + RESIZE_WITH_CARET = 3, + + /** + * None Type, nothing to do when keyboard height changed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + NONE = 4 +} + +/** + * Enum of SwiperDynamicSyncSceneType + * + * @enum { number } SwiperDynamicSyncSceneType + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const enum SwiperDynamicSyncSceneType { + /** + * Scene type is GESTURE. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + GESTURE = 0, + + /** + * Scene type is ANIMATION. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ANIMATION = 1 +} + +/** + * Enum of scene type for Marquee + * + * @enum { number } MarqueeDynamicSyncSceneType + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const enum MarqueeDynamicSyncSceneType { + /** + * Scene type is ANIMATION. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ANIMATION = 1 +} + +/** + * class TextMenuController + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class TextMenuController { + /** + * Set text menu options. + * + * @param { TextMenuOptions } options - the options of the text menu. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setMenuOptions(options: TextMenuOptions): void; + + /** + * Disable all system service menus, such as translation and ai writer. + * True means disable, false means enable. + * + * @param { boolean } disable - flag to disable service menu items + * @static + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + static disableSystemServiceMenuItems(disable: boolean): void; +} + +/** + * The class used to control ContentConver + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class ContentCoverController { + /** + * The constructor. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(); + + /** + * Update cotentCoverOptions. + * + * @param { ContentCoverOptions } contentCoverOptions - The options of contentCover. + * @param { boolean } [partialUpdate] - If true, only the specified properties in the sheetOptions are updated, + * otherwise the rest of the properties are overwritten with the default values. + * Default value is false. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + update(contentCoverOptions: ContentCoverOptions, partialUpdate?: boolean): void; + + /** + * Close contentConver. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + close(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.ChipGroup.d.ets b/api/@ohos.arkui.advanced.ChipGroup.d.ets index 1242e40f7ab976df799aa0b5a870eef8a043d748..bc833d450a26fa434c2aed87a31e6a63678bf675 100644 --- a/api/@ohos.arkui.advanced.ChipGroup.d.ets +++ b/api/@ohos.arkui.advanced.ChipGroup.d.ets @@ -668,7 +668,7 @@ export declare struct ChipGroup { chipGroupPadding?: ChipGroupPaddingOptions; /** - * Chip group callback. + * Chip group callback. when chip status is changed, this onChange is called. * * @type { ?Callback> } * @syscap SystemCapability.ArkUI.ArkUI.Full diff --git a/api/@ohos.arkui.advanced.ComposeListItem.d.ets b/api/@ohos.arkui.advanced.ComposeListItem.d.ets index e62ea4898c24b03b8173ca0e6620dc5969386935..022f294323fa08766e535b212247c9b4b927a03c 100644 --- a/api/@ohos.arkui.advanced.ComposeListItem.d.ets +++ b/api/@ohos.arkui.advanced.ComposeListItem.d.ets @@ -18,20 +18,14 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Component } from './arkui/component/customComponent'; -import { ResourceStr } from './arkui/component/units'; -import { PropRef } from './arkui/stateManagement/decorator'; -import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; -import { Builder } from './arkui/component/builder'; -/*** endif */ - /** * Declare enum IconType * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 */ + + /** * Declare enum IconType * @enum { number } @@ -46,7 +40,6 @@ import { Builder } from './arkui/component/builder'; * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ export declare enum IconType { /** @@ -66,7 +59,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ BADGE = 1, /** @@ -86,7 +78,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ NORMAL_ICON = 2, /** @@ -106,7 +97,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ SYSTEM_ICON = 3, /** @@ -126,7 +116,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ HEAD_SCULPTURE = 4, /** @@ -146,7 +135,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ APP_ICON = 5, /** @@ -166,7 +154,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ PREVIEW = 6, /** @@ -186,7 +173,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ LONGITUDINAL = 7, /** @@ -206,7 +192,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ VERTICAL = 8 } @@ -228,7 +213,6 @@ export declare enum IconType { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ export declare class OperateIcon { /** @@ -251,7 +235,6 @@ export declare class OperateIcon { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ value: ResourceStr; @@ -269,7 +252,6 @@ export declare class OperateIcon { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ symbolStyle?: SymbolGlyphModifier; @@ -293,7 +275,6 @@ export declare class OperateIcon { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ action?: () => void; @@ -313,7 +294,6 @@ export declare class OperateIcon { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityText?: ResourceStr; @@ -333,7 +313,6 @@ export declare class OperateIcon { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityDescription?: ResourceStr; @@ -355,7 +334,6 @@ export declare class OperateIcon { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityLevel?: string; } @@ -377,7 +355,6 @@ export declare class OperateIcon { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ export declare class OperateCheck { /** @@ -400,7 +377,6 @@ export declare class OperateCheck { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ isCheck?: boolean; @@ -424,7 +400,6 @@ export declare class OperateCheck { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ onChange?: (value: boolean) => void; @@ -444,7 +419,6 @@ export declare class OperateCheck { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityText?: ResourceStr; @@ -464,7 +438,6 @@ export declare class OperateCheck { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityDescription?: ResourceStr; @@ -486,7 +459,6 @@ export declare class OperateCheck { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityLevel?: string; } @@ -508,7 +480,6 @@ export declare class OperateCheck { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ export declare class OperateButton { /** @@ -531,7 +502,6 @@ export declare class OperateButton { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ text?: ResourceStr; @@ -551,7 +521,6 @@ export declare class OperateButton { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityText?: ResourceStr; @@ -571,7 +540,6 @@ export declare class OperateButton { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityDescription?: ResourceStr; @@ -593,7 +561,6 @@ export declare class OperateButton { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ accessibilityLevel?: string; } @@ -615,7 +582,6 @@ export declare class OperateButton { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ export declare class ContentItem { /** @@ -638,7 +604,6 @@ export declare class ContentItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ iconStyle?: IconType; @@ -662,7 +627,6 @@ export declare class ContentItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ icon?: ResourceStr; @@ -680,7 +644,6 @@ export declare class ContentItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ symbolStyle?: SymbolGlyphModifier; @@ -704,7 +667,6 @@ export declare class ContentItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ primaryText?: ResourceStr; @@ -728,7 +690,6 @@ export declare class ContentItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ secondaryText?: ResourceStr; @@ -752,7 +713,6 @@ export declare class ContentItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ description?: ResourceStr; } @@ -774,7 +734,6 @@ export declare class ContentItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ export declare class OperateItem { /** @@ -797,7 +756,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ icon?: OperateIcon; @@ -821,7 +779,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ subIcon?: OperateIcon; @@ -845,7 +802,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ button?: OperateButton; @@ -869,21 +825,9 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1 */ switch?: OperateCheck; - /** - * Sets the toggle. - * @type { ?OperateCheck } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - toggle?: OperateCheck; - /** * Sets the checkBox. * @type { ?OperateCheck } @@ -904,7 +848,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ checkbox?: OperateCheck; @@ -928,7 +871,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ radio?: OperateCheck; @@ -952,7 +894,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ image?: ResourceStr; @@ -970,7 +911,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ symbolStyle?: SymbolGlyphModifier; @@ -994,7 +934,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ text?: ResourceStr; @@ -1018,7 +957,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ arrow?: OperateIcon; } @@ -1046,7 +984,6 @@ export declare class OperateItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ @Component export declare struct ComposeListItem { @@ -1070,21 +1007,9 @@ export declare struct ComposeListItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1 */ @Prop contentItem?: ContentItem; - /** - * The ContentItem. - * @type { ?ContentItem } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef contentItem?: ContentItem; - /** * The OperateItem. * @type { ?OperateItem } @@ -1105,27 +1030,6 @@ export declare struct ComposeListItem { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1 */ @Prop operateItem?: OperateItem; - - /** - * The OperateItem. - * @type { ?OperateItem } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef operateItem?: OperateItem; - - /** - * The method to build component. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @Builder build(): void; } \ No newline at end of file diff --git a/api/@internal/component/ets/location_button.d.ts b/api/@ohos.arkui.advanced.ComposeListItem.static.d.ets similarity index 30% rename from api/@internal/component/ets/location_button.d.ts rename to api/@ohos.arkui.advanced.ComposeListItem.static.d.ets index b6c3c31d04e0a79e00d4e1a24cf44e4dabbbaf46..356bdf70bde70d95c0ac89a3927791670388e96c 100644 --- a/api/@internal/component/ets/location_button.d.ts +++ b/api/@ohos.arkui.advanced.ComposeListItem.static.d.ets @@ -1,537 +1,426 @@ -/* - * Copyright (c) 2023 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit ArkUI - */ - -/** - * Enumerates the icon styles. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ -/** - * Enumerates the icon styles. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ -declare enum LocationIconStyle { - /** - * Icon filled with the specified color. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Icon filled with the specified color. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - FULL_FILLED = 0, - - /** - * Icon rendered as lines. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Icon rendered as lines. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - LINES = 1 -} - -/** - * Enumerates the text that can be displayed on the location button. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ -/** - * Enumerates the text that can be displayed on the location button. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ -declare enum LocationDescription { - /** - * Current Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Current Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - CURRENT_LOCATION = 0, - - /** - * Add Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Add Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - ADD_LOCATION = 1, - - /** - * Select Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Select Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - SELECT_LOCATION = 2, - - /** - * Share Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Share Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - SHARE_LOCATION = 3, - - /** - * Send Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Send Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - SEND_LOCATION = 4, - - /** - * Locating - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Locating - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - LOCATING = 5, - - /** - * Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - LOCATION = 6, - - /** - * Send Current Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Send Current Location - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - SEND_CURRENT_LOCATION = 7, - - /** - * Relocation - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Relocation - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - RELOCATION = 8, - - /** - * Punch In - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Punch In - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - PUNCH_IN = 9, - - /** - * Current Position - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Current Position - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - CURRENT_POSITION = 10 -} - -/** - * Declares the interface for setting the location button options. - * - * @interface LocationButtonOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ -/** - * Declares the interface for setting the location button options. - * - * @interface LocationButtonOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ -declare interface LocationButtonOptions { - /** - * Style of the icon to be drawn. - * - * @type { ?LocationIconStyle } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Style of the icon to be drawn. - * - * @type { ?LocationIconStyle } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - icon?: LocationIconStyle; - - /** - * Text to be displayed on the button. - * - * @type { ?LocationDescription } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Text to be displayed on the button. - * - * @type { ?LocationDescription } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - text?: LocationDescription; - - /** - * Type of the button. - * - * @type { ?ButtonType } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Type of the button. - * - * @type { ?ButtonType } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - buttonType?: ButtonType; -} - -/** - * Enumerates the click event results of the location button. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ -/** - * Enumerates the click event results of the location button. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ -declare enum LocationButtonOnClickResult { - /** - * Success. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Success. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - SUCCESS = 0, - - /** - * Failure because the application is not temporarily authorized for accessing location data. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Failure because the application is not temporarily authorized for accessing location data. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - TEMPORARY_AUTHORIZATION_FAILED = 1 -} - -/** - * Defines the interface for setting a location button. - * - * @interface LocationButtonInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ -/** - * Defines the interface for setting a location button. - * - * @interface LocationButtonInterface - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ -interface LocationButtonInterface { - /** - * Creates a location button. - * - * @returns { LocationButtonAttribute } TReturns the attribute of the location button. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Creates a location button. - * - * @returns { LocationButtonAttribute } TReturns the attribute of the location button. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - (): LocationButtonAttribute; - - /** - * Creates a location button with the specified composition. - * If an attribute is not set, the corresponding element will not be drawn. - * - * @param { LocationButtonOptions } options - Indicates the options of the location button. - * @returns { LocationButtonAttribute } Returns the attribute of the location button. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Creates a location button with the specified composition. - * If an attribute is not set, the corresponding element will not be drawn. - * - * @param { LocationButtonOptions } options - Indicates the options of the location button. - * @returns { LocationButtonAttribute } Returns the attribute of the location button. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ - (options: LocationButtonOptions): LocationButtonAttribute; -} - -/** - * Callback function when the location button is clicked. - * - * @typedef { function } LocationButtonCallback - * @param { ClickEvent } event - The click event. - * @param { LocationButtonOnClickResult } result - The result of click event. - * @param { BusinessError } [error] - The error code and message of click event. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 18 - */ -type LocationButtonCallback = (event: ClickEvent, result: LocationButtonOnClickResult, error?: BusinessError) => void; - -/** - * Defines the attributes of the location button. - * - * @extends SecurityComponentMethod - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ -/** - * Defines the attributes of the location button. - * - * @extends SecurityComponentMethod - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ -declare class LocationButtonAttribute extends SecurityComponentMethod { - /** - * Called when the location button is clicked. - * - * @param { function } event - * @returns { LocationButtonAttribute } Returns the attribute of the location button. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Called when the location button is clicked. - * - * @param { function } event - * @returns { LocationButtonAttribute } Returns the attribute of the location button. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * Called when the location button is clicked. - * - * @param { LocationButtonCallback } event - * @returns { LocationButtonAttribute } Returns the attribute of the location button. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 18 - */ - onClick(event: LocationButtonCallback): LocationButtonAttribute; -} - -/** - * Defines a button that interacts with the security component service to - * request the authorization for accessing location data. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ -/** - * Defines a button that interacts with the security component service to - * request the authorization for accessing location data. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - * @useinstead ohos.abilityAccessCtrl#requestPermissionsFromUser - */ -declare const LocationButton: LocationButtonInterface; - -/** - * Defines a location button instance for secure access. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ -/** - * Defines a location button instance for secure access. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - * @deprecated since 15 - */ -declare const LocationButtonInstance: LocationButtonAttribute; +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Component } from './arkui/component/customComponent'; +import { ResourceStr } from './arkui/component/units'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { Builder } from './arkui/component/builder'; +/** + * Declare enum IconType + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum IconType { + /** + * Badge type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + BADGE = 1, + /** + * Normal icon type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + NORMAL_ICON = 2, + /** + * System icon type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + SYSTEM_ICON = 3, + /** + * HeadSculpture type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + HEAD_SCULPTURE = 4, + /** + * App icon type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + APP_ICON = 5, + /** + * Preview type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + PREVIEW = 6, + /** + * Longitudinal type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + LONGITUDINAL = 7, + /** + * Vertical type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + VERTICAL = 8 +} +/** + * Declare type OperateIcon + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class OperateIcon { + /** + * The content of text or the address of icon. + * + * @type { ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public value: ResourceStr; + /** + * The content of text or the address of symbol. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public symbolStyle?: SymbolGlyphModifier; + + /** + * Callback function when operate the icon. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public action?: () => void; + /** + * The accessibilityText of the icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of the icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of the icon. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; +} +/** + * Declare type OperateCheck + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class OperateCheck { + /** + * Whether is checked on default. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public isCheck?: boolean; + /** + * Callback function when operate the checkbox/switch/radio. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public onChange?: (value: boolean) => void; + /** + * The accessibilityText of the checkbox/switch/radio. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of the checkbox/switch/radio. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of the checkbox/switch/radio. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; +} +/** + * Declare type OperateButton + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class OperateButton { + /** + * The text on the button. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public text?: ResourceStr; + /** + * The accessibilityText of the button. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of the button. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of the button. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; +} +/** + * Declare ContentItem + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class ContentItem { + /** + * The type of icon. + * + * @type { ?IconType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public iconStyle?: IconType; + /** + * Sets the icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public icon?: ResourceStr; + /** + * Sets the symbol. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public symbolStyle?: SymbolGlyphModifier; + /** + * Sets the primaryText. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public primaryText?: ResourceStr; + /** + * Sets the secondaryText. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public secondaryText?: ResourceStr; + /** + * Sets the description. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public description?: ResourceStr; +} +/** + * Declare OperateItem + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class OperateItem { + /** + * Sets the icon. + * + * @type { ?OperateIcon } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public icon?: OperateIcon; + /** + * Sets the subIcon. + * + * @type { ?OperateIcon } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public subIcon?: OperateIcon; + /** + * Sets the button. + * + * @type { ?OperateButton } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public button?: OperateButton; + /** + * Sets the toggle. + * + * @type { ?OperateCheck } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public toggle?: OperateCheck; + /** + * Sets the checkBox. + * + * @type { ?OperateCheck } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public checkbox?: OperateCheck; + /** + * Sets the radio. + * + * @type { ?OperateCheck } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public radio?: OperateCheck; + /** + * Sets the image. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public image?: ResourceStr; + /** + * Sets the symbolStyle. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public symbolStyle?: SymbolGlyphModifier; + /** + * Sets the text. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public text?: ResourceStr; + /** + * Sets the arrow. + * + * @type { ?OperateIcon } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public arrow?: OperateIcon; +} +/** + * Declare ComposeListItem + * + * @struct { ComposeListItem } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct ComposeListItem { + /** + * The ContentItem. + * + * @type { ?ContentItem } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + contentItem?: ContentItem; + /** + * The OperateItem. + * + * @type { ?OperateItem } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + operateItem?: OperateItem; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.ComposeTitleBar.static.d.ets b/api/@ohos.arkui.advanced.ComposeTitleBar.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..29c4b4d251b696fe62a67190ac371be24b88336b --- /dev/null +++ b/api/@ohos.arkui.advanced.ComposeTitleBar.static.d.ets @@ -0,0 +1,154 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceStr } from './arkui/component/units'; +import { Component } from './arkui/component/customComponent'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { Builder } from './arkui/component/builder'; +/** + * Declaration of the menu item on the right side. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class ComposeTitleBarMenuItem { + /** + * Icon resource for this menu item. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public value: ResourceStr; + /** + * Symbol resource for this menu item. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public symbolStyle?: SymbolGlyphModifier; + /** + * Icon label for this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public label?: ResourceStr; + /** + * Whether to enable this menu item. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public isEnabled?: boolean; + /** + * Callback function when click on this menu item. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public action?: () => void; + /** + * The accessibilityText of this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of this menu item. + * + * @type { ?string } + * @default "auto".The options are as follows:
+ * "auto":The value is converted to "yes" or "no" based on the component. + * "yes": the current component is selectable for the accessibility service. + * "no": The current component is not selectable for the accessibility service. + * "no-hide-descendants":The current component and all its child components are not selectable
+ * for the accessibility service. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; +} +/** + * Declaration of the composable title bar. + * @struct { ComposeTitleBar } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct ComposeTitleBar { + /** + * Avatar resource and event callback of this title bar. + * + * @type { ?ComposeTitleBarMenuItem } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + item?: ComposeTitleBarMenuItem; + /** + * Title of this title bar. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + title: ResourceStr; + /** + * Sub-title of this title bar. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + subtitle?: ResourceStr; + /** + * Menu items on the right side. + * + * @type { ?Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + menuItems?: Array; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.Dialog.static.d.ets b/api/@ohos.arkui.advanced.Dialog.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..51e8a6db630fa935abc540586540fc64027ae96d --- /dev/null +++ b/api/@ohos.arkui.advanced.Dialog.static.d.ets @@ -0,0 +1,672 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Theme, CustomTheme } from './@ohos.arkui.theme'; +import { Component, CustomDialog } from './arkui/component/customComponent'; +import { ResourceStr, ResourceColor, Padding, LocalizedPadding, SizeOptions } from './arkui/component/units'; +import { ButtonStyleMode, ButtonRole } from './arkui/component/button'; +import { PixelMap, ThemeColorMode, CustomPopupOptions } from './arkui/component/common'; +import { PropRef, Link, Require } from './arkui/stateManagement/decorator'; +import { Callback } from './@ohos.base'; +import { CustomDialogController } from './arkui/component/customDialogController'; +import { BuilderParam, Builder } from './arkui/component/builder'; +import { SheetInfo } from './arkui/component/actionSheet'; +/** + * Declare ButtonOptions + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class ButtonOptions { + /** + * Sets the Display Content of a Button. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public value: ResourceStr; + /** + * Sets the Button Callback. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public action?: () => void; + /** + * Sets the background color of a button. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public background?: ResourceColor; + /** + * Sets the Button Text Color. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public fontColor?: ResourceColor; + /** + * Describes the Button style. + * + * @type { ?ButtonStyleMode } + * @default ButtonStyleMode.TEXTUAL + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public buttonStyle?: ButtonStyleMode; + /** + * Describes the Button role. + * + * @type { ?ButtonRole } + * @default ButtonRole.NORMAL + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public role?: ButtonRole; + /** + * Set the default focus of a button. + * + * @type { ?boolean } + * @default { false } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public defaultFocus?: boolean; +} +/** + * Declare CustomDialog TipsDialog + * @struct { TipsDialog } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@CustomDialog +export declare struct TipsDialog { + /** + * Sets the TipsDialog Controller. + * + * @type { CustomDialogController } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + controller: CustomDialogController; + /** + * Sets the TipsDialog imageRes. + * + * @type { ResourceStr | PixelMap } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + imageRes: ResourceStr | PixelMap; + /** + * Sets the TipsDialog image size. + * + * @type { ?SizeOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + imageSize?: SizeOptions; + /** + * Sets the TipsDialog title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + title?: ResourceStr; + /** + * Sets the TipsDialog content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + content?: ResourceStr; + /** + * Sets the TipsDialog checkbox tips. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + checkTips?: ResourceStr; + /** + * Sets the TipsDialog checkbox check state. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef isChecked?: boolean; + /** + * Sets the TipsDialog CheckBox Callback. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + checkAction?: (isChecked: boolean) => void; + /** + * Sets the TipsDialog primary button. + * + * @type { ?ButtonOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryButton?: ButtonOptions; + /** + * Sets the TipsDialog secondary button. + * + * @type { ?ButtonOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryButton?: ButtonOptions; + /** + * Custom Theme. + * + * @type { ?(Theme | CustomTheme) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + theme?: Theme | CustomTheme; + /** + * Sets the TipsDialog dark or light Mode. + * + * @type { ?ThemeColorMode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + themeColorMode?: ThemeColorMode; + /** + * Sets the TipsDialog CheckBox Callback. + * + * @type { ?Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onCheckedChange?: Callback; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} +/** + * Declare CustomDialog SelectDialog + * @struct { SelectDialog } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@CustomDialog +export declare struct SelectDialog { + /** + * Sets the SelectDialog Controller. + * + * @type { CustomDialogController } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + controller: CustomDialogController; + /** + * Sets the SelectDialog title. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + title: ResourceStr; + /** + * Sets the SelectDialog content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + content?: ResourceStr; + /** + * Sets the SelectDialog selected index. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + selectedIndex?: int; + /** + * Sets the SelectDialog confirm button. + * + * @type { ?ButtonOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + confirm?: ButtonOptions; + /** + * Sets the SelectDialog sheets. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + radioContent: Array; + /** + * Custom Theme. + * + * @type { ?(Theme | CustomTheme) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + theme?: Theme | CustomTheme; + /** + * Sets the SelectDialog dark or light Mode. + * + * @type { ?ThemeColorMode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + themeColorMode?: ThemeColorMode; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} +/** + * Declare CustomDialog ConfirmDialog + * @struct { ConfirmDialog } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@CustomDialog +export declare struct ConfirmDialog { + /** + * Sets the ConfirmDialog Controller. + * + * @type { CustomDialogController } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + controller: CustomDialogController; + /** + * Sets the ConfirmDialog title. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + title: ResourceStr; + /** + * Sets the ConfirmDialog content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + content?: ResourceStr; + /** + * Sets the ConfirmDialog checkbox tips. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + checkTips?: ResourceStr; + /** + * Sets the ConfirmDialog checkbox state. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef isChecked?: boolean; + /** + * Sets the ConfirmDialog primary button. + * + * @type { ?ButtonOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryButton?: ButtonOptions; + /** + * Sets the ConfirmDialog secondary button. + * + * @type { ?ButtonOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryButton?: ButtonOptions; + /** + * Custom Theme. + * + * @type { ?(Theme | CustomTheme) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + theme?: Theme | CustomTheme; + /** + * Sets the ConfirmDialog dark or light Mode. + * + * @type { ?ThemeColorMode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + themeColorMode?: ThemeColorMode; + /** + * Sets the ConfirmDialog CheckBox Callback. + * + * @type { ?Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onCheckedChange?: Callback; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} +/** + * Declare CustomDialog AlertDialog + * @struct { AlertDialog } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@CustomDialog +export declare struct AlertDialog { + /** + * Sets the AlertDialog Controller. + * + * @type { CustomDialogController } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + controller: CustomDialogController; + /** + * Sets the AlertDialog title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryTitle?: ResourceStr; + /** + * Sets the AlertDialog secondary title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryTitle?: ResourceStr; + /** + * Sets the AlertDialog content. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + content: ResourceStr; + /** + * Sets the AlertDialog primary button. + * + * @type { ?ButtonOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryButton?: ButtonOptions; + /** + * Sets the AlertDialog secondary button. + * + * @type { ?ButtonOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryButton?: ButtonOptions; + /** + * Custom Theme. + * + * @type { ?(Theme | CustomTheme) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + theme?: Theme | CustomTheme; + /** + * Sets the AlertDialog dark or light Mode. + * + * @type { ?ThemeColorMode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + themeColorMode?: ThemeColorMode; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} +/** + * Declare CustomDialog LoadingDialog + * @struct { LoadingDialog } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@CustomDialog +export declare struct LoadingDialog { + /** + * Sets the LoadingDialog Controller. + * + * @type { CustomDialogController } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Controller: CustomDialogController; + /** + * Sets the LoadingDialog content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + content?: ResourceStr; + /** + * Custom Theme. + * + * @type { ?(Theme | CustomTheme) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + theme?: Theme | CustomTheme; + /** + * Sets the LoadingDialog dark or light Mode. + * + * @type { ?ThemeColorMode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + themeColorMode?: ThemeColorMode; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} +/** + * Declare custom content dialog + * @struct { CustomContentDialog } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@CustomDialog +export declare struct CustomContentDialog { + /** + * Sets the CustomContentDialog Controller. + * + * @type { CustomDialogController } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + controller: CustomDialogController; + /** + * Sets the CustomContentDialog title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryTitle?: ResourceStr; + /** + * Sets the CustomContentDialog secondary title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryTitle?: ResourceStr; + /** + * Sets the CustomContentDialog content. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam + contentBuilder: () => void; + /** + * Sets the CustomContentDialog content area padding. + * + * @type { ?Padding } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + contentAreaPadding?: Padding; + /** + * Sets the CustomContentDialog content area localized padding. + * + * @type { ?LocalizedPadding } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + localizedContentAreaPadding?: LocalizedPadding; + /** + * Sets the CustomContentDialog buttons. + * + * @type { ?ButtonOptions[] } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + buttons?: ButtonOptions[]; + /** + * Custom Theme. + * + * @type { ?(Theme | CustomTheme) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + theme?: Theme | CustomTheme; + /** + * Sets the CustomContentDialog dark or light Mode. + * + * @type { ?ThemeColorMode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + themeColorMode?: ThemeColorMode; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} +/** + * Declare struct PopoverDialog + * @struct { PopoverDialog } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct PopoverDialog { + /** + * Sets the PopoverDialog Visible Status. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Link visible: boolean; + /** + * Sets the PopoverDialog options. + * + * @type { PopoverOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require @PropRef + popover: PopoverOptions; + /** + * Sets the targetBuilder content. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require @BuilderParam + targetBuilder: () => void; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} +/** + * Defines PopoverDialog Options + * + * @extends CustomPopupOptions + * @typedef PopoverOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare interface PopoverOptions extends CustomPopupOptions { +} diff --git a/api/@ohos.arkui.advanced.DialogV2.static.d.ets b/api/@ohos.arkui.advanced.DialogV2.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..8945fa8cbe595899922f9ea363e959820ae131a8 --- /dev/null +++ b/api/@ohos.arkui.advanced.DialogV2.static.d.ets @@ -0,0 +1,714 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ComponentV2 } from './arkui/component/customComponent'; +import { ResourceStr, ResourceColor, LocalizedPadding, SizeOptions } from './arkui/component/units'; +import { ButtonStyleMode, ButtonRole } from './arkui/component/button'; +import { PixelMap, ThemeColorMode, CustomPopupOptions } from './arkui/component/common'; +import { Local, Param, ObservedV2, Require, Trace, Event } from './arkui/stateManagement/decorator'; +import { BuilderParam, Builder, CustomBuilder } from './arkui/component/builder'; +import { LengthMetrics, ColorMetrics } from './arkui/Graphics'; +import { SheetInfo } from './arkui/component/actionSheet'; +/** + * Declare the action when the button of dialog is clicked. + * + * @typedef { function } AdvancedDialogV2ButtonAction + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare type AdvancedDialogV2ButtonAction = () => void; +/** + * Declare AdvancedDialogV2Button. + * + * @class AdvancedDialogV2Button + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class AdvancedDialogV2Button { + /** + * Sets the Display Content of a Button. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public content: ResourceStr; + /** + * Sets the Button Callback. + * + * @type { ?AdvancedDialogV2ButtonAction } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public action?: AdvancedDialogV2ButtonAction; + /** + * Sets the background color of a button. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public background?: ColorMetrics; + /** + * Sets the Button Text Color. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public fontColor?: ColorMetrics; + /** + * Describes the Button style. + * + * @type { ?ButtonStyleMode } + * @default ButtonStyleMode.TEXTUAL + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public buttonStyle?: ButtonStyleMode; + /** + * Describes the Button role. + * + * @type { ?ButtonRole } + * @default ButtonRole.NORMAL + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public role?: ButtonRole; + /** + * Set the default focus of a button. + * + * @type { ?boolean } + * @default { false } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public defaultFocus?: boolean; + /** + * Set the availability of the button. + * + * @type { ?boolean } + * @default { true } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public enabled?: boolean; + /** + * The constructor used to create a AdvancedDialogV2Button object. + * + * @param { AdvancedDialogV2ButtonOptions } options - button info. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options: AdvancedDialogV2ButtonOptions); +} +/** + * Declare the options of AdvancedDialogV2Button + * + * @interface AdvancedDialogV2ButtonOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare interface AdvancedDialogV2ButtonOptions { + /** + * Sets the Display Content of a Button. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + content: ResourceStr; + /** + * Sets the Button Callback. + * + * @type { ?AdvancedDialogV2ButtonAction } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + action?: AdvancedDialogV2ButtonAction; + /** + * Sets the background color of a button. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + background?: ColorMetrics; + /** + * Sets the Button Text Color. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontColor?: ColorMetrics; + /** + * Describes the Button style. + * + * @type { ?ButtonStyleMode } + * @default ButtonStyleMode.TEXTUAL + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + buttonStyle?: ButtonStyleMode; + /** + * Describes the Button role. + * + * @type { ?ButtonRole } + * @default ButtonRole.NORMAL + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + role?: ButtonRole; + /** + * Set the default focus of a button. + * + * @type { ?boolean } + * @default { false } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + defaultFocus?: boolean; + /** + * Set the availability of the button. + * + * @type { ?boolean } + * @default { true } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + enabled?: boolean; +} +/** + * Declare the callback when the checkbox of dialog is changed. + * + * @typedef { function } AdvancedDialogV2OnCheckedChange + * @param { boolean } checked - Checkbox status. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare type AdvancedDialogV2OnCheckedChange = (checked: boolean) => void; +/** + * Declare CustomDialog TipsDialogV2 + * + * @struct { TipsDialogV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct TipsDialogV2 { + /** + * Sets the TipsDialogV2 imageRes. + * + * @type { ResourceStr | PixelMap } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + imageRes: ResourceStr | PixelMap; + /** + * Sets the TipsDialogV2 image size. + * + * @type { ?SizeOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + imageSize?: SizeOptions; + /** + * Sets the borderColor of TipsDialogV2 image. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + imageBorderColor?: ColorMetrics; + /** + * Sets the borderWidth of TipsDialogV2 image. + * + * @type { ?LengthMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + imageBorderWidth?: LengthMetrics; + /** + * Sets the TipsDialogV2 title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + title?: ResourceStr; + /** + * Sets the TipsDialogV2 content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + content?: ResourceStr; + /** + * Sets the TipsDialogV2 checkbox tips. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + checkTips?: ResourceStr; + /** + * Sets the TipsDialogV2 checkbox check state. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + checked?: boolean; + /** + * Sets the TipsDialogV2 primary button. + * + * @type { ?AdvancedDialogV2Button } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + primaryButton?: AdvancedDialogV2Button; + /** + * Sets the TipsDialogV2 secondary button. + * + * @type { ?AdvancedDialogV2Button } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + secondaryButton?: AdvancedDialogV2Button; + /** + * Sets the TipsDialogV2 CheckBox Callback. + * @type { ?AdvancedDialogV2OnCheckedChange } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + onCheckedChange?: AdvancedDialogV2OnCheckedChange; + /** + * The method to build component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare CustomDialog SelectDialogV2 + * + * @struct { SelectDialogV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct SelectDialogV2 { + /** + * Sets the SelectDialogV2 title. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + title: ResourceStr; + /** + * Sets the SelectDialogV2 content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + content?: ResourceStr; + /** + * Sets the SelectDialogV2 selected index. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + selectedIndex?: int; + /** + * Sets the SelectDialogV2 confirm button. + * + * @type { ?AdvancedDialogV2Button } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + confirm?: AdvancedDialogV2Button; + /** + * Sets the SelectDialog sheets. + * @type { SheetInfo[] } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + radioContent: SheetInfo[]; + /** + * The method to build component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare CustomDialog ConfirmDialogV2 + * + * @struct { ConfirmDialogV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct ConfirmDialogV2 { + /** + * Sets the ConfirmDialogV2 title. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + title: ResourceStr; + /** + * Sets the ConfirmDialogV2 content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + content?: ResourceStr; + /** + * Sets the ConfirmDialogV2 checkbox tips. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + checkTips?: ResourceStr; + /** + * Sets the ConfirmDialogV2 checkbox state. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + checked?: boolean; + /** + * Sets the ConfirmDialogV2 primary button. + * + * @type { ?AdvancedDialogV2Button } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + primaryButton?: AdvancedDialogV2Button; + /** + * Sets the ConfirmDialogV2 secondary button. + * + * @type { ?AdvancedDialogV2Button } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + secondaryButton?: AdvancedDialogV2Button; + /** + * Sets the ConfirmDialogV2 CheckBox Callback. + * + * @type { ?AdvancedDialogV2OnCheckedChange } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + onCheckedChange?: AdvancedDialogV2OnCheckedChange; + /** + * The method to build component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare CustomDialog AlertDialogV2. + * + * @struct { AlertDialogV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct AlertDialogV2 { + /** + * Sets the AlertDialogV2 title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + primaryTitle?: ResourceStr; + /** + * Sets the AlertDialogV2 secondary title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + secondaryTitle?: ResourceStr; + /** + * Sets the AlertDialogV2 content. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + content: ResourceStr; + /** + * Sets the AlertDialogV2 primary button. + * + * @type { ?AdvancedDialogV2Button } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + primaryButton?: AdvancedDialogV2Button; + /** + * Sets the AlertDialogV2 secondary button. + * + * @type { ?AdvancedDialogV2Button } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + secondaryButton?: AdvancedDialogV2Button; + /** + * The method to build component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare CustomDialog LoadingDialogV2 + * + * @struct { LoadingDialogV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct LoadingDialogV2 { + /** + * Sets the LoadingDialogV2 content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + content?: ResourceStr; + /** + * The method to build component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare custom content dialog + * + * @struct { CustomContentDialogV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct CustomContentDialogV2 { + /** + * Sets the CustomContentDialogV2 title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + primaryTitle?: ResourceStr; + /** + * Sets the CustomContentDialogV2 secondary title. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + secondaryTitle?: ResourceStr; + /** + * Sets the CustomContentDialogV2 content. + * + * @type { CustomBuilder } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam + contentBuilder: CustomBuilder; + /** + * Sets the CustomContentDialogV2 content area padding. + * + * @type { ?LocalizedPadding } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + contentAreaPadding?: LocalizedPadding; + /** + * Sets the CustomContentDialogV2 buttons. + * @type { ?AdvancedDialogV2Button[] } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + buttons?: AdvancedDialogV2Button[]; + /** + * The method to build component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare struct PopoverDialogV2 + * + * @struct { PopoverDialogV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct PopoverDialogV2 { + /** + * Sets the PopoverDialogV2 Visible Status. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + visible: boolean; + /** + * Sets the callback when visibility changed. + * + * @type { ?PopoverDialogV2OnVisibleChange } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Event + $visible?: PopoverDialogV2OnVisibleChange; + /** + * Sets the PopoverDialogV2 options. + * + * @type { PopoverDialogV2Options } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + popover: PopoverDialogV2Options; + /** + * Sets the targetBuilder content. + * + * @type { CustomBuilder } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam + targetBuilder: CustomBuilder; + /** + * The method to build component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare the callback when the visibility of PopoverDialogV2 is changed. + * + * @typedef { function } PopoverDialogV2OnVisibleChange + * @param { boolean } visible - The visibility of PopoverDialogV2. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare type PopoverDialogV2OnVisibleChange = (visible: boolean) => void; +/** + * Defines PopoverDialogV2 Options + * + * @extends CustomPopupOptions + * @interface PopoverDialogV2Options + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare interface PopoverDialogV2Options extends CustomPopupOptions { +} diff --git a/api/@ohos.arkui.advanced.EditableTitleBar.static.d.ets b/api/@ohos.arkui.advanced.EditableTitleBar.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..7d4a083939da2677f1ec2f097094cbd0eb0d1cee --- /dev/null +++ b/api/@ohos.arkui.advanced.EditableTitleBar.static.d.ets @@ -0,0 +1,304 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceStr, ResourceColor, LocalizedMargin } from './arkui/component/units'; +import { SafeAreaType, SafeAreaEdge, BlurStyle } from './arkui/component/common'; +import { Component } from './arkui/component/customComponent'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { Builder } from './arkui/component/builder'; +/** + * Declaration of the menu item on the right side. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class EditableTitleBarMenuItem { + /** + * Icon resource for this menu item. + * + * @type { ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public value: ResourceStr; + /** + * Symbol style for this menu item. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public symbolStyle?: SymbolGlyphModifier; + /** + * Icon label for this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public label?: ResourceStr; + /** + * Whether to enable this menu item. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public isEnabled?: boolean; + /** + * Callback function when click on this menu item. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public action?: () => void; + /** + * The accessibilityText of this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of this menu item. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; + /** + * Set the default focus state of this menu item. + * + * @type { ?boolean } + * @default { false } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public defaultFocus?: boolean; +} +/** + * Declaration of the image item . + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export type EditableTitleBarItem = EditableTitleBarMenuItem; +/** + * Declaration of the left icon type. + * + * @enum { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum EditableLeftIconType { + /** + * The back type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Back = 0, + /** + * The cancel type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Cancel = 1 +} +/** + * Indicates the options of the editable title bar. + * + * @interface EditableTitleBarOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare interface EditableTitleBarOptions { + /** + * Background color. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundColor?: ResourceColor; + /** + * Background blur style. + * + * @type { ?BlurStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundBlurStyle?: BlurStyle; + /** + * Indicates the types of the safe area. + * + * @type { ?Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + safeAreaTypes?: Array; + /** + * Indicates the edges of the safe area. + * + * @type { ?Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + safeAreaEdges?: Array; +} +/** + * Declaration of the editable title bar. + * @struct { EditableTitleBar } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct EditableTitleBar { + /** + * Style of the left icon. + * + * @type { EditableLeftIconType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + leftIconStyle: EditableLeftIconType; + /** + * Image item between the left icon and the title. + * + * @type { ?EditableTitleBarItem } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + imageItem?: EditableTitleBarItem; + /** + * Title of this title bar. + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + title: ResourceStr; + /** + * Sub-Title of this title bar. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + subtitle?: ResourceStr; + /** + * Whether to required the save icon. + * + * @type { boolean } + * @default true + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + isSaveIconRequired: boolean; + /** + * Menu items on the right side. + * + * @type { ?Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + menuItems?: Array; + /** + * Callback function when click on the save icon at the right side. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onSave?: () => void; + /** + * Callback function when click on the cancel icon at the left side. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onCancel?: () => void; + /** + * Indicates the options of titlebar. + * + * @type { EditableTitleBarOptions } + * @default {expandSafeAreaTypes: SafeAreaType.SYSTEM, expandSafeAreaEdges: SafeAreaEdge.TOP} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + options: EditableTitleBarOptions; + /** + * Sets the content margin. + * + * @type { ?LocalizedMargin } + * @default {start: LengthMetrics.resource($r('sys.float.margin_left')), + *
end: LengthMetrics.resource($r('sys.float.margin_right'))} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + contentMargin?: LocalizedMargin; + /** + * Sets the default focus state of left icon. + * + * @type { ?boolean } + * @default { false } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + leftIconDefaultFocus?: boolean; + /** + * Sets the default focus state of save icon. + * + * @type { ?boolean } + * @default { false } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + saveIconDefaultFocus?: boolean; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.ExceptionPrompt.static.d.ets b/api/@ohos.arkui.advanced.ExceptionPrompt.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..99a72c3f38cb0b76f39d33bafbfede8e91b83a16 --- /dev/null +++ b/api/@ohos.arkui.advanced.ExceptionPrompt.static.d.ets @@ -0,0 +1,160 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceStr, Dimension } from './arkui/component/units'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { Component } from './arkui/component/customComponent'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { Builder } from './arkui/component/builder'; +/** + * Control margin status of ExceptionPrompt. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum MarginType { + /** + * Default margin of MarginType,Margin 1: references ohos_id_card_margin_start, + * margin 2: references ohos_id_card_margin_end. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * + * @since 20 + */ + DEFAULT_MARGIN = 0, + /** + * Margins can be adapted of MarginType,Margin 1: references ohos_id_max_padding_start, + * margin 2: references ohos_id_max_padding_end. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + FIT_MARGIN = 1, +} +/** + * Configuration parameter of ExceptionPrompt. + * + * @interface PromptOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface PromptOptions { + /** + * Icon of PromptOptions. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + icon?: ResourceStr; + /** + * SymbolGlyphModifier of PromptOptions. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolStyle?: SymbolGlyphModifier; + /** + * Tip text of PromptOptions. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + tip?: ResourceStr; + /** + * Margin Type of ExceptionPrompt. + * + * @type { MarginType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + marginType: MarginType; + /** + * Right icon button text of PromptOptions. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + actionText?: ResourceStr; + /** + * Distance from the top of PromptOptions. + * + * @type { Dimension } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + marginTop: Dimension + /** + * Control concealment of PromptOptions. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + isShown?: boolean +} +/** + * Declare struct ExceptionPrompt higher-order component. + * @struct { ExceptionPrompt } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct ExceptionPrompt { + /** + * Configuration information of ExceptionPrompt. + * + * @type { PromptOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef options: PromptOptions; + /** + * Callback when clicking the text on the left. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onTipClick?: () => void; + /** + * Callback when click the icon button. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onActionTextClick?: () => void; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.Filter.static.d.ets b/api/@ohos.arkui.advanced.Filter.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..5adc0e4dcd39b7be80aa0e4eac21df98cb24ba17 --- /dev/null +++ b/api/@ohos.arkui.advanced.Filter.static.d.ets @@ -0,0 +1,182 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Component } from './arkui/component/customComponent'; +import { ResourceStr } from './arkui/component/units'; +import { BuilderParam, Builder } from './arkui/component/builder'; +import { PropRef } from './arkui/stateManagement/decorator'; +/** + * Declare FilterType + * + * @enum { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum FilterType { + /** + * The multi_line_filter type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + MULTI_LINE_FILTER = 0, + /** + * The list_filter type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + LIST_FILTER = 1 +} +/** + * This parameter is used to define the input of each filtering dimension. + * @typedef FilterParams + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare interface FilterParams { + /** + * filter item name. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + name: ResourceStr; + /** + * filter options. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + options: Array; +} +/** + * This parameter specifies the selection result of a filtering dimension. + * The index starts from 0. + * @typedef FilterResult + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare interface FilterResult { + /** + * result name. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + name: ResourceStr; + /** + * result index. + * + * @type { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + index: int; + /** + * result value. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + value: ResourceStr; +} + +/** + * Callback method after a user clicks a filter item. + * + * @typedef { function } OnFilterChangedCallback + * @param { Array } filterResults - The result of filter. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +declare type OnFilterChangedCallback = (filterResults: Array) => void; + +/** + * Declare Filter.The Filter is used in scenarios where multi-dimensional filtering is required. + * @struct { Filter } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct Filter { + /** + * Container in the user-defined filtering result display area. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam + container: () => void; + /** + * Multi-dimensional filtering parameters. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + multiFilters: Array; + /** + * FilterParams, Additional filter item parameter. The filter item name is displayed and can be deselected. + * + * @type { ?FilterParams } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + additionFilters?: FilterParams; + /** + * FilterParams, Callback method after a user clicks a filter item. + * + * @type { OnFilterChangedCallback } FilterType, Filter display style type. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onFilterChanged: OnFilterChangedCallback; + /** + * FilterType, Filter display style type. + * + * @type { ?FilterType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + filterType?: FilterType; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.FullScreenLaunchComponent.d.ets b/api/@ohos.arkui.advanced.FullScreenLaunchComponent.d.ets index 3d541c1aee4a5fd246d539972738caac1afd1c94..44ab11e7c50512cdd66631f88be89b535691a899 100644 --- a/api/@ohos.arkui.advanced.FullScreenLaunchComponent.d.ets +++ b/api/@ohos.arkui.advanced.FullScreenLaunchComponent.d.ets @@ -19,7 +19,7 @@ */ import AtomicServiceOptions from '@ohos.app.ability.AtomicServiceOptions'; -import { Callback, ErrorCallback } from '@ohos.base'; +import { ErrorCallback, Callback } from '@ohos.base'; /** * Declares the FullScreenLaunchComponent, a component provided by ArkUI that allows @@ -28,6 +28,7 @@ import { Callback, ErrorCallback } from '@ohos.base'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 + * @noninterop */ @Component export declare struct FullScreenLaunchComponent { diff --git a/api/@ohos.arkui.advanced.FullScreenLaunchComponent.static.d.ets b/api/@ohos.arkui.advanced.FullScreenLaunchComponent.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..53097300467173ac4b9457c6d464cd4c6e5e57db --- /dev/null +++ b/api/@ohos.arkui.advanced.FullScreenLaunchComponent.static.d.ets @@ -0,0 +1,109 @@ +'use static'; +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + /** + * @file Defines the fullScreen launch component + * @kit ArkUI + * @arkts 1.2 + */ + +import AtomicServiceOptions from '@ohos.app.ability.AtomicServiceOptions'; +import { Callback, ErrorCallback } from '@ohos.base'; +import { Component, BuilderParam, TerminationInfo, Builder } from '@ohos.arkui.component' + +/** + * Defines RecordData. + * + * @typedef { undefined | null | Object | Record | Array } RecordData + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @arkts 1.2 + */ +export type RecordData = undefined | null | Object | Record | Array; +/** + * Defines ContentBuilder. + * + * @typedef { function } ContentBuilder + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +@Builder +type ContentBuilder = () => void; +/** + * Declares the FullScreenLaunchComponent, a component provided by ArkUI that allows + * you to define and use it in your application through the ArkTS-based declarative + * development paradigm. + * @struct { FullScreenLaunchComponent } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct FullScreenLaunchComponent { + /** + * Sets the component content. + * @type { ContentBuilder } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam content: ContentBuilder; + /** + * Indicates atomic service appId. + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + appId: string; + /** + * Indicates the atomic service start options. + * @type { ?AtomicServiceOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + options?: AtomicServiceOptions; + /** + * Callback triggered when an error occurs during running of the started ExtensionAbility. + * It is supported only when the atomic service runs in embedded mode, + * with the parameter being of type BusinessError. + * @type { ?ErrorCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onError?: ErrorCallback; + /** + * Callback triggered when the EmbeddableUIAbility is terminated to receive the information + * about the termination. It is supported only when the atomic service runs in embedded mode, + * with the parameter being of type TerminationInfo. + * @type { ?Callback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onTerminated?: Callback; + /** + * Indicates the callback of onReceive. + * @type { ?Callback> } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onReceive?: Callback>; + + /** + * The method to build component. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.GridObjectSortComponent.d.ets b/api/@ohos.arkui.advanced.GridObjectSortComponent.d.ets index 61ed933ac2379c64e0de179395e45792f9485ba5..7b87b79ada879764fa709b7862986b0fb3658b50 100644 --- a/api/@ohos.arkui.advanced.GridObjectSortComponent.d.ets +++ b/api/@ohos.arkui.advanced.GridObjectSortComponent.d.ets @@ -18,37 +18,30 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource, ResourceStr, ResourceColor, LocalizedMargin } from './arkui/component/units'; -import { Prop } from './arkui/stateManagement/common'; -import { Component } from './arkui/component/customComponent'; -/*** endif */ - /** * Controls the style types of GridObjectSortComponent. * @enum { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** +/** * Controls the style types of GridObjectSortComponent. * @enum { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 + * @noninterop */ export declare enum GridObjectSortComponentType { /** * The GridObjectSortComponent image text type. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * The GridObjectSortComponent image text type. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -61,10 +54,9 @@ export declare enum GridObjectSortComponentType { * The GridObjectSortComponent text type. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * The GridObjectSortComponent text type. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform @@ -79,16 +71,16 @@ export declare enum GridObjectSortComponentType { * @interface GridObjectSortComponentIteml * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** +/** * Declaration of the GridObjectSortComponent item. * @interface GridObjectSortComponentIteml * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 + * @noninterop */ export interface GridObjectSortComponentItem { /** @@ -96,10 +88,9 @@ export interface GridObjectSortComponentItem { * @type { number | string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * id of GridObjectSortComponent item. * @type { number | string } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -114,10 +105,9 @@ export interface GridObjectSortComponentItem { * @type { ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * GridObjectSortComponent item text. * @type { ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -132,10 +122,9 @@ export interface GridObjectSortComponentItem { * @type { boolean } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * selected of GridObjectSortComponent item, true is show area, false is add area. * @type { boolean } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -150,10 +139,9 @@ export interface GridObjectSortComponentItem { * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * order of GridObjectSortComponentItem, Used for sorting dataList. * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -168,10 +156,9 @@ export interface GridObjectSortComponentItem { * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * image resource path of the GridObjectSortComponent item. * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -196,16 +183,16 @@ export interface GridObjectSortComponentItem { * @interface GridEditOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** +/** * GridObjectSortComponentOptions of GridObjectSortComponent. * @interface GridEditOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 + * @noninterop */ export interface GridObjectSortComponentOptions { /** @@ -214,10 +201,9 @@ export interface GridObjectSortComponentOptions { * @default GridObjectSortComponentType.TEXT * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * Configuration GridObjectSortComponent type. * @type { GridObjectSortComponentType } * @default GridObjectSortComponentType.TEXT @@ -233,10 +219,9 @@ export interface GridObjectSortComponentOptions { * @type { ?number | ?Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * The size of the GridObjectSortComponent image. * @type { ?number | ?Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -251,10 +236,9 @@ export interface GridObjectSortComponentOptions { * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * The title displayed in the unedited state of the GridObjectSortComponent. * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -269,10 +253,9 @@ export interface GridObjectSortComponentOptions { * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * The title displayed in the GridObjectSortComponent edit state. * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -287,10 +270,9 @@ export interface GridObjectSortComponentOptions { * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * Display Area Title, First subtitle of the GridObjectSortComponent. * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -305,10 +287,9 @@ export interface GridObjectSortComponentOptions { * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * Add Zone Title, second subtitle of the GridObjectSortComponent. * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -324,16 +305,16 @@ export interface GridObjectSortComponentOptions { * @struct { GridObjectSortComponent } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** +/** * Declare struct GridObjectSortComponent. * @struct { GridObjectSortComponent } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 12 + * @noninterop */ @Component export declare struct GridObjectSortComponent { @@ -342,10 +323,9 @@ export declare struct GridObjectSortComponent { * @type { GridObjectSortComponentOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * Component types and parameters of the GridObjectSortComponent. * @type { GridObjectSortComponentOptions } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -361,10 +341,9 @@ export declare struct GridObjectSortComponent { * @type { Array } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * Data list of GridObjectSortComponent. * @type { Array } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -379,10 +358,9 @@ export declare struct GridObjectSortComponent { * @type { (select: Array, unselect: Array) => void } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * Callback when Obtain edited data. * @type { (select: Array, unselect: Array) => void } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -397,10 +375,9 @@ export declare struct GridObjectSortComponent { * @type { () => void } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * Cancel callback for saving data. * @type { () => void } * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -414,10 +391,9 @@ export declare struct GridObjectSortComponent { * Build function of GridObjectSortComponent. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - /** + /** * Build function of GridObjectSortComponent. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform diff --git a/api/@ohos.arkui.advanced.GridObjectSortComponent.static.d.ets b/api/@ohos.arkui.advanced.GridObjectSortComponent.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..e0697e7bd7abf33cdbb0af2ef471db9aeaba8a22 --- /dev/null +++ b/api/@ohos.arkui.advanced.GridObjectSortComponent.static.d.ets @@ -0,0 +1,219 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Resource, ResourceStr, ResourceColor, LocalizedMargin } from './arkui/component/units'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { Component } from './arkui/component/customComponent'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { Builder } from './arkui/component/builder'; +/** + * Controls the style types of GridObjectSortComponent. + * + * @enum { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum GridObjectSortComponentType { + /** + * The GridObjectSortComponent image text type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + IMAGE_TEXT = 'image_text', + /** + * The GridObjectSortComponent text type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + TEXT = 'text' +} +/** + * Declaration of the GridObjectSortComponent item. + * + * @interface GridObjectSortComponentIteml + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface GridObjectSortComponentItem { + /** + * id of GridObjectSortComponent item. + * + * @type { number | string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + id: number | string; + /** + * GridObjectSortComponent item text. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + text: ResourceStr; + /** + * selected of GridObjectSortComponent item, true is show area, false is add area. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + selected: boolean; + /** + * order of GridObjectSortComponentItem, Used for sorting dataList. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + order: number; + /** + * image resource path of the GridObjectSortComponent item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + url?: ResourceStr; + /** + * symbol of the GridObjectSortComponent item. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolStyle?: SymbolGlyphModifier; +} +/** + * GridObjectSortComponentOptions of GridObjectSortComponent. + * + * @interface GridEditOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface GridObjectSortComponentOptions { + /** + * Configuration GridObjectSortComponent type. + * + * @type { ?GridObjectSortComponentType } + * @default GridObjectSortComponentType.TEXT + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + type?: GridObjectSortComponentType; + /** + * The size of the GridObjectSortComponent image. + * + * @type { ?(number | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + imageSize?: number | Resource; + /** + * The title displayed in the unedited state of the GridObjectSortComponent. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + normalTitle?: ResourceStr; + /** + * The title displayed in the GridObjectSortComponent edit state. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + editTitle?: ResourceStr; + /** + * Display Area Title, First subtitle of the GridObjectSortComponent. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showAreaTitle?: ResourceStr; + /** + * Add Zone Title, second subtitle of the GridObjectSortComponent. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 20 + */ + addAreaTitle?: ResourceStr; +} +/** + * Declare struct GridObjectSortComponent. + * @struct { GridObjectSortComponent } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct GridObjectSortComponent { + /** + * Component types and parameters of the GridObjectSortComponent. + * + * @type { GridObjectSortComponentOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + options: GridObjectSortComponentOptions; + /** + * Data list of GridObjectSortComponent. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + dataList: Array; + /** + * Callback when Obtain edited data. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onSave: (select: Array, unselect: Array) => void; + /** + * Cancel callback for saving data. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onCancel: () => void; + /** + * Build function of GridObjectSortComponent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.MultiNavigation.d.ets b/api/@ohos.arkui.advanced.MultiNavigation.d.ets index a90ca599fcb99a4aa3fa4131fccf43c179892f3d..e0a1c8b4258683436592570a3e5fed5dcfa676b1 100644 --- a/api/@ohos.arkui.advanced.MultiNavigation.d.ets +++ b/api/@ohos.arkui.advanced.MultiNavigation.d.ets @@ -1,539 +1,539 @@ -/** - * Copyright (C) 2024 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit ArkUI - */ - -import base from '@ohos.base'; - -/** - * Splitpolicy indicates the policy of pages pushed to the stack. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ -export declare enum SplitPolicy { - /** - * Indicates that the page will be pushed to the stack as home page. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - HOME_PAGE = 0, - - /** - * Indicates that the page will be pushed to the stack as detail page. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - DETAIL_PAGE = 1, - - /** - * Indicates that the page will be pushed to the stack as full-screen page. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - FULL_PAGE = 2, -} - -/** - * Declaration struct MultiNavigation. - * - * @struct { MultiNavigation } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ -@Component -export declare struct MultiNavigation { - /** - * MultiNavigation path stack of the MultiNavigation. - * - * @type { MultiNavPathStack } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - @State - multiStack: MultiNavPathStack; - - /** - * build function of NavDestination. - * - * @type { NavDestinationBuildFunction } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - @BuilderParam - navDestination: NavDestinationBuildFunction; - - /** - * callback when the MultiNavigationMode change. - * - * @type { ?OnNavigationModeChangeCallback } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - onNavigationModeChange?: OnNavigationModeChangeCallback; - - /** - * This callback is triggered when the HomePage at the top of the stack. - * - * @type { ?OnHomeShowOnTopCallback } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - onHomeShowOnTop?: OnHomeShowOnTopCallback; -} - -/** - * MultiNavPathStack is used for storing pages when shown as split mode. - * - * @extends NavPathStack - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ -export declare class MultiNavPathStack extends NavPathStack { - /** - * Creates an instance of MultiNavPathStack. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - constructor(); - - /** - * Pushes the NavDestination into the stack. - * - * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @param { SplitPolicy } [policy] - SplitPolicy of the NavDestination which is currently - * pushed in stack. Default splitPolicy is DETAIL_PAGE. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - pushPath(info: NavPathInfo, animated?: boolean, policy?: SplitPolicy): void; - - /** - * Pushes the NavDestination into the stack. - * - * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. - * @param { NavigationOptions } [options] - Indicates options of stack operation. - * @param { SplitPolicy } [policy] - SplitPolicy of the NavDestination which is currently - * pushed in stack. Default splitPolicy is DETAIL_PAGE. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - pushPath(info: NavPathInfo, options?: NavigationOptions, policy?: SplitPolicy): void; - - /** - * Pushes the NavDestination of specified name into the stack. - * - * @param { string } name - Indicates the name of the NavDestination to be pushed. - * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @param { SplitPolicy } [policy] - SplitPolicy of the NavDestination which is currently - * pushed in stack. Default splitPolicy is DETAIL_PAGE. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - pushPathByName(name: string, param: Object, animated?: boolean, policy?: SplitPolicy): void; - - /** - * Pushes the NavDestination of specified name into the stack. - * - * @param { string } name - Indicates the name of the NavDestination to be pushed. - * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. - * @param { base.Callback } [onPop] - The callback when next page returns. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @param { SplitPolicy } [policy] - SplitPolicy of the NavDestination which is currently - * pushed in stack. Default splitPolicy is DETAIL_PAGE. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - pushPathByName( - name: string, param: Object, onPop?: base.Callback, animated?: boolean, policy?: SplitPolicy): void; - - /** - * Replace the current NavDestination with the one specificed by NavPathInfo. - * The current NavDestination will be destroyed. - * - * @param { NavPathInfo } info - Indicates the new NavDestination in top of the stack. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - replacePath(info: NavPathInfo, animated?: boolean): void; - - /** - * Replace the current NavDestination with the one specificed by NavPathInfo. - * The current NavDestination will be destroyed. - * - * @param { NavPathInfo } info - Indicates the new NavDestination in top of the stack. - * @param { NavigationOptions } [options] - Indicates options of stack operation. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - replacePath(info: NavPathInfo, options?: NavigationOptions): void; - - /** - * Replace the current NavDestination with the one specificed by name. - * The current NavDestination will be destroyed. - * - * @param { string } name - Indicates name of the new NavDestination in top of stack. - * @param { Object } param - Indicates the detailed parameter of the new NavDestination in top of the stack. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - replacePathByName(name: string, param: Object, animated?: boolean): void; - - /** - * Remove the specified NavDestinations by indexes. - * - * @param { Array } indexes - Indicates the indexes of the NavDestinations to be removed. - * @returns { number } Returns the number of removed pages. Invalid indexes will be ignored. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - removeByIndexes(indexes: Array): number; - - /** - * Remove the specified NavDestination by name. - * - * @param { string } name - Indicates the name of the NavDestination to be removed. - * @returns { number } Returns the number of removed NavDestinations. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - removeByName(name: string): number; - - /** - * Pop the top NavDestination of the stack. - * - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @returns { NavPathInfo | undefined } Returns the top NavPathInfo if the stack is not empty, - * otherwise returns undefined. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - pop(animated?: boolean): NavPathInfo | undefined; - - /** - * Pop the top NavDestination of the stack. When keepBottomPage sets true, the page at the bottom of the - * stack will be retained. - * - * @param { Object } [result] - Page Customization processing results. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @returns { NavPathInfo | undefined } Returns the top NavPathInfo if the stack is not empty, - * otherwise returns undefined. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - pop(result?: Object, animated?: boolean): NavPathInfo | undefined; - - /** - * Pop to the NavDestination of specified name. Always the first one - * in the stack from bottom up when several NavDestinations match the same name. - * - * @param { string } name - Name of the NavDestination. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - popToName(name: string, animated?: boolean): number; - - /** - * Pop to the NavDestination of specified name. Always the first one - * in the stack from bottom up when several NavDestinations match the same name. - * - * @param { string } name - Name of the NavDestination. - * @param { Object } result - Page Customization processing results. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - popToName(name: string, result: Object, animated?: boolean): number; - - /** - * Pop to the NavDestination of specified index. Do nothing if index is invalid. - * - * @param { number } index - The index of NavDestination page. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - popToIndex(index: number, animated?: boolean): void; - - /** - * Pop to the NavDestination of specified index. Do nothing if index is invalid. - * - * @param { number } index - The index of NavDestination page. - * @param { Object } result - Page Customization processing results. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - popToIndex(index: number, result: Object, animated?: boolean): void; - - /** - * Move the first NavDestination of specified name to the top of the stack. Always the first one - * in the stack from bottom up when several NavDestinations match the same name. - * - * @param { string } name - Indicates the name of the NavDestination to be moved to the top. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - moveToTop(name: string, animated?: boolean): number; - - /** - * Move the first NavDestination of specified index to the top of the stack. - * - * @param { number } index - Indicates the index of the NavDestination to be moved to the top. - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - moveIndexToTop(index: number, animated?: boolean): void; - - /** - * Clear the stack. When keepBottomPage sets true, the page at the bottom of the - * stack will be retained. - * - * @param { boolean } [animated] - Indicates whether the transition is animated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - clear(animated?: boolean): void; - - /** - * Obtains all the NavDestination name in the stack. - * - * @returns { Array } Returns all the NavDestination name in the stack. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - getAllPathName(): Array; - - /** - * Obtains parameter information of the NavDestination page specified by index. - * - * @param { number } index - The index of NavDestination page. - * @returns { unknown | undefined } Returns the detailed parameter of the NavDestination - * if it exists in the stack, otherwise returns undefined. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - getParamByIndex(index: number): Object | undefined; - - /** - * Obtains parameter information of all NavDestination pages specified by name. - * - * @param { string } name - Indicates the name of the NavDestination. - * @returns { Array } Returns the detailed parameter of all the NavDestinations. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - getParamByName(name: string): Array; - - /** - * Obtains the index of all NavDestination pages specified by name. - * - * @param { string } name - Indicates the name of the NavDestination. - * @returns { Array } Returns the index of all the NavDestinations. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - getIndexByName(name: string): Array; - - /** - * Obtains the size of the stack. - * - * @returns { number } Returns the size of the stack. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - size(): number; - - /** - * disable or enable all transition animation in this MultiNavigation. - * - * @param { boolean } disable - Indicates whether to disable the transition animation. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - disableAnimation(disable: boolean): void; - - /** - * Switches the details page of the split-mode page on the top stack to full screen (true) - * or split (false). - * - * @param { boolean } [isFullScreen] - Whether to switch to full screen. - * @returns { boolean } Returns switch result success(true) or failure(false). - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - switchFullScreenState(isFullScreen?: boolean): boolean; - - /** - * Sets the dragable range of the home page width. - * - * @param { number } minPercent - Minimum Home Width Percentage. - * @param { number } maxPercent - Maximum Home Width Percentage. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - setHomeWidthRange(minPercent: number, maxPercent: number): void; - - /** - * Indicates whether to retain the bottom NavDestination of the stack when doing pop or clear. - * - * @param { boolean } keepBottom - Indicates whether to retain the bottom NavDestination of the stack. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - keepBottomPage(keepBottom: boolean): void; - - /** - * Set placeholder NavDestination. - * - * @param { NavPathInfo } info - info of placeHolder NavDestination. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ - setPlaceholderPage(info: NavPathInfo): void; -} - -/** - * Function that sets the rule route to NavDestination. - * - * @typedef { function } NavDestinationBuildFunction - * @param { string } name - Indicates the name of target NavDestination. - * @param { object } [param] - Indicates the parameter of route operation. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ -declare type NavDestinationBuildFunction = (name: string, param?: object) => void; - -/** - * Callback function when NavigationMode changed. - * - * @typedef { function } OnNavigationModeChangeCallback - * @param { NavigationMode } mode - current NavigationMode. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ -declare type OnNavigationModeChangeCallback = (mode: NavigationMode) => void; - -/** - * Callback function when home NavDestination shown in top. - * - * @typedef { function } OnHomeShowOnTopCallback - * @param { string } name - the name of home NavDestination shown in top. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 14 - */ +/** + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + */ + +import base from '@ohos.base'; + +/** + * Splitpolicy indicates the policy of pages pushed to the stack. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ +export declare enum SplitPolicy { + /** + * Indicates that the page will be pushed to the stack as home page. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + HOME_PAGE = 0, + + /** + * Indicates that the page will be pushed to the stack as detail page. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + DETAIL_PAGE = 1, + + /** + * Indicates that the page will be pushed to the stack as full-screen page. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + FULL_PAGE = 2, +} + +/** + * Declaration struct MultiNavigation. + * + * @struct { MultiNavigation } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ +@Component +export declare struct MultiNavigation { + /** + * MultiNavigation path stack of the MultiNavigation. + * + * @type { MultiNavPathStack } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + @State + multiStack: MultiNavPathStack; + + /** + * build function of NavDestination. + * + * @type { NavDestinationBuildFunction } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + @BuilderParam + navDestination: NavDestinationBuildFunction; + + /** + * callback when the MultiNavigationMode change. + * + * @type { ?OnNavigationModeChangeCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + onNavigationModeChange?: OnNavigationModeChangeCallback; + + /** + * This callback is triggered when the HomePage at the top of the stack. + * + * @type { ?OnHomeShowOnTopCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + onHomeShowOnTop?: OnHomeShowOnTopCallback; +} + +/** + * MultiNavPathStack is used for storing pages when shown as split mode. + * + * @extends NavPathStack + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ +export declare class MultiNavPathStack extends NavPathStack { + /** + * Creates an instance of MultiNavPathStack. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + constructor(); + + /** + * Pushes the NavDestination into the stack. + * + * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @param { SplitPolicy } [policy] - SplitPolicy of the NavDestination which is currently + * pushed in stack. Default splitPolicy is DETAIL_PAGE. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + pushPath(info: NavPathInfo, animated?: boolean, policy?: SplitPolicy): void; + + /** + * Pushes the NavDestination into the stack. + * + * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. + * @param { NavigationOptions } [options] - Indicates options of stack operation. + * @param { SplitPolicy } [policy] - SplitPolicy of the NavDestination which is currently + * pushed in stack. Default splitPolicy is DETAIL_PAGE. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + pushPath(info: NavPathInfo, options?: NavigationOptions, policy?: SplitPolicy): void; + + /** + * Pushes the NavDestination of specified name into the stack. + * + * @param { string } name - Indicates the name of the NavDestination to be pushed. + * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @param { SplitPolicy } [policy] - SplitPolicy of the NavDestination which is currently + * pushed in stack. Default splitPolicy is DETAIL_PAGE. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + pushPathByName(name: string, param: Object, animated?: boolean, policy?: SplitPolicy): void; + + /** + * Pushes the NavDestination of specified name into the stack. + * + * @param { string } name - Indicates the name of the NavDestination to be pushed. + * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. + * @param { base.Callback } [onPop] - The callback when next page returns. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @param { SplitPolicy } [policy] - SplitPolicy of the NavDestination which is currently + * pushed in stack. Default splitPolicy is DETAIL_PAGE. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + pushPathByName( + name: string, param: Object, onPop?: base.Callback, animated?: boolean, policy?: SplitPolicy): void; + + /** + * Replace the current NavDestination with the one specificed by NavPathInfo. + * The current NavDestination will be destroyed. + * + * @param { NavPathInfo } info - Indicates the new NavDestination in top of the stack. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + replacePath(info: NavPathInfo, animated?: boolean): void; + + /** + * Replace the current NavDestination with the one specificed by NavPathInfo. + * The current NavDestination will be destroyed. + * + * @param { NavPathInfo } info - Indicates the new NavDestination in top of the stack. + * @param { NavigationOptions } [options] - Indicates options of stack operation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + replacePath(info: NavPathInfo, options?: NavigationOptions): void; + + /** + * Replace the current NavDestination with the one specificed by name. + * The current NavDestination will be destroyed. + * + * @param { string } name - Indicates name of the new NavDestination in top of stack. + * @param { Object } param - Indicates the detailed parameter of the new NavDestination in top of the stack. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + replacePathByName(name: string, param: Object, animated?: boolean): void; + + /** + * Remove the specified NavDestinations by indexes. + * + * @param { Array } indexes - Indicates the indexes of the NavDestinations to be removed. + * @returns { number } Returns the number of removed pages. Invalid indexes will be ignored. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + removeByIndexes(indexes: Array): number; + + /** + * Remove the specified NavDestination by name. + * + * @param { string } name - Indicates the name of the NavDestination to be removed. + * @returns { number } Returns the number of removed NavDestinations. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + removeByName(name: string): number; + + /** + * Pop the top NavDestination of the stack. + * + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @returns { NavPathInfo | undefined } Returns the top NavPathInfo if the stack is not empty, + * otherwise returns undefined. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + pop(animated?: boolean): NavPathInfo | undefined; + + /** + * Pop the top NavDestination of the stack. When keepBottomPage sets true, the page at the bottom of the + * stack will be retained. + * + * @param { Object } [result] - Page Customization processing results. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @returns { NavPathInfo | undefined } Returns the top NavPathInfo if the stack is not empty, + * otherwise returns undefined. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + pop(result?: Object, animated?: boolean): NavPathInfo | undefined; + + /** + * Pop to the NavDestination of specified name. Always the first one + * in the stack from bottom up when several NavDestinations match the same name. + * + * @param { string } name - Name of the NavDestination. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + popToName(name: string, animated?: boolean): number; + + /** + * Pop to the NavDestination of specified name. Always the first one + * in the stack from bottom up when several NavDestinations match the same name. + * + * @param { string } name - Name of the NavDestination. + * @param { Object } result - Page Customization processing results. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + popToName(name: string, result: Object, animated?: boolean): number; + + /** + * Pop to the NavDestination of specified index. Do nothing if index is invalid. + * + * @param { number } index - The index of NavDestination page. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + popToIndex(index: number, animated?: boolean): void; + + /** + * Pop to the NavDestination of specified index. Do nothing if index is invalid. + * + * @param { number } index - The index of NavDestination page. + * @param { Object } result - Page Customization processing results. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + popToIndex(index: number, result: Object, animated?: boolean): void; + + /** + * Move the first NavDestination of specified name to the top of the stack. Always the first one + * in the stack from bottom up when several NavDestinations match the same name. + * + * @param { string } name - Indicates the name of the NavDestination to be moved to the top. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + moveToTop(name: string, animated?: boolean): number; + + /** + * Move the first NavDestination of specified index to the top of the stack. + * + * @param { number } index - Indicates the index of the NavDestination to be moved to the top. + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + moveIndexToTop(index: number, animated?: boolean): void; + + /** + * Clear the stack. When keepBottomPage sets true, the page at the bottom of the + * stack will be retained. + * + * @param { boolean } [animated] - Indicates whether the transition is animated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + clear(animated?: boolean): void; + + /** + * Obtains all the NavDestination name in the stack. + * + * @returns { Array } Returns all the NavDestination name in the stack. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + getAllPathName(): Array; + + /** + * Obtains parameter information of the NavDestination page specified by index. + * + * @param { number } index - The index of NavDestination page. + * @returns { unknown | undefined } Returns the detailed parameter of the NavDestination + * if it exists in the stack, otherwise returns undefined. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + getParamByIndex(index: number): Object | undefined; + + /** + * Obtains parameter information of all NavDestination pages specified by name. + * + * @param { string } name - Indicates the name of the NavDestination. + * @returns { Array } Returns the detailed parameter of all the NavDestinations. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + getParamByName(name: string): Array; + + /** + * Obtains the index of all NavDestination pages specified by name. + * + * @param { string } name - Indicates the name of the NavDestination. + * @returns { Array } Returns the index of all the NavDestinations. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + getIndexByName(name: string): Array; + + /** + * Obtains the size of the stack. + * + * @returns { number } Returns the size of the stack. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + size(): number; + + /** + * disable or enable all transition animation in this MultiNavigation. + * + * @param { boolean } disable - Indicates whether to disable the transition animation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + disableAnimation(disable: boolean): void; + + /** + * Switches the details page of the split-mode page on the top stack to full screen (true) + * or split (false). + * + * @param { boolean } [isFullScreen] - Whether to switch to full screen. + * @returns { boolean } Returns switch result success(true) or failure(false). + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + switchFullScreenState(isFullScreen?: boolean): boolean; + + /** + * Sets the dragable range of the home page width. + * + * @param { number } minPercent - Minimum Home Width Percentage. + * @param { number } maxPercent - Maximum Home Width Percentage. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + setHomeWidthRange(minPercent: number, maxPercent: number): void; + + /** + * Indicates whether to retain the bottom NavDestination of the stack when doing pop or clear. + * + * @param { boolean } keepBottom - Indicates whether to retain the bottom NavDestination of the stack. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + keepBottomPage(keepBottom: boolean): void; + + /** + * Set placeholder NavDestination. + * + * @param { NavPathInfo } info - info of placeHolder NavDestination. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + setPlaceholderPage(info: NavPathInfo): void; +} + +/** + * Function that sets the rule route to NavDestination. + * + * @typedef { function } NavDestinationBuildFunction + * @param { string } name - Indicates the name of target NavDestination. + * @param { object } [param] - Indicates the parameter of route operation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ +declare type NavDestinationBuildFunction = (name: string, param?: object) => void; + +/** + * Callback function when NavigationMode changed. + * + * @typedef { function } OnNavigationModeChangeCallback + * @param { NavigationMode } mode - current NavigationMode. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ +declare type OnNavigationModeChangeCallback = (mode: NavigationMode) => void; + +/** + * Callback function when home NavDestination shown in top. + * + * @typedef { function } OnHomeShowOnTopCallback + * @param { string } name - the name of home NavDestination shown in top. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ declare type OnHomeShowOnTopCallback = (name: string) => void; \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.ProgressButton.static.d.ets b/api/@ohos.arkui.advanced.ProgressButton.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..164490a6833e025c26c16d3f7c49561bee07be91 --- /dev/null +++ b/api/@ohos.arkui.advanced.ProgressButton.static.d.ets @@ -0,0 +1,146 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Component } from './arkui/component/customComponent'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { ResourceColor, ResourceStr, Length } from './arkui/component/units'; +import { Builder } from './arkui/component/builder'; +import { LengthMetrics } from './arkui/Graphics'; +/** + * Declare Component ProgressButton + * @struct { ProgressButton } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct ProgressButton { + /** + * Sets the content when progress. + * + * @type { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + progress: int; + /** + * Sets the ProgressButton content. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + content: ResourceStr; + /** + * Sets the ProgressButton progressButtonWidth. + * + * @type { ?Length } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + progressButtonWidth?: Length; + /** + * Sets the ProgressButton clickCallback. + * + * @type { function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + clickCallback: () => void; + /** + * Sets the ProgressButton enable state. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + enable: boolean; + /** + * Set Color options of the ProgressButton. + * + * @type { ?ProgressButtonColorOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + colorOptions?: ProgressButtonColorOptions; + /** + * Set border rounded corner radius of progress. + * + * @type { ?LengthMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + progressButtonRadius?: LengthMetrics; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare Color options of the ProgressButton. + * @typedef ProgressButtonColorOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare interface ProgressButtonColorOptions { + /** + * Set progress color of the ProgressButton. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + progressColor?: ResourceColor; + /** + * Set border color of the ProgressButton. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + borderColor?: ResourceColor; + /** + * Set text color of the ProgressButton. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + textColor?: ResourceColor; + /** + * Set background color of the ProgressButton. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundColor?: ResourceColor; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.ProgressButtonV2.static.d.ets b/api/@ohos.arkui.advanced.ProgressButtonV2.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..af96bfe0aebf924b7a976aebaf985a2e1be2f2c9 --- /dev/null +++ b/api/@ohos.arkui.advanced.ProgressButtonV2.static.d.ets @@ -0,0 +1,217 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ComponentV2 } from './arkui/component/customComponent'; +import { Require, Param, Once, Trace, ObservedV2 } from './arkui/stateManagement/decorator'; +import { ResourceStr } from './arkui/component/units'; +import { Builder } from './arkui/component/builder'; +import { LengthMetrics, ColorMetrics } from './arkui/Graphics'; +/** + * Declare Component ProgressButtonV2 + * @struct { ProgressButtonV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct ProgressButtonV2 { + /** + * Sets the ProgressButtonV2 progress. + * + * @type { int } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + readonly progress: int; + /** + * Sets the ProgressButtonV2 content. + * + * @type { ResourceStr } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + readonly content: ResourceStr; + /** + * Sets the ProgressButtonV2 progressButtonWidth. + * + * @type { ?LengthMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + @Once + progressButtonWidth?: LengthMetrics; + /** + * Sets the ProgressButtonV2 onClicked. + * + * @type { ClickCallback } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + readonly onClicked: ClickCallback; + /** + * Sets the ProgressButtonV2 isEnabled state. + * + * @type { boolean } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + readonly isEnabled: boolean; + /** + * Set Color options of the ProgressButtonV2. + * + * @type { ?ProgressButtonV2Color } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + colorOptions?: ProgressButtonV2Color; + /** + * Set border rounded corner radius of progress. + * + * @type { ?LengthMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + progressButtonRadius?: LengthMetrics; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} +/** + * Declare ProgressButtonV2 Color. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class ProgressButtonV2Color { + /** + * Set progress color of the ProgressButtonV2. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public progressColor?: ColorMetrics; + /** + * Set border color of the ProgressButtonV2. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public borderColor?: ColorMetrics; + /** + * Set text color of the ProgressButtonV2. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public textColor?: ColorMetrics; + /** + * Set background color of the ProgressButtonV2. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public backgroundColor?: ColorMetrics; + /** + * The constructor of ProgressButtonV2 + * + * @param { ProgressButtonV2ColorOptions } options - the options of the ProgressButtonV2 + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options: ProgressButtonV2ColorOptions); +} +/** + * Defines ClickCallback of the ProgressButtonV2. + * @typedef { function } ClickCallback + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export type ClickCallback = () => void; +/** + * Declare Color options interface of the ProgressButtonV2. + * @typedef ProgressButtonV2ColorOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare interface ProgressButtonV2ColorOptions { + /** + * Set progress color of the ProgressButtonV2. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + progressColor?: ColorMetrics; + /** + * Set border color of the ProgressButtonV2. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + borderColor?: ColorMetrics; + /** + * Set text color of the ProgressButtonV2. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + textColor?: ColorMetrics; + /** + * Set background color of the ProgressButtonV2. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundColor?: ColorMetrics; +} diff --git a/api/@ohos.arkui.advanced.SegmentButton.d.ets b/api/@ohos.arkui.advanced.SegmentButton.d.ets index 1112cd8a2ca7838fe79bf4d9fbfb36dd1eb72de5..4b2fa37acb11d2313dfc7a7617fbf783e7436c4c 100644 --- a/api/@ohos.arkui.advanced.SegmentButton.d.ets +++ b/api/@ohos.arkui.advanced.SegmentButton.d.ets @@ -333,23 +333,25 @@ declare type DimensionNoPercentage = PX | VP | FP | LPX | Resource; /** * Defines the BorderRadiusMode type. - * * @syscap SystemCapability.ArkUI.ArkUI.Full + * @enum { number } * @crossplatform * @atomicservice * @since 20 */ declare enum BorderRadiusMode { - /** + /** * Default mode, radius is auto calculated by framework. + * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 20 */ DEFAULT = 0, - /** + /** * Custom mode, radius can be set by developers. + * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 20 diff --git a/api/@ohos.arkui.advanced.SelectTitleBar.static.d.ets b/api/@ohos.arkui.advanced.SelectTitleBar.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..9b7e498651eb28ebb52432593eb8d68452c0fd3e --- /dev/null +++ b/api/@ohos.arkui.advanced.SelectTitleBar.static.d.ets @@ -0,0 +1,185 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceStr } from './arkui/component/units'; +import { Component } from './arkui/component/customComponent'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { SelectOption } from './arkui/component/select'; +import { Builder } from './arkui/component/builder'; +import { PropRef } from './arkui/stateManagement/decorator'; +/** + * Declaration of the menu item on the right side. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class SelectTitleBarMenuItem { + /** + * Icon resource for this menu item. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public value: ResourceStr; + /** + * Symbol resource for this menu item. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public symbolStyle?: SymbolGlyphModifier; + /** + * Icon label for this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public label?: ResourceStr; + /** + * Whether to enable this menu item. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public isEnabled?: boolean; + /** + * Callback function when click on this menu item. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public action?: () => void; + /** + * The accessibilityText of this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of this menu item. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; +} +/** + * Callback method when an option is selected. + * @typedef { function } OnSelectedCallback + * @param { int } index -the result of option. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +declare type OnSelectedCallback = (index: int) => void; +/** + * Declaration of the selectable title bar. + * @struct { SelectTitleBar } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct SelectTitleBar { + /** + * Selected index of the initial options in the drop-down menu. The index of the first item is 0. + * If this attribute is not set, the default value is -1. Which means, no menu item is selected. + * + * @type { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + selected: int; + /** + * Options inside the drop-down list. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + options: Array; + /** + * Menu items on the right side. + * + * @type { ?Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + menuItems?: Array; + /** + * Sub-title of this title bar. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + subtitle?: ResourceStr; + /** + * The interger displayed in a badge. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + badgeValue?: int; + /** + * Whether to hide the back arrow at the left side. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + hidesBackButton?: boolean; + /** + * Callback function when an option is selected + * + * @type { ?OnSelectedCallback } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onSelected?: OnSelectedCallback; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} diff --git a/api/@ohos.arkui.advanced.SplitLayout.d.ets b/api/@ohos.arkui.advanced.SplitLayout.d.ets index 72388ba2d30f578a1b9f4228c1f217318ace2c3b..8641e9cb6b0adcfa1f58d07dee69de2c7f418d1f 100644 --- a/api/@ohos.arkui.advanced.SplitLayout.d.ets +++ b/api/@ohos.arkui.advanced.SplitLayout.d.ets @@ -17,12 +17,10 @@ * @file * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceStr } from './arkui/component/units'; -import { State, PropRef } from './arkui/stateManagement/decorator'; -import { Component } from './arkui/component/customComponent'; -import { BuilderParam, Builder } from './arkui/component/builder'; -/*** endif */ + + + + /** * Declare SplitLayout.The SplitLayout is used for upper and lower graphic layouts. @@ -33,8 +31,7 @@ import { BuilderParam, Builder } from './arkui/component/builder'; * Declare SplitLayout.The SplitLayout is used for upper and lower graphic layouts. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ @Component export declare struct SplitLayout { @@ -49,8 +46,7 @@ export declare struct SplitLayout { * @type { container: () => void }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ @BuilderParam container: () => void; @@ -65,8 +61,7 @@ export declare struct SplitLayout { * @type { ResourceStr }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'11','1.2':'20' } - * @arkts 1.1&1.2 + * @since 11 */ @State mainImage: ResourceStr; @@ -82,20 +77,9 @@ export declare struct SplitLayout { * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 - * @arkts 1.1 */ @Prop primaryText: ResourceStr; - /** - * Title text in the layout. - * @type { ResourceStr }. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef primaryText: ResourceStr; - /** * Description text in the layout. * @type { ?ResourceStr }. @@ -108,20 +92,9 @@ export declare struct SplitLayout { * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 - * @arkts 1.1 */ @Prop secondaryText?: ResourceStr; - /** - * Description text in the layout. - * @type { ?ResourceStr }. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef secondaryText?: ResourceStr; - /** * Auxiliary text in the layout. * @type { ?ResourceStr }. @@ -134,26 +107,6 @@ export declare struct SplitLayout { * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 - * @arkts 1.1 */ @Prop tertiaryText?: ResourceStr; - - /** - * Auxiliary text in the layout. - * @type { ?ResourceStr }. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef tertiaryText?: ResourceStr; - - /** - * The method to build component. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @Builder build(): void; -} +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.SplitLayout.static.d.ets b/api/@ohos.arkui.advanced.SplitLayout.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..18c9a9946b0b16ed9f08332f1c6a6be4c6a9a959 --- /dev/null +++ b/api/@ohos.arkui.advanced.SplitLayout.static.d.ets @@ -0,0 +1,88 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceStr } from './arkui/component/units'; +import { State, PropRef } from './arkui/stateManagement/decorator'; +import { Component } from './arkui/component/customComponent'; +import { BuilderParam, Builder } from './arkui/component/builder'; +/** + * Declare SplitLayout.The SplitLayout is used for upper and lower graphic layouts. + * @struct { SplitLayout } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct SplitLayout { + /** + * Container in the user-defined splitlayout display area. + * + * @type { function }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam + container: () => void; + /** + * Image in the layout. + * + * @type { ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @State + mainImage: ResourceStr; + /** + * Title text in the layout. + * + * @type { ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + primaryText: ResourceStr; + /** + * Description text in the layout. + * + * @type { ?ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + secondaryText?: ResourceStr; + /** + * Auxiliary text in the layout. + * + * @type { ?ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + tertiaryText?: ResourceStr; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.SubHeader.d.ets b/api/@ohos.arkui.advanced.SubHeader.d.ets index a7cde45e007cbcf7918576c2eb96b28bf77f86c6..17972e466ab7c17ef3c9f036d0bcb46d904998cc 100644 --- a/api/@ohos.arkui.advanced.SubHeader.d.ets +++ b/api/@ohos.arkui.advanced.SubHeader.d.ets @@ -17,19 +17,9 @@ * @file * @kit ArkUI */ -/*** if arkts 1.1 */ + import { TextModifier } from './@ohos.arkui.modifier'; -/*** endif */ -/*** if arkts 1.2 */ -import { TextModifier } from './arkui/TextModifier'; -import { ResourceStr, Resource, ResourceColor, LocalizedMargin, LocalizedPadding } from './arkui/component/units'; -import { SelectOption } from './arkui/component/select'; -import { PropRef } from './arkui/stateManagement/decorator'; -import { Component } from './arkui/component/customComponent'; -import { FontWeight } from './arkui/component/enums'; -import { SymbolEffectStrategy, SymbolRenderingStrategy } from './arkui/component/symbolglyph'; -import { BuilderParam, Builder } from './arkui/component/builder'; -/*** endif */ + /** * Control style of operation element @@ -50,8 +40,7 @@ import { BuilderParam, Builder } from './arkui/component/builder'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ export declare enum OperationType { /** @@ -70,8 +59,8 @@ export declare enum OperationType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ TEXT_ARROW = 0, @@ -91,8 +80,8 @@ export declare enum OperationType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ BUTTON = 1, @@ -112,8 +101,8 @@ export declare enum OperationType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ ICON_GROUP = 2, @@ -133,8 +122,8 @@ export declare enum OperationType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ LOADING = 3 } @@ -155,8 +144,7 @@ export declare enum OperationType { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ export declare class OperationOption { /** @@ -178,42 +166,39 @@ export declare class OperationOption { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ value: ResourceStr; /** * callback function when operate the text or icon. - * @type { () => void }. + * @type { ?function }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 */ /** * callback function when operate the text or icon. - * @type { () => void }. + * @type { ?function }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 */ /** * callback function when operate the text or icon. - * @type { () => void }. + * @type { ?function }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ action?: () => void; /** - * The accessibilityText of this text or icon. - * @type { ?ResourceStr }. + * Accessible label name for the icon on the right side of the subheader. + * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ accessibilityText?: ResourceStr; @@ -222,8 +207,7 @@ export declare class OperationOption { * @type { ?ResourceStr } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ accessibilityDescription?: ResourceStr; @@ -233,8 +217,7 @@ export declare class OperationOption { * @default "auto" * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ accessibilityLevel?: string; @@ -244,8 +227,7 @@ export declare class OperationOption { * @default { false } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ defaultFocus?: boolean; } @@ -266,8 +248,7 @@ export declare class OperationOption { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ export declare class SelectOptions { /** @@ -289,8 +270,8 @@ export declare class SelectOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ options: Array; @@ -313,8 +294,8 @@ export declare class SelectOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ selected?: number; @@ -346,7 +327,6 @@ export declare class SelectOptions { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ value?: ResourceStr; @@ -369,8 +349,8 @@ export declare class SelectOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ onSelect?: (index: number, value?: string) => void; @@ -380,8 +360,8 @@ export declare class SelectOptions { * @default { false } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ defaultFocus?: boolean; } @@ -390,14 +370,14 @@ export declare class SelectOptions { * Declare type SymbolOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since 12 + * @since 12 */ - /** +/** * Declare type SymbolOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 18 + * @since 18 */ export declare class SymbolOptions { /** @@ -413,8 +393,8 @@ export declare class SymbolOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ fontSize?: number | string | Resource; @@ -431,8 +411,8 @@ export declare class SymbolOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ fontColor?: Array; @@ -449,8 +429,8 @@ export declare class SymbolOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ fontWeight?: number | FontWeight | string; @@ -467,8 +447,8 @@ export declare class SymbolOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ effectStrategy?: SymbolEffectStrategy; @@ -485,8 +465,8 @@ export declare class SymbolOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 + */ renderingStrategy?: SymbolRenderingStrategy; } @@ -507,8 +487,7 @@ export declare class SymbolOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ @Component export declare struct SubHeader { @@ -528,272 +507,221 @@ export declare struct SubHeader { */ /** * Icon resource of content area. - * @type { ResourceStr }. + * @type { ?ResourceStr }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 18 - * @arkts 1.1 */ @Prop icon?: ResourceStr; - /** - * Icon resource of content area. - * @type { ResourceStr }. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef icon?: ResourceStr; - /** * Attributes of Symbol icon. - * @type { SymbolOptions}. + * @type { ?SymbolOptions }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 */ /** * Attributes of Symbol icon. - * @type { SymbolOptions}. + * @type { ?SymbolOptions }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ iconSymbolOptions?: SymbolOptions; /** * The first line text of content area. - * @type { ResourceStr }. + * @type { ?ResourceStr }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 */ /** * The first line text of content area. - * @type { ResourceStr }. + * @type { ?ResourceStr }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 */ /** * The first line text of content area. - * @type { ResourceStr }. + * @type { ?ResourceStr }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 18 - * @arkts 1.1 */ + @Prop primaryTitle?: ResourceStr; - /** - * The first line text of content area. - * @type { ResourceStr }. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef primaryTitle?: ResourceStr; - /** * The secondary line text of content area. - * @type { ResourceStr }. + * @type { ?ResourceStr }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 */ /** * The secondary line text of content area. - * @type { ResourceStr }. + * @type { ?ResourceStr }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 */ /** * The secondary line text of content area. - * @type { ResourceStr }. + * @type { ?ResourceStr }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 18 - * @arkts 1.1 */ + @Prop secondaryTitle?: ResourceStr; - /** - * The secondary line text of content area. - * @type { ResourceStr }. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef secondaryTitle?: ResourceStr; - /** * Select option of content area. - * @type { SelectOptions }. + * @type { ?SelectOptions }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 */ /** * Select option of content area. - * @type { SelectOptions }. + * @type { ?SelectOptions }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 */ /** * Select option of content area. - * @type { SelectOptions }. + * @type { ?SelectOptions }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ select?: SelectOptions; /** * Operation style of SubHeader. - * @type { OperationStyle }. + * @type { ?OperationType }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 */ /** * Operation style of SubHeader. - * @type { OperationStyle }. + * @type { ?OperationType }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 */ /** * Operation style of SubHeader. - * @type { OperationStyle }. + * @type { ?OperationType }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 18 - * @arkts 1.1 */ + @Prop operationType?: OperationType; - /** - * Operation style of SubHeader. - * @type { OperationStyle }. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef operationType?: OperationType; - /** * operation item. - * @type { Array }. + * @type { ?Array }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 */ /** * operation item. - * @type { Array }. + * @type { ?Array }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 */ /** * operation item. - * @type { Array }. + * @type { ?Array }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ operationItem?: Array; /** * Attributes of Symbol icons in operation area. - * @type { Array }. + * @type { ?Array }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 */ /** * Attributes of Symbol icons in operation area. - * @type { Array }. + * @type { ?Array }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ operationSymbolOptions?: Array; /** * Text modifier for primary title. - * @type { TextModifier }. + * @type { ?TextModifier }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 */ /** * Text modifier for primary title. - * @type { TextModifier }. + * @type { ?TextModifier }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ primaryTitleModifier?: TextModifier; /** * Text modifier for secondary title. - * @type { TextModifier }. + * @type { ?TextModifier }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 */ /** * Text modifier for secondary title. - * @type { TextModifier }. + * @type { ?TextModifier }. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ secondaryTitleModifier?: TextModifier; /** * Set the title content. - * @type { () => void } + * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 */ /** * Set the title content. - * @type { () => void } + * @type { ?function } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts{ '1.1':'18','1.2':'20' } - * @arkts 1.1&1.2 + * @since 18 */ + @BuilderParam titleBuilder?: () => void; /** * Set the content margin. * @type { ?LocalizedMargin } * @default {start: LengthMetrics.resource($r('sys.float.margin_left')), - *
end: LengthMetrics.resource($r('sys.float.margin_right'))} + *
end: LengthMetrics.resource($r('sys.float.margin_right'))} * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 @@ -802,34 +730,21 @@ export declare struct SubHeader { * Set the content margin. * @type { ?LocalizedMargin } * @default {start: LengthMetrics.resource($r('sys.float.margin_left')), - *
end: LengthMetrics.resource($r('sys.float.margin_right'))} + *
end: LengthMetrics.resource($r('sys.float.margin_right'))} * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 18 - * @arkts 1.1 */ + @Prop contentMargin?: LocalizedMargin; - /** - * Set the content margin. - * @type { ?LocalizedMargin } - * @default {start: LengthMetrics.resource($r('sys.float.margin_left')), - *
end: LengthMetrics.resource($r('sys.float.margin_right'))} - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef contentMargin?: LocalizedMargin; - /** * Set the content padding. * @type { ?LocalizedPadding } * @default set different default values according to the width of the subHeader: - *
When the left area is secondaryTitle or the group of secondaryTitle and icon, - *
the default value is {start: LengthMetrics.vp(12), end: LengthMetrics.vp(12)}; + *
When the left area is secondaryTitle or the group of secondaryTitle and icon, + *
the default value is {start: LengthMetrics.vp(12), end: LengthMetrics.vp(12)}; * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 @@ -838,36 +753,13 @@ export declare struct SubHeader { * Set the content padding. * @type { ?LocalizedPadding } * @default set different default values according to the width of the subHeader: - *
When the left area is secondaryTitle or the group of secondaryTitle and icon, - *
the default value is {start: LengthMetrics.vp(12), end: LengthMetrics.vp(12)}; + *
When the left area is secondaryTitle or the group of secondaryTitle and icon, + *
the default value is {start: LengthMetrics.vp(12), end: LengthMetrics.vp(12)}; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice * @since 18 - * @arkts 1.1 */ + @Prop contentPadding?: LocalizedPadding; - - /** - * Set the content padding. - * @type { ?LocalizedPadding } - * @default set different default values according to the width of the subHeader: - *
When the left area is secondaryTitle or the group of secondaryTitle and icon, - *
the default value is {start: LengthMetrics.vp(12), end: LengthMetrics.vp(12)}; - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef contentPadding?: LocalizedPadding; - - /** - * The method to build component. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @Builder build(): void; } \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.SubHeader.static.d.ets b/api/@ohos.arkui.advanced.SubHeader.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..d7806344ce61c7fac4b558f54c32a44a3c5dd5c9 --- /dev/null +++ b/api/@ohos.arkui.advanced.SubHeader.static.d.ets @@ -0,0 +1,359 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { TextModifier } from './arkui/TextModifier'; +import { ResourceStr, Resource, ResourceColor, LocalizedMargin, LocalizedPadding } from './arkui/component/units'; +import { SelectOption } from './arkui/component/select'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { Component } from './arkui/component/customComponent'; +import { FontWeight } from './arkui/component/enums'; +import { SymbolEffectStrategy, SymbolRenderingStrategy } from './arkui/component/symbolglyph'; +import { BuilderParam, Builder } from './arkui/component/builder'; +/** + * Control style of operation element + * + * @enum { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum OperationType { + /** + * The TextArrow style. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + TEXT_ARROW = 0, + /** + * The Button style. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + BUTTON = 1, + /** + * The IconGroup style. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ICON_GROUP = 2, + /** + * The LoadingProgress style. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + LOADING = 3 +} +/** + * Declare type OperationOption + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class OperationOption { + /** + * The content of text or the address of icon. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public value: ResourceStr; + /** + * callback function when operate the text or icon. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public action?: () => void; + /** + * The accessibilityText of this text or icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of this text or icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of this text or icon. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; + /** + * Sets the default focus state of the text or icon. + * + * @type { ?boolean } + * @default { false } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public defaultFocus?: boolean; +} +/** + * Declare type SelectOption + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class SelectOptions { + /** + * SubOption array of the select. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public options: Array; + /** + * The default selected index. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public selected?: int; + /** + * The default text value. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public value?: ResourceStr; + /** + * Callback when the select is selected. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public onSelect?: (index: int, value?: string) => void; + /** + * Sets the default focus state of select. + * + * @type { ?boolean } + * @default { false } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public defaultFocus?: boolean; +} +/** +* Declare type SymbolOptions +* +* @syscap SystemCapability.ArkUI.ArkUI.Full +* @since 20 +* @noninterop +*/ +export declare class SymbolOptions { + /** + * The size of symbol icon. + * + * @type { ?(int | string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public fontSize?: int | string | Resource; + /** + * The color of symbol icon. + * + * @type { ?Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public fontColor?: Array; + /** + * The fontWeight of symbol icon. + * + * @type { ?(int | FontWeight | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public fontWeight?: int | FontWeight | string; + /** + * The effect strategy of symbol icon. + * + * @type { ?SymbolEffectStrategy } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public effectStrategy?: SymbolEffectStrategy; + /** + * The rendering strategy of symbol icon. + * + * @type { ?SymbolRenderingStrategy } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public renderingStrategy?: SymbolRenderingStrategy; +} +/** + * Declare struct SubHeader + * @struct { SubHeader } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct SubHeader { + /** + * Icon resource of content area. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + icon?: ResourceStr; + /** + * Attributes of Symbol icon. + * + * @type { ?SymbolOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconSymbolOptions?: SymbolOptions; + /** + * The first line text of content area. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + primaryTitle?: ResourceStr; + /** + * The secondary line text of content area. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + secondaryTitle?: ResourceStr; + /** + * Select option of content area. + * + * @type { ?SelectOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + select?: SelectOptions; + /** + * Operation style of SubHeader. + * + * @type { ?OperationType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + operationType?: OperationType; + /** + * operation item. + * + * @type { ?Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + operationItem?: Array; + /** + * Attributes of Symbol icons in operation area. + * + * @type { ?Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + operationSymbolOptions?: Array; + /** + * Text modifier for primary title. + * + * @type { ?TextModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryTitleModifier?: TextModifier; + /** + * Text modifier for secondary title. + * + * @type { ?TextModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryTitleModifier?: TextModifier; + /** + * Set the title content. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam + titleBuilder?: () => void; + /** + * Set the content margin. + * + * @type { ?LocalizedMargin } + * @default {start: LengthMetrics.resource($r('sys.float.margin_left')), + *
end: LengthMetrics.resource($r('sys.float.margin_right'))} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + contentMargin?: LocalizedMargin; + /** + * Set the content padding. + * + * @type { ?LocalizedPadding } + * @default set different default values according to the width of the subHeader: + *
When the left area is secondaryTitle or the group of secondaryTitle and icon, + *
the default value is {start: LengthMetrics.vp(12), end: LengthMetrics.vp(12)}; + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + contentPadding?: LocalizedPadding; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} diff --git a/api/@ohos.arkui.advanced.SubHeaderV2.static.d.ets b/api/@ohos.arkui.advanced.SubHeaderV2.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..d5a2c4e053029ce9652ae872eec146f68d49296b --- /dev/null +++ b/api/@ohos.arkui.advanced.SubHeaderV2.static.d.ets @@ -0,0 +1,548 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { TextModifier } from './arkui/TextModifier'; +import { ResourceStr } from './arkui/component/units'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { SelectOption } from './arkui/component/select'; +import { ObservedV2, Trace, Param } from './arkui/stateManagement/decorator'; +import { ComponentV2 } from './arkui/component/customComponent'; +import { BuilderParam, Builder } from './arkui/component/builder'; +/** + * SubHeaderV2IconType + * + * @typedef { ResourceStr | SymbolGlyphModifier } SubHeaderV2IconType + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +declare type SubHeaderV2IconType = ResourceStr | SymbolGlyphModifier; +/** + * Defines the SubHeaderV2TitleOptions. + * + * @interface SubHeaderV2TitleOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface SubHeaderV2TitleOptions { + /** + * The first line text of content area. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryTitle?: ResourceStr; + /** + * Text modifier for primary title. + * + * @type { ?TextModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryTitleModifier?: TextModifier; + /** + * The secondary line text of content area. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryTitle?: ResourceStr; + /** + * Text modifier for secondary title. + * + * @type { ?TextModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryTitleModifier?: TextModifier; +} +/** + * Declare the SubHeaderV2Title + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class SubHeaderV2Title { + /** + * The first line text of content area. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public primaryTitle?: ResourceStr; + /** + * Text modifier for primary title. + * + * @type { ?TextModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public primaryTitleModifier?: TextModifier; + /** + * The secondary line text of content area. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public secondaryTitle?: ResourceStr; + /** + * Text modifier for secondary title. + * + * @type { ?TextModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public secondaryTitleModifier?: TextModifier; + /** + * The constructor of SubHeaderV2Title + * + * @param { SubHeaderV2TitleOptions } options - the options of the SubHeaderV2Title + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public constructor(options: SubHeaderV2TitleOptions); +} +/** + * The callback function that will be invoked when the selectedIndex of the SubHeaderV2Select is selected. + * + * @typedef { function } SubHeaderV2SelectOnSelect + * @param { int } selectedIndex - the index of selected item + * @param { string } [selectedContent] - the content of selected item + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export type SubHeaderV2SelectOnSelect = (selectedIndex: int, selectedContent?: string) => void; +/** + * Defines the SubHeaderV2SelectOptions. + * + * @interface SubHeaderV2SelectOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface SubHeaderV2SelectOptions { + /** + * Sets the options of the SubHeaderV2SelectOptions. + * + * @type { SelectOption[] } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + options: SelectOption[]; + /** + * Sets the selected index of the SubHeaderV2SelectOptions. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + selectedIndex?: int; + /** + * Sets the selected content of the SubHeaderV2SelectOptions. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + selectedContent?: ResourceStr; + /** + * Sets the onSelect of the SubHeaderV2SelectOptions. + * + * @type { ?SubHeaderV2SelectOnSelect } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onSelect?: SubHeaderV2SelectOnSelect; + /** + * Sets the default focus state of SubHeaderV2SelectOptions. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + defaultFocus?: boolean; +} +/** + * Declare the SubHeaderV2Select + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class SubHeaderV2Select { + /** + * Sets the options of the SubHeaderV2SelectOptions. + * + * @type { SelectOption[] } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public options: SelectOption[]; + /** + * Sets the selected index of the SubHeaderV2SelectOptions. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public selectedIndex?: int; + /** + * Sets the selected content of the SubHeaderV2SelectOptions. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public selectedContent?: ResourceStr; + /** + * Sets the onSelect of the SubHeaderV2SelectOptions. + * + * @type { ?SubHeaderV2SelectOnSelect } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public onSelect?: SubHeaderV2SelectOnSelect; + /** + * Sets the default focus state of SubHeaderV2SelectOptions. + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public defaultFocus?: boolean; + /** + * The constructor of SubHeaderV2Select + * + * @param { SubHeaderV2SelectOptions } options - the options of the SubHeaderV2Select + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public constructor(options: SubHeaderV2SelectOptions); +} +/** + * Control style of operation element + * + * @enum { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum SubHeaderV2OperationType { + /** + * The TextArrow style. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + TEXT_ARROW = 0, + /** + * The Button style. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + BUTTON = 1, + /** + * The IconGroup style. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ICON_GROUP = 2, + /** + * The LoadingProgress style. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + LOADING = 3 +} +/** + * Defines the action callback of the SubHeaderV2OperationItem. + * + * @typedef { function } OnClicked + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export type SubHeaderV2OperationItemAction = () => void; +/** + * SubHeaderV2OperationItemType + * + * @typedef { ResourceStr | SymbolGlyphModifier } SubHeaderV2OperationItemType + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +declare type SubHeaderV2OperationItemType = ResourceStr | SymbolGlyphModifier; +/** + * Defines the SubHeaderV2OperationItemOptions. + * + * @interface SubHeaderV2OperationItemOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface SubHeaderV2OperationItemOptions { + /** + * The content of text or the address of icon. + * + * @type { SubHeaderV2OperationItemType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + content: SubHeaderV2OperationItemType; + /** + * callback function when operate the text or icon. + * + * @type { ?SubHeaderV2OperationItemAction } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + action?: SubHeaderV2OperationItemAction; + /** + * The accessibilityText of this text or icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of this text or icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of this text or icon. + * + * @type { ?string } + * @default "auto".The options are as follows:
+ * "auto":The value is converted to "yes" or "no" based on the component. + * "yes": the current component is selectable for the accessibility service. + * "no": The current component is not selectable for the accessibility service. + * "no-hide-descendants":The current component and all its child components are not selectable
+ * for the accessibility service. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityLevel?: string; + /** + * Sets the default focus state of the text or icon. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + defaultFocus?: boolean; +} +/** + * Declare the SubHeaderV2OperationItem + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class SubHeaderV2OperationItem { + /** + * The content of text or the address of icon. + * + * @type { SubHeaderV2OperationItemType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public content: SubHeaderV2OperationItemType; + /** + * callback function when operate the text or icon. + * + * @type { ?SubHeaderV2OperationItemAction } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public action?: SubHeaderV2OperationItemAction; + /** + * The constructor of SubHeaderV2OperationItem + * + * @param { SubHeaderV2OperationItemOptions } options - the options of the SubHeaderV2OperationItem + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options: SubHeaderV2OperationItemOptions); + /** + * The accessibilityText of this text or icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of this text or icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of this text or icon. + * + * @type { ?string } + * @default "auto".The options are as follows:
+ * "auto":The value is converted to "yes" or "no" based on the component. + * "yes": the current component is selectable for the accessibility service. + * "no": The current component is not selectable for the accessibility service. + * "no-hide-descendants":The current component and all its child components are not selectable
+ * for the accessibility service. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public accessibilityLevel?: string; + /** + * Sets the default focus state of the text or icon. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public defaultFocus?: boolean; +} +/** + * The callback function that will be invoked when the title build. + * + * @typedef { function } SubHeaderV2TitleBuilder + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Builder +export type SubHeaderV2TitleBuilder = () => void; +/** + * Defines struct SubHeaderV2. + * + * @struct { SubHeaderV2 } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct SubHeaderV2 { + /** + * Sets the icon of the SubHeaderV2. + * + * @type { ?SubHeaderV2IconType } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + readonly icon?: SubHeaderV2IconType; + /** + * Sets the title of the SubHeaderV2. + * + * @type { ?SubHeaderV2Title } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + readonly title?: SubHeaderV2Title; + /** + * Sets the select of the SubHeaderV2. + * + * @type { ?SubHeaderV2Select } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + readonly select?: SubHeaderV2Select; + /** + * Sets the operationType of the SubHeaderV2. + * + * @type { ?SubHeaderV2OperationType } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + readonly operationType?: SubHeaderV2OperationType; + /** + * Sets the operationItems of the SubHeaderV2. + * + * @type { ?SubHeaderV2OperationItem[] } + * @readonly + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + readonly operationItems?: SubHeaderV2OperationItem[]; + /** + * Set the title content. + * + * @type { ?SubHeaderV2TitleBuilder } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam + titleBuilder?: SubHeaderV2TitleBuilder; + + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} + diff --git a/api/@ohos.arkui.advanced.SwipeRefresher.d.ets b/api/@ohos.arkui.advanced.SwipeRefresher.d.ets index 1c42bba52e4fd3238f9e6162d95022f42580473f..e17f55838bdf44e65c784e059072faefd76bcc29 100644 --- a/api/@ohos.arkui.advanced.SwipeRefresher.d.ets +++ b/api/@ohos.arkui.advanced.SwipeRefresher.d.ets @@ -17,12 +17,6 @@ * @file * @kit ArkUI */ -/*** if arkts 1.2 */ -import { ResourceStr } from './arkui/component/units'; -import { PropRef } from './arkui/stateManagement/decorator'; -import { Component } from './arkui/component/customComponent'; -import { Builder } from './arkui/component/builder'; -/*** endif */ /** * Declare component SwipeRefresher @@ -41,7 +35,6 @@ import { Builder } from './arkui/component/builder'; * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ @Component export declare struct SwipeRefresher { @@ -53,7 +46,7 @@ export declare struct SwipeRefresher { */ /** * Sets the content when loading. - * @type { ?ResourceStr } + * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 11 @@ -65,21 +58,9 @@ export declare struct SwipeRefresher { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1 */ @Prop content?: ResourceStr; - /** - * Sets the content when loading. - * @type { ?ResourceStr } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef content?: ResourceStr; - /** * Whether the component is loading. * type { boolean } @@ -100,27 +81,6 @@ export declare struct SwipeRefresher { * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1 */ @Prop isLoading: boolean; - - /** - * Whether the component is loading. - * type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @PropRef isLoading: boolean; - - /** - * The method to build component. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - @Builder build(): void; -} +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.SwipeRefresher.static.d.ets b/api/@ohos.arkui.advanced.SwipeRefresher.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..41412209f62d522f7a7f6db931da3dea883687c8 --- /dev/null +++ b/api/@ohos.arkui.advanced.SwipeRefresher.static.d.ets @@ -0,0 +1,61 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceStr } from './arkui/component/units'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { Component } from './arkui/component/customComponent'; +import { Builder } from './arkui/component/builder'; +/** + * Declare component SwipeRefresher + * @struct { SwipeRefresher } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct SwipeRefresher { + /** + * Sets the content when loading. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + content?: ResourceStr; + /** + * Whether the component is loading. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + isLoading: boolean; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.TabTitleBar.static.d.ets b/api/@ohos.arkui.advanced.TabTitleBar.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..8b35346cbf012e06f3b46c66985d4a8e96dd18df --- /dev/null +++ b/api/@ohos.arkui.advanced.TabTitleBar.static.d.ets @@ -0,0 +1,175 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Component } from './arkui/component/customComponent'; +import { ResourceStr } from './arkui/component/units'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { BuilderParam, Builder } from './arkui/component/builder'; +/** + * Declaration of the menu item on the right side. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class TabTitleBarMenuItem { + /** + * Icon resource for this menu item. + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public value: ResourceStr; + /** + * Symbol resource for this menu item. + * + * @type { ?SymbolGlyphModifier }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public symbolStyle?: SymbolGlyphModifier; + /** + * Icon label for this menu item. + * + * @type { ?ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public label?: ResourceStr; + /** + * Whether to enable this menu item. + * + * @type { ?boolean }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public isEnabled?: boolean; + /** + * Callback function when click on this menu item. + * + * @type { ?function }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public action?: () => void; + /** + * The accessibilityText of this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of this menu item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of this menu item. + * + * @type { ?string } + * @default 'auto' + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; +} +/** + * Declaration of the tab item. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class TabTitleBarTabItem { + /** + * Text description for this tab item. + * + * @type { ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public title: ResourceStr; + /** + * Icon resource for this tab item. + * + * @type { ?ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public icon?: ResourceStr; + /** + * Symbol resource for this tab item. + * + * @type { ?SymbolGlyphModifier }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public symbolStyle?: SymbolGlyphModifier; +} +/** + * Declaration of the tabbed title bar. + * @struct { TabTitleBar } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct TabTitleBar { + /** + * Tab items on the left side. + * + * @type { Array }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + tabItems: Array; + /** + * Menu items on the right side. + * + * @type { ?Array }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + menuItems?: Array; + /** + * Content builder. Each component corresponds to a tab item. + * The builder needs to be transferred. + * + * @type { function }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @BuilderParam + swiperContent: () => void; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.ToolBar.static.d.ets b/api/@ohos.arkui.advanced.ToolBar.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..07ee9db63e25894e57497fe11e4b5273cab4cdb9 --- /dev/null +++ b/api/@ohos.arkui.advanced.ToolBar.static.d.ets @@ -0,0 +1,308 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Component } from './arkui/component/customComponent'; +import { ResourceStr, Resource, ResourceColor } from './arkui/component/units'; +import { PropRef, Observed, ObjectLink } from './arkui/stateManagement/decorator'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { DividerModifier } from './arkui/DividerModifier'; +import { LengthMetrics } from './arkui/Graphics'; +import { TabsController } from './arkui/component/tabs'; +import { Builder } from './arkui/component/builder'; +/** + * Declare enum ItemState. + * + * @enum { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum ItemState { + /** + * Enable type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ENABLE = 1, + /** + * Disable type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + DISABLE = 2, + /** + * Activate type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ACTIVATE = 3 +} +/** + * Defines toolBar symbolGlyph options. + * + * @interface ToolBarSymbolGlyphOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface ToolBarSymbolGlyphOptions { + /** + * Modifier of toolbar's normal symbol. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + normal?: SymbolGlyphModifier; + /** + * Modifier of toolbar's activated symbol. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + activated?: SymbolGlyphModifier; +} +/** + * Declare type ToolBarOption. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Observed +export declare class ToolBarOption { + /** + * Define text content. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public content: ResourceStr; + /** + * Define the action event. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public action?: () => void; + /** + * Define icon resource. + * + * @type { ?Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public icon?: Resource; + /** + * Define item type. + * + * @type { ?ItemState } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public state?: ItemState; + /** + * Define text fontColor. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public textColor?: ResourceColor; + /** + * Text fontColor when the item is activated. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public activatedTextColor?: ResourceColor; + /** + * Define icon fillColor. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public iconColor?: ResourceColor; + /** + * Icon fillColor when the item is activated. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public activatedIconColor?: ResourceColor; + /** + * Item symbol icon. + * + * @type { ?ToolBarSymbolGlyphOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public toolBarSymbolOptions?: ToolBarSymbolGlyphOptions; + /** + * The accessibilityText of item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of item. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public accessibilityLevel?: string; +} +/** + * Declare ToolBarOptions use in ToolBar. + * @typedef { Array } ToolBarOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export type ToolBarOptions = Array +/** + * Declare ToolBarModifier use in ToolBar. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class ToolBarModifier { + /** + * Sets the height of the toolBar. + * + * @param { LengthMetrics } height - toolBar's height. + * @returns { ToolBarModifier } returns the instance of the ToolBarModifier. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public height(height: LengthMetrics): ToolBarModifier; + /** + * Sets the backgroundColor of the toolBar. + * + * @param { ResourceColor } backgroundColor - toolBar's backgroundColor. + * @returns { ToolBarModifier } returns the instance of the ToolBarModifier. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public backgroundColor(backgroundColor: ResourceColor): ToolBarModifier; + /** + * Sets the left and right padding of the toolbar. + * + * @param { LengthMetrics } padding - left and right padding. + * @returns { ToolBarModifier } returns the instance of the ToolBarModifier. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public padding(padding: LengthMetrics): ToolBarModifier; + /** + * Sets whether or not to display the press status effect. + * + * @param { boolean } stateEffect - press status effect. + * @returns { ToolBarModifier } returns the instance of the ToolBarModifier. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public stateEffect(stateEffect: boolean): ToolBarModifier; +} +/** + * Declare Component ToolBar. + * @struct { ToolBar } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct ToolBar { + /** + * Define toolbar list array. + * + * @type { ToolBarOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @ObjectLink + toolBarList: ToolBarOptions; + /** + * Define toolbar activate item index, default is -1. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + activateIndex?: int; + /** + * Define toolbar controller. + * + * @type { TabsController } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + controller: TabsController; + /** + * Define divider Modifier. + * + * @type { ?DividerModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + dividerModifier?: DividerModifier; + /** + * Define toolbar modifier. + * + * @type { ?ToolBarModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + toolBarModifier?: ToolBarModifier; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} diff --git a/api/@ohos.arkui.advanced.ToolBarV2.static.d.ets b/api/@ohos.arkui.advanced.ToolBarV2.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..3b94b908c252c88f8733d8d58f468d7e35e4d4c2 --- /dev/null +++ b/api/@ohos.arkui.advanced.ToolBarV2.static.d.ets @@ -0,0 +1,549 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ComponentV2 } from './arkui/component/customComponent'; +import { ResourceStr } from './arkui/component/units'; +import { ObservedV2, Param, Require, Trace } from './arkui/stateManagement/decorator'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { DividerModifier } from './arkui/DividerModifier'; +import { ColorMetrics, LengthMetrics } from './arkui/Graphics'; +import { Builder } from './arkui/component/builder'; +/** + * Declare enum ToolBarV2ItemState. + * + * @enum { int }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum ToolBarV2ItemState { + /** + * Enable type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ENABLE = 1, + /** + * Disable type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + DISABLE = 2, + /** + * Activate type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ACTIVATE = 3 +} +/** + * Defines toolBarV2 symbolGlyph. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class ToolBarV2SymbolGlyph { + /** + * Modifier of toolbarV2's normal symbol. + * + * @type { SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public normal: SymbolGlyphModifier; + /** + * Modifier of toolbarV2's activated symbol. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public activated?: SymbolGlyphModifier; + /** + * The constructor used to create a ToolBarV2SymbolGlyph object. + * + * @param { ToolBarV2SymbolGlyphOptions } options - symbol info. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options: ToolBarV2SymbolGlyphOptions); +} +/** + * Declare the options of ToolBarV2SymbolGlyph. + * + * @interface ToolBarV2SymbolGlyphOptions. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface ToolBarV2SymbolGlyphOptions { + /** + * Modifier of toolbarV2's normal symbol. + * + * @type { SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + normal: SymbolGlyphModifier; + /** + * Modifier of toolbarV2's activated symbol. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + activated?: SymbolGlyphModifier; +} +/** + * Declare type ToolBarV2ItemText. + * + * @class ToolBarV2ItemText. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class ToolBarV2ItemText { + /** + * Define text content. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public text: ResourceStr; + /** + * Define text fontColor. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public color?: ColorMetrics; + /** + * Text fontColor when the item is activated. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public activatedColor?: ColorMetrics; + /** + * The constructor used to create a ToolBarV2ItemText object. + * + * @param { ToolBarV2ItemTextOptions } options - text info. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options: ToolBarV2ItemTextOptions); +} +/** + * Declare the options of ToolBarV2ItemText. + * + * @interface ToolBarV2ItemTextOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface ToolBarV2ItemTextOptions { + /** + * Define text content. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + text: ResourceStr; + /** + * Define text fontColor. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + color?: ColorMetrics; + /** + * Text fontColor when the item is activated. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + activatedColor?: ColorMetrics; +} +/** + * Defines the icon type of ToolBarV2 item. + * @typedef { ToolBarV2ItemImage | ToolBarV2SymbolGlyph } ToolBarV2ItemIconType + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare type ToolBarV2ItemIconType = ToolBarV2ItemImage | ToolBarV2SymbolGlyph; +/** + * Declare type ToolBarV2ItemImage. + * + * @class ToolBarV2ItemImage. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class ToolBarV2ItemImage { + /** + * Define icon resource. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public src: ResourceStr; + /** + * Define icon fillColor. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public color?: ColorMetrics; + /** + * Icon fillColor when the item is activated. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public activatedColor?: ColorMetrics; + /** + * The constructor used to create a ToolBarV2ItemImage object. + * + * @param { ToolBarV2ItemImageOptions } options - text info. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options: ToolBarV2ItemImageOptions); +} +/** + * Declare the options of ToolBarV2ItemImage. + * + * @interface ToolBarV2ItemImageOptions. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface ToolBarV2ItemImageOptions { + /** + * Define icon resource. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + src: ResourceStr; + /** + * Define icon fillColor. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + color?: ColorMetrics; + /** + * Icon fillColor when the item is activated. + * + * @type { ?ColorMetrics } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + activatedColor?: ColorMetrics; +} +/** + * Declare type ToolBarV2Item. + * + * @class ToolBarV2Item + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ObservedV2 +export declare class ToolBarV2Item { + /** + * Define text content. + * + * @type { ToolBarV2ItemText } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public content: ToolBarV2ItemText; + /** + * Define the action event. + * + * @type { ?ToolBarV2ItemAction } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public action?: ToolBarV2ItemAction; + /** + * Define icon resource. + * + * @type { ?ToolBarV2ItemIconType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public icon?: ToolBarV2ItemIconType; + /** + * Define item type. + * + * @type { ?ToolBarV2ItemState } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public state?: ToolBarV2ItemState; + /** + * The accessibilityText of item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of item. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Trace + public accessibilityLevel?: string; + /** + * The constructor used to create a ToolBarV2Item object. + * + * @param { ToolBarV2ItemOptions } options - text info. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options: ToolBarV2ItemOptions); +} +/** + * Declare the options of ToolBarV2Item. + * + * @interface ToolBarV2ItemOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface ToolBarV2ItemOptions { + /** + * Define text content. + * + * @type { ToolBarV2ItemText } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + content: ToolBarV2ItemText; + /** + * Define the action event. + * + * @type { ?ToolBarV2ItemAction } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + action?: ToolBarV2ItemAction; + /** + * Define icon resource. + * + * @type { ?ToolBarV2ItemIconType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + icon?: ToolBarV2ItemIconType; + /** + * Define item type. + * + * @type { ?ToolBarV2ItemState } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + state?: ToolBarV2ItemState; + /** + * The accessibilityText of item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of item. + * + * @type { ?string } + * @default "auto". + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityLevel?: string; +} +/** + * Defines the action callback of ToolBarV2Item. + * @typedef { function } ToolBarV2ItemAction + * @param { int } index - toolBarV2's ItemAction. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export type ToolBarV2ItemAction = (index: int) => void; +/** + * Declare ToolBarV2Modifier used in ToolBar. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class ToolBarV2Modifier { + /** + * Sets the height of the toolBarV2. + * + * @param { LengthMetrics } height - toolBarV2's height. + * @returns { ToolBarV2Modifier } returns the instance of the ToolBarV2Modifier. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public height(height: LengthMetrics): ToolBarV2Modifier; + /** + * Sets the backgroundColor of the toolBarV2. + * + * @param { ColorMetrics } backgroundColor - toolBarV2's backgroundColor. + * @returns { ToolBarV2Modifier } returns the instance of the ToolBarV2Modifier. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public backgroundColor(backgroundColor: ColorMetrics): ToolBarV2Modifier; + /** + * Sets the left and right padding of the toolbarV2. + * + * @param { LengthMetrics } padding - left and right padding. + * @returns { ToolBarV2Modifier } returns the instance of the ToolBarV2Modifier. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public padding(padding: LengthMetrics): ToolBarV2Modifier; + /** + * Sets whether or not to display the press status effect. + * + * @param { boolean } stateEffect - press status effect. + * @returns { ToolBarV2Modifier } returns the instance of the ToolBarV2Modifier. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public stateEffect(stateEffect: boolean): ToolBarV2Modifier; +} +/** + * Declare Component ToolBarV2 + * + * @struct { ToolBarV2 }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@ComponentV2 +export declare struct ToolBarV2 { + /** + * Define toolbarV2 item list. + * + * @type { ToolBarV2Item[] } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Require + @Param + toolBarList: ToolBarV2Item[]; + /** + * Define toolbarV2 activate item index, default is -1. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + activatedIndex?: int; + /** + * Define divider Modifier. + * + * @type { ?DividerModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + dividerModifier?: DividerModifier; + /** + * Define toolbarV2 modifier. + * + * @type { ?ToolBarV2Modifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Param + toolBarModifier?: ToolBarV2Modifier; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder + build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.TreeView.static.d.ets b/api/@ohos.arkui.advanced.TreeView.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..b2862f958bf184771f5305b8fc391bb21a2e3f08 --- /dev/null +++ b/api/@ohos.arkui.advanced.TreeView.static.d.ets @@ -0,0 +1,366 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceStr } from './arkui/component/units'; +import { Component } from './arkui/component/customComponent'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { Builder } from './arkui/component/builder'; +/** + * Control style of operation element + * + * @enum { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare enum TreeListenType { + /** + * register listener after a node is clicked. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + NODE_CLICK = 'NodeClick', + /** + * register listener after a node is add. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * + * @since 20 + */ + NODE_ADD = 'NodeAdd', + /** + * register listener after a node is delected. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + NODE_DELETE = 'NodeDelete', + /** + * register listener after a node is modified. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + NODE_MODIFY = 'NodeModify', + /** + * register listener after a node is moved. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + NODE_MOVE = 'NodeMove', +} +/** + * Callback method of Event registration and processing. + * + * @typedef { function } OnChangedCallback + * @param { CallbackParam } callbackParam - The result of event. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +declare type OnChangedCallback = (callbackParam: CallbackParam) => void; +/** + * Declare class TreeListener + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class TreeListener { + /** + * Event registration and processing. + * The event will not be destroyed after being processed. + * + * @param { TreeListenType } type - Registered Events. + * @param { OnChangedCallback } callback + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public on(type: TreeListenType, callback: OnChangedCallback): void; + /** + * Event registration and processing. + * After the event is processed once, it will be destroyed. + * + * @param { TreeListenType } type - Registered Events. + * @param { OnChangedCallback } callback + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public once(type: TreeListenType, callback: OnChangedCallback): void; + /** + * Destroy event. + * + * @param { TreeListenType } type - Registered Events. + * @param { OnChangedCallback } [callback] + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public off(type: TreeListenType, callback?: OnChangedCallback): void; +} +/** + * Declare class TreeListenerManager + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class TreeListenerManager { + /** + * Get instance of treeListenerManager. + * + * @returns { TreeListenerManager } Returns the treeListenerManager instance. + * @static + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + static getInstance(): TreeListenerManager; + /** + * Get treeListener. + * + * @returns { TreeListener } Returns the treeListener object. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public getTreeListener(): TreeListener; +} +/** + * Declare TreeView Component + * @struct { TreeView } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +@Component +export declare struct TreeView { + /** + * Node data source of TreeView. + * + * @type { TreeController } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + treeController: TreeController; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} +/** + * Declare CallbackParam + * + * @typedef CallbackParam + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface CallbackParam { + /** + * Get the currentNodeId. + * + * @type { int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + currentNodeId: int, + /** + * Get the parentNodeId. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + parentNodeId?: int, + /** + * Get the childIndex. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + childIndex?: int +} +/** + * Declare NodeParam + * + * @typedef NodeParam + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export interface NodeParam { + /** + * Set the parentNodeId. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + parentNodeId?: int, + /** + * Set currentNodeId. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + currentNodeId?: int, + /** + * Set catalog whether is floder. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + isFolder?: boolean; + /** + * Set the icon resource. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + icon?: ResourceStr; + /** + * Set the symbol resource. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolIconStyle?: SymbolGlyphModifier; + /** + * Set selected icon resource. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + selectedIcon?: ResourceStr; + /** + * Set selected symbol resource. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolSelectedIconStyle?: SymbolGlyphModifier; + /** + * Set edit icon resource. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + editIcon?: ResourceStr; + /** + * Set edit symbol resource. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolEditIconStyle?: SymbolGlyphModifier; + /** + * Set primary title content. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryTitle?: ResourceStr; + /** + * Set secondary title content. + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * + * @since 20 + */ + secondaryTitle?: ResourceStr; + /** + * set subcomponent binded on tree item. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + container?: () => void; +} +/** + * Declare TreeController + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @noninterop + */ +export declare class TreeController { + /** + * Delete a node. + * Register an ON_ITEM_DELETE callback through the ListTreeListener mechanism to obtain the IDs of all deleted + * nodes. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public removeNode(): void; + /** + * Modify the node name. + * Register an ON_ITEM_MODIFY callback to obtain the ID, parent node ID, and node name of the modified node. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public modifyNode(): void; + /** + * Initialize the interface of the tree view. This interface is used to generate ListNodeDataSource data. + * addNode is only designed for initialization. It can only be invoked during initialization. + * A maximum of 50 directory levels can be added. + * For details, see the comment description of NodeParam. + * + * @param { NodeParam } [nodeParam] Configuration information of the newly added node. + * @returns { TreeController } ListTreeNode Tree view component proxy class. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public addNode(nodeParam?: NodeParam): TreeController; + /** + * This interface is called when a secondaryTitle needs to be updated + * + * @param { int } parentId - ID of the parent node. + * @param { ResourceStr } parentSubTitle - secondaryTitle of parent node. + * @param { ResourceStr } currentSubtitle - secondaryTitle of current node. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public refreshNode(parentId: int, parentSubTitle: ResourceStr, currentSubtitle: ResourceStr): void; + /** + * After the initialization is complete by calling the addNode interface, + * call this interface to complete initialization. + * This interface must be called when you finish initializing the ListTreeView by addNode. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + public buildDone(): void; +} diff --git a/api/@ohos.arkui.component.d.ets b/api/@ohos.arkui.component.d.ets index a0fe3c2371592461fd29063e99add539952569be..36844983ffdd3dcd5ac364c8ad8ea0aa25576a74 100644 --- a/api/@ohos.arkui.component.d.ets +++ b/api/@ohos.arkui.component.d.ets @@ -23,7 +23,6 @@ export * from './arkui/UserView'; export * from './arkui/component/animation'; export * from './arkui/component/customComponent'; export * from './arkui/component/common'; -export * from './arkui/component/column'; export * from './arkui/component/text'; export * from './arkui/component/styledString'; export * from './arkui/component/enums'; @@ -80,13 +79,11 @@ export * from './arkui/component/inspector'; export * from './arkui/component/interop'; export * from './arkui/component/lazyForEach'; export * from './arkui/component/line'; -export * from './arkui/component/linearindicator'; export * from './arkui/component/list'; export * from './arkui/component/listItem'; export * from './arkui/component/listItemGroup'; export * from './arkui/component/loadingProgress'; export * from './arkui/component/marquee'; -export * from './arkui/component/matrix2d'; export * from './arkui/component/mediaCachedImage'; export * from './arkui/component/menu'; export * from './arkui/component/menuItem'; @@ -127,7 +124,6 @@ export * from './arkui/component/sidebar'; export * from './arkui/component/slider'; export * from './arkui/component/span'; export * from './arkui/component/stack'; -export * from './arkui/component/stateManagement'; export * from './arkui/component/stepper'; export * from './arkui/component/stepperItem'; export * from './arkui/component/styledString'; diff --git a/api/@ohos.arkui.componentSnapshot.d.ts b/api/@ohos.arkui.componentSnapshot.d.ts index 9d76a24829f7ec7508377272affc3e7df6480d2e..bbb183f6ddf63287b1a01f0ff4dae8d7a7adb909 100644 --- a/api/@ohos.arkui.componentSnapshot.d.ts +++ b/api/@ohos.arkui.componentSnapshot.d.ts @@ -18,12 +18,8 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { CustomBuilder } from './arkui/component/builder'; -/*** endif */ - import { AsyncCallback } from './@ohos.base'; -import image from './@ohos.multimedia.image'; +import image from './@ohos.multimedia.image' /** * This module allows developers to export snapshot image from a component or a custom builder. @@ -40,8 +36,7 @@ import image from './@ohos.multimedia.image'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare namespace componentSnapshot { /** @@ -51,10 +46,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ - export interface SnapshotRegion { + interface SnapshotRegion { /** * Left side position of rectangle, in PX. * @@ -62,8 +56,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ left: number; @@ -74,8 +67,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ right: number; @@ -86,8 +78,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ top: number; @@ -98,8 +89,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ bottom: number; } @@ -112,10 +102,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ - export interface LocalizedSnapshotRegion { + interface LocalizedSnapshotRegion { /** * Left/Right side position of rectangle, in PX * @@ -123,8 +112,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ start: number; @@ -135,8 +123,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ end: number; @@ -147,8 +134,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ top: number; @@ -159,8 +145,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ bottom: number; } @@ -172,10 +157,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ - export type SnapshotRegionType = SnapshotRegion | LocalizedSnapshotRegion; + type SnapshotRegionType = SnapshotRegion | LocalizedSnapshotRegion; /** * Defines the extra options for snapshot taking. @@ -184,10 +168,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface SnapshotOptions { + interface SnapshotOptions { /** * Defines the scale property to render the snapshot. * @@ -195,8 +178,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ scale?: number @@ -207,8 +189,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ waitUntilRenderFinished?: boolean @@ -219,8 +200,7 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ region?: SnapshotRegionType } @@ -253,10 +233,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since 12 * @deprecated since 18 * @useinstead ohos.arkui.UIContext.ComponentSnapshot#get - * @arkts 1.1&1.2 */ function get(id: string, callback: AsyncCallback, options?: SnapshotOptions): void; @@ -288,10 +267,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since 12 * @deprecated since 18 * @useinstead ohos.arkui.UIContext.ComponentSnapshot#get - * @arkts 1.1&1.2 */ function get(id: string, options?: SnapshotOptions): Promise; @@ -327,10 +305,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since 12 * @deprecated since 18 * @useinstead ohos.arkui.UIContext.ComponentSnapshot#createFromBuilder - * @arkts 1.1&1.2 */ function createFromBuilder(builder: CustomBuilder, callback: AsyncCallback, delay?: number, checkImageStatus?: boolean, options?: SnapshotOptions): void; @@ -367,10 +344,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since 12 * @deprecated since 18 * @useinstead ohos.arkui.UIContext.ComponentSnapshot#createFromBuilder - * @arkts 1.1&1.2 */ function createFromBuilder(builder: CustomBuilder, delay?: number, checkImageStatus?: boolean, options?: SnapshotOptions): Promise; @@ -392,10 +368,9 @@ declare namespace componentSnapshot { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export function getSync(id: string, options?: SnapshotOptions): image.PixelMap; + function getSync(id: string, options?: SnapshotOptions): image.PixelMap; } export default componentSnapshot; diff --git a/api/@ohos.arkui.componentSnapshot.static.d.ets b/api/@ohos.arkui.componentSnapshot.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..f24eb7c1e67aa9f5b50ad05921e459e0bcd69855 --- /dev/null +++ b/api/@ohos.arkui.componentSnapshot.static.d.ets @@ -0,0 +1,175 @@ +/* + * Copyright (c) 2023 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { CustomBuilder } from './arkui/component/builder'; +import { AsyncCallback } from './@ohos.base'; +import image from './@ohos.multimedia.image'; + +/** + * This module allows developers to export snapshot image from a component or a custom builder. + * + * @namespace componentSnapshot + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace componentSnapshot { + /** + * Defines the extra options for snapshot taking. + * + * @typedef SnapshotRegion + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface SnapshotRegion { + /** + * Left side position of rectangle, in PX. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + left: number; + /** + * Right side position of Rectangle, in PX. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + right: number; + /** + * Top side position of Rectangle, in PX. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + top: number; + /** + * Bottom side position of Rectangle, in PX. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + bottom: number; + } + /** + * Defines the extra options for snapshot taking, if this is used, the start and end will + * be assigned to left and right value according to the layout direction of node automaticlly. + * + * @typedef LocalizedSnapshotRegion + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface LocalizedSnapshotRegion { + /** + * Left/Right side position of rectangle, in PX + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + start: number; + /** + * End side position of Rectangle, in PX. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + end: number; + /** + * Left/Right side position of rectangle, in PX + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + top: number; + /** + * Bottom side position of Rectangle, in PX. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + bottom: number; + } + /** + * Defines the snapshot region rect type. + * + * @typedef { SnapshotRegion | LocalizedSnapshotRegion } SnapshotRegionType + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export type SnapshotRegionType = SnapshotRegion | LocalizedSnapshotRegion; + /** + * Defines the extra options for snapshot taking. + * + * @typedef SnapshotOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface SnapshotOptions { + /** + * Defines the scale property to render the snapshot. + * + * @type {?number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + scale?: number; + /** + * Whether to wait the rendering is finished. + * + * @type {?boolean} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + waitUntilRenderFinished?: boolean; + /** + * Defines the rect reigon type of the snapshot. + * + * @type {?SnapshotRegionType} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + region?: SnapshotRegionType; + } + /** + * Take a screenshot of the specified component in synchronous mode, + * this mode will block the main thread, please use it with caution, the maximum + * waiting time of the interface is 3s, if it does not return after 3s, an exception will be thrown. + * + * @param { string } id - Target component ID, set by developer through .id attribute. + * @param { SnapshotOptions } [options] - Define the snapshot options. + * @returns { image.PixelMap } The snapshot result in PixelMap format. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 100001 - Invalid ID. + * @throws { BusinessError } 160002 - Timeout. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function getSync(id: string, options?: SnapshotOptions): image.PixelMap; +} +export default componentSnapshot; diff --git a/api/@ohos.arkui.componentUtils.d.ts b/api/@ohos.arkui.componentUtils.d.ts index 5f2b6268df7841b1c25d4b4b01f67dd361d7d6b0..32658420dca159b505dcfb4717f7f95fb6b865ed 100644 --- a/api/@ohos.arkui.componentUtils.d.ts +++ b/api/@ohos.arkui.componentUtils.d.ts @@ -37,8 +37,7 @@ * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare namespace componentUtils { @@ -61,10 +60,9 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface ComponentInfo { + interface ComponentInfo { /** * component size. @@ -85,8 +83,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ size: Size @@ -109,8 +106,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ localOffset: Offset @@ -133,8 +129,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ windowOffset: Offset @@ -157,8 +152,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ screenOffset: Offset @@ -181,8 +175,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ translate: TranslateResult @@ -205,8 +198,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ scale: ScaleResult @@ -229,8 +221,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ rotate: RotateResult @@ -253,8 +244,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ transform: Matrix4Result } @@ -278,10 +268,9 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface Size { + interface Size { /** * Defines the width property. @@ -302,8 +291,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width: number @@ -326,8 +314,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height: number } @@ -351,10 +338,9 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface Offset { + interface Offset { /** * Coordinate x of the Position. @@ -375,8 +361,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ x: number @@ -399,8 +384,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ y: number } @@ -424,10 +408,9 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface TranslateResult { + interface TranslateResult { /** * Indicates the translation distance of the x-axis, in vp. @@ -448,8 +431,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ x: number @@ -472,8 +454,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ y: number @@ -496,8 +477,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ z: number } @@ -521,10 +501,9 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface ScaleResult { + interface ScaleResult { /** * Zoom factor of the x-axis. @@ -545,8 +524,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ x: number @@ -569,8 +547,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ y: number @@ -593,8 +570,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ z: number @@ -617,8 +593,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ centerX: number @@ -641,8 +616,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ centerY: number } @@ -666,10 +640,9 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface RotateResult { + interface RotateResult { /** * Axis of rotation vector x coordinate. @@ -690,8 +663,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ x: number @@ -714,8 +686,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ y: number @@ -738,8 +709,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ z: number @@ -762,8 +732,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ centerX: number @@ -786,8 +755,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ centerY: number @@ -810,8 +778,7 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ angle: number } @@ -835,10 +802,9 @@ declare namespace componentUtils { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export type Matrix4Result = [ + type Matrix4Result = [ number, number, number, diff --git a/api/@ohos.arkui.componentUtils.static.d.ets b/api/@ohos.arkui.componentUtils.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..3db3aebc22143d861e79fbddaada1e8f0c494f79 --- /dev/null +++ b/api/@ohos.arkui.componentUtils.static.d.ets @@ -0,0 +1,351 @@ +/* + * Copyright (c) 2023-2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + + +/** + * This module provides functionality for component coordinates and sizes. + * @namespace componentUtils + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace componentUtils { + + + /** + * Component information. + * @typedef ComponentInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface ComponentInfo { + + + /** + * component size. + * @type {Size} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + size: Size; + + + /** + * Obtain attribute information relative to the local. + * @type {Offset} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + localOffset: Offset; + + + /** + * Obtain attribute information relative to the window. + * @type {Offset} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + windowOffset: Offset; + + + /** + * Obtain attribute information relative to the screen. + * @type {Offset} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + screenOffset: Offset; + + + /** + * Obtain attribute information for translation. + * @type {TranslateResult} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + translate: TranslateResult; + + + /** + * Obtain attribute information for scale. + * @type {ScaleResult} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + scale: ScaleResult; + + + /** + * Obtain attribute information for rotate. + * @type {RotateResult} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + rotate: RotateResult; + + + /** + * Obtain attribute information of the transformation matrix. + * @type {Matrix4Result} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + transform: Matrix4Result; + } + + + /** + * Defines the size property. + * @typedef Size + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface Size { + + + /** + * Defines the width property. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + width: number; + + + /** + * Defines the height property. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + height: number; + } + + + /** + * Defines the offset property. + * @typedef Offset + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface Offset { + + + /** + * Coordinate x of the Position. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + x: number; + + + /** + * Coordinate y of the Position. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + y: number; + } + + + /** + * Translation Result + * @typedef TranslateResult + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface TranslateResult { + + + /** + * Indicates the translation distance of the x-axis, in vp. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + x: number; + + + /** + * Indicates the translation distance of the y-axis, in vp. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + y: number; + + + /** + * Indicates the translation distance of the z-axis, in vp. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + z: number; + } + + + /** + * Scale Result + * @typedef ScaleResult + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface ScaleResult { + + + /** + * Zoom factor of the x-axis. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + x: number; + + + /** + * Zoom factor of the y-axis. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + y: number; + + + /** + * Zoom factor of the z-axis. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + z: number; + + + /** + * Transform the x-axis coordinate of the center point. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + centerX: number; + + + /** + * Transform the y-axis coordinate of the center point. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + centerY: number; + } + + + /** + * Rotation Result. + * @typedef RotateResult + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface RotateResult { + + + /** + * Axis of rotation vector x coordinate. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + x: number; + + + /** + * Axis of rotation vector y coordinate. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + y: number; + + + /** + * Axis of rotation vector z coordinate. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + z: number; + + + /** + * Transform the x-axis coordinate of the center point. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + centerX: number; + + + /** + * Transform the y-axis coordinate of the center point. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + centerY: number; + + + /** + * Rotation angle. + * @type {number} + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + angle: number; + } + + + /** + * The matrix is column-first fourth-order matrix. + * @typedef { [number, number, number, number, number, number, number, number, number, number, number, number, + * number, number, number, number,] } Matrix4Result + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export type Matrix4Result = [ + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; +} +export default componentUtils; diff --git a/api/@ohos.arkui.dragController.d.ts b/api/@ohos.arkui.dragController.d.ts index 644633570beba5f4b62c5bb2934aa30f0da3f6d0..01b51d532bd6a3c19b5451b3a0b852720d1189a3 100644 --- a/api/@ohos.arkui.dragController.d.ts +++ b/api/@ohos.arkui.dragController.d.ts @@ -18,12 +18,6 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { DragEvent, DragPreviewOptions, DragItemInfo, ICurve } from './arkui/component/common'; -import { CustomBuilder } from './arkui/component/builder'; -import { TouchPoint, ResourceColor } from './arkui/component/units'; -import { Curve } from './arkui/component/enums'; -/*** endif */ import type { AsyncCallback, BusinessError, Callback } from './@ohos.base'; @@ -48,8 +42,7 @@ import type unifiedDataChannel from './@ohos.data.unifiedDataChannel'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ declare namespace dragController { /** @@ -74,8 +67,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ const enum DragStatus { /** @@ -94,8 +86,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ STARTED = 0, /** @@ -114,8 +105,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ ENDED = 1, } @@ -142,8 +132,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface DragAndDropInfo { /** @@ -165,8 +154,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ status: DragStatus; /** @@ -188,8 +176,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ event: DragEvent; /** @@ -211,8 +198,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ extraParams?: string; } @@ -239,8 +225,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface DragAction { /** @@ -268,8 +253,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ startDrag(): Promise; /** @@ -300,8 +284,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ on(type: 'statusChange', callback: Callback): void; @@ -333,8 +316,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ off(type: 'statusChange', callback?: Callback): void; } @@ -361,8 +343,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface DragInfo { /** @@ -384,8 +365,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ pointerId: number; @@ -408,8 +388,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ data?: unifiedDataChannel.UnifiedData; @@ -432,8 +411,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ extraParams?: string; @@ -456,8 +434,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ touchPoint?: TouchPoint; @@ -480,8 +457,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ previewOptions?: DragPreviewOptions; @@ -522,8 +498,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface AnimationOptions { /** @@ -545,8 +520,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ duration?: number; /** @@ -568,8 +542,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ curve?: Curve | ICurve; } @@ -590,8 +563,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ export class DragPreview { /** @@ -613,8 +585,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ setForegroundColor(color: ResourceColor): void; /** @@ -639,8 +610,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ animate(options: AnimationOptions, handler: () =>void): void; } @@ -660,8 +630,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface DragEventParam { @@ -684,8 +653,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ event: DragEvent; @@ -708,8 +676,7 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ extraParams: string; } @@ -718,12 +685,11 @@ declare namespace dragController { * Execute a drag event. * @param { CustomBuilder | DragItemInfo } custom - Object used for prompts displayed when the object is dragged. * @param { DragInfo } dragInfo - Information about the drag event. - * @param { AsyncCallback<{ event: DragEvent, extraParams: string }> } callback - Callback that contains the drag - * event information. - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @param { AsyncCallback<{ event: DragEvent, extraParams: string }> } callback - Callback that contains the drag event information. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 @@ -733,45 +699,44 @@ declare namespace dragController { * @param { CustomBuilder | DragItemInfo } custom - Object used for prompts displayed when the object is dragged. * @param { DragInfo } dragInfo - Information about the drag event. * @param { AsyncCallback } callback - Callback that contains the drag event information. - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 12 - */ + */ /** * Execute a drag event. * @param { CustomBuilder | DragItemInfo } custom - Object used for prompts displayed when the object is dragged. * @param { DragInfo } dragInfo - Information about the drag event. * @param { AsyncCallback } callback - Callback that contains the drag event information. - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @deprecated since 18 + * @since 18 + * @deprecated since 18 * @useinstead ohos.arkui.UIContext.DragController#executeDrag - * @arkts 1.1&1.2 */ function executeDrag(custom: CustomBuilder | DragItemInfo, dragInfo: DragInfo, - callback: AsyncCallback): void; + callback: AsyncCallback): void; /** * Execute a drag event. * @param { CustomBuilder | DragItemInfo } custom - Object used for prompts displayed when the object is dragged. * @param { DragInfo } dragInfo - Information about the drag event. * @returns { Promise<{ event: DragEvent, extraParams: string }> } A Promise with the drag event information. - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 10 @@ -781,10 +746,10 @@ declare namespace dragController { * @param { CustomBuilder | DragItemInfo } custom - Object used for prompts displayed when the object is dragged. * @param { DragInfo } dragInfo - Information about the drag event. * @returns { Promise } A Promise with the drag event information. - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -795,18 +760,17 @@ declare namespace dragController { * @param { CustomBuilder | DragItemInfo } custom - Object used for prompts displayed when the object is dragged. * @param { DragInfo } dragInfo - Information about the drag event. * @returns { Promise } A Promise with the drag event information. - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since 18 * @deprecated since 18 * @useinstead ohos.arkui.UIContext.DragController#executeDrag - * @arkts 1.1&1.2 */ function executeDrag(custom: CustomBuilder | DragItemInfo, dragInfo: DragInfo): Promise; @@ -814,13 +778,13 @@ declare namespace dragController { * Create one drag action object, which can be used for starting drag later or monitoring * the drag status after drag started. * @param { Array } customArray - Objects used for prompts - * displayed when the objects are dragged. + * displayed when the objects are dragged. * @param { DragInfo } dragInfo - Information about the drag event. * @returns { DragAction } one drag action object - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 11 @@ -829,13 +793,13 @@ declare namespace dragController { * Create one drag action object, which can be used for starting drag later or monitoring * the drag status after drag started. * @param { Array } customArray - Objects used for prompts - * displayed when the objects are dragged. + * displayed when the objects are dragged. * @param { DragInfo } dragInfo - Information about the drag event. * @returns { DragAction } one drag action object - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice @@ -845,21 +809,20 @@ declare namespace dragController { * Create one drag action object, which can be used for starting drag later or monitoring * the drag status after drag started. * @param { Array } customArray - Objects used for prompts - * displayed when the objects are dragged. + * displayed when the objects are dragged. * @param { DragInfo } dragInfo - Information about the drag event. * @returns { DragAction } one drag action object - * @throws { BusinessError } 401 - Parameter error. Possible causes: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. * @throws { BusinessError } 100001 - Internal handling failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since 18 * @deprecated since 18 * @useinstead ohos.arkui.UIContext.DragController#createDragAction - * @arkts 1.1&1.2 */ function createDragAction(customArray: Array, dragInfo: DragInfo): DragAction; @@ -882,42 +845,39 @@ declare namespace dragController { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since 18 * @deprecated since 18 * @useinstead ohos.arkui.UIContext.DragController#getDragPreview - * @arkts 1.1&1.2 */ function getDragPreview(): DragPreview; /** * Define the status for the application to notify the framework whether to execute drag. - * + * * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ const enum DragStartRequestStatus { + /** * Notify the framework that the application is not yet ready and needs to temporarily block * the start of drag, only effective in onDragStart calls. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ WAITING = 0, /** * Notify the framework that the drag can continue to be started, but only during the start * of drag, and will not take effect when the drag is started. - * + * * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ READY = 1, } @@ -932,7 +892,7 @@ declare namespace dragController { * @atomicservice * @since 20 */ - enum DragSpringLoadingState { + const enum DragSpringLoadingState { /** * The user has remained stationary for a period, initiating the spring loading process. * This state allows for some preparatory operations during spring loading. @@ -1045,10 +1005,12 @@ declare namespace dragController { * @since 20 */ dataSummary?: unifiedDataChannel.Summary; + /** - * Summary of the dragged data. This field is absent if the source application did not configure data. + * Additional information provided by the source application when initiating the drag operation. + * This field is absent if the source application did not configure it. * - * @type { ?unifiedDataChannel.Summary } + * @type { ?string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 20 @@ -1119,7 +1081,7 @@ declare namespace dragController { * Typically, applications should use default configurations or set them once during binding. * Use this method sparingly, e.g., for different drag data types requiring varied UX timing. * - * @param { config } The spring loading detection configuration + * @param { DragSpringLoadingConfiguration } config - The spring loading detection configuration * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice * @since 20 diff --git a/api/@ohos.arkui.dragController.static.d.ets b/api/@ohos.arkui.dragController.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..a78d8c648fa5e0b2f760775e65be8c1f7c816299 --- /dev/null +++ b/api/@ohos.arkui.dragController.static.d.ets @@ -0,0 +1,313 @@ +/* + * Copyright (c) 2023 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { DragEvent, DragPreviewOptions, DragItemInfo, ICurve } from './arkui/component/common'; +import { CustomBuilder } from './arkui/component/builder'; +import { TouchPoint, ResourceColor } from './arkui/component/units'; +import { Curve } from './arkui/component/enums'; +import type { AsyncCallback, BusinessError, Callback } from './@ohos.base'; +import type unifiedDataChannel from './@ohos.data.unifiedDataChannel'; + + +/** + * This module allows developers to trigger a drag event. + * @namespace dragController + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace dragController { + + + /** + * Defines the Drag Status. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + const enum DragStatus { + + + /** + * Drag has started. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + STARTED = 0, + + + /** + * Drag has ended. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ENDED = 1 + } + + + /** + * Drag and drop information + * + * @interface DragAndDropInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface DragAndDropInfo { + + + /** + * The drag status. + * @type { DragStatus } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + status: DragStatus; + + + /** + * The information containing the drag event. + * @type { DragEvent } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + event: DragEvent; + + + /** + * Additional information about the drag info. + * @type { ?string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + extraParams?: string; + } + + + /** + * One drag action object for drag process + * + * @interface DragAction + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface DragAction { + + + /** + * trigger drag action + * + * @returns { Promise } A Promise can indicate the start result. + * @throws { BusinessError } 100001 - Internal handling failed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + startDrag(): Promise; + + + /** + * Registers a callback for listening on drag status changes. + * This callback is triggered when the drag status change. + * + * @param { 'statusChange' } type for status changing + * @param { Callback } callback with drag event and status information + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'statusChange', callback: Callback): void; + + + /** + * Deregisters a callback for listening on drag status changes. + * This callback is not triggered when the drag status change. + * + * @param { 'statusChange' } type for status changing + * @param { Callback } callback with drag event and status information + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'statusChange', callback?: Callback): void; + } + + + /** + * DragInfo object description + * + * @interface DragInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface DragInfo { + + + /** + * A unique identifier to identify which touch point. + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pointerId: number; + + + /** + * Drag data. + * @type { ?unifiedDataChannel.UnifiedData } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + data?: unifiedDataChannel.UnifiedData; + + + /** + * Additional information about the drag info. + * @type { ?string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + extraParams?: string; + + + /** + * Touch point coordinates. + * @type { ?TouchPoint } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + touchPoint?: TouchPoint; + + + /** + * Drag preview options. + * @type { ?DragPreviewOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + previewOptions?: DragPreviewOptions; + } + + + /** + * Defines the animation options for drag preview. + * + * @interface AnimationOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface AnimationOptions { + + + /** + * Animation duration, in ms. + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + duration?: number; + + + /** + * Animation curve. + * @type { ?(Curve | ICurve) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + curve?: Curve | ICurve; + } + + + /** + * Provides the functions of setting color or updating animation. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export class DragPreview { + + + /** + * change foreground color of preview + * @param { ResourceColor } color - color value + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setForegroundColor(color: ResourceColor): void; + + + /** + * update preview style with animation + * @param { AnimationOptions } options - animation options + * @param { function } handler - change style functions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + animate(options: AnimationOptions, handler: () => void): void; + } + + /** + * Define the drag event paramters + * + * @interface DragEventParam + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface DragEventParam { + + + /** + * The information containing the drag event. + * @type { DragEvent } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + event: DragEvent; + + + /** + * Additional information about the drag info. + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + extraParams: string; + } + /** + * Define the status for the application to notify the framework whether to execute drag. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + const enum DragStartRequestStatus { + /** + * Notify the framework that the application is not yet ready and needs to temporarily block + * the start of drag, only effective in onDragStart calls. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + WAITING = 0, + /** + * Notify the framework that the drag can continue to be started, but only during the start + * of drag, and will not take effect when the drag is started. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + READY = 1 + } +} +export default dragController; diff --git a/api/@ohos.arkui.drawableDescriptor.d.ts b/api/@ohos.arkui.drawableDescriptor.d.ts index e57f057fc71547d07bb5349a5e903c81e25d4ed9..e3e85be516aa93036422a6b7c2657f53977e8ac1 100644 --- a/api/@ohos.arkui.drawableDescriptor.d.ts +++ b/api/@ohos.arkui.drawableDescriptor.d.ts @@ -20,63 +20,6 @@ import image from './@ohos.multimedia.image'; -/** - * Indicates the return result of the data to be fetched. - * - * @typedef DrawableDescriptorResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ -declare interface DrawableDescriptorResult { - /** - * DrawableDescriptor width.The default value is -1. - * - * @type { ?number } - * @readonly - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - readonly width?: number; - - /** - * DrawableDescriptor height.The default value is -1. - * - * @type { ?number } - * @readonly - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - readonly height?: number; -} - -/** - * DrawableDescriptor's option which is used in constructor. - * - * @typedef DrawableDescriptorOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ -declare interface DrawableDescriptorOptions { - /** - * If true, it will fetch the data using the uri when object is constructing.The default value is false. - * - * @type { ?boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - fetchWhenConstructingWithUri?: boolean; -} - /** * Use the DrawableDescriptor class to get drawable image. * @@ -96,17 +39,15 @@ declare interface DrawableDescriptorOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export declare class DrawableDescriptor { +export class DrawableDescriptor { /** * Creates a new DrawableDescriptor. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ constructor(); @@ -135,66 +76,6 @@ export declare class DrawableDescriptor { * @since 12 */ getPixelMap(): image.PixelMap; - - /** - * Get pixelMap of drawable image. - * - * @returns { image.PixelMap | undefined } Return the PixelMap of the calling DrawableDescriptor object. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - getPixelMap(): image.PixelMap | undefined; - - /** - * Get original width of drawable object. - * - * @returns { number } Return the width of the DrawableDescriptor object. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - getOriginalWidth(): number; - - /** - * Get original height of drawable object. - * - * @returns { number } Return the height of the DrawableDescriptor object. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - getOriginalHeight(): number; - - /** - * Fetch the drawable's data whose corresponding uri is passed in constructor.This fetched data can be draw in Image view. - * - * @returns { Promise } Return the promise returned by the funciton. - * @throws { BusinessError } 100001 - Data loading failed. Maybe the uri is invalid. - * @throws { BusinessError } 100002 - Data decoding failed. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - fetch(): Promise; - - /** - * Fetch the drawable's data whose corresponding uri is passed in constructor.This fetched data can be draw in Image view. - * - * @returns { DrawableDescriptorResult } Return the result of the DrawableDescriptor object. - * @throws { BusinessError } 100001 - Data loading failed. Maybe the uri is invalid. - * @throws { BusinessError } 100002 - Data decoding failed. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - fetchSync(): DrawableDescriptorResult; } /** @@ -219,20 +100,18 @@ export declare class DrawableDescriptor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export declare class LayeredDrawableDescriptor extends DrawableDescriptor { +export class LayeredDrawableDescriptor extends DrawableDescriptor { /** * Creates a new LayeredDrawableDescriptor. - * + * * @param { DrawableDescriptor } [foreground] - Indicates the foreground option to create LayeredDrawableDescriptor. * @param { DrawableDescriptor } [background] - Indicates the background option to create LayeredDrawableDescriptor. * @param { DrawableDescriptor } [mask] - Indicates the mask option to create LayeredDrawableDescriptor. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor( foreground?: DrawableDescriptor, @@ -266,18 +145,6 @@ export declare class LayeredDrawableDescriptor extends DrawableDescriptor { */ getForeground(): DrawableDescriptor; - /** - * Get DrawableDescriptor for the foreground. - * - * @returns { DrawableDescriptor | undefined } Return the DrawableDescriptor object of foreground. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - getForeground(): DrawableDescriptor | undefined; - /** * Get DrawableDescriptor for the background. * @@ -304,18 +171,6 @@ export declare class LayeredDrawableDescriptor extends DrawableDescriptor { */ getBackground(): DrawableDescriptor; - /** - * Get DrawableDescriptor for the background. - * - * @returns { DrawableDescriptor | undefined } Return the DrawableDescriptor object of background. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - getBackground(): DrawableDescriptor | undefined; - /** * Get DrawableDescriptor for the mask. * @@ -342,18 +197,6 @@ export declare class LayeredDrawableDescriptor extends DrawableDescriptor { */ getMask(): DrawableDescriptor; - /** - * Get DrawableDescriptor for the mask. - * - * @returns { DrawableDescriptor | undefined } Return the DrawableDescriptor object of mask. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - getMask(): DrawableDescriptor | undefined; - /** * Get the clip path info of the adaptive icon mask. @@ -377,8 +220,7 @@ export declare class LayeredDrawableDescriptor extends DrawableDescriptor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static getMaskClipPath(): string; } @@ -389,30 +231,17 @@ export declare class LayeredDrawableDescriptor extends DrawableDescriptor { * @extends DrawableDescriptor * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export declare class PixelMapDrawableDescriptor extends DrawableDescriptor { +export class PixelMapDrawableDescriptor extends DrawableDescriptor { /** * Creates a new PixelMapDrawableDescriptor. * @param { image.PixelMap } src - Indicates the resource to create PixelMapDrawableDescriptor. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(src?: image.PixelMap); - - /** - * Creates a new PixelMapDrawableDescriptor. - * @param { image.PixelMap | ResourceStr } src - Indicates the resource to create PixelMapDrawableDescriptor. - * @param { DrawableDescriptorOptions } options - Indicates the option to create PixelMapDrawableDescriptor. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - constructor(src?: image.PixelMap | ResourceStr, options?: DrawableDescriptorOptions); } /** @@ -422,10 +251,9 @@ export declare class PixelMapDrawableDescriptor extends DrawableDescriptor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export declare interface AnimationOptions { +declare interface AnimationOptions { /** * The duration of animation playback once. * @@ -433,8 +261,7 @@ export declare interface AnimationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ duration?: number; /** @@ -444,21 +271,9 @@ export declare interface AnimationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iterations?: number; - - /** - * If true, it will fetch the data using the uri when object is constructing.The default value is false. - * - * @type { ?boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - fetchWhenConstructingWithUri?: boolean; } /** @@ -468,10 +283,9 @@ export declare interface AnimationOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export declare class AnimatedDrawableDescriptor extends DrawableDescriptor { +export class AnimatedDrawableDescriptor extends DrawableDescriptor { /** * Creates a new AnimatedDrawableDescriptor. * @@ -480,53 +294,7 @@ export declare class AnimatedDrawableDescriptor extends DrawableDescriptor { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(pixelMaps: Array, options?: AnimationOptions); - - /** - * Creates a new AnimatedDrawableDescriptor. - * @param { Array | ResourceStr } pixelMaps - Indicates the resource to create AnimatedDrawableDescriptor. - * @param { ?AnimationOptions } [options] - Animation control options. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - constructor(pixelMaps: Array | ResourceStr, options?: AnimationOptions); - - /** - * Get the running status of animation. - * - * @returns { boolean } Return the running status of animation. - * @throws { BusinessError } 100001 - Image data is not ready.Maybe you should fetch the data first. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - isRunning(): boolean; - - /** - * Start the animation. - * - * @throws { BusinessError } 100001 - Image data is not ready.Maybe you should fetch the data first. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - start(): void; - - /** - * Stop the animation. - * - * @throws { BusinessError } 100001 - Image data is not ready.Maybe you should fetch the data first. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 18 - */ - stop(): void; } diff --git a/api/@ohos.arkui.drawableDescriptor.static.d.ets b/api/@ohos.arkui.drawableDescriptor.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..7aa2e8cbe8d78900ad5cdbc785514ce1d5315f58 --- /dev/null +++ b/api/@ohos.arkui.drawableDescriptor.static.d.ets @@ -0,0 +1,172 @@ +'use static'; +/* + * Copyright (c) 2023-2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +import image from './@ohos.multimedia.image'; + +/** + * Use the DrawableDescriptor class to get drawable image. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class DrawableDescriptor { + /** + * Creates a new DrawableDescriptor. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi Hide this for inner system use. + * @since 20 + */ + constructor(); + + /** + * Get pixelMap of drawable image. + * + * @returns { image.PixelMap | undefined } Return the PixelMap of the calling DrawableDescriptor object. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getPixelMap(): image.PixelMap | undefined; +} + +/** + * Use the LayeredDrawableDescriptor class to get the foreground, the background and the mask DrawableDescriptor. + * + * @extends DrawableDescriptor + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class LayeredDrawableDescriptor extends DrawableDescriptor { + /** + * Creates a new LayeredDrawableDescriptor. + * + * @param { DrawableDescriptor } [foreground] - Indicates the foreground option to create LayeredDrawableDescriptor. + * @param { DrawableDescriptor } [background] - Indicates the background option to create LayeredDrawableDescriptor. + * @param { DrawableDescriptor } [mask] - Indicates the mask option to create LayeredDrawableDescriptor. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor( + foreground?: DrawableDescriptor, + background?: DrawableDescriptor, + mask?: DrawableDescriptor + ); + + /** + * Get DrawableDescriptor for the foreground. + * + * @returns { DrawableDescriptor | undefined } Return the DrawableDescriptor object of foreground. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getForeground(): DrawableDescriptor | undefined; + + /** + * Get DrawableDescriptor for the background. + * + * @returns { DrawableDescriptor | undefined } Return the DrawableDescriptor object of background. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getBackground(): DrawableDescriptor | undefined; + + /** + * Get DrawableDescriptor for the mask. + * + * @returns { DrawableDescriptor | undefined } Return the DrawableDescriptor object of mask. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + getMask(): DrawableDescriptor | undefined; + + /** + * Get the clip path info of the adaptive icon mask. + * + * @returns { string } Return the clip path info of mask. + * @static + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + static getMaskClipPath(): string; +} + +/** + * Use the PixelMapDrawableDescriptor class to get the resource of pixelmap or resource descriptor information. + * + * @extends DrawableDescriptor + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class PixelMapDrawableDescriptor extends DrawableDescriptor { + /** + * Creates a new PixelMapDrawableDescriptor. + * @param { image.PixelMap } [src] - Indicates the resource to create PixelMapDrawableDescriptor. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(src?: image.PixelMap); +} + +/** + * Animation control options + * + * @interface AnimationOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface AnimationOptions { + /** + * The duration of animation playback once. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + duration?: number; + /** + * Animation playback times. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iterations?: number; +} + +/** + * Define the data structure for PixelMap animations. + * + * @extends DrawableDescriptor + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class AnimatedDrawableDescriptor extends DrawableDescriptor { + /** + * Creates a new AnimatedDrawableDescriptor. + * + * @param { Array } pixelMaps - PixelMap List. + * @param { AnimationOptions } [options] - Animation control options. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(pixelMaps: Array, options?: AnimationOptions); +} diff --git a/api/@ohos.arkui.inspector.d.ts b/api/@ohos.arkui.inspector.d.ts index 2634340ef8a1c270e2f0626d4c1d20bdec2c1d1d..7588379244d078300cf24b5674986eed8fd50a88 100644 --- a/api/@ohos.arkui.inspector.d.ts +++ b/api/@ohos.arkui.inspector.d.ts @@ -33,8 +33,7 @@ import { Callback } from './@ohos.base'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare namespace inspector { @@ -51,8 +50,7 @@ declare namespace inspector { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface ComponentObserver { @@ -73,8 +71,7 @@ declare namespace inspector { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'layout', callback: () => void): void; @@ -95,8 +92,7 @@ declare namespace inspector { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'layout', callback?: () => void): void; @@ -117,8 +113,7 @@ declare namespace inspector { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'draw', callback: () => void): void; @@ -139,8 +134,7 @@ declare namespace inspector { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'draw', callback?: () => void): void; @@ -184,85 +178,11 @@ declare namespace inspector { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 * @deprecated since 18 * @useinstead ohos.arkui.UIContext.UIInspector#createComponentObserver */ function createComponentObserver(id: string): ComponentObserver; - - /** - * Obtains all attributes of the component with the specified ID. - * - * @param { string } id - ID of the component whose attributes are to be obtained. - * @returns { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @test - * @arkts 1.2 - */ - function getInspectorByKey(id: string): string; - - /** - * Get components tree. - * - * @returns { Object } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @test - * @arkts 1.2 - */ - function getInspectorTree(): Object; - - /** - * Sends an event to the component with the specified ID. - * - * @param { string } id - ID of the component for which the event is to be sent. - * @param { number } action - Type of the event to be sent. The options are as follows: Click event: 10 LongClick: 11. - * @param { string } params - Event parameters. If there is no parameter, pass an empty string "". - * @returns { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @test - * @arkts 1.2 - */ - function sendEventByKey(id: string, action: number, params: string): boolean; } -export default inspector; -/** - * export function getInspectorByKey from inspector namespace and provide it for kit ArkUI. - * @constant - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -export const GETINSPECTORBYKEY = inspector.getInspectorByKey; -/** - * export function getInspectorTree from inspector namespace and provide it for kit ArkUI. - * @constant - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -export const GETINSPECTORTREE = inspector.getInspectorTree; -/** - * export function sendEventByKey from inspector namespace and provide it for kit ArkUI. - * @constant - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -export const SENDEVENTBYKEY = inspector.sendEventByKey; \ No newline at end of file +export default inspector; \ No newline at end of file diff --git a/api/@ohos.arkui.inspector.static.d.ets b/api/@ohos.arkui.inspector.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..550453938deb54f10a5b80c62b95a65babe31a25 --- /dev/null +++ b/api/@ohos.arkui.inspector.static.d.ets @@ -0,0 +1,164 @@ +'use static'; +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Callback, RecordData } from './@ohos.base'; + +/** + * Used to do observer layout and draw event for component. + * + * @namespace inspector + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace inspector { + + /** + * The ComponentObserver is used to listen for layout, draw and drawChildren events. + * + * @interface ComponentObserver + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface ComponentObserver { + + /** + * Registers a callback with the corresponding query condition by using the handle. + * This callback is triggered when the component layout complete. + * @param { 'layout' } type - type of the listened event. + * @param { Callback } callback - callback of the listened event. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onLayout(type: 'layout', callback: Callback): void; + + /** + * Deregisters a callback with the corresponding query condition by using the handle. + * This callback is not triggered when the component layout complete. + * @param { 'layout' } type - type of the listened event. + * @param { Callback } [callback] - callback of the listened event. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + offLayout(type: 'layout', callback?: Callback): void; + + /** + * Registers a callback with the corresponding query condition by using the handle. + * This callback is triggered when the component draw complete. + * @param { 'draw' } type - type of the listened event. + * @param { Callback } callback - callback of the listened event. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onDraw(type: 'draw', callback: Callback): void; + + /** + * Deregisters a callback with the corresponding query condition by using the handle. + * This callback is not triggered when the component draw complete. + * @param { 'draw' } type - type of the listened event. + * @param { Callback } [callback] - callback of the listened event. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + offDraw(type: 'draw', callback?: Callback): void; + + /** + * Registers a callback with the corresponding query condition by using the handle. + * This callback is triggered when the child of component draw complete. + * @param { 'drawChildren' } type - type of the listened event. + * @param { Callback } callback - callback of the listened event. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onDrawChildren(type: 'drawChildren', callback: Callback): void; + + /** + * Deregisters a callback with the corresponding query condition by using the handle. + * This callback is not triggered when the child of component draw complete. + * @param { 'drawChildren' } type - type of the listened event. + * @param { Callback } [callback] - callback of the listened event. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + offDrawChildren(type: 'drawChildren', callback?: Callback): void; + + /** + * @since 20 + */ + overload on { onLayout, onDraw, onDrawChildren } + /** + * @since 20 + */ + overload off { offLayout, offDraw, offDrawChildren } + } + + /** + * Obtains all attributes of the component with the specified ID. + * + * @param { string } id - ID of the component whose attributes are to be obtained. + * @returns { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @test + */ + function getInspectorByKey(id: string): string; + /** + * Get components tree. + * + * @returns { RecordData } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @test + */ + function getInspectorTree(): RecordData; + /** + * Sends an event to the component with the specified ID. + * + * @param { string } id - ID of the component for which the event is to be sent. + * @param { int } action - Type of the event to be sent. The options are as follows: Click event: 10 LongClick: 11. + * @param { string } params - Event parameters. If there is no parameter, pass an empty string "". + * @returns { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + * @test + */ + function sendEventByKey(id: string, action: int, params: string): boolean; +} +export default inspector; +/** + * export function getInspectorByKey from inspector namespace and provide it for kit ArkUI. + * @constant + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const GETINSPECTORBYKEY = inspector.getInspectorByKey; +/** + * export function getInspectorTree from inspector namespace and provide it for kit ArkUI. + * @constant + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const GETINSPECTORTREE = inspector.getInspectorTree; +/** + * export function sendEventByKey from inspector namespace and provide it for kit ArkUI. + * @constant + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export const SENDEVENTBYKEY = inspector.sendEventByKey; diff --git a/api/@ohos.arkui.modifier.static.d.ets b/api/@ohos.arkui.modifier.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..7632fd86fa60f0742abb034983639096ac88e671 --- /dev/null +++ b/api/@ohos.arkui.modifier.static.d.ets @@ -0,0 +1,210 @@ +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +/** + * Export TextModifier, which is used to expose applyNormalAttribute function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { TextModifier } from './arkui/TextModifier'; + +/** + * Export CommonModifier, which is used to expose applyNormalAttribute function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { CommonModifier } from './arkui/CommonModifier'; + +/** + * Export AttributeUpdater, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { AttributeUpdater } from './arkui/AttributeUpdater'; + +/** + * Export GridModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { GridModifier } from './arkui/GridModifier'; + +/** + * Export GridItemModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { GridItemModifier } from './arkui/GridItemModifier'; + +/** + * Export ListItemGroupModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { ListItemGroupModifier } from './arkui/ListItemGroupModifier'; + +/** + * Export ListItemModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { ListItemModifier } from './arkui/ListItemModifier'; + +/** + * Export ListModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { ListModifier } from './arkui/ListModifier'; + +/** + * Export NavDestinationModifier, which is used to expose applyNormalAttribute function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { NavDestinationModifier } from './arkui/NavDestinationModifier'; + +/** + * Export NavigationModifier, which is used to expose applyNormalAttribute function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { NavigationModifier } from './arkui/NavigationModifier'; + +/** + * Export RefreshModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { RefreshModifier } from './arkui/RefreshModifier'; + +/** + * Export RefreshModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { ScrollModifier } from './arkui/ScrollModifier'; + +/** + * Export SideBarContainerModifier, which is used to expose applyNormalAttribute function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { SideBarContainerModifier } from './arkui/SideBarContainerModifier'; + +/** + * Export StepperItemModifier, which is used to expose applyNormalAttribute function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { StepperItemModifier } from './arkui/StepperItemModifier'; + +/** + * Export StepperModifier, which is used to expose applyNormalAttribute function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { StepperModifier } from './arkui/StepperModifier'; + +/** + * Export SwiperModifier, which is used to expose applyNormalAttribute function. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { SwiperModifier } from './arkui/SwiperModifier'; + +/** + * Export RefreshModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { WaterFlowModifier } from './arkui/WaterFlowModifier'; + +/** + * Export ButtonModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { ButtonModifier } from './arkui/ButtonModifier'; + +/** + * Export SymbolGlyphModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; + + +/** + * Export LineModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { LineModifier } from './arkui/LineModifier'; + +/** + * Export PathModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { PathModifier } from './arkui/PathModifier'; + +/** + * Export PolygonModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { PolygonModifier } from './arkui/PolygonModifier'; + +/** + * Export PolylineModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { PolylineModifier } from './arkui/PolylineModifier'; + +/** + * Export RectModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { RectModifier } from './arkui/RectModifier'; + +/** + * Export ShapeModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { ShapeModifier } from './arkui/ShapeModifier'; + +/** + * Export VideoModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { VideoModifier } from './arkui/VideoModifier'; + +/** + * Export ParticleModifier, which is used to update attributes to native side. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { ParticleModifier } from './arkui/ParticleModifier'; \ No newline at end of file diff --git a/api/@ohos.arkui.node.d.ts b/api/@ohos.arkui.node.d.ts index 7c332a641f102e2e475d3576c0d7f08b296ac29f..e384de6c316d4a4b3968457f2d2f9bf72349fe05 100644 --- a/api/@ohos.arkui.node.d.ts +++ b/api/@ohos.arkui.node.d.ts @@ -29,8 +29,7 @@ * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { NodeRenderType, RenderOptions, BuilderNode } from './arkui/BuilderNode'; @@ -39,8 +38,7 @@ export { NodeRenderType, RenderOptions, BuilderNode } from './arkui/BuilderNode' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { BuildOptions } from './arkui/BuilderNode'; @@ -68,8 +66,7 @@ export { InputEventType } from './arkui/BuilderNode'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { NodeController } from './arkui/NodeController'; @@ -96,19 +93,7 @@ export { FrameNode, LayoutConstraint, ExpandMode, UIState } from './arkui/FrameN * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since 20 - * @arkts 1.2 - */ -export { FrameNode, LayoutConstraint, ExpandMode } from './arkui/FrameNode'; - -/** - * Export FrameNode. FrameNode defines a basic type of node which contains a RenderNode. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { typeNode, NodeAdapter } from './arkui/FrameNode'; @@ -125,8 +110,7 @@ export { typeNode, NodeAdapter } from './arkui/FrameNode'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { DrawContext, Size, Offset, Position, Pivot, Scale, Translation, Matrix4, Rotation, Frame, RoundRect, Circle, CommandPath, ShapeMask, ShapeClip, BorderRadiuses, CornerRadius, Rect, Edges, edgeColors, edgeWidths, borderStyles, borderRadiuses, LengthMetricsUnit } from './arkui/Graphics'; @@ -136,8 +120,7 @@ export { DrawContext, Size, Offset, Position, Pivot, Scale, Translation, Matrix4 * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { LengthUnit, SizeT, LengthMetrics, ColorMetrics } from './arkui/Graphics'; @@ -154,8 +137,7 @@ export { LengthUnit, SizeT, LengthMetrics, ColorMetrics } from './arkui/Graphics * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { RenderNode } from './arkui/RenderNode'; @@ -182,8 +164,7 @@ export { XComponentNode } from './arkui/XComponentNode'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { Content } from './arkui/Content'; @@ -193,8 +174,7 @@ export { Content } from './arkui/Content'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { ComponentContent , ComponentContentBase } from './arkui/ComponentContent'; @@ -204,7 +184,6 @@ export { ComponentContent , ComponentContentBase } from './arkui/ComponentConten * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ export { NodeContent } from './arkui/NodeContent'; \ No newline at end of file diff --git a/api/@ohos.arkui.node.static.d.ets b/api/@ohos.arkui.node.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..04bbf706ea40cd8b38b6fea401218eab93e637e0 --- /dev/null +++ b/api/@ohos.arkui.node.static.d.ets @@ -0,0 +1,104 @@ +'use static' + +/* + * Copyright (c) 2023 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +/** + * Export NodeRenderType, RenderOptions, BuilderNode, which is used to create a node trees by builder function + * and manage the update of the tree. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { NodeRenderType, RenderOptions, BuilderNode } from 'arkui.BuilderNode'; + +/** + * Export BuildOptions which is used to create a node trees by builder function and manage the update of the tree. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { BuildOptions } from 'arkui.BuilderNode'; + +/** + * Export NodeController, which defines the controller of node container. + * Provides lifecycle callbacks for the associated NodeContainer + * and methods to control the child node of the NodeContainer. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { NodeController } from 'arkui.NodeController'; +/** + * Export FrameNode. FrameNode defines a basic type of node which contains a RenderNode. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { FrameNode, LayoutConstraint, ExpandMode } from 'arkui.FrameNode'; +/** + * Export FrameNode. FrameNode defines a basic type of node which contains a RenderNode. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { typeNode, NodeAdapter } from 'arkui.FrameNode'; + +/** + * Export Graphics. Defines the basic types related to the Graphics. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { DrawContext, Size, Offset, Position, Pivot, Scale, Translation, Matrix4, Rotation, Frame, RoundRect, Circle, CommandPath, ShapeMask, ShapeClip, NodeBorderRadiuses, CornerRadius, Rect, Edges, edgeColors, edgeWidths, borderStyles, borderRadiuses, LengthMetricsUnit } from 'arkui.Graphics'; +/** + * Export Graphics. Defines the basic types related to the Graphics. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { LengthUnit, SizeT, LengthMetrics, ColorMetrics } from 'arkui.Graphics'; + +/** + * Export RenderNode. RenderNode contains node tree operations and render property operations on node. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { RenderNode } from 'arkui.RenderNode'; +/** + * Export Content. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { Content } from 'arkui.Content'; +/** + * Export ComponentContent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { ComponentContent, ComponentContentBase } from 'arkui.ComponentContent'; +/** + * Export NodeContent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export { NodeContent } from 'arkui.NodeContent'; diff --git a/api/@ohos.arkui.observer.d.ts b/api/@ohos.arkui.observer.d.ts index dcc34ce7762a7935db1f6c721c8b0778ea3d7cde..6ba74fa4c2501f3198e94f8911ef3925be5339c0 100644 --- a/api/@ohos.arkui.observer.d.ts +++ b/api/@ohos.arkui.observer.d.ts @@ -17,19 +17,9 @@ * @file * @kit ArkUI */ -/*** if arkts 1.2 */ -import { NavPathStack, NavigationOperation, NavBar, ResourceStr } from '@ohos.arkui.component'; -import { UIContext } from '@ohos.arkui.UIContext'; -import UIAbilityContext from './application/UIAbilityContext'; -import { Callback } from './@ohos.base'; -/*** endif */ - -/*** if arkts 1.1 */ import type { Callback } from './@ohos.base'; import type UIAbilityContext from './application/UIAbilityContext'; import type { NavigationOperation, NavBar } from '../component/navigation'; -/*** endif */ - /** * Register callbacks to observe ArkUI behavior. * @@ -45,8 +35,7 @@ import type { NavigationOperation, NavBar } from '../component/navigation'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare namespace uiObserver { /** @@ -64,8 +53,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum NavDestinationState { /** @@ -76,13 +64,12 @@ declare namespace uiObserver { * @since 11 */ /** - * When the NavDestination is displayed. + * When the NavDestination displayed. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_SHOWN = 0, @@ -99,8 +86,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_HIDDEN = 1, @@ -110,8 +96,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_APPEAR = 2, @@ -121,8 +106,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_DISAPPEAR = 3, @@ -132,8 +116,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_WILL_SHOW = 4, @@ -143,8 +126,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_WILL_HIDE = 5, @@ -154,8 +136,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_WILL_APPEAR = 6, @@ -165,8 +146,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_WILL_DISAPPEAR = 7, @@ -196,8 +176,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_BACKPRESS = 100 } @@ -217,8 +196,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum RouterPageState { /** @@ -234,8 +212,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ABOUT_TO_APPEAR = 0, @@ -252,8 +229,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ABOUT_TO_DISAPPEAR = 1, @@ -270,8 +246,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_PAGE_SHOW = 2, @@ -288,8 +263,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_PAGE_HIDE = 3, @@ -306,8 +280,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_BACK_PRESS = 4 } @@ -319,8 +292,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum ScrollEventType { /** @@ -329,8 +301,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SCROLL_START = 0, @@ -340,8 +311,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ SCROLL_STOP = 1 } @@ -353,8 +323,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum TabContentState { /** @@ -363,8 +332,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_SHOW = 0, @@ -374,8 +342,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ON_HIDE = 1 } @@ -395,8 +362,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface NavDestinationInfo { /** @@ -414,8 +380,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ navigationId: ResourceStr, @@ -434,8 +399,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ name: ResourceStr, @@ -454,8 +418,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ state: NavDestinationState, @@ -466,8 +429,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ index: number; @@ -478,8 +440,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ param?: Object; @@ -490,8 +451,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ navDestinationId: string; @@ -525,8 +485,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface NavigationInfo { /** @@ -536,8 +495,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ navigationId: string; @@ -548,8 +506,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pathStack: NavPathStack; @@ -572,8 +529,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface ScrollEventInfo { /** @@ -583,8 +539,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id: string, @@ -595,8 +550,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ uniqueId: number, @@ -607,8 +561,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ scrollEvent: ScrollEventType, @@ -619,8 +572,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ offset: number, @@ -643,8 +595,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface TabContentInfo { /** @@ -654,8 +605,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ tabContentId: string, @@ -666,8 +616,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ tabContentUniqueId: number, @@ -678,8 +627,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ state: TabContentState, @@ -690,8 +638,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ index: number, @@ -702,8 +649,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id: string, @@ -714,8 +660,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ uniqueId: number } @@ -727,8 +672,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface ObserverOptions { /** @@ -738,8 +682,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ id: string } @@ -757,8 +700,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export class RouterPageInfo { /** @@ -776,8 +718,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ context: UIAbilityContext | UIContext; @@ -796,8 +737,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ index: number; @@ -816,8 +756,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ name: string; @@ -836,8 +775,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ path: string; @@ -856,8 +794,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ state: RouterPageState; @@ -868,8 +805,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pageId: string; } @@ -880,8 +816,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export class DensityInfo { /** @@ -891,8 +826,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ context: UIContext; @@ -903,8 +837,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ density: number; } @@ -916,8 +849,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface NavDestinationSwitchInfo { /** @@ -927,8 +859,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ context: UIAbilityContext | UIContext; @@ -939,8 +870,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ from: NavDestinationInfo | NavBar; @@ -951,8 +881,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ to: NavDestinationInfo | NavBar; @@ -963,8 +892,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ operation: NavigationOperation; } @@ -976,8 +904,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface NavDestinationSwitchObserverOptions { /** @@ -987,8 +914,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ navigationId: ResourceStr; } @@ -1015,21 +941,6 @@ declare namespace uiObserver { * @since 12 */ export function on(type: 'navDestinationUpdate', options: { navigationId: ResourceStr }, callback: Callback): void; - - /** - * Registers a callback function to be called when the navigation destination is updated. - * - * @param { 'navDestinationUpdate' } type - The type of event to listen for. Must be 'navDestinationUpdate'. - * @param { NavDestinationSwitchObserverOptions } options - The options object. - * @param { Callback } callback - The callback function to be called when the navigation destination is updated. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - export function on(type: 'navDestinationUpdate', options: NavDestinationSwitchObserverOptions, callback: Callback): void; - /** * Removes a callback function that was previously registered with `on()`. * @@ -1054,21 +965,6 @@ declare namespace uiObserver { * @since 12 */ export function off(type: 'navDestinationUpdate', options: { navigationId: ResourceStr }, callback?: Callback): void; - - /** - * Removes a callback function that was previously registered with `on()`. - * - * @param { 'navDestinationUpdate' } type - The type of event to remove the listener for. Must be 'navDestinationUpdate'. - * @param { NavDestinationSwitchObserverOptions } options - The options object. - * @param { Callback } callback - The callback function to remove. If not provided, all callbacks for the given event type and - * navigation ID will be removed. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - export function off(type: 'navDestinationUpdate', options: NavDestinationSwitchObserverOptions, callback?: Callback): void; /** * Registers a callback function to be called when the navigation destination is updated. @@ -1087,8 +983,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'navDestinationUpdate', callback: Callback): void; @@ -1111,8 +1006,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'navDestinationUpdate', callback?: Callback): void; @@ -1125,8 +1019,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'scrollEvent', options: ObserverOptions, callback: Callback): void; @@ -1140,8 +1033,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'scrollEvent', options: ObserverOptions, callback?: Callback): void; @@ -1153,8 +1045,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'scrollEvent', callback: Callback): void; @@ -1167,8 +1058,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'scrollEvent', callback?: Callback): void; @@ -1191,8 +1081,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'routerPageUpdate', context: UIAbilityContext | UIContext, callback: Callback): void; @@ -1217,8 +1106,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'routerPageUpdate', context: UIAbilityContext | UIContext, callback?: Callback): void; @@ -1231,8 +1119,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'densityUpdate', context: UIContext, callback: Callback): void; @@ -1246,8 +1133,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'densityUpdate', context: UIContext, callback?: Callback): void; @@ -1260,8 +1146,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'willDraw', context: UIContext, callback: Callback): void; @@ -1275,8 +1160,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'willDraw', context: UIContext, callback?: Callback): void; @@ -1289,8 +1173,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'didLayout', context: UIContext, callback: Callback): void; @@ -1304,8 +1187,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'didLayout', context: UIContext, callback?: Callback): void; @@ -1318,8 +1200,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'tabContentUpdate', options: ObserverOptions, callback: Callback): void; @@ -1333,8 +1214,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'tabContentUpdate', options: ObserverOptions, callback?: Callback): void; @@ -1346,8 +1226,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on(type: 'tabContentUpdate', callback: Callback): void; @@ -1360,8 +1239,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off(type: 'tabContentUpdate', callback?: Callback): void; @@ -1374,8 +1252,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on( type: 'navDestinationSwitch', @@ -1393,8 +1270,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off( type: 'navDestinationSwitch', @@ -1412,8 +1288,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function on( type: 'navDestinationSwitch', @@ -1433,8 +1308,7 @@ declare namespace uiObserver { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export function off( type: 'navDestinationSwitch', diff --git a/api/@ohos.arkui.observer.static.d.ets b/api/@ohos.arkui.observer.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..234c6bd9b5e89e18e9f6fdcc7e6d32c4a004a48d --- /dev/null +++ b/api/@ohos.arkui.observer.static.d.ets @@ -0,0 +1,896 @@ +'use static'; +/* + * Copyright (c) 2023 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceStr } from './arkui/component/units'; +import { NavPathStack, NavigationOperation, NavBar } from './arkui/component/navigation'; +import { UIContext } from '@ohos.arkui.UIContext'; +import UIAbilityContext from './application/UIAbilityContext'; +import { Callback } from './@ohos.base'; +import { NavDestinationMode } from './arkui/component/navDestination'; + +/** + * Register callbacks to observe ArkUI behavior. + * + * @namespace uiObserver + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace uiObserver { + + /** + * NavDestination state. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export enum NavDestinationState { + + /** + * When the NavDestination is displayed. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_SHOWN = 0, + + /** + * When the NavDestination is hidden. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_HIDDEN = 1, + /** + * When the NavDestination appear. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_APPEAR = 2, + /** + * When the NavDestination disappear. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_DISAPPEAR = 3, + /** + * Before the NavDestination is displayed. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_WILL_SHOW = 4, + /** + * Before the NavDestination is hidden. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_WILL_HIDE = 5, + /** + * Before the NavDestination is appeared. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_WILL_APPEAR = 6, + /** + * Before the NavDestination is disappeared. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_WILL_DISAPPEAR = 7, + /** + * When the NavDestination is active. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_ACTIVE = 8, + /** + * When the NavDestination is inactive. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_INACTIVE = 9, + /** + * When back press event happened in NavDestination. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_BACKPRESS = 100 + } + + /** + * Router page state. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export enum RouterPageState { + + /** + * When the router page create. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ABOUT_TO_APPEAR = 0, + + /** + * When the router page destroy. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ABOUT_TO_DISAPPEAR = 1, + + /** + * When the router page show. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_PAGE_SHOW = 2, + + /** + * When the router page hide. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_PAGE_HIDE = 3, + + /** + * When back press event happened in the router page. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_BACK_PRESS = 4 + } + /** + * ScrollEvent type. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export enum ScrollEventType { + /** + * When the ScrollEvent start. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + SCROLL_START = 0, + /** + * When the ScrollEvent stop. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + SCROLL_STOP = 1 + } + /** + * TabContent state. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export enum TabContentState { + /** + * When the TabContent hidden. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_SHOW = 0, + /** + * When the TabContent hidden. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ON_HIDE = 1 + } + + /** + * NavDestination info. + * + * @interface NavDestinationInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface NavDestinationInfo { + + /** + * Navigation id. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + navigationId: ResourceStr; + + /** + * Changed NavDestination name. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + name: ResourceStr; + + /** + * Changed NavDestination state. + * + * @type { NavDestinationState } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + state: NavDestinationState; + /** + * NavDestination index. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + index: number; + /** + * The detailed parameter of NavDestination. + * + * @type { ?Object } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + param?: Object; + /** + * Auto-generated navDestination id, which is different from common property id of Component. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + navDestinationId: string; + + /** + * NavDestination uniqueId. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + uniqueId?: number; + + /** + * NavDestination mode. + * + * @type { NavDestinationMode } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + mode?: NavDestinationMode; + } + /** + * Navigation info. + * + * @interface NavigationInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface NavigationInfo { + /** + * Navigation id. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + navigationId: string; + /** + * Navigation path stack. + * + * @type { NavPathStack } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pathStack: NavPathStack; + /** + * The uniqueId of the navigation. + * + * @type { ?int } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + uniqueId?: int; + } + /** + * ScrollEvent info. + * + * @interface ScrollEventInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface ScrollEventInfo { + /** + * Scroll id. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + id: string; + /** + * The uniqueId of the scrollable component. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + uniqueId: number; + /** + * Changed ScrollEvent type. + * + * @type { ScrollEventType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + scrollEvent: ScrollEventType; + /** + * Changed ScrollEvent offset. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + offset: number; + } + /** + * TabContent info. + * + * @typedef TabContentInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface TabContentInfo { + /** + * TabContent id. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + tabContentId: string; + /** + * TabContent uniqueId. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + tabContentUniqueId: number; + /** + * The state of TabContent. + * + * @type { TabContentState } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + state: TabContentState; + /** + * The index of TabContent in Tabs. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + index: number; + /** + * Tabs id. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + id: string; + /** + * Tabs uniqueId. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + uniqueId: number; + } + /** + * observer options. + * + * @interface ObserverOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface ObserverOptions { + /** + * component id. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + id: string; + } + + /** + * Router page info. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export class RouterPageInfo { + + /** + * The context of the changed router page. + * + * @type { UIAbilityContext | UIContext } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + context: UIAbilityContext | UIContext; + + /** + * The index of the changed router page in router stack. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + index: number; + + /** + * The name of the changed router page. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + name: string; + + /** + * The path of the changed router page. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + path: string; + + /** + * The state of the changed router page. + * + * @type { RouterPageState } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + state: RouterPageState; + /** + * The unique identifier of the router page. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pageId: string; + } + /** + * Density info. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export class DensityInfo { + /** + * The context of the changed screen density. + * + * @type { UIContext } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + context: UIContext; + /** + * The changed screen density. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + density: number; + } + /** + * NavDestination switch info + * + * @interface NavDestinationSwitchInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface NavDestinationSwitchInfo { + /** + * The context of the navigation operation. + * + * @type { UIAbilityContext | UIContext } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + context: UIAbilityContext | UIContext; + /** + * From navigation content info. + * + * @type { NavDestinationInfo | NavBar } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + from: NavDestinationInfo | NavBar; + /** + * To navigation content info. + * + * @type { NavDestinationInfo | NavBar } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + to: NavDestinationInfo | NavBar; + /** + * The operation type. + * + * @type { NavigationOperation } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + operation: NavigationOperation; + } + /** + * Indicates the options of NavDestination switch. + * + * @interface NavDestinationSwitchObserverOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface NavDestinationSwitchObserverOptions { + /** + * The navigationId that need observation + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + navigationId: ResourceStr; + } + /** + * Registers a callback function to be called when the navigation destination is updated. + * + * @param { 'navDestinationUpdate' } type - The type of event to listen for. Must be 'navDestinationUpdate'. + * @param { NavDestinationSwitchObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to be called when the navigation + * destination is updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on( + type: 'navDestinationUpdate', + options: NavDestinationSwitchObserverOptions, + callback: Callback + ): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'navDestinationUpdate' } type - The type of event to remove the listener for. Must be + * 'navDestinationUpdate'. + * @param { NavDestinationSwitchObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to remove. If not provided, all + * callbacks for the given event type and navigation ID will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off( + type: 'navDestinationUpdate', + options: NavDestinationSwitchObserverOptions, + callback?: Callback + ): void; + + /** + * Registers a callback function to be called when the navigation destination is updated. + * + * @param { 'navDestinationUpdate' } type - The type of event to listen for. Must be 'navDestinationUpdate'. + * @param { Callback } callback - The callback function to be called when the navigation + * destination is updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on(type: 'navDestinationUpdate', callback: Callback): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'navDestinationUpdate'} type - The type of event to remove the listener for. Must be + * 'navDestinationUpdate'. + * @param { Callback } [callback] - The callback function to remove. If not provided, all + * callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off(type: 'navDestinationUpdate', callback?: Callback): void; + /** + * Registers a callback function to be called when the scroll event start or stop. + * + * @param { 'scrollEvent' } type - The type of event to listen for. Must be 'scrollEvent'. + * @param { ObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to be called when the scroll event + * start or stop. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on(type: 'scrollEvent', options: ObserverOptions, callback: Callback): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'scrollEvent' } type - The type of event to remove the listener for. Must be 'scrollEvent'. + * @param { ObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to remove. If not provided, all callbacks + * for the given event type and scroll ID will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off(type: 'scrollEvent', options: ObserverOptions, callback?: Callback): void; + /** + * Registers a callback function to be called when the scroll event start or stop. + * + * @param { 'scrollEvent' } type - The type of event to listen for. Must be 'scrollEvent'. + * @param { Callback } callback - The callback function to be called when the scroll event + * start or stop. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on(type: 'scrollEvent', callback: Callback): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'scrollEvent'} type - The type of event to remove the listener for. Must be 'scrollEvent'. + * @param { Callback } [callback] - The callback function to remove. If not provided, all + * callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off(type: 'scrollEvent', callback?: Callback): void; + + /** + * Registers a callback function to be called when the router page is updated. + * + * @param { 'routerPageUpdate' } type - The type of event to listen for. Must be 'routerPageUpdate'. + * @param { UIAbilityContext | UIContext } context - The context scope of the observer. + * @param { Callback } callback - The callback function to be called when the router page is + * updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on( + type: 'routerPageUpdate', + context: UIAbilityContext | UIContext, + callback: Callback + ): void; + + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'routerPageUpdate' } type - The type of event to remove the listener for. Must be 'routerPageUpdate'. + * @param { UIAbilityContext | UIContext } context - The context scope of the observer. + * @param { Callback } [callback] - The callback function to remove. If not provided, all + * callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off( + type: 'routerPageUpdate', + context: UIAbilityContext | UIContext, + callback?: Callback + ): void; + + /** + * Registers a callback function to be called when the screen density is updated. + * + * @param { 'densityUpdate' } type - The type of event to listen for. Must be 'densityUpdate'. + * @param { UIContext } context - The context scope of the observer. + * @param { Callback } callback - The callback function to be called when the screen density + * is updated. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on(type: 'densityUpdate', context: UIContext, callback: Callback): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'densityUpdate' } type - The type of event to remove the listener for. Must be 'densityUpdate'. + * @param { UIContext } context - The context scope of the observer. + * @param { Callback } [callback] - The callback function to remove. If not provided, all callbacks + * for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off(type: 'densityUpdate', context: UIContext, callback?: Callback): void; + /** + * Registers a callback function to be called when the draw command will be drawn. + * + * @param { 'willDraw' } type - The type of event to listen for. Must be 'willDraw'. + * @param { UIContext } context - The context scope of the observer. + * @param { Callback } callback - The callback function to be called when the draw command will be drawn. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on(type: 'willDraw', context: UIContext, callback: Callback): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'willDraw' } type - The type of event to remove the listener for. Must be 'willDraw'. + * @param { UIContext } context - The context scope of the observer. + * @param { Callback } [callback] - The callback function to remove. If not provided, all callbacks + * for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off(type: 'willDraw', context: UIContext, callback?: Callback): void; + /** + * Registers a callback function to be called when the layout is done. + * + * @param { 'didLayout' } type - The type of event to listen for. Must be 'didLayout'. + * @param { UIContext } context - The context scope of the observer. + * @param { Callback } callback - The callback function to be called when the layout is done. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on(type: 'didLayout', context: UIContext, callback: Callback): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'didLayout' } type - The type of event to remove the listener for. Must be 'didLayout'. + * @param { UIContext } context - The context scope of the observer. + * @param { Callback } [callback] - The callback function to remove. If not provided, all callbacks + * for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off(type: 'didLayout', context: UIContext, callback?: Callback): void; + /** + * Registers a callback function to be called when the tabContent is showed or hidden. + * + * @param { 'tabContentUpdate' } type - The type of event to listen for. Must be 'tabContentUpdate'. + * @param { ObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to be called when when the tabContent + * is showed or hidden. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on(type: 'tabContentUpdate', options: ObserverOptions, callback: Callback): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'tabContentUpdate' } type - The type of event to remove the listener for. Must be 'tabContentUpdate'. + * @param { ObserverOptions } options - The options object. + * @param { Callback } callback - The callback function to remove. If not provided, all callbacks + * for the given event type and Tabs ID will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off(type: 'tabContentUpdate', options: ObserverOptions, callback?: Callback): void; + /** + * Registers a callback function to be called when the tabContent is showed or hidden. + * + * @param { 'tabContentUpdate' } type - The type of event to listen for. Must be 'tabContentUpdate'. + * @param { Callback } callback - The callback function to be called when the tabContent + * is showed or hidden. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on(type: 'tabContentUpdate', callback: Callback): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'tabContentUpdate'} type - The type of event to remove the listener for. Must be 'tabContentUpdate'. + * @param { Callback } [callback] - The callback function to remove. If not provided, all + * callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off(type: 'tabContentUpdate', callback?: Callback): void; + /** + * Registers a callback function to be called when the navigation switched to a new navDestination. + * + * @param { 'navDestinationSwitch' } type - The type of event to listen for. Must be 'navDestinationSwitch'. + * @param { UIAbilityContext | UIContext } context - The context scope of the observer. + * @param { Callback } callback - The callback function to be called when the navigation + * switched to a new navDestination. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on( + type: 'navDestinationSwitch', + context: UIAbilityContext | UIContext, + callback: Callback + ): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'navDestinationSwitch' } type - The type of event to remove the listener for. Must be + * 'navDestinationSwitch'. + * @param { UIAbilityContext | UIContext } context - The context scope of the observer. + * @param { Callback } [callback] - The callback function to remove. + * If not provided, all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off( + type: 'navDestinationSwitch', + context: UIAbilityContext | UIContext, + callback?: Callback + ): void; + /** + * Registers a callback function to be called when the navigation switched to a new navDestination. + * + * @param { 'navDestinationSwitch' } type - The type of event to listen for. Must be 'navDestinationSwitch'. + * @param { UIAbilityContext | UIContext } context - The context scope of the observer. + * @param { NavDestinationSwitchObserverOptions } observerOptions - Options. + * @param { Callback } callback - The callback function to be called when the + * navigation switched to a new navDestination. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function on( + type: 'navDestinationSwitch', + context: UIAbilityContext | UIContext, + observerOptions: NavDestinationSwitchObserverOptions, + callback: Callback + ): void; + /** + * Removes a callback function that was previously registered with `on()`. + * + * @param { 'navDestinationSwitch' } type - The type of event to remove the listener for. Must be + * 'navDestinationSwitch'. + * @param { UIAbilityContext | UIContext } context - The context scope of the observer. + * @param { NavDestinationSwitchObserverOptions } observerOptions - Options. + * @param { Callback } [callback] - The callback function to remove. If not provided, + * all callbacks for the given event type will be removed. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function off( + type: 'navDestinationSwitch', + context: UIAbilityContext | UIContext, + observerOptions: NavDestinationSwitchObserverOptions, + callback?: Callback + ): void; +} +export default uiObserver; diff --git a/api/@ohos.arkui.performanceMonitor.d.ts b/api/@ohos.arkui.performanceMonitor.d.ts index 5f64735337d276e29544a4254f87cb593e156ce7..19be899cf1cf90193dde644e90f55326be7826a2 100644 --- a/api/@ohos.arkui.performanceMonitor.d.ts +++ b/api/@ohos.arkui.performanceMonitor.d.ts @@ -21,7 +21,8 @@ /** * Provides interfaces to monitor a scene for performance measurement. * - *

These interfaces are used to monitor the begin, end, and value changes of finger processes that last for at least 3 ms. + *

These interfaces are used to monitor the begin, end, and value changes of finger processes that last for at least + * 3 ms. * *

Example: * import "@ohos.arkui.performanceMonitor.d.ts" @@ -37,8 +38,7 @@ * @namespace performanceMonitor * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ declare namespace performanceMonitor { /** @@ -47,16 +47,14 @@ declare namespace performanceMonitor { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ export enum ActionType { /** * The user presses the finger on the screen. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ LAST_DOWN = 0, @@ -64,8 +62,7 @@ declare namespace performanceMonitor { * The user lifts up the finger from the screen. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ LAST_UP = 1, @@ -73,8 +70,7 @@ declare namespace performanceMonitor { * The user first moves the finger after pressing down the screen. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ FIRST_MOVE = 2 } @@ -85,16 +81,14 @@ declare namespace performanceMonitor { * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export enum SourceType { /** * The user touches the screen to trigger the scene. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PERF_TOUCH_EVENT = 0, @@ -102,8 +96,7 @@ declare namespace performanceMonitor { * TThe user uses the mouse to trigger the scene. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PERF_MOUSE_EVENT = 1, @@ -111,8 +104,7 @@ declare namespace performanceMonitor { * The user uses the touchpad to trigger the scene. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PERF_TOUCHPAD_EVENT = 2, @@ -120,8 +112,7 @@ declare namespace performanceMonitor { * The user uses the joystick to trigger the scene. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PERF_JOYSTICK_EVENT = 3, @@ -129,8 +120,7 @@ declare namespace performanceMonitor { * The user uses the keyboard to trigger the scene. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ PERF_KEY_EVENT = 4 } @@ -143,10 +133,9 @@ declare namespace performanceMonitor { * @param { string } note Indicates the app expected info delivered. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ - function begin(scene: string, startInputType: ActionType, note?: string): void; + function begin(scene: string, startInputType: ActionType, note?: string): void; /** * End monitoring an application scene. @@ -154,8 +143,7 @@ declare namespace performanceMonitor { * @param { string } scene Indicates the scene name. It must be the same with the {@code scene} of start. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function end(scene: string): void; @@ -165,11 +153,10 @@ declare namespace performanceMonitor { * @param { ActionType } type - Indicates the scene input event type. * @param { SourceType } sourceType - Indicates the scene input source type. * @param { number } time - Indicates the scene input time. - * @throws { BusinessError } 202 - not system application. + * @throws { BusinessError } 202 - not system application. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function recordInputEventTime(type: ActionType, sourceType: SourceType, time: number): void; } diff --git a/api/@ohos.arkui.performanceMonitor.static.d.ets b/api/@ohos.arkui.performanceMonitor.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..c035aa775bd1629f8a8320a5e416a093a3cd0011 --- /dev/null +++ b/api/@ohos.arkui.performanceMonitor.static.d.ets @@ -0,0 +1,154 @@ +'use static'; +/* + * Copyright (C) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +/** + * Provides interfaces to monitor a scene for performance measurement. + * + *

These interfaces are used to monitor the begin, end, and value changes of finger processes that last for at least + * 3 ms. + * + *

Example: + * import "@ohos.arkui.performanceMonitor.d.ts" + * To start scene monitoring that is expected to complete within 5 ms: + *

{@code
+ * performanceMonitor.begin(string, ActionType, string);
+ * //scene finished
+ * performanceMonitor.end(string);
+ * }
+ * + *

Each {@code begin} matches one {@code end}, and they must have the same scene id. + * + * @namespace performanceMonitor + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ +declare namespace performanceMonitor { + /** + * Enumerates the input event type. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + export enum ActionType { + /** + * The user presses the finger on the screen. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + LAST_DOWN = 0, + /** + * The user lifts up the finger from the screen. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + LAST_UP = 1, + /** + * The user first moves the finger after pressing down the screen. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + FIRST_MOVE = 2 + } + /** + * Enumerates the input source type. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + export enum SourceType { + /** + * The user touches the screen to trigger the scene. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + PERF_TOUCH_EVENT = 0, + /** + * TThe user uses the mouse to trigger the scene. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + PERF_MOUSE_EVENT = 1, + /** + * The user uses the touchpad to trigger the scene. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + PERF_TOUCHPAD_EVENT = 2, + /** + * The user uses the joystick to trigger the scene. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + PERF_JOYSTICK_EVENT = 3, + /** + * The user uses the keyboard to trigger the scene. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + PERF_KEY_EVENT = 4 + } + /** + * Begin monitoring an application scene. + * + * @param { string } scene Indicates the scene name. + * @param { ActionType } startInputType Indicates the scene input event type. + * @param { string } note Indicates the app expected info delivered. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + function begin(scene: string, startInputType: ActionType, note?: string): void; + /** + * End monitoring an application scene. + * + * @param { string } scene Indicates the scene name. It must be the same with the {@code scene} of start. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + function end(scene: string): void; + /** + * recordInputEventTime monitoring an application scene. + * + * @param { ActionType } type - Indicates the scene input event type. + * @param { SourceType } sourceType - Indicates the scene input source type. + * @param { number } time - Indicates the scene input time. + * @throws { BusinessError } 202 - not system application. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + */ + function recordInputEventTime(type: ActionType, sourceType: SourceType, time: number): void; +} +export default performanceMonitor; \ No newline at end of file diff --git a/api/@ohos.arkui.shape.d.ts b/api/@ohos.arkui.shape.d.ts index 3274f282b20d6ac3f484d23002c52dd538c260c6..f4688f6e5c8e55933a4ed6dce5fd5772008173d0 100644 --- a/api/@ohos.arkui.shape.d.ts +++ b/api/@ohos.arkui.shape.d.ts @@ -18,9 +18,7 @@ * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Position, ResourceColor, Length, SizeOptions } from './arkui/component/units' -/*** endif */ + /** * Interface for shape size properties. @@ -30,18 +28,16 @@ import { Position, ResourceColor, Length, SizeOptions } from './arkui/component/ * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export interface ShapeSize { +interface ShapeSize { /** * Defines the width of Shape. * @type { ? (number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width?: number | string; @@ -51,8 +47,7 @@ export interface ShapeSize { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height?: number | string; } @@ -66,18 +61,16 @@ export interface ShapeSize { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export interface RectShapeOptions extends ShapeSize { +interface RectShapeOptions extends ShapeSize { /** * Defines the corner radius of the RectShape. * @type { ? (number | string | Array) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radius?: number | string | Array; } @@ -91,18 +84,16 @@ export interface RectShapeOptions extends ShapeSize { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export interface RoundRectShapeOptions extends ShapeSize { +interface RoundRectShapeOptions extends ShapeSize { /** * Defines the width of the corner radius for RectShape. * @type { ? (number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radiusWidth?: number | string; @@ -112,8 +103,7 @@ export interface RoundRectShapeOptions extends ShapeSize { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radiusHeight?: number | string; } @@ -126,18 +116,16 @@ export interface RoundRectShapeOptions extends ShapeSize { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ -export interface PathShapeOptions { +interface PathShapeOptions { /** * Defines the commands for drawing the PathShape. * @type { ?string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ commands?: string; } @@ -149,8 +137,7 @@ export interface PathShapeOptions { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class CommonShapeMethod { /** @@ -162,8 +149,7 @@ declare class CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ offset(offset: Position): T; @@ -176,8 +162,7 @@ declare class CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fill(color: ResourceColor): T; @@ -190,8 +175,7 @@ declare class CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ position(position: Position): T; } @@ -204,8 +188,7 @@ declare class CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare class BaseShape extends CommonShapeMethod { /** @@ -217,8 +200,7 @@ declare class BaseShape extends CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width(width: Length): T; @@ -231,8 +213,7 @@ declare class BaseShape extends CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height(height: Length): T; @@ -245,8 +226,7 @@ declare class BaseShape extends CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ size(size: SizeOptions): T; } @@ -259,8 +239,7 @@ declare class BaseShape extends CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export declare class RectShape extends BaseShape { /** @@ -271,8 +250,7 @@ export declare class RectShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(options?: RectShapeOptions | RoundRectShapeOptions); @@ -285,8 +263,7 @@ export declare class RectShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radiusWidth(rWidth: number | string): RectShape; @@ -299,8 +276,7 @@ export declare class RectShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radiusHeight(rHeight: number | string): RectShape; @@ -313,8 +289,7 @@ export declare class RectShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ radius(radius: number | string | Array): RectShape; } @@ -327,8 +302,7 @@ export declare class RectShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export declare class CircleShape extends BaseShape { /** @@ -339,8 +313,7 @@ export declare class CircleShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(options?: ShapeSize); } @@ -353,8 +326,7 @@ export declare class CircleShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export declare class EllipseShape extends BaseShape { /** @@ -365,8 +337,7 @@ export declare class EllipseShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(options?: ShapeSize); } @@ -379,8 +350,7 @@ export declare class EllipseShape extends BaseShape { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export declare class PathShape extends CommonShapeMethod { /** @@ -391,8 +361,7 @@ export declare class PathShape extends CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ constructor(options?: PathShapeOptions); @@ -405,8 +374,7 @@ export declare class PathShape extends CommonShapeMethod { * @crossplatform * @form * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ commands(commands: string): PathShape; } \ No newline at end of file diff --git a/api/@ohos.arkui.shape.static.d.ets b/api/@ohos.arkui.shape.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..c84cfe09e2ae98ef477db1f4e3ba3c029e265dfc --- /dev/null +++ b/api/@ohos.arkui.shape.static.d.ets @@ -0,0 +1,278 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +import { Position, ResourceColor, Length, SizeOptions } from './arkui/component/units'; +/** + * Interface for shape size properties. + * + * @interface ShapeSize + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface ShapeSize { + /** + * Defines the width of Shape. + * @type { ? (number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + width?: number | string; + /** + * Defines the height of Shape. + * @type { ? (number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + height?: number | string; +} +/** + * Interface for RectShape constructor parameters. + * + * @extends ShapeSize + * @interface RectShapeOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface RectShapeOptions extends ShapeSize { + /** + * Defines the corner radius of the RectShape. + * @type { ? (number | string | Array) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + radius?: number | string | Array; +} +/** + * Interface for RectShape constructor parameters with separate radius values. + * + * @extends ShapeSize + * @interface RoundRectShapeOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface RoundRectShapeOptions extends ShapeSize { + /** + * Defines the width of the corner radius for RectShape. + * @type { ? (number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + radiusWidth?: number | string; + /** + * Defines the height of the corner radius for RectShape. + * @type { ? (number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + radiusHeight?: number | string; +} +/** + * Interface for PathShape constructor parameters. + * + * @interface PathShapeOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface PathShapeOptions { + /** + * Defines the commands for drawing the PathShape. + * @type { ?string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + commands?: string; +} +/** + * Common shape method class + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare class CommonShapeMethod { + /** + * Sets coordinate offset relative to the layout completion position. + * + * @param { Position } offset + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + offset(offset: Position): T; + /** + * Sets the fill color of the shape. + * + * @param { ResourceColor } color + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fill(color: ResourceColor): T; + /** + * Sets the position of the shape. + * + * @param { Position } position + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + position(position: Position): T; +} +/** + * Base shape class + * + * @extends CommonShapeMethod + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare class BaseShape extends CommonShapeMethod { + /** + * Sets the width of the shape. + * + * @param { Length } width + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + width(width: Length): T; + /** + * Sets the height of the shape. + * + * @param { Length } height + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + height(height: Length): T; + /** + * Sets the size of the shape. + * + * @param { SizeOptions } size + * @returns { T } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + size(size: SizeOptions): T; +} +/** + * Defines a rect drawing class. + * + * @extends BaseShape + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class RectShape extends BaseShape { + /** + * Constructor. + * + * @param { RectShapeOptions | RoundRectShapeOptions } options + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options?: RectShapeOptions | RoundRectShapeOptions); + /** + * Sets the width of the corner radius for RectShape. + * + * @param { number | string } rWidth + * @returns { RectShape } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + radiusWidth(rWidth: number | string): RectShape; + /** + * Sets the height of the corner radius for RectShape. + * + * @param { number | string } rHeight + * @returns { RectShape } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + radiusHeight(rHeight: number | string): RectShape; + /** + * Sets the corner radius for RectShape. + * + * @param { number | string | Array } radius + * @returns { RectShape } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + radius(radius: number | string | Array): RectShape; +} +/** + * Defines a circle drawing class. + * + * @extends BaseShape + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class CircleShape extends BaseShape { + /** + * Constructor. + * + * @param { ShapeSize } options + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options?: ShapeSize); +} +/** + * Defines an ellipse drawing class. + * + * @extends BaseShape + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class EllipseShape extends BaseShape { + /** + * Constructor. + * + * @param { ShapeSize } options + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options?: ShapeSize); +} +/** + * Defines a path drawing class. + * + * @extends CommonShapeMethod + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class PathShape extends CommonShapeMethod { + /** + * Constructor. + * + * @param { PathShapeOptions } options + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + constructor(options?: PathShapeOptions); + /** + * Sets the commands for drawing the PathShape. + * + * @param { string } commands + * @returns { PathShape } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + commands(commands: string): PathShape; +} diff --git a/api/@ohos.arkui.stateManagement.d.ets b/api/@ohos.arkui.stateManagement.static.d.ets similarity index 96% rename from api/@ohos.arkui.stateManagement.d.ets rename to api/@ohos.arkui.stateManagement.static.d.ets index 94b7c1ab1e9de08e097b1db1fb7fc0b1a10df3c5..4f8e84173bb4dfc78d7b79441a86a0b14a756fd6 100644 --- a/api/@ohos.arkui.stateManagement.d.ets +++ b/api/@ohos.arkui.stateManagement.static.d.ets @@ -1,3 +1,4 @@ +'use static' /* * Copyright (C) 2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/api/@ohos.arkui.theme.d.ts b/api/@ohos.arkui.theme.d.ts index 50f2062772205f75c8b4595c24474139a5a9aeee..b2c873def59fe764e929e573cb054cca023ffdde 100644 --- a/api/@ohos.arkui.theme.d.ts +++ b/api/@ohos.arkui.theme.d.ts @@ -18,11 +18,6 @@ * @file * @kit ArkUI */ - -/*** if arkts 1.2 */ -import { ResourceColor } from './arkui/component/units'; -/*** endif */ - /** * Defines the struct of Theme. * @@ -30,8 +25,7 @@ import { ResourceColor } from './arkui/component/units'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export declare interface Theme { /** @@ -41,8 +35,7 @@ export declare interface Theme { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ colors: Colors; } @@ -54,8 +47,7 @@ export declare interface Theme { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export declare interface Colors { @@ -66,8 +58,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ brand: ResourceColor; @@ -78,8 +69,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ warning: ResourceColor; @@ -90,8 +80,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ alert: ResourceColor; @@ -102,8 +91,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ confirm: ResourceColor; @@ -114,8 +102,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontPrimary: ResourceColor; @@ -126,8 +113,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontSecondary: ResourceColor; @@ -138,8 +124,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontTertiary: ResourceColor; @@ -150,8 +135,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontFourth: ResourceColor; @@ -162,8 +146,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontEmphasize: ResourceColor; @@ -174,8 +157,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontOnPrimary: ResourceColor; @@ -186,8 +168,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontOnSecondary: ResourceColor; @@ -198,8 +179,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontOnTertiary: ResourceColor; @@ -210,8 +190,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontOnFourth: ResourceColor; @@ -222,8 +201,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconPrimary: ResourceColor; @@ -234,8 +212,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconSecondary: ResourceColor; @@ -246,8 +223,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconTertiary: ResourceColor; @@ -258,8 +234,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconFourth: ResourceColor; @@ -270,8 +245,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconEmphasize: ResourceColor; @@ -282,8 +256,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconSubEmphasize: ResourceColor; @@ -294,8 +267,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconOnPrimary: ResourceColor; @@ -306,8 +278,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconOnSecondary: ResourceColor; @@ -318,8 +289,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconOnTertiary: ResourceColor; @@ -330,8 +300,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ iconOnFourth: ResourceColor; @@ -342,8 +311,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundPrimary: ResourceColor; @@ -354,8 +322,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundSecondary: ResourceColor; @@ -366,8 +333,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundTertiary: ResourceColor; @@ -378,8 +344,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundFourth: ResourceColor; @@ -390,8 +355,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ backgroundEmphasize: ResourceColor; @@ -402,8 +366,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compForegroundPrimary: ResourceColor; @@ -414,8 +377,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundPrimary: ResourceColor; @@ -426,8 +388,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundPrimaryTran: ResourceColor; @@ -438,8 +399,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundPrimaryContrary: ResourceColor; @@ -450,8 +410,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundGray: ResourceColor; @@ -462,8 +421,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundSecondary: ResourceColor; @@ -474,8 +432,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundTertiary: ResourceColor; @@ -486,8 +443,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundEmphasize: ResourceColor; @@ -498,8 +454,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundNeutral: ResourceColor; @@ -510,8 +465,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compEmphasizeSecondary: ResourceColor; @@ -522,8 +476,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compEmphasizeTertiary: ResourceColor; @@ -534,8 +487,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compDivider: ResourceColor; @@ -546,8 +498,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compCommonContrary: ResourceColor; @@ -558,8 +509,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compBackgroundFocus: ResourceColor; @@ -570,8 +520,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compFocusedPrimary: ResourceColor; @@ -582,8 +531,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compFocusedSecondary: ResourceColor; @@ -594,8 +542,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ compFocusedTertiary: ResourceColor; @@ -606,68 +553,62 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interactiveHover: ResourceColor; /** - * Pressed interactive color + * Pressed interactive color * * @type { ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interactivePressed: ResourceColor; /** - * Focus interactive color + * Focus interactive color * * @type { ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interactiveFocus: ResourceColor; /** - * Active interactive color + * Active interactive color * * @type { ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interactiveActive: ResourceColor; /** - * Select interactive color + * Select interactive color * * @type { ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interactiveSelect: ResourceColor; /** - * Click interactive color + * Click interactive color * * @type { ResourceColor } * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interactiveClick: ResourceColor; } @@ -679,8 +620,7 @@ export declare interface Colors { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export declare interface CustomTheme { /** @@ -690,8 +630,7 @@ export declare interface CustomTheme { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ colors?: CustomColors; } @@ -706,27 +645,13 @@ export declare interface CustomTheme { * @since 12 */ export declare type CustomColors = Partial; - -/** - * Defines the struct of CustomColors. - * - * @typedef { Partial } CustomColors - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ -export type CustomColors = Partial; - /** * Class ThemeControl provides the Theme management for whole Ability and pages. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export declare class ThemeControl { /** @@ -738,8 +663,7 @@ export declare class ThemeControl { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ static setDefaultTheme(theme: CustomTheme): void; } diff --git a/api/@ohos.arkui.theme.static.d.ets b/api/@ohos.arkui.theme.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..01238b37d2b98d943dc3632c142906e641fc9deb --- /dev/null +++ b/api/@ohos.arkui.theme.static.d.ets @@ -0,0 +1,499 @@ +'use static'; +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { ResourceColor } from './arkui/component/units'; +/** + * Defines the struct of Theme. + * + * @interface Theme + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare interface Theme { + /** + * Define tokens associated with color resources. + * + * @type { Colors } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + colors: Colors; +} +/** + * Defines the struct of Colors. + * + * @interface Colors + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare interface Colors { + /** + * System brand Color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + brand: ResourceColor; + /** + * System warning Color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + warning: ResourceColor; + /** + * System alert Color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + alert: ResourceColor; + /** + * System confirm Color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + confirm: ResourceColor; + /** + * First level text color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontPrimary: ResourceColor; + /** + * Secondary text color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontSecondary: ResourceColor; + /** + * tertiary text color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontTertiary: ResourceColor; + /** + * Fourth text color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontFourth: ResourceColor; + /** + * Emphasize text color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontEmphasize: ResourceColor; + /** + * First level text inversion, used on colored backgrounds. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontOnPrimary: ResourceColor; + /** + * Secondary level text inversion, used on colored backgrounds. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontOnSecondary: ResourceColor; + /** + * Tertiary level text inversion, used on colored backgrounds. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontOnTertiary: ResourceColor; + /** + * Fourth level text inversion, used on colored backgrounds. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontOnFourth: ResourceColor; + /** + * First level icon color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconPrimary: ResourceColor; + /** + * Secondary level icon color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconSecondary: ResourceColor; + /** + * Tertiary level icon color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconTertiary: ResourceColor; + /** + * Fourth level icon color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconFourth: ResourceColor; + /** + * Emphasize level icon color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconEmphasize: ResourceColor; + /** + * Secondary emphasize level icon color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconSubEmphasize: ResourceColor; + /** + * First level icon reversed, used on a colored background. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconOnPrimary: ResourceColor; + /** + * Secondary level icon reversed, used on a colored background. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconOnSecondary: ResourceColor; + /** + * Tertiary level icon reversed, used on a colored background. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconOnTertiary: ResourceColor; + /** + * Fourth level icon reversed, used on a colored background. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconOnFourth: ResourceColor; + /** + * System Primary level background color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundPrimary: ResourceColor; + /** + * System Secondary level background color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundSecondary: ResourceColor; + /** + * System tertiary level background color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundTertiary: ResourceColor; + /** + * System fourth level background color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundFourth: ResourceColor; + /** + * System emphasize level background color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + backgroundEmphasize: ResourceColor; + /** + * CompForegroundPrimary color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compForegroundPrimary: ResourceColor; + /** + * CompBackgroundPrimary color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundPrimary: ResourceColor; + /** + * CompBackgroundPrimaryTran color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundPrimaryTran: ResourceColor; + /** + * CompBackgroundPrimaryContrary color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundPrimaryContrary: ResourceColor; + /** + * CompBackgroundGray color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundGray: ResourceColor; + /** + * 10% black universal control background. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundSecondary: ResourceColor; + /** + * 5% black universal control background. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundTertiary: ResourceColor; + /** + * 100% bright brand background color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundEmphasize: ResourceColor; + /** + * Black neutral high gloss color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundNeutral: ResourceColor; + /** + * 20% High gloss brand background color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compEmphasizeSecondary: ResourceColor; + /** + * 10% High gloss brand background color. + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compEmphasizeTertiary: ResourceColor; + /** + * Universal Division Line Color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compDivider: ResourceColor; + /** + * CompCommonContrary Color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compCommonContrary: ResourceColor; + /** + * CompBackgroundFocus Color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compBackgroundFocus: ResourceColor; + /** + * CompFocusedPrimary Color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compFocusedPrimary: ResourceColor; + /** + * CompFocusedSecondary Color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compFocusedSecondary: ResourceColor; + /** + * CompFocusedTertiary Color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + compFocusedTertiary: ResourceColor; + /** + * Hover interactive color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interactiveHover: ResourceColor; + /** + * Pressed interactive color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interactivePressed: ResourceColor; + /** + * Focus interactive color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interactiveFocus: ResourceColor; + /** + * Active interactive color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interactiveActive: ResourceColor; + /** + * Select interactive color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interactiveSelect: ResourceColor; + /** + * Click interactive color + * + * @type { ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interactiveClick: ResourceColor; +} +/** + * Defines the struct of CustomTheme. + * + * @interface CustomTheme + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare interface CustomTheme { + /** + * Define tokens associated with color resources.. + * + * @type { ?CustomColors } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + colors?: CustomColors; +} +/** + * Defines the struct of CustomColors. + * + * @typedef { Partial } CustomColors + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export type CustomColors = Partial; +/** + * Class ThemeControl provides the Theme management for whole Ability and pages. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class ThemeControl { + /** + * Sets the default Theme: + * - for whole Ability when invoked from the Ability level code. + * - for the ArkUI page and for later opened pages when invoked at the ArkUI page level. + * + * @param { CustomTheme } theme + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + static setDefaultTheme(theme: CustomTheme): void; +} diff --git a/api/@ohos.arkui.uiExtension.d.ts b/api/@ohos.arkui.uiExtension.d.ts index d9e31f89a458426fa3c4ae1715d4f492024f9d96..5046c23213c21f78914950b9545e8a606886941d 100644 --- a/api/@ohos.arkui.uiExtension.d.ts +++ b/api/@ohos.arkui.uiExtension.d.ts @@ -18,8 +18,6 @@ * @kit ArkUI */ - - import { Callback } from './@ohos.base'; import window from './@ohos.window'; /** @@ -28,8 +26,7 @@ import window from './@ohos.window'; * @namespace uiExtension * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare namespace uiExtension { /** @@ -38,10 +35,9 @@ declare namespace uiExtension { * @interface WindowProxy * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface WindowProxy { + interface WindowProxy { /** * Obtains the area where this window cannot be displayed, for example, the system bar area, notch, gesture area, and soft keyboard area. * @@ -53,15 +49,15 @@ declare namespace uiExtension { *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getWindowAvoidArea(type: window.AvoidAreaType): window.AvoidArea; /** * Subscribes to the event indicating changes to the area where the window cannot be displayed. * - * @param { 'avoidAreaChange' } type - Event type. The value is fixed at 'avoidAreaChange', indicating the event of changes to the area where the window cannot be displayed. + * @param { 'avoidAreaChange' } type - Event type. The value is fixed at 'avoidAreaChange', + * indicating the event of changes to the area where the window cannot be displayed. * @param { Callback } callback - Callback used to return the avoid area information. * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. @@ -69,15 +65,15 @@ declare namespace uiExtension { *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'avoidAreaChange', callback: Callback): void; /** * Unsubscribes from the event indicating changes to the area where the window cannot be displayed. * - * @param { 'avoidAreaChange' } type - Event type. The value is fixed at 'avoidAreaChange', indicating the event of changes to the area where the window cannot be displayed. + * @param { 'avoidAreaChange' } type - Event type. The value is fixed at 'avoidAreaChange', + * indicating the event of changes to the area where the window cannot be displayed. * @param { Callback } callback - Callback used to return the avoid area information. * @throws { BusinessError } 401 - Parameter error. Possible causes: *
1. Mandatory parameters are left unspecified. @@ -85,8 +81,7 @@ declare namespace uiExtension { *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'avoidAreaChange', callback?: Callback): void; @@ -101,8 +96,7 @@ declare namespace uiExtension { *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'windowSizeChange', callback: Callback): void; @@ -117,15 +111,15 @@ declare namespace uiExtension { *
3. Parameter verification failed. * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'windowSizeChange', callback?: Callback): void; /** * Subscribes to changes in the position and size of the component (EmbeddedComponent or UIExtensionComponent). This API can be used only on 2-in-1 devices. * - * @param { 'rectChange' } type - Event type. The value is fixed at 'rectChange', indicating the rectangle change event for the component (EmbeddedComponent or UIExtensionComponent). + * @param { 'rectChange' } type - Event type. The value is fixed at 'rectChange', + * indicating the rectangle change event for the component (EmbeddedComponent or UIExtensionComponent). * @param { 'number' } reasons - The reasons of component rect change. * @param { Callback } callback - Callback used to return the RectChangeOptions. * @throws { BusinessError } 401 - Parameter error. Possible cause: @@ -140,9 +134,11 @@ declare namespace uiExtension { on(type: 'rectChange', reasons: number, callback: Callback): void; /** - * Unsubscribes from changes in the position and size of the component (EmbeddedComponent or UIExtensionComponent). This API can be used only on 2-in-1 devices. + * Unsubscribes from changes in the position and size of the component (EmbeddedComponent or UIExtensionComponent). + * This API can be used only on 2-in-1 devices. * - * @param { 'rectChange' } type - Event type. The value is fixed at 'rectChange', indicating the rectangle change event for the component (EmbeddedComponent or UIExtensionComponent). + * @param { 'rectChange' } type - Event type. The value is fixed at 'rectChange', + * indicating the rectangle change event for the component (EmbeddedComponent or UIExtensionComponent). * @param { Callback } callback - Callback used to return the RectChangeOptions. * @throws { BusinessError } 401 - Parameter error. Possible cause: *
1. Mandatory parameters are left unspecified. @@ -173,8 +169,7 @@ declare namespace uiExtension { * @throws { BusinessError } 1300003 - This window manager service works abnormally. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ hideNonSecureWindows(shouldHide: boolean): Promise; @@ -194,42 +189,42 @@ declare namespace uiExtension { * @syscap SystemCapability.ArkUI.ArkUI.Full * @StageModelOnly * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ createSubWindowWithOptions(name: string, subWindowOptions: window.SubWindowOptions): Promise; /** * Adds or deletes the watermark flag for this window. This API uses a promise to return the result. * - * @param { boolean } enable - Whether to add or delete the flag. The value true means to add the watermark flag, and false means to delete the watermark flag. + * @param { boolean } enable - Whether to add or delete the flag. The value true means to add the watermark flag, + * and false means to delete the watermark flag. * @returns { Promise } - The promise returned by the function * @throws { BusinessError } 1300002 - The UIExtension window proxy is abnormal. * @throws { BusinessError } 1300003 - This window manager service works abnormally. * @throws { BusinessError } 1300008 - The display device is abnormal. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - setWaterMarkFlag(enable: boolean): Promise; + setWaterMarkFlag(enable: boolean): Promise; - /** - * Sets the events that the component (EmbeddedComponent or UIExtensionComponent) will occupy, preventing the host from responding to these events within the component's area. - * - * @param { EventFlag } eventFlags - Type of events to occupy. For details about the available values, see {@link uiExtension.EventFlag }. - * @returns { Promise } - The promise returned by the function - * @throws { BusinessError } 401 - Parameter error. Possible cause: - *
1. Mandatory parameters are left unspecified. - *
2. Incorrect parameters types. - *
3. Parameter verification failed. - * @throws { BusinessError } 1300002 - This window state is abnormal. - * @throws { BusinessError } 1300003 - This window manager service works abnormally. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 18 - */ - occupyEvents(eventFlags: number): Promise; + /** + * Sets the events that the component (EmbeddedComponent or UIExtensionComponent) will occupy, + * preventing the host from responding to these events within the component's area. + * + * @param { EventFlag } eventFlags - Type of events to occupy. For details about the available values, see {@link uiExtension.EventFlag }. + * @returns { Promise } - The promise returned by the function + * @throws { BusinessError } 401 - Parameter error. Possible cause: + *
1. Mandatory parameters are left unspecified. + *
2. Incorrect parameters types. + *
3. Parameter verification failed. + * @throws { BusinessError } 1300002 - This window state is abnormal. + * @throws { BusinessError } 1300003 - This window manager service works abnormally. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 18 + */ + occupyEvents(eventFlags: number): Promise; /** * The properties of the UIExtension window @@ -315,18 +310,16 @@ declare namespace uiExtension { * @interface AvoidAreaInfo * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - export interface AvoidAreaInfo { + interface AvoidAreaInfo { /** * Type of the area where the window cannot be displayed. * * @type { window.AvoidAreaType } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ type: window.AvoidAreaType; @@ -336,8 +329,7 @@ declare namespace uiExtension { * @type { window.AvoidArea } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ area: window.AvoidArea; } @@ -348,19 +340,17 @@ declare namespace uiExtension { * @interface WindowProxyProperties * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 * */ - export interface WindowProxyProperties { + interface WindowProxyProperties { /** * Position and size of the component (EmbeddedComponent or UIExtensionComponent). * * @type { window.Rect } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ uiExtensionHostWindowProxyRect: window.Rect; } diff --git a/api/@ohos.base.d.ets b/api/@ohos.base.d.ets deleted file mode 100644 index 2db65e803e6790af078ce6cdbe04f7afc54daf1e..0000000000000000000000000000000000000000 --- a/api/@ohos.base.d.ets +++ /dev/null @@ -1,177 +0,0 @@ -/* - * Copyright (c) 2021-2023 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit BasicServicesKit - */ - -/** - * Defines the basic callback. - * - * @typedef { Callback } - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ -export type Callback = (data: T) => void; - -/** - * Defines the basic error callback. - * - * @typedef { ErrorCallback } - * @syscap SystemCapability.Base - * @crossplatform - * @atomicservice - * @since 20 - */ -export type ErrorCallback = (err: T)=> void; - -/** - * Defines the basic async callback. - * - * @typedef { AsyncCallback } - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ -export type AsyncCallback = (err: BusinessError | null, data: T | undefined)=> void; - -/** - * Defines the error interface. - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ -export declare class BusinessError extends Error { - /** - * A constructor used to create a BusinessError object - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - constructor(); - /** - * A constructor used to create a BusinessError object - * @params { int } code - * @params { Error } error - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - constructor(code: int, error: Error); - /** - * A constructor used to create a BusinessError object - * @params { int } code - * @params { T } data - * @params { Error } error - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - constructor(code: int, data: T, error: Error); - /** - * Defines the basic error code. - * @type { number } code - * @syscap SystemCapability.Base - * @since 6 - */ - /** - * Defines the basic error code. - * @type { number } code - * @syscap SystemCapability.Base - * @crossplatform - * @since 10 - */ - /** - * Defines the basic error code. - * @type { number } code - * @syscap SystemCapability.Base - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Defines the basic error code. - * @type { number } code - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - /** - * Defines the basic error code. - * @type { int } code - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - code: int; - /** - * Defines the additional information for business - * @type { ?T } data - * @syscap SystemCapability.Base - * @since 9 - */ - /** - * Defines the additional information for business - * @type { ?T } data - * @syscap SystemCapability.Base - * @crossplatform - * @since 10 - */ - /** - * Defines the additional information for business - * @type { ?T } data - * @syscap SystemCapability.Base - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Defines the additional information for business - * @type { ?T } data - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - /** - * Defines the additional information for business - * @type { ?T } data - * @syscap SystemCapability.Base - * @crossplatform - * @form - * @atomicservice - * @since 20 - */ - data?: T; -} diff --git a/api/@ohos.base.d.ts b/api/@ohos.base.d.ts index b9930a4b6fd6d393f4a13ed87f19241bed4f52da..12b9052cb6b144cee8c112b3ba7b76e4c7de60f8 100644 --- a/api/@ohos.base.d.ts +++ b/api/@ohos.base.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021-2023 Huawei Device Co., Ltd. + * Copyright (c) 2021-2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -84,7 +84,7 @@ export interface Callback { /** * Defines the basic error callback. - * @typedef ErrorCallback + * @typedef ErrorCallback * @syscap SystemCapability.Base * @since 6 */ diff --git a/api/@ohos.base.static.d.ets b/api/@ohos.base.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..3e22da2fda6e645109aa920ac1250d6f7f65be4b --- /dev/null +++ b/api/@ohos.base.static.d.ets @@ -0,0 +1,115 @@ +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit BasicServicesKit + */ + +/** + * Defines the basic callback. + * + * @typedef { Callback } + * @syscap SystemCapability.Base + * @since 20 + */ + export type Callback = (data: T) => void; + + /** + * Defines the basic error callback. + * + * @typedef { ErrorCallback } + * @syscap SystemCapability.Base + * @since 20 + */ + export type ErrorCallback = (err: T)=> void; + + /** + * Defines the basic async callback. + * + * @typedef { AsyncCallback } + * @syscap SystemCapability.Base + * @since 20 + */ + export type AsyncCallback = (err: BusinessError | null, data: T | undefined)=> void; + + /** + * Defines the error interface. + * @syscap SystemCapability.Base + * @since 20 + */ + export declare class BusinessError extends Error { + /** + * A constructor used to create a BusinessError object + * @syscap SystemCapability.Base + * @since 20 + */ + constructor(); + /** + * A constructor used to create a BusinessError object + * @param { int } code + * @param { Error } error + * @syscap SystemCapability.Base + * @since 20 + */ + constructor(code: int, error: Error); + /** + * A constructor used to create a BusinessError object + * @param { int } code + * @param { T } data + * @param { Error } error + * @syscap SystemCapability.Base + * @since 20 + */ + constructor(code: int, data: T, error: Error); + + /** + * Defines the basic error code. + * @type { int } code + * @syscap SystemCapability.Base + * @since 20 + */ + code: int; + /** + * Defines the additional information for business + * @type { ?T } data + * @syscap SystemCapability.Base + * @since 20 + */ + data?: T; + } + + /** + * In ArkTS static typing, for literals where the hierarchy and the number + * of attributes per level are uncertain, you can use RecordData for initialization. + * @typedef RecordData + * @syscap SystemCapability.Base + * @since 20 + * @example + * import { RecordData } from '@kit.BasicServiceKit'; + * const param: RecordData = { + * "key": { + * "a": 1 + * } + * } + * let want: Want = { + * bundleName: 'com.example.myapplication', + * abilityName: 'EntryAbility', + * parameters: param + * }; + * this.context.startAbility(want); + */ + export type RecordData = undefined | null | Object | Record | Array; + \ No newline at end of file diff --git a/api/@ohos.bluetooth.access.d.ts b/api/@ohos.bluetooth.access.d.ts index 13915e2e9ee373f5b6aeae58158d26bfcdfa8890..7aeb4edc2d8696bc8b88fe06c1eff538a1993688 100644 --- a/api/@ohos.bluetooth.access.d.ts +++ b/api/@ohos.bluetooth.access.d.ts @@ -288,7 +288,8 @@ declare namespace access { * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'stateChange', callback: Callback): void; @@ -349,7 +350,8 @@ declare namespace access { * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'stateChange', callback?: Callback): void; @@ -442,7 +444,7 @@ declare namespace access { /** * The enum of bluetooth state. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice diff --git a/api/@ohos.bluetooth.baseProfile.d.ts b/api/@ohos.bluetooth.baseProfile.d.ts index 27764959f4c3e811cd60966ad2423b5b1c92ccbe..680e085e71e25f6bb956ea41b6ec0782d5cec655 100644 --- a/api/@ohos.bluetooth.baseProfile.d.ts +++ b/api/@ohos.bluetooth.baseProfile.d.ts @@ -425,7 +425,8 @@ declare namespace baseProfile { * @throws { BusinessError } 801 - Capability not supported. * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} + * @arkts 1.1&1.2 */ on(type: 'connectionStateChange', callback: Callback): void; @@ -454,7 +455,8 @@ declare namespace baseProfile { * @throws { BusinessError } 801 - Capability not supported. * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} + * @arkts 1.1&1.2 */ off(type: 'connectionStateChange', callback?: Callback): void; } diff --git a/api/@ohos.bluetooth.ble.d.ts b/api/@ohos.bluetooth.ble.d.ts index c2feb8c7779cfceaf1f6529b96f78e9b3128ae73..2271a38e95bdde4242a3bc6f7dc6724a603a1e22 100644 --- a/api/@ohos.bluetooth.ble.d.ts +++ b/api/@ohos.bluetooth.ble.d.ts @@ -2880,7 +2880,7 @@ declare namespace ble { * Set the mtu size of a BLE peripheral device. * * @permission ohos.permission.ACCESS_BLUETOOTH - * @param { number } mtu - The maximum transmission unit. + * @param { int } mtu - The maximum transmission unit. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. 3. Parameter verification failed. @@ -2893,7 +2893,7 @@ declare namespace ble { * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - setBLEMtuSize(mtu: number): void; + setBLEMtuSize(mtu: int): void; /** * Enables or disables notification of a characteristic when value changed. @@ -4107,14 +4107,14 @@ declare namespace ble { /** * The Id of the read request * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - transId: number; + transId: int; /** * Indicates the byte offset of the start position for reading characteristic value * @@ -4125,13 +4125,13 @@ declare namespace ble { /** * Indicates the byte offset of the start position for reading characteristic value * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - offset: number; + offset: int; /** * The UUID of a CharacteristicReadRequest instance * @@ -4256,14 +4256,14 @@ declare namespace ble { /** * The Id of the write request * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - transId: number; + transId: int; /** * Indicates the byte offset of the start position for writing characteristic value * @@ -4274,13 +4274,13 @@ declare namespace ble { /** * Indicates the byte offset of the start position for writing characteristic value * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - offset: number; + offset: int; /** * Whether this request should be pending for later operation * @@ -4463,14 +4463,14 @@ declare namespace ble { /** * The Id of the read request * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - transId: number; + transId: int; /** * Indicates the byte offset of the start position for reading characteristic value * @@ -4481,13 +4481,13 @@ declare namespace ble { /** * Indicates the byte offset of the start position for reading characteristic value * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - offset: number; + offset: int; /** * The UUID of a DescriptorReadRequest instance * @@ -4638,14 +4638,14 @@ declare namespace ble { /** * The Id of the write request * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - transId: number; + transId: int; /** * Indicates the byte offset of the start position for writing characteristic value * @@ -4656,13 +4656,13 @@ declare namespace ble { /** * Indicates the byte offset of the start position for writing characteristic value * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - offset: number; + offset: int; /** * Whether this request should be pending for later operation * @@ -4871,14 +4871,14 @@ declare namespace ble { /** * The Id of the write request * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - transId: number; + transId: int; /** * Indicates the status of the read or write request, set this parameter to '0' in normal cases * @@ -4897,14 +4897,14 @@ declare namespace ble { /** * Indicates the status of the read or write request, set this parameter to '0' in normal cases * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - status: number; + status: int; /** * Indicates the byte offset of the start position for reading or writing operation * @@ -4915,13 +4915,13 @@ declare namespace ble { /** * Indicates the byte offset of the start position for reading or writing operation * - * @type { number } + * @type { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - offset: number; + offset: int; /** * Indicates the value to be sent * @@ -5259,13 +5259,13 @@ declare namespace ble { * Maximum slot value for the advertising interval, which is {@code 16777215} (10485.759375s) * Default slot value for the advertising interval, which is {@code 1600} (1s) * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Communication.Bluetooth.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - interval?: number; + interval?: int; /** * Minimum transmission power level for advertising, which is {@code -127} * Maximum transmission power level for advertising, which is {@code 1} @@ -5280,13 +5280,13 @@ declare namespace ble { * Maximum transmission power level for advertising, which is {@code 1} * Default transmission power level for advertising, which is {@code -7} * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Communication.Bluetooth.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - txPower?: number; + txPower?: int; /** * Indicates whether the BLE is connectable, default is {@code true} * @@ -5529,12 +5529,12 @@ declare namespace ble { * The duration, in 10ms unit. Valid range is from 1 (10ms) to 65535 (655,350 ms). * If this parameter is not specified or is set to 0, advertisement is continuously sent. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Communication.Bluetooth.Core * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - duration?: number; + duration?: int; } /** @@ -5558,12 +5558,12 @@ declare namespace ble { * The duration, in 10ms unit. Valid range is from 1 (10ms) to 65535 (655,350 ms). * If this parameter is not specified or is set to 0, advertise is continuously sent. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Communication.Bluetooth.Core * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - duration?: number; + duration?: int; } /** @@ -6154,14 +6154,14 @@ declare namespace ble { /** * Time of delay for reporting the scan result * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - interval?: number; + interval?: int; /** * Bluetooth LE scan mode * @@ -6432,7 +6432,7 @@ declare namespace ble { /** * The enum of gatt characteristic write type * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice @@ -6506,7 +6506,7 @@ declare namespace ble { /** * The enum of scan duty. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice @@ -6593,7 +6593,7 @@ declare namespace ble { /** * The enum of BLE match mode. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} diff --git a/api/@ohos.bluetooth.connection.d.ts b/api/@ohos.bluetooth.connection.d.ts index efbc3b9f7738e38b5f256cea1f68ce30e9afb4af..4f19dba260267696593df3c2025eaac7cedff92a 100644 --- a/api/@ohos.bluetooth.connection.d.ts +++ b/api/@ohos.bluetooth.connection.d.ts @@ -746,7 +746,7 @@ declare namespace connection { * * @permission ohos.permission.ACCESS_BLUETOOTH * @param { ScanMode } mode - Indicates the Bluetooth scan mode to set. - * @param { number } duration - Indicates the duration in seconds, in which the host is discoverable. + * @param { int } duration - Indicates the duration in seconds, in which the host is discoverable. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. 3. Parameter verification failed. @@ -758,7 +758,7 @@ declare namespace connection { * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - function setBluetoothScanMode(mode: ScanMode, duration: number): void; + function setBluetoothScanMode(mode: ScanMode, duration: int): void; /** * Obtains the Bluetooth scanning mode of a device. @@ -1372,7 +1372,8 @@ declare namespace connection { * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'bluetoothDeviceFind', callback: Callback>): void; @@ -1413,7 +1414,8 @@ declare namespace connection { * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'bluetoothDeviceFind', callback?: Callback>): void; @@ -1444,7 +1446,8 @@ declare namespace connection { * @throws { BusinessError } 801 - Capability not supported. * @throws { BusinessError } 2900099 - Operation failed. * @syscap SystemCapability.Communication.Bluetooth.Core - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'discoveryResult', callback: Callback>): void; @@ -1471,7 +1474,8 @@ declare namespace connection { * @throws { BusinessError } 801 - Capability not supported. * @throws { BusinessError } 2900099 - Operation failed. * @syscap SystemCapability.Communication.Bluetooth.Core - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'discoveryResult', callback?: Callback>): void; @@ -1502,7 +1506,8 @@ declare namespace connection { * @throws { BusinessError } 2900099 - Operation failed. * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'bondStateChange', callback: Callback): void; @@ -1533,7 +1538,8 @@ declare namespace connection { * @throws { BusinessError } 2900099 - Operation failed. * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'bondStateChange', callback?: Callback): void; @@ -1549,7 +1555,8 @@ declare namespace connection { * @throws { BusinessError } 801 - Capability not supported. * @throws { BusinessError } 2900099 - Operation failed. * @syscap SystemCapability.Communication.Bluetooth.Core - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'pinRequired', callback: Callback): void; @@ -1565,7 +1572,8 @@ declare namespace connection { * @throws { BusinessError } 801 - Capability not supported. * @throws { BusinessError } 2900099 - Operation failed. * @syscap SystemCapability.Communication.Bluetooth.Core - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'pinRequired', callback?: Callback): void; @@ -1578,7 +1586,8 @@ declare namespace connection { * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2900099 - Operation failed. * @syscap SystemCapability.Communication.Bluetooth.Core - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'batteryChange', callback: Callback): void; @@ -1591,7 +1600,8 @@ declare namespace connection { * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2900099 - Operation failed. * @syscap SystemCapability.Communication.Bluetooth.Core - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'batteryChange', callback?: Callback): void; @@ -1804,7 +1814,7 @@ declare namespace connection { /** * The enum of BR scan mode. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @since arkts {'1.1':'13','1.2':'20'} @@ -1895,7 +1905,7 @@ declare namespace connection { /** * The enum of bond state. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice diff --git a/api/@ohos.bluetooth.constant.d.ts b/api/@ohos.bluetooth.constant.d.ts index 2f6a671b02713dbe273184c4ca74eb99f29ce29a..acd1baf6cd7f54b8f4373698e3f8ebd07dc5c624 100644 --- a/api/@ohos.bluetooth.constant.d.ts +++ b/api/@ohos.bluetooth.constant.d.ts @@ -361,7 +361,7 @@ declare namespace constant { /** * The enum of profile connection state. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @atomicservice @@ -471,7 +471,7 @@ declare namespace constant { /** * The enum of major class of a bluetooth device. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @since arkts {'1.1':'13','1.2':'20'} @@ -584,7 +584,7 @@ declare namespace constant { /** * The enum of major minor class of a bluetooth device. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Communication.Bluetooth.Core * @crossplatform * @since arkts {'1.1':'13','1.2':'20'} diff --git a/api/@ohos.buffer.d.ts b/api/@ohos.buffer.d.ts index bed436ace9ca449dd697017fe34ca1b8cd2c9c5a..884b5ed545af112f133749b955704b9332fcd907 100644 --- a/api/@ohos.buffer.d.ts +++ b/api/@ohos.buffer.d.ts @@ -126,6 +126,35 @@ declare namespace buffer { | Float64Array | BigInt64Array | BigUint64Array; + + /** + * ArrayUnionType features and methods + * + * @typedef { Array | Array | Array | Array | Array | Array | + * Array | Array | Array | Array | Array | Array | + * Array | Array | Array} + * @syscap SystemCapability.Utils.Lang + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + type ArrayUnionType = Array + | Array + | Array + | Array + | Array + | Array + | Array + | Array + | Array + | Array + | Array + | Array + | Array + | Array + | Array; + /** * Allocates a new Buffer for a fixed size bytes. If fill is undefined, the Buffer will be zero-filled. * @@ -159,7 +188,7 @@ declare namespace buffer { * Creates and initializes a Buffer instance of the specified length. * * @param { int } size - Size of the Buffer instance to create, in bytes. - * @param { string | Buffer | double | long } [fill] - Value to be filled in the buffer. The default value is 0. + * @param { string | Buffer | int | double | long } [fill] - Value to be filled in the buffer. The default value is 0. * @param { BufferEncoding } [encoding] - Encoding format (valid only when fill is a string). The default value is 'utf8'. * @returns { Buffer } Return a new allocated Buffer * @throws { BusinessError } 401 - Parameter error. Possible causes: @@ -172,7 +201,7 @@ declare namespace buffer { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - function alloc(size: int, fill?: string | Buffer | double | long, encoding?: BufferEncoding): Buffer; + function alloc(size: int, fill?: string | Buffer | int | double | long, encoding?: BufferEncoding): Buffer; /** * Allocates a new Buffer for a fixed size bytes. The Buffer will not be initially filled. @@ -407,8 +436,7 @@ declare namespace buffer { * @syscap SystemCapability.Utils.Lang * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function from(array: double[]): Buffer; @@ -465,23 +493,6 @@ declare namespace buffer { */ function from(arrayBuffer: ArrayBuffer | SharedArrayBuffer, byteOffset?: number, length?: number): Buffer; - /** - * This creates a view of the ArrayBuffer without copying the underlying memory. - * - * @param { ArrayBuffer } arrayBuffer - arrayBuffer arrayBuffer An ArrayBuffer, - * @param { int } [byteOffset] - byteOffset [byteOffset = 0] Index of first byte to expose - * @param { int } [length] - length [length = arrayBuffer.byteLength - byteOffset] Number of bytes to expose - * @returns { Buffer } Return a view of the ArrayBuffer - * @throws { BusinessError } 10200001 - The value of "[byteOffset/length]" is out of range. - * It must be >= [left range] and <= [right range]. Received value is: [byteOffset/length] - * @syscap SystemCapability.Utils.Lang - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - function from(arrayBuffer: ArrayBuffer, byteOffset?: int, length?: int): Buffer; - /** * Copies the passed buffer data onto a new Buffer instance. * @@ -516,8 +527,7 @@ declare namespace buffer { * @syscap SystemCapability.Utils.Lang * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function from(buffer: Buffer | Uint8Array): Buffer; @@ -566,21 +576,6 @@ declare namespace buffer { */ function from(object: Object, offsetOrEncoding: int | string, length: int): Buffer; - /** - * Creates a Buffer instance based on the specified object. - * - * @param { Object } input - Object that supports Symbol.toPrimitive or valueOf(). - * @param { int | string } offsetOrEncoding - Byte offset or encoding format. - * @param { int } length - Length of the Buffer instance to create, in bytes. - * @returns { Buffer } Return a new allocated Buffer - * @syscap SystemCapability.Utils.Lang - * @crossplatform - * @atomicservice - * @since 20 - * @arkts 1.2 - */ - function from(input: Object, offsetOrEncoding: int | string, length: int): Buffer; - /** * Creates a new Buffer containing string. The encoding parameter identifies the character encoding * to be used when converting string into bytes. @@ -619,11 +614,96 @@ declare namespace buffer { * @syscap SystemCapability.Utils.Lang * @crossplatform * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function from(string: String, encoding?: BufferEncoding): Buffer; + /** + * Creates a Buffer instance with the specified array. + * + * @param { double[] } array - Array to create a Buffer instance. + * @returns { Buffer } Return a new allocated Buffer + * @syscap SystemCapability.Utils.Lang + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + function fromWithArray(array: double[]): Buffer; + + /** + * This creates a view of the ArrayBuffer without copying the underlying memory. + * + * @param { ArrayBuffer } arrayBuffer - arrayBuffer arrayBuffer An ArrayBuffer, + * @param { int } [byteOffset] - byteOffset [byteOffset = 0] Index of first byte to expose + * @param { int } [length] - length [length = arrayBuffer.byteLength - byteOffset] Number of bytes to expose + * @returns { Buffer } Return a view of the ArrayBuffer + * @throws { BusinessError } 10200001 - The value of "[byteOffset/length]" is out of range. + * It must be >= [left range] and <= [right range]. Received value is: [byteOffset/length] + * @syscap SystemCapability.Utils.Lang + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + function fromWithArrayBufferByteOffsetLength(arrayBuffer: ArrayBuffer, byteOffset?: int, length?: int): Buffer; + + /** + * Copies the data of a passed Buffer instance to create a new Buffer instance and returns the new one. + * + * @param { Buffer | Uint8Array } buffer - Buffer or Uint8Array instance. + * @returns { Buffer } Return a new allocated Buffer + * @syscap SystemCapability.Utils.Lang + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + function fromWithBuffer(buffer: Buffer | Uint8Array): Buffer; + + /** + * Creates a Buffer instance based on the specified object. + * + * @param { Object } input - Object that supports Symbol.toPrimitive or valueOf(). + * @param { int | string } offsetOrEncoding - Byte offset or encoding format. + * @param { int } length - Length of the Buffer instance to create, in bytes. + * @returns { Buffer } Return a new allocated Buffer + * @syscap SystemCapability.Utils.Lang + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + function fromWithObjectTypedInputOffsetOrEncodingLength(input: Object, offsetOrEncoding: int | string, length: int): Buffer; + + /** + * Creates a Buffer instance based on various types. + * + * @param { string } input - string. + * @param { BufferEncoding } [encoding] - Encoding format of the string. The default value is 'utf8'. + * @returns { Buffer } Return a new Buffer containing string + * @syscap SystemCapability.Utils.Lang + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + function fromWithStringTypedInputEncoding(input: string, encoding?: BufferEncoding): Buffer; + + /** + * Creates a Buffer instance based on a string in the given encoding format. + * + * @overload { fromWithArray, fromWithArrayBufferByteOffsetLength, fromWithBuffer, + fromWithObjectTypedInputOffsetOrEncodingLength, fromWithStringTypedInputEncoding } + * @syscap SystemCapability.Utils.Lang + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + export overload from { fromWithArray, fromWithArrayBufferByteOffsetLength, fromWithBuffer, + fromWithObjectTypedInputOffsetOrEncodingLength, fromWithStringTypedInputEncoding } + /** * Returns true if obj is a Buffer, false otherwise * @@ -975,7 +1055,7 @@ declare namespace buffer { /** * Fills this Buffer instance at the specified position. By default, data is filled cyclically. * - * @param { string | Buffer | Uint8Array | double | long } value - Value to fill. + * @param { string | Buffer | Uint8Array | int | double | long } value - Value to fill. * @param { int } [offset] - Offset to the start position in this Buffer instance where data is filled. The default value is 0. * @param { int } [end] - Offset to the end position in this Buffer instance (not inclusive). The default value is the length of this Buffer instance. * @param { BufferEncoding } [encoding] - Encoding format (valid only when value is a string). The default value is 'utf8'. @@ -991,7 +1071,7 @@ declare namespace buffer { * @arkts 1.1&1.2 */ fill( - value: string | Buffer | Uint8Array | double | long, + value: string | Buffer | Uint8Array | int | double | long, offset?: int, end?: int, encoding?: BufferEncoding @@ -1219,7 +1299,7 @@ declare namespace buffer { /** * Checks whether this Buffer instance contains the specified value. * - * @param { string | double | long | Buffer | Uint8Array } value - Value to match. + * @param { string | int | double | long | Buffer | Uint8Array } value - Value to match. * @param { int } [byteOffset] - Number of bytes to skip before starting to check data. * Number of bytes to skip before starting to check data. If the offset is a negative number, * data is checked from the end of the Buffer instance. The default value is 0. @@ -1234,7 +1314,7 @@ declare namespace buffer { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - includes(value: string | double | long | Buffer | Uint8Array, byteOffset?: int, encoding?: BufferEncoding): boolean; + includes(value: string | int | double | long | Buffer | Uint8Array, byteOffset?: int, encoding?: BufferEncoding): boolean; /** * The index of the first occurrence of value in buf @@ -1268,7 +1348,7 @@ declare namespace buffer { /** * Obtains the index of the first occurrence of the specified value in this Buffer instance. * - * @param { string | double | long | Buffer | Uint8Array } value - Value to match. + * @param { string | int | double | long | Buffer | Uint8Array } value - Value to match. * @param { int } [byteOffset] - Number of bytes to skip before starting to check data. * If the offset is a negative number, data is checked from the end of the Buffer instance. The default value is 0. * @param { BufferEncoding } [encoding] - Encoding format (valid only when value is a string). The default value is 'utf8'. @@ -1282,7 +1362,7 @@ declare namespace buffer { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - indexOf(value: string | double | long | Buffer | Uint8Array, byteOffset?: int, encoding?: BufferEncoding): int; + indexOf(value: string | int | double | long | Buffer | Uint8Array, byteOffset?: int, encoding?: BufferEncoding): int; /** * Creates and returns an iterator of buf keys (indices). @@ -1399,7 +1479,7 @@ declare namespace buffer { /** * Obtains the index of the last occurrence of the specified value in this Buffer instance. * - * @param { string | double | long | Buffer | Uint8Array } value - Value to match. + * @param { string | int | double | long | Buffer | Uint8Array } value - Value to match. * @param { int } [byteOffset] - Number of bytes to skip before starting to check data. * If the offset is a negative number, data is checked from the end of the Buffer instance. * The default value is the length of this Buffer instance. @@ -1414,7 +1494,7 @@ declare namespace buffer { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - lastIndexOf(value: string | double | long | Buffer | Uint8Array, byteOffset?: int, encoding?: BufferEncoding): int; + lastIndexOf(value: string | int | double | long | Buffer | Uint8Array, byteOffset?: int, encoding?: BufferEncoding): int; /** * Reads a signed, big-endian 64-bit integer from buf at the specified offset @@ -3165,7 +3245,8 @@ declare namespace buffer { * Writes a big-endian signed value of the specified length to this Buffer instance at the specified offset. * * @param { long } value - Data to write. - * @param { int } offset - Number of bytes to skip before starting to write data. The default value is 0. The value range is [0, Buffer.length - byteLength]. + * @param { int } offset - Number of bytes to skip before starting to write data. The default value is 0. + * The value range is [0, Buffer.length - byteLength]. * @param { int } byteLength - Number of bytes to write. * @returns { int } offset plus the number of bytes written * @throws { BusinessError } 401 - Parameter error. Possible causes: @@ -3213,7 +3294,8 @@ declare namespace buffer { * Writes a little-endian signed value of the specified length to this Buffer instance at the specified offset. * * @param { long } value - Data to write. - * @param { int } offset - Number of bytes to skip before starting to write data. The default value is 0. The value range is [0, Buffer.length - byteLength]. + * @param { int } offset - Number of bytes to skip before starting to write data. The default value is 0. + * The value range is [0, Buffer.length - byteLength]. * @param { int } byteLength - Number of bytes to write. * @returns { int } offset plus the number of bytes written * @throws { BusinessError } 401 - Parameter error. Possible causes: @@ -3501,7 +3583,8 @@ declare namespace buffer { * Writes an unsigned big-endian value of the specified length to this Buffer instance at the specified offset. * * @param { long } value - Data to write. - * @param { int } offset - Number of bytes to skip before starting to write data. The default value is 0. The value range is [0, Buffer.length - byteLength]. + * @param { int } offset - Number of bytes to skip before starting to write data. The default value is 0. + * The value range is [0, Buffer.length - byteLength]. * @param { int } byteLength - Number of bytes to write. * @returns { int } offset plus the number of bytes written * @throws { BusinessError } 401 - Parameter error. Possible causes: @@ -3549,7 +3632,8 @@ declare namespace buffer { * Writes an unsigned little-endian value of the specified length to this Buffer instance at the specified offset. * * @param { long } value - Data to write. - * @param { int } offset - Number of bytes to skip before starting to write data. The default value is 0. The value range is [0, Buffer.length - byteLength]. + * @param { int } offset - Number of bytes to skip before starting to write data. The default value is 0. + * The value range is [0, Buffer.length - byteLength]. * @param { int } byteLength - Number of bytes to write. * @returns { int } offset plus the number of bytes written * @throws { BusinessError } 401 - Parameter error. Possible causes: @@ -3577,7 +3661,7 @@ declare namespace buffer { * @since 20 * @arkts 1.2 */ - [index: int]: Long; + [index: int]: long; } /** @@ -3687,21 +3771,17 @@ declare namespace buffer { /** * Creates a new Blob object containing a concatenation of the given sources. * - * @param { Array | Array | Array | Array | Array } sources - sources sources An array of string, , - * , , or objects, or any mix of such objects, that will be stored within the Blob + * @param { ArrayUnionType } sources - sources sources ArrayUnionType * @param { BlobOptions } [options] - options options {endings: string, type: string} * endings: One of either 'transparent' or 'native'. * type: The Blob content-type - * @throws { BusinessError } 401 - Parameter error. Possible causes: - * 1.Mandatory parameters are left unspecified; - * 2.Incorrect parameter types. * @syscap SystemCapability.Utils.Lang * @crossplatform * @atomicservice * @since 20 * @arkts 1.2 */ - constructor(sources: Array | Array | Array | Array | Array, options?: BlobOptions); + constructor(sources: ArrayUnionType, options?: BlobOptions); /** * The total size of the Blob in bytes @@ -3728,7 +3808,7 @@ declare namespace buffer { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - size: int; + get size(): int; /** * The content-type of the Blob @@ -3755,7 +3835,7 @@ declare namespace buffer { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - type: string; + get type(): string; /** * Returns a promise that fulfills with an containing a copy of the Blob data. diff --git a/api/@ohos.bundle.bundleManager.d.ts b/api/@ohos.bundle.bundleManager.d.ts index f37ee52072b4c7ce1be256024d0f7b266cd1a9e4..2b929348edec133d01c14fed823ef6746c49b69a 100644 --- a/api/@ohos.bundle.bundleManager.d.ts +++ b/api/@ohos.bundle.bundleManager.d.ts @@ -972,16 +972,6 @@ declare namespace bundleManager { */ LIVE_FORM = 30, - /** - * Indicates extension info with type of selection. - * This type of extension can access data such as text selected by the user. - * - * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 20 - * @arkts 1.1&1.2 - */ - SELECTION = 31, - /** * Indicates extension info with type of unspecified * diff --git a/api/@ohos.commonEventManager.d.ts b/api/@ohos.commonEventManager.d.ts index 6207edf017a39e90e826be68f0ab3becbcc9a588..6c7178151ff72afad92644eaa6654cd93073d111 100644 --- a/api/@ohos.commonEventManager.d.ts +++ b/api/@ohos.commonEventManager.d.ts @@ -2052,8 +2052,7 @@ declare namespace commonEventManager { * sent by the window manager service when the window mode is split. * * @syscap SystemCapability.Notification.CommonEvent - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ /** * sent by the window manager service when the window mode is split. @@ -2701,8 +2700,7 @@ declare namespace commonEventManager { * * @syscap SystemCapability.Notification.CommonEvent * @atomicservice - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ /** * Describes the information of the subscriber diff --git a/api/@ohos.curves.d.ts b/api/@ohos.curves.d.ts index 6e9f42033bd1b286e920b84aebe88c31541f769f..3c0b0007a82ea62ef7d470dd22b0135152518044 100644 --- a/api/@ohos.curves.d.ts +++ b/api/@ohos.curves.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021-2025 Huawei Device Co., Ltd. + * Copyright (c) 2021-2023 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -42,17 +42,6 @@ * @atomicservice * @since 11 */ -/** - * Contains interpolator functions such as initialization, third-order Bezier curves, and spring curves. - * - * @namespace curves - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ declare namespace curves { /** * enum Curve. @@ -78,18 +67,7 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * enum Curve. - * - * @enum { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ - export enum Curve { + enum Curve { /** * Linear. Indicates that the animation has the same velocity from start to finish. * @@ -111,16 +89,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * Linear. Indicates that the animation has the same velocity from start to finish. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ Linear, /** * Ease. Indicates that the animation starts at a low speed, then speeds up, and slows down before the end, @@ -146,17 +114,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * Ease. Indicates that the animation starts at a low speed, then speeds up, and slows down before the end, - * CubicBezier(0.25, 0.1, 0.25, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ Ease, /** * EaseIn. Indicates that the animation starts at a low speed, Cubic Bezier (0.42, 0.0, 1.0, 1.0). @@ -179,16 +136,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * EaseIn. Indicates that the animation starts at a low speed, Cubic Bezier (0.42, 0.0, 1.0, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ EaseIn, /** * EaseOut. Indicates that the animation ends at low speed, CubicBezier (0.0, 0.0, 0.58, 1.0). @@ -211,16 +158,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * EaseOut. Indicates that the animation ends at low speed, CubicBezier (0.0, 0.0, 0.58, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ EaseOut, /** * EaseInOut. Indicates that the animation starts and ends at low speed, CubicBezier (0.42, 0.0, 0.58, 1.0). @@ -243,16 +180,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * EaseInOut. Indicates that the animation starts and ends at low speed, CubicBezier (0.42, 0.0, 0.58, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ EaseInOut, /** * FastOutSlowIn. Standard curve, cubic-bezier (0.4, 0.0, 0.2, 1.0). @@ -275,16 +202,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * FastOutSlowIn. Standard curve, cubic-bezier (0.4, 0.0, 0.2, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ FastOutSlowIn, /** * LinearOutSlowIn. Deceleration curve, cubic-bezier (0.0, 0.0, 0.2, 1.0). @@ -307,16 +224,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * LinearOutSlowIn. Deceleration curve, cubic-bezier (0.0, 0.0, 0.2, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ LinearOutSlowIn, /** * FastOutLinearIn. Acceleration curve, cubic-bezier (0.4, 0.0, 1.0, 1.0). @@ -339,16 +246,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * FastOutLinearIn. Acceleration curve, cubic-bezier (0.4, 0.0, 1.0, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ FastOutLinearIn, /** * ExtremeDeceleration. Abrupt curve, cubic-bezier (0.0, 0.0, 0.0, 1.0). @@ -371,16 +268,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * ExtremeDeceleration. Abrupt curve, cubic-bezier (0.0, 0.0, 0.0, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ ExtremeDeceleration, /** * Sharp. Sharp curves, cubic-bezier (0.33, 0.0, 0.67, 1.0). @@ -403,16 +290,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * Sharp. Sharp curves, cubic-bezier (0.33, 0.0, 0.67, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ Sharp, /** * Rhythm. Rhythmic curve, cubic-bezier (0.7, 0.0, 0.2, 1.0). @@ -435,16 +312,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * Rhythm. Rhythmic curve, cubic-bezier (0.7, 0.0, 0.2, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ Rhythm, /** * Smooth. Smooth curves, cubic-bezier (0.4, 0.0, 0.4, 1.0). @@ -467,16 +334,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * Smooth. Smooth curves, cubic-bezier (0.4, 0.0, 0.4, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ Smooth, /** * Friction. Damping curves, CubicBezier (0.2, 0.0, 0.2, 1.0). @@ -499,16 +356,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * Friction. Damping curves, CubicBezier (0.2, 0.0, 0.2, 1.0). - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ Friction, } @@ -536,18 +383,7 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * Interface for curve object. - * - * @interface ICurve - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ - export interface ICurve { + interface ICurve { /** * Get curve value by fraction. * @@ -580,19 +416,6 @@ declare namespace curves { * @atomicservice * @since 11 */ - /** - * Get curve value by fraction. - * - * @param { number } fraction -Indicates the current normalized time parameter. Value range: [0, 1]. - * Note: If the value is less than 0, it will be processed as 0. If the value is greater than 1, 1 is used. - * @returns { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 20 - * @arkts 1.1&1.2 - */ interpolate(fraction: number): number; } @@ -622,10 +445,9 @@ declare namespace curves { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export function initCurve(curve?: Curve): ICurve; + function initCurve(curve?: Curve): ICurve; /** * Initializes the interpolator curve when called. @@ -672,10 +494,9 @@ declare namespace curves { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export function stepsCurve(count: number, end: boolean): ICurve; + function stepsCurve(count: number, end: boolean): ICurve; /** * Constructs a custom curve when called. @@ -701,10 +522,9 @@ declare namespace curves { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export function customCurve(interpolate: (fraction: number) => number): ICurve; + function customCurve(interpolate: (fraction: number) => number): ICurve; /** * Constructs a step curve when called. @@ -762,10 +582,9 @@ declare namespace curves { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export function cubicBezierCurve(x1: number, y1: number, x2: number, y2: number): ICurve; + function cubicBezierCurve(x1: number, y1: number, x2: number, y2: number): ICurve; /** * Creates a cubic Bezier curve. The curve value must range from 0 to 1. This API is deprecated since API version 9. @@ -838,10 +657,9 @@ declare namespace curves { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export function springCurve(velocity: number, mass: number, stiffness: number, damping: number): ICurve; + function springCurve(velocity: number, mass: number, stiffness: number, damping: number): ICurve; /** * Constructs a spring curve when called. @@ -920,10 +738,9 @@ declare namespace curves { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export function springMotion(response?: number, dampingFraction?: number, overlapDuration?: number): ICurve; + function springMotion(response?: number, dampingFraction?: number, overlapDuration?: number): ICurve; /** * Constructs a responsive spring motion when called. @@ -980,10 +797,9 @@ declare namespace curves { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export function responsiveSpringMotion(response?: number, dampingFraction?: number, overlapDuration?: number): ICurve; + function responsiveSpringMotion(response?: number, dampingFraction?: number, overlapDuration?: number): ICurve; /** * Constructs an interpolating spring curve when called, the animation duration can not be specified manually, @@ -1034,10 +850,9 @@ declare namespace curves { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export function interpolatingSpring(velocity: number, mass: number, stiffness: number, damping: number): ICurve; + function interpolatingSpring(velocity: number, mass: number, stiffness: number, damping: number): ICurve; } export default curves; diff --git a/api/@ohos.curves.static.d.ets b/api/@ohos.curves.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..27a99ab5368b1534d035fcc04bb20f39645f22c6 --- /dev/null +++ b/api/@ohos.curves.static.d.ets @@ -0,0 +1,361 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +/** + * Contains interpolator functions such as initialization, third-order Bezier curves, and spring curves. + * + * @namespace curves + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace curves { + + /** + * enum Curve. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export enum Curve { + + /** + * Linear. Indicates that the animation has the same velocity from start to finish. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Linear, + + /** + * Ease. Indicates that the animation starts at a low speed, then speeds up, and slows down before the end, + * CubicBezier(0.25, 0.1, 0.25, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Ease, + + /** + * EaseIn. Indicates that the animation starts at a low speed, Cubic Bezier (0.42, 0.0, 1.0, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + EaseIn, + + /** + * EaseOut. Indicates that the animation ends at low speed, CubicBezier (0.0, 0.0, 0.58, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + EaseOut, + + /** + * EaseInOut. Indicates that the animation starts and ends at low speed, CubicBezier (0.42, 0.0, 0.58, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + EaseInOut, + + /** + * FastOutSlowIn. Standard curve, cubic-bezier (0.4, 0.0, 0.2, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + FastOutSlowIn, + + /** + * LinearOutSlowIn. Deceleration curve, cubic-bezier (0.0, 0.0, 0.2, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + LinearOutSlowIn, + + /** + * FastOutLinearIn. Acceleration curve, cubic-bezier (0.4, 0.0, 1.0, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + FastOutLinearIn, + + /** + * ExtremeDeceleration. Abrupt curve, cubic-bezier (0.0, 0.0, 0.0, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + ExtremeDeceleration, + + /** + * Sharp. Sharp curves, cubic-bezier (0.33, 0.0, 0.67, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Sharp, + + /** + * Rhythm. Rhythmic curve, cubic-bezier (0.7, 0.0, 0.2, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Rhythm, + + /** + * Smooth. Smooth curves, cubic-bezier (0.4, 0.0, 0.4, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Smooth, + + /** + * Friction. Damping curves, CubicBezier (0.2, 0.0, 0.2, 1.0). + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + Friction + } + + /** + * Interface for curve object. + * + * @interface ICurve + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface ICurve { + /** + * Get curve value by fraction. + * + * @param { number } fraction -Indicates the current normalized time parameter. Value range: [0, 1]. + * Note: If the value is less than 0, it will be processed as 0. If the value is greater than 1, 1 is used. + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interpolate(fraction: number): number; + } + + /** + * Implements initialization for the interpolation curve, + * which is used to create an interpolation curve based on the input parameter. + * + * @param { Curve } [curve] - Curve type.
Default value: **Curve.Linear**. + * @returns { ICurve } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function initCurve(curve?: Curve): ICurve; + + /** + * Creates a step curve. + * + * @param { number } count - Number of steps. The value must be a positive integer.
Value range: [1, +∞). + *

**NOTE**: + *
A value less than 1 evaluates to the value **1**. + *

+ * @param { boolean } end -Whether jumping occurs when the interpolation ends. + * **true**: Jumping occurs when the interpolation ends. + * *false**: Jumping occurs when the interpolation starts. + * @returns { ICurve } Interpolation curve. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function stepsCurve(count: number, end: boolean): ICurve; + + /** + * Creates a custom curve. + * + * @param { function } interpolate - Custom interpolation callback.fraction: input x value for interpolation. + * when the animation starts. Value range: [0, 1]The return value is the y value of the curve. Value range: [0, 1]. + *

**NOTE**: + *
If fraction is 0, the return value 0 corresponds to the animation start point; + *
any other return value means that the animation jumps at the start point.If fraction is 1, the return + *
value 1 corresponds to the animation end point; any other return value means that the end value + *
of the animation is not the value of the state variable, which will result in an effect of transitions + *
from that end value to the value of the state variable. + *

+ * @returns { ICurve } Interpolation curve. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function customCurve(interpolate: (fraction: number) => number): ICurve; + + /** + * Creates a cubic Bezier curve. The curve values must be between 0 and 1. + * + * @param { number } x1 - X coordinate of the first point on the Bezier curve.
Value range: [0, 1]. + *

**NOTE**: + *
A value less than 0 is handed as **0**. A value greater than 1 is handed as **1**. + *

+ * @param { number } y1 - Y coordinate of the first point on the Bezier curve.
Value range: (-∞, +∞). + * @param { number } x2 - X coordinate of the second point on the Bezier curve.
Value range: [0, 1]. + *

**NOTE**: + *
A value less than 0 is handed as **0**. A value greater than 1 is handed as **1**. + *

+ * @param { number } y2 - Y coordinate of the second point on the Bezier curve.
Value range: (-∞, +∞). + * @returns { ICurve } Interpolation curve. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function cubicBezierCurve(x1: number, y1: number, x2: number, y2: number): ICurve; + + /** + * Creates a spring curve. The curve shape is subject to the spring parameters, and the animation duration + * is subject to the **duration** parameter in **animation** and **animateTo**. + * + * @param { number } velocity - Initial velocity. It is applied by external factors to the spring animation, + * designed to help ensure the smooth transition from the previous motion state. The velocity is the normalized + * velocity, and its value is equal to the actual velocity at the beginning of the animation divided by the + * animation attribute change value.Value range: (-∞, +∞). + * @param { number } mass - Mass, which influences the inertia in the spring system. The greater the mass, + * the greater the amplitude of the oscillation, and the slower the speed of restoring to the equilibrium position. + * Value range: (0, +∞). + *

**NOTE**: + *
If this parameter is set to a value less than or equal to 0, the value 1 is used. + *

+ * @param { number } stiffness - Stiffness.It is the degree to which an object deforms by resisting the force + * applied. In an elastic system, the greater the stiffness, the stronger the ability to resist deformation, + * and the faster the speed of restoring to the equilibrium position.Value range: (0, +∞). + *

**NOTE**: + *
If this parameter is set to a value less than or equal to 0, the value 1 is used. + *

+ * @param { number } damping -Damping. It is used to describe the oscillation and attenuation of the system + * after being disturbed. The larger the damping, the smaller the number of oscillations of elastic motion, + * and the smaller the oscillation amplitude.Value range: (0, +∞). + *

**NOTE**: + *
If this parameter is set to a value less than or equal to 0, the value 1 is used. + *

+ * @returns { ICurve } Interpolation curve. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function springCurve(velocity: number, mass: number, stiffness: number, damping: number): ICurve; + + /** + * Creates a spring animation curve. + * If multiple spring animations are applied to the same attribute of an object, + * each animation replaces their predecessor and inherits the velocity. + * + * @param { number } [response] Duration of one complete oscillation. + *
Default value: **0.55**.
Unit: second
Value range: (0, +∞). + *

**NOTE**: + *
If this parameter is set to a value less than or equal to 0, the default value **0.55** is used. + *

+ * @param { number } [dampingFraction] Damping coefficient. + * **0**: undamped. In this case, the spring oscillates forever.
> 0 and < 1: underdamped. + * In this case, the spring overshoots the equilibrium position.
**1**: critically damped. + * 1: overdamped. In this case, the spring approaches equilibrium gradually.
Default value: **0.825**. + * Unit: second. + * Value range: [0, +∞). + *

**NOTE**: + *
A value less than 0 evaluates to the default value **0.825**. + *

+ * @param { number } [overlapDuration] Duration for animations to overlap, in seconds. + * When animations overlap, the **response** values of these animations will transit smoothly over this duratio + * if they are different.
Default value: **0**
Unit: second
Value range: [0, +∞). + *

**NOTE** + *
A value less than 0 evaluates to the default value **0**. + *
The spring animation curve is physics-based. Its duration depends on the **springMotion** parameters and + * the previous velocity, rather than the **duration** parameter in animation, animateTo, or pageTransition. + * The time cannot be normalized. Therefore, the interpolation cannot be obtained using + * the **interpolate** function of the curve. + *

+ * @returns { ICurve } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function springMotion(response?: number, dampingFraction?: number, overlapDuration?: number): ICurve; + + /** + * Creates a responsive spring animation curve. It is a special case of [springMotion](#curvesspringmotion9), + * with the only difference in the default values. It can be used together with **springMotion**. + * + * @param { number } [response] See **response** in **springMotion**.
Default value: **0.15**. + * Unit: second
Value range: (0, +∞). + *

**NOTE**: + *
If this parameter is set to a value less than or equal to 0, the default value **0.15** is used. + *

+ * @param { number } [dampingFraction] See **dampingFraction** in **springMotion**.
Default value: **0.86**. + * Unit: second
Value range: [0, +∞). + *

**NOTE** + *
A value less than 0 evaluates to the default value **0.86**. + *

+ * @param { number } [overlapDuration] See **overlapDuration** in **springMotion**.
Default value: **0.25**. + * Unit: second
Value range: [0, +∞). + *

**NOTE**: + *
A value less than 0 evaluates to the default value **0.25**. + *
To apply custom settings for a spring animation, you are advised to use **springMotion**. + *
When using **responsiveSpringMotion**, you are advised to retain the default settings. + *
The duration of the responsive spring animation depends on the **responsiveSpringMotion** parameters and the + * previous velocity, rather than the duration parameter in animation, animateTo, or pageTransition. + *
In addition, the interpolation cannot be obtained using the **interpolate** function of the curve. + *

+ * @returns { ICurve } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function responsiveSpringMotion(response?: number, dampingFraction?: number, overlapDuration?: number): ICurve; + + /** + * Creates an interpolating spring curve animated from 0 to 1. The actual animation value is calculated based + * on the curve. The animation duration is subject to the curve parameters, rather than the **duration** parameter + * in **animation** or **animateTo**. + * + * @param { number } velocity - Initial velocity. It is applied by external factors to the spring animation, + * designed to help ensure the smooth transition from the previous motion state. + * The velocity is the normalized velocity, and its value is equal to the actual velocity at the beginning of + * the animation divided by the animation attribute change value.
Value range: (-∞, +∞). + * @param { number } mass - Mass, which influences the inertia in the spring system. The greater the mass, + * the greater the amplitude of the oscillation, and the slower the speed of restoring to the equilibrium position. + *
Value range: (0, +∞). + *

**NOTE**: + *
If this parameter is set to a value less than or equal to 0, the value **1** is used. + *

+ * @param { number } stiffness - Stiffness. It is the degree to which an object deforms by resisting + * the force applied. In an elastic system, the greater the stiffness, the stronger the ability to resist + * deformation, and the faster the speed of restoring to the equilibrium position.
Value range: (0, +∞). + *

**NOTE**: + *
If this parameter is set to a value less than or equal to 0, the value **1** is used. + *

+ * @param { number } damping - Damping. It is used to describe the oscillation and attenuation of the system + * after being disturbed. The larger the damping, the smaller the number of oscillations of elastic motion, + * and the smaller the oscillation amplitude.
Value range: (0, +∞)
+ *

**NOTE**: + *
If this parameter is set to a value less than or equal to 0, the value **1** is used. + *

+ * @returns { ICurve } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function interpolatingSpring(velocity: number, mass: number, stiffness: number, damping: number): ICurve; +} +export default curves; diff --git a/api/@ohos.data.dataShare.d.ts b/api/@ohos.data.dataShare.d.ts index 24a53a0d9497d1f745df7ebef4cf3a0174062eb8..7297e0e82b0cae897f29d3750917312eec8d7b38 100644 --- a/api/@ohos.data.dataShare.d.ts +++ b/api/@ohos.data.dataShare.d.ts @@ -31,8 +31,7 @@ import { ValuesBucket, ValueType } from './@ohos.data.ValuesBucket'; * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @systemapi * @stagemodelonly - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ /** * This module provides the dataShare capability for consumer. @@ -457,8 +456,7 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @systemapi * @stagemodelonly - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Specifies the predicates of the template. @@ -576,8 +574,7 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @systemapi * @stagemodelonly - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ /** * Enumerates the data change types. @@ -595,8 +592,7 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @systemapi * @stagemodelonly - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ /** * Data inserted. @@ -604,7 +600,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ INSERT = 0, @@ -614,8 +609,7 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @systemapi * @stagemodelonly - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ /** * Data deleted. @@ -623,7 +617,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ DELETE, /** @@ -632,8 +625,7 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @systemapi * @stagemodelonly - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ /** * Data updated. @@ -641,7 +633,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ UPDATE } @@ -1823,7 +1814,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ function createDataProxyHandle(): Promise; @@ -1834,7 +1824,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ interface ProxyData { /** @@ -1844,7 +1833,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ uri: string; @@ -1857,7 +1845,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ value?: ValueType; @@ -1872,7 +1859,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ allowList?: string[]; } @@ -1884,7 +1870,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ interface DataProxyChangeInfo { /** @@ -1894,7 +1879,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ type: ChangeType; @@ -1905,7 +1889,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ uri: string; @@ -1916,7 +1899,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ value: ValueType; } @@ -1928,7 +1910,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ enum DataProxyErrorCode { /** @@ -1937,7 +1918,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ SUCCESS = 0, @@ -1947,7 +1927,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ URI_NOT_EXIST = 1, @@ -1957,7 +1936,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ NO_PERMISSION = 2, @@ -1967,7 +1945,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ OVER_LIMIT = 3 } @@ -1979,7 +1956,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ interface DataProxyResult { /** @@ -1989,7 +1965,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ uri: string; @@ -1999,7 +1974,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ result: DataProxyErrorCode; } @@ -2011,7 +1985,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ interface DataProxyGetResult { /** @@ -2021,7 +1994,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ uri: string; @@ -2032,7 +2004,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ result: DataProxyErrorCode; @@ -2044,7 +2015,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ value: ValueType | undefined; @@ -2057,7 +2027,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ allowList: string[] | undefined; } @@ -2069,7 +2038,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ enum DataProxyType { /** @@ -2078,7 +2046,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ SHARED_CONFIG = 0 } @@ -2090,7 +2057,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ interface DataProxyConfig { /** @@ -2100,7 +2066,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ type: DataProxyType; } @@ -2112,7 +2077,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ interface DataProxyHandle { /** @@ -2128,7 +2092,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ on( event: 'dataChange', @@ -2150,7 +2113,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ off( event: 'dataChange', @@ -2173,7 +2135,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ publish(data: ProxyData[], config: DataProxyConfig): Promise; @@ -2189,7 +2150,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ delete(uris: string[], config: DataProxyConfig): Promise; @@ -2205,7 +2165,6 @@ declare namespace dataShare { * @syscap SystemCapability.DistributedDataManager.DataShare.Consumer * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ get(uris: string[], config: DataProxyConfig): Promise; } diff --git a/api/@ohos.data.preferences.d.ts b/api/@ohos.data.preferences.d.ts index a01564d4f5807ab4c62b9f653b125ae183103500..e190beed2e49d4755027ed990186c41ee6ee2ea6 100644 --- a/api/@ohos.data.preferences.d.ts +++ b/api/@ohos.data.preferences.d.ts @@ -149,8 +149,7 @@ declare namespace preferences { * @syscap SystemCapability.DistributedDataManager.Preferences.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ const MAX_VALUE_LENGTH: number; @@ -160,8 +159,7 @@ declare namespace preferences { * @enum { number } * @syscap SystemCapability.DistributedDataManager.Preferences.Core * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enum StorageType { /** @@ -169,8 +167,7 @@ declare namespace preferences { * * @syscap SystemCapability.DistributedDataManager.Preferences.Core * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ XML = 0, @@ -179,8 +176,7 @@ declare namespace preferences { * * @syscap SystemCapability.DistributedDataManager.Preferences.Core * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ GSKV } @@ -248,8 +244,7 @@ declare namespace preferences { * @type { ?(StorageType | null | undefined) } * @syscap SystemCapability.DistributedDataManager.Preferences.Core * @atomicservice - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ storageType?: StorageType | null | undefined; } diff --git a/api/@ohos.data.relationalStore.d.ts b/api/@ohos.data.relationalStore.d.ts index 6a7921332cc62cff4fba68e5a4352b3864137f2f..58cfadbf95663494e309e06647f634640e2b9e5f 100644 --- a/api/@ohos.data.relationalStore.d.ts +++ b/api/@ohos.data.relationalStore.d.ts @@ -44,7 +44,7 @@ declare namespace relationalStore { /** * Describes the status of asset * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since arkts {'1.1':'10', '1.2':'20'} @@ -229,13 +229,13 @@ declare namespace relationalStore { /** * Indicates possible value types * - * @typedef { null | number | string | boolean | Uint8Array | Asset | Assets | Float32Array | bigint } ValueType + * @typedef { null | long | double | string | boolean | Uint8Array | Asset | Assets | Float32Array | bigint } ValueType * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - type ValueType = null | number | string | boolean | Uint8Array | Asset | Assets | Float32Array | bigint; + type ValueType = null | long | double | string | boolean | Uint8Array | Asset | Assets | Float32Array | bigint; /** * Values in buckets are stored in key-value pairs @@ -266,18 +266,20 @@ declare namespace relationalStore { /** * The type of the priority key can be number or string * - * @typedef { number | string } PRIKeyType + * @typedef { long | string } PRIKeyType * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ - type PRIKeyType = number | string; + type PRIKeyType = long | string; /** * The time is in UTC format. * * @typedef { Date } UTCTime * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ type UTCTime = Date; @@ -286,7 +288,8 @@ declare namespace relationalStore { * * @typedef { Map } ModifyTime * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ type ModifyTime = Map; @@ -520,7 +523,7 @@ declare namespace relationalStore { /** * Enumerates the high availability modes of the RDB store. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} @@ -599,13 +602,13 @@ declare namespace relationalStore { * Default number is 10000. * When the number is set to 0, use default iteration number and encryption algorithm. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 * @arkts 1.1&1.2 */ - iterationCount?: number; + iterationCount?: int; /** * Specifies the encryption algorithm when opening an encrypted database. @@ -679,13 +682,13 @@ declare namespace relationalStore { * Specifies the page size used when opening an encrypted database. * Default crypto page size is 1024. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 * @arkts 1.1&1.2 */ - cryptoPageSize?: number; + cryptoPageSize?: int; } /** @@ -698,7 +701,7 @@ declare namespace relationalStore { /** * Enumerates the supported encryption algorithm when opening a database. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 @@ -748,7 +751,7 @@ declare namespace relationalStore { /** * Enumerates the supported HMAC algorithm when opening a database. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 @@ -814,7 +817,7 @@ declare namespace relationalStore { /** * Enumerates the supported KDF algorithm when opening a database. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 @@ -1164,12 +1167,12 @@ declare namespace relationalStore { /** * Total time used for executing the SQL statements, in μs. * - * @type { number } + * @type { long } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 */ - totalTime: number; + totalTime: long; /** * Maximum time allowed to obtain the SQL file handle, in μs. @@ -1181,12 +1184,12 @@ declare namespace relationalStore { /** * Maximum time allowed to obtain the SQL file handle, in μs. * - * @type { number } + * @type { long } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 */ - waitTime: number; + waitTime: long; /** * Time used to prepare SQL and args, in μs. @@ -1198,12 +1201,12 @@ declare namespace relationalStore { /** * Time used to prepare SQL and args, in μs. * - * @type { number } + * @type { long } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 */ - prepareTime: number; + prepareTime: long; /** * Time used to execute the SQL statements, in μs. @@ -1215,12 +1218,12 @@ declare namespace relationalStore { /** * Time used to execute the SQL statements, in μs. * - * @type { number } + * @type { long } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 */ - executeTime: number; + executeTime: long; } /** @@ -1235,12 +1238,12 @@ declare namespace relationalStore { /** * Error code returned by SQLite, see {@link https://www.sqlite.org/rescode.html}. * - * @type { number } + * @type { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 */ - code: number; + code: int; /** * Error message. @@ -1296,7 +1299,7 @@ declare namespace relationalStore { /** * Describes the {@code RdbStore} type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since arkts {'1.1':'9', '1.2':'20'} @@ -1351,7 +1354,7 @@ declare namespace relationalStore { /** * Indicates the database synchronization mode. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 9 */ @@ -1400,7 +1403,7 @@ declare namespace relationalStore { /** * Describes the subscription type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 9 */ @@ -1455,7 +1458,7 @@ declare namespace relationalStore { /** * Describes the change type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 10 */ @@ -1521,31 +1524,31 @@ declare namespace relationalStore { * Indicates if there is a string primary key, the inserted will keep data's primary keys * otherwise it will keep the data's rowid. * - * @type { Array | Array } + * @type { Array | Array } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 10 */ - inserted: Array | Array; + inserted: Array | Array; /** * Indicates if there is a string primary key, the updated will keep data's primary keys * otherwise it will keep the data's rowid. * - * @type { Array | Array } + * @type { Array | Array } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 10 */ - updated: Array | Array; + updated: Array | Array; /** * Indicates if there is a string primary key, the deleted will keep data's primary keys * otherwise it will keep the data's rowid. * - * @type { Array | Array } + * @type { Array | Array } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 10 */ - deleted: Array | Array; + deleted: Array | Array; } /** @@ -1669,7 +1672,7 @@ declare namespace relationalStore { /** * Describes the conflict resolutions to insert data into the table. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since arkts {'1.1':'10', '1.2':'20'} @@ -1899,7 +1902,7 @@ declare namespace relationalStore { /** * Enumerates the type of rebuild. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 @@ -1943,7 +1946,7 @@ declare namespace relationalStore { /** * Enumerates the type of transaction. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 20 @@ -2038,7 +2041,7 @@ declare namespace relationalStore { /** * Enumerates the data types of a column. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since 18 @@ -2773,7 +2776,7 @@ declare namespace relationalStore { /** * Restricts the max number of return records. * - * @param { number } value - Indicates the max length of the return list. + * @param { int } value - Indicates the max length of the return list. * @returns { RdbPredicates } - The SQL query statement with the specified {@link RdbPredicates}. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -2782,7 +2785,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'10', '1.2':'20'} * @arkts 1.1&1.2 */ - limitAs(value: number): RdbPredicates; + limitAs(value: int): RdbPredicates; /** * Configure RdbPredicates to specify the start position of the returned result. @@ -2800,7 +2803,7 @@ declare namespace relationalStore { * Configure RdbPredicates to specify the start position of the returned result. * Use this method together with limit(number). * - * @param { number } rowOffset - Indicates the start position of the returned result. + * @param { int } rowOffset - Indicates the start position of the returned result. * The value is a positive integer. * @returns { RdbPredicates } - The SQL query statement with the specified {@link RdbPredicates}. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -2810,7 +2813,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'10', '1.2':'20'} * @arkts 1.1&1.2 */ - offsetAs(rowOffset: number): RdbPredicates; + offsetAs(rowOffset: int): RdbPredicates; /** * Configure RdbPredicates to group query results by specified columns. @@ -2885,11 +2888,26 @@ declare namespace relationalStore { *
2. Incorrect parameter types. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ in(field: string, value: Array): RdbPredicates; + /** + * Configure RdbPredicates to match the specified field whose data type is ValueType array and values + * are within a given range. + * + * @param { string } field - Indicates the column name in the database table. + * @param { Array } value - Indicates the values to match with {@link RdbPredicates}. + * @returns { RdbPredicates } - The SQL statement with the specified {@link RdbPredicates}. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + inValues(field: string, value: Array): RdbPredicates; + /** * Configure RdbPredicates to match the specified field whose data type is ValueType array and values * are out of a given range. @@ -2913,11 +2931,26 @@ declare namespace relationalStore { *
2. Incorrect parameter types. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ notIn(field: string, value: Array): RdbPredicates; + /** + * Configure RdbPredicates to match the specified field whose data type is ValueType array and values + * are out of a given range. + * + * @param { string } field - Indicates the column name in the database table. + * @param { Array } value - Indicates the values to match with {@link RdbPredicates}. + * @returns { RdbPredicates } - The SQL statement with the specified {@link RdbPredicates}. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + notInValues(field: string, value: Array): RdbPredicates; + /** * Sets the RdbPredicates to match the field whose data type is string and value * does not contain the specified value. @@ -3042,13 +3075,13 @@ declare namespace relationalStore { * The returned number is equal to the length of the string array returned by the * columnNames method. * - * @type { number } + * @type { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since arkts {'1.1':'10', '1.2':'20'} * @arkts 1.1&1.2 */ - columnCount: number; + columnCount: int; /** * Obtains the number of rows in the result set. @@ -3059,13 +3092,13 @@ declare namespace relationalStore { /** * Obtains the number of rows in the result set. * - * @type { number } + * @type { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since arkts {'1.1':'10', '1.2':'20'} * @arkts 1.1&1.2 */ - rowCount: number; + rowCount: int; /** * Obtains the current index of the result set. @@ -3078,13 +3111,13 @@ declare namespace relationalStore { * Obtains the current index of the result set. * The result set index starts from 0. * - * @type { number } + * @type { int } * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform * @since arkts {'1.1':'10', '1.2':'20'} * @arkts 1.1&1.2 */ - rowIndex: number; + rowIndex: int; /** * Checks whether the cursor is positioned at the first row. @@ -3198,7 +3231,7 @@ declare namespace relationalStore { * The column name is passed as an input parameter. * * @param { string } columnName - Indicates the name of the specified column in the result set. - * @returns { number } The index of the specified column. + * @returns { int } The index of the specified column. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -3226,7 +3259,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getColumnIndex(columnName: string): number; + getColumnIndex(columnName: string): int; /** * Obtains the column name based on the specified column index. @@ -3257,7 +3290,7 @@ declare namespace relationalStore { * Obtains the column name based on the specified column index. * The column index is passed as an input parameter. * - * @param { number } columnIndex - Indicates the index of the specified column in the result set. + * @param { int } columnIndex - Indicates the index of the specified column in the result set. * @returns { string } The name of the specified column. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -3286,13 +3319,13 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getColumnName(columnIndex: number): string; + getColumnName(columnIndex: int): string; /** * Obtains the column data type based on the specified column index. * The column index is passed as an input parameter. * - * @param { number | string } columnIdentifier - Index or name of the column. + * @param { int | string } columnIdentifier - Index or name of the column. * @returns { Promise } Promise used to return the data type obtained, * in an {@link ColumnType} instance. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -3322,12 +3355,12 @@ declare namespace relationalStore { * @crossplatform * @since 18 */ - getColumnType(columnIdentifier: number | string): Promise; + getColumnType(columnIdentifier: int | string): Promise; /** * Obtains the column data type based on the specified column index. This API returns the result synchronously. * - * @param { number | string } columnIdentifier - Index or name of the column. + * @param { int | string } columnIdentifier - Index or name of the column. * @returns { ColumnType } Column data type obtained. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -3356,7 +3389,7 @@ declare namespace relationalStore { * @crossplatform * @since 18 */ - getColumnTypeSync(columnIdentifier: number | string): ColumnType; + getColumnTypeSync(columnIdentifier: int | string): ColumnType; /** * Go to the specified row of the result set forwards or backwards by an offset relative to its current position. @@ -3389,7 +3422,7 @@ declare namespace relationalStore { * Go to the specified row of the result set forwards or backwards by an offset relative to its current position. * A positive offset indicates moving backwards, and a negative offset indicates moving forwards. * - * @param { number } offset - Indicates the offset relative to the current position. + * @param { int } offset - Indicates the offset relative to the current position. * @returns { boolean } True if the result set is moved successfully and does not go beyond the range; * Returns false otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -3419,7 +3452,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - goTo(offset: number): boolean; + goTo(offset: int): boolean; /** * Go to the specified row of the result set. @@ -3447,7 +3480,7 @@ declare namespace relationalStore { /** * Go to the specified row of the result set. * - * @param { number } position - Indicates the index of the specified row, which starts from 0. + * @param { int } position - Indicates the index of the specified row, which starts from 0. * @returns { boolean } True if the result set is moved successfully; Returns false otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -3476,7 +3509,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - goToRow(position: number): boolean; + goToRow(position: int): boolean; /** * Go to the first row of the result set. @@ -3714,7 +3747,7 @@ declare namespace relationalStore { * The implementation class determines whether to throw an exception if the value of the specified column * in the current row is null or the specified column is not of the Blob type. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. * @returns { Uint8Array } The value of the specified column as a byte array. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -3743,7 +3776,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getBlob(columnIndex: number): Uint8Array; + getBlob(columnIndex: int): Uint8Array; /** * Obtains the value of the specified column in the current row as string. @@ -3777,7 +3810,7 @@ declare namespace relationalStore { * The implementation class determines whether to throw an exception if the value of the specified column * in the current row is null or the specified column is not of the string type. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. * @returns { string } The value of the specified column as a string. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -3806,7 +3839,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getString(columnIndex: number): string; + getString(columnIndex: int): string; /** * Obtains the value of the specified column in the current row as long. @@ -3840,8 +3873,8 @@ declare namespace relationalStore { * The implementation class determines whether to throw an exception if the value of the specified column * in the current row is null, the specified column is not of the integer type. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. - * @returns { number } The value of the specified column as a long. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. + * @returns { long } The value of the specified column as a long. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -3869,7 +3902,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getLong(columnIndex: number): number; + getLong(columnIndex: int): long; /** * Obtains the value of the specified column in the current row as double. @@ -3903,8 +3936,8 @@ declare namespace relationalStore { * The implementation class determines whether to throw an exception if the value of the specified column * in the current row is null, the specified column is not of the double type. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. - * @returns { number } The value of the specified column as a double. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. + * @returns { double } The value of the specified column as a double. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -3932,7 +3965,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getDouble(columnIndex: number): number; + getDouble(columnIndex: int): double; /** * Obtains the value of the specified column in the current row as an asset. @@ -3953,7 +3986,7 @@ declare namespace relationalStore { * The implementation class determines whether to throw an exception if the value of the specified column * in the current row is null or the specified column is not of the Asset type. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. * @returns { Asset } The value of the specified column as an asset. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -3982,7 +4015,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getAsset(columnIndex: number): Asset; + getAsset(columnIndex: int): Asset; /** * Obtains the value of the specified column in the current row as assets. @@ -4003,7 +4036,7 @@ declare namespace relationalStore { * The implementation class determines whether to throw an exception if the value of the specified column * in the current row is null or the specified column is not of the Assets type. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. * @returns { Assets } The value of the specified column as assets. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -4032,7 +4065,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getAssets(columnIndex: number): Assets; + getAssets(columnIndex: int): Assets; /** * Obtains the value of the specified column in the current row. @@ -4107,7 +4140,7 @@ declare namespace relationalStore { * Inserting an empty blob, after API14 and API14, the obtained value is an empty blob; Before API 14, * the obtained value was null. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. * @returns { ValueType } The value of the specified column. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -4136,7 +4169,7 @@ declare namespace relationalStore { * @since 20 * @arkts 1.1&1.2 */ - getValue(columnIndex: number): ValueType; + getValue(columnIndex: int): ValueType; /** * Obtains the value of the specified column in the current row. @@ -4169,7 +4202,7 @@ declare namespace relationalStore { * The implementation class determines whether to throw an exception if the value of the specified column * in the current row is null or the specified column is not of the float array type. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. * @returns { Float32Array } The value of the specified column as a float array. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -4197,7 +4230,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - getFloat32Array(columnIndex: number): Float32Array; + getFloat32Array(columnIndex: int): Float32Array; /** * Obtains the values of all columns in the specified row. @@ -4294,8 +4327,8 @@ declare namespace relationalStore { /** * Obtains the values of all columns in the specified rows. - * @param { number } maxCount - Indicates the maximum number of rows. - * @param { number } position - Indicates the start position to obtain the values. + * @param { int } maxCount - Indicates the maximum number of rows. + * @param { int } [position] - Indicates the start position to obtain the values. * @returns { Promise> } Promise used to return the values obtained, * in an {@link Array}. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -4321,7 +4354,7 @@ declare namespace relationalStore { * @crossplatform * @since 18 */ - getRows(maxCount: number, position?: number): Promise>; + getRows(maxCount: int, position?: int): Promise>; /** * Obtains the values of all columns in the specified row. @@ -4381,7 +4414,7 @@ declare namespace relationalStore { /** * Checks whether the value of the specified column in the current row is null. * - * @param { number } columnIndex - Indicates the specified column index, which starts from 0. + * @param { int } columnIndex - Indicates the specified column index, which starts from 0. * @returns { boolean } True if the value of the specified column in the current row is null; * Returns false otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -4411,7 +4444,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - isColumnNull(columnIndex: number): boolean; + isColumnNull(columnIndex: int): boolean; /** * Closes the result set. @@ -4486,7 +4519,7 @@ declare namespace relationalStore { * Set RdbStore version. The version number must be an integer greater than 0. * Obtains the RdbStore version. * - * @type { number } + * @type { int } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 801 - Capability not supported. @@ -4508,7 +4541,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - version: number; + version: int; /** * Set whether the database is rebuilt. @@ -4661,7 +4694,7 @@ declare namespace relationalStore { * * @param { string } table - Indicates the target table. * @param { ValuesBucket } values - Indicates the row of data {@link ValuesBucket} to be inserted into the table. - * @returns { Promise } The row ID if the operation is successful. return -1 otherwise. + * @returns { Promise } The row ID if the operation is successful. return -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -4689,7 +4722,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - insert(table: string, values: ValuesBucket): Promise; + insert(table: string, values: ValuesBucket): Promise; /** * Inserts a row of data into the target table. @@ -4712,7 +4745,7 @@ declare namespace relationalStore { * @param { string } table - Indicates the target table. * @param { ValuesBucket } values - Indicates the row of data {@link ValuesBucket} to be inserted into the table. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { Promise } The row ID if the operation is successful. return -1 otherwise. + * @returns { Promise } The row ID if the operation is successful. return -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -4740,7 +4773,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - insert(table: string, values: ValuesBucket, conflict: ConflictResolution): Promise; + insert(table: string, values: ValuesBucket, conflict: ConflictResolution): Promise; /** * Inserts a row of data into the target table with sync interface. @@ -4748,7 +4781,7 @@ declare namespace relationalStore { * @param { string } table - Indicates the target table. * @param { ValuesBucket } values - Indicates the row of data {@link ValuesBucket} to be inserted into the table. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { number } The row ID if the operation is successful. return -1 otherwise. + * @returns { long } The row ID if the operation is successful. return -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -4773,9 +4806,10 @@ declare namespace relationalStore { * @throws { BusinessError } 14800047 - The WAL file size exceeds the default limit. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - insertSync(table: string, values: ValuesBucket, conflict?: ConflictResolution): number; + insertSync(table: string, values: ValuesBucket, conflict?: ConflictResolution): long; /** * Inserts a row of data into the target table with sync interface. @@ -4914,7 +4948,7 @@ declare namespace relationalStore { * @param { string } table - Indicates the target table. * @param { Array } values - * Indicates the rows of data {@link ValuesBucket} to be inserted into the table. - * @returns { Promise } The number of values that were inserted if the operation is successful. + * @returns { Promise } The number of values that were inserted if the operation is successful. * returns -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -4943,7 +4977,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - batchInsert(table: string, values: Array): Promise; + batchInsert(table: string, values: Array): Promise; /** * Inserts a batch of data into the target table. @@ -4951,7 +4985,7 @@ declare namespace relationalStore { * @param { string } table - Indicates the target table. * @param { Array } values - * Indicates the rows of data {@link ValuesBucket} to be inserted into the table. - * @returns { number } The number of values that were inserted if the operation is successful. returns -1 otherwise. + * @returns { long } The number of values that were inserted if the operation is successful. returns -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -4979,7 +5013,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - batchInsertSync(table: string, values: Array): number; + batchInsertSync(table: string, values: Array): long; /** * Inserts a batch of data into the target table. @@ -4988,7 +5022,7 @@ declare namespace relationalStore { * @param { Array } values - * Indicates the rows of data {@link ValuesBucket} to be inserted into the table. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { Promise } The number of values that were inserted if the operation is successful. + * @returns { Promise } The number of values that were inserted if the operation is successful. * returns -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -5016,7 +5050,7 @@ declare namespace relationalStore { * @crossplatform * @since 18 */ - batchInsertWithConflictResolution(table: string, values: Array, conflict: ConflictResolution): Promise; + batchInsertWithConflictResolution(table: string, values: Array, conflict: ConflictResolution): Promise; /** * Inserts a batch of data into the target table. @@ -5024,7 +5058,8 @@ declare namespace relationalStore { * @param { string } table - Indicates the target table. * @param { Array } values - * Indicates the rows of data {@link ValuesBucket} to be inserted into the table. - * @returns { number } The number of values that were inserted if the operation is successful. returns -1 otherwise. + * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. + * @returns { long } The number of values that were inserted if the operation is successful. returns -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -5051,7 +5086,7 @@ declare namespace relationalStore { * @crossplatform * @since 18 */ - batchInsertWithConflictResolutionSync(table: string, values: Array, conflict: ConflictResolution): number; + batchInsertWithConflictResolutionSync(table: string, values: Array, conflict: ConflictResolution): long; /** * Updates data in the database based on a specified instance object of RdbPredicates. @@ -5215,7 +5250,7 @@ declare namespace relationalStore { * The key-value pairs are associated with column names of the database table. * @param { RdbPredicates } predicates - * Indicates the specified update condition by the instance object of {@link RdbPredicates}. - * @returns { Promise } The number of affected rows. + * @returns { Promise } The number of affected rows. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -5243,7 +5278,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - update(values: ValuesBucket, predicates: RdbPredicates): Promise; + update(values: ValuesBucket, predicates: RdbPredicates): Promise; /** * Updates data in the database based on a specified instance object of RdbPredicates. @@ -5270,7 +5305,7 @@ declare namespace relationalStore { * @param { RdbPredicates } predicates - * Indicates the specified update condition by the instance object of {@link RdbPredicates}. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { Promise } The number of affected rows. + * @returns { Promise } The number of affected rows. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -5298,7 +5333,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - update(values: ValuesBucket, predicates: RdbPredicates, conflict: ConflictResolution): Promise; + update(values: ValuesBucket, predicates: RdbPredicates, conflict: ConflictResolution): Promise; /** * Updates data in the database based on a specified instance object of RdbPredicates with sync interface. @@ -5308,7 +5343,7 @@ declare namespace relationalStore { * @param { RdbPredicates } predicates - * Indicates the specified update condition by the instance object of {@link RdbPredicates}. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { number } The number of affected rows. + * @returns { long } The number of affected rows. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -5333,9 +5368,10 @@ declare namespace relationalStore { * @throws { BusinessError } 14800047 - The WAL file size exceeds the default limit. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - updateSync(values: ValuesBucket, predicates: RdbPredicates, conflict?: ConflictResolution): number; + updateSync(values: ValuesBucket, predicates: RdbPredicates, conflict?: ConflictResolution): long; /** * Updates data in the database based on a specified instance object of RdbPredicates. @@ -5468,7 +5504,7 @@ declare namespace relationalStore { * The key-value pairs are associated with column names of the database table. * @param { dataSharePredicates.DataSharePredicates } predicates - Indicates the specified update condition by * the instance object of {@link dataSharePredicates.DataSharePredicates}. - * @returns { Promise } The number of affected rows. + * @returns { Promise } The number of affected rows. * @throws { BusinessError } 202 - Permission verification failed, * application which is not a system application uses system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -5499,7 +5535,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - update(table: string, values: ValuesBucket, predicates: dataSharePredicates.DataSharePredicates): Promise; + update(table: string, values: ValuesBucket, predicates: dataSharePredicates.DataSharePredicates): Promise; /** * Deletes data from the database based on a specified instance object of RdbPredicates. @@ -5592,7 +5628,7 @@ declare namespace relationalStore { * * @param { RdbPredicates } predicates - * The specified delete condition by the instance object of {@link RdbPredicates}. - * @returns { Promise } return the number of affected rows. + * @returns { Promise } return the number of affected rows. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -5620,14 +5656,14 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - delete(predicates: RdbPredicates): Promise; + delete(predicates: RdbPredicates): Promise; /** * Deletes data from the database based on a specified instance object of RdbPredicates with sync interface. * * @param { RdbPredicates } predicates - * The specified delete condition by the instance object of {@link RdbPredicates}. - * @returns { number } return the number of rows deleted. + * @returns { long } return the number of rows deleted. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -5655,7 +5691,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - deleteSync(predicates: RdbPredicates): number; + deleteSync(predicates: RdbPredicates): long; /** * Deletes data from the database based on a specified instance object of RdbPredicates. * @@ -5770,7 +5806,7 @@ declare namespace relationalStore { * @param { string } table - Indicates the target table. * @param { dataSharePredicates.DataSharePredicates } predicates - * The specified delete condition by the instance object of {@link dataSharePredicates.DataSharePredicates}. - * @returns { Promise } The number of affected rows. + * @returns { Promise } The number of affected rows. * @throws { BusinessError } 202 - Permission verification failed, * application which is not a system application uses system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -5801,7 +5837,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - delete(table: string, predicates: dataSharePredicates.DataSharePredicates): Promise; + delete(table: string, predicates: dataSharePredicates.DataSharePredicates): Promise; /** * Queries data in the database based on specified conditions. @@ -6048,7 +6084,8 @@ declare namespace relationalStore { * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @systemapi * @StageModelOnly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ query( table: string, @@ -6452,7 +6489,7 @@ declare namespace relationalStore { * otherwise clean all. * * @param { string } table - Indicates the name of the table to check. - * @param { number } [cursor] - Indicates the cursor. + * @param { long } [cursor] - Indicates the cursor. * @returns { Promise } -The promise returned by the function. * @throws { BusinessError } 401 - Parameter error. Possible causes: * 1. Need 1 - 3 parameter(s)! 2. The RdbStore must be not nullptr. @@ -6480,7 +6517,7 @@ declare namespace relationalStore { * @syscap SystemCapability.DistributedDataManager.CloudSync.Client * @since 12 */ - cleanDirtyData(table: string, cursor?: number): Promise; + cleanDirtyData(table: string, cursor?: long): Promise; /** * Obtains sharing resource of rows corresponding to the predicates. @@ -6885,8 +6922,7 @@ declare namespace relationalStore { * @throws { BusinessError } 14800034 - SQLite: Library used incorrectly. * @throws { BusinessError } 14800047 - The WAL file size exceeds the default limit. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ execute(sql: string, txId: number, args?: Array): Promise; @@ -7709,8 +7745,8 @@ declare namespace relationalStore { * @param { SyncMode } mode - Indicates the database synchronization mode. * @param { RdbPredicates } predicates - * The specified sync condition by the instance object of {@link RdbPredicates}. - * @returns { Promise> } - * {Array<[string, number]>}: devices sync status array, {string}: device id, {number}: device sync status. + * @returns { Promise> } + * {Array<[string, int]>}: devices sync status array, {string}: device id, {number}: device sync status. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 801 - Capability not supported. @@ -7719,7 +7755,7 @@ declare namespace relationalStore { * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 12 */ - sync(mode: SyncMode, predicates: RdbPredicates): Promise>; + sync(mode: SyncMode, predicates: RdbPredicates): Promise>; /** * Sync data to cloud. @@ -8448,8 +8484,8 @@ declare namespace relationalStore { * * @param { string } fullPath - Indicates the path of the database file to attach. * @param { string } attachName - Indicates the alias of the database. - * @param { number } waitTime - Indicates the maximum time allowed for attaching the database file. - * @returns { Promise } Promise used to return the number of attached databases. + * @param { long } waitTime - Indicates the maximum time allowed for attaching the database file. + * @returns { Promise } Promise used to return the number of attached databases. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 801 - Capability not supported. @@ -8477,7 +8513,7 @@ declare namespace relationalStore { * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 12 */ - attach(fullPath: string, attachName: string, waitTime?: number) : Promise; + attach(fullPath: string, attachName: string, waitTime?: long) : Promise; /** * Attaches a database file to the currently linked database. @@ -8486,8 +8522,8 @@ declare namespace relationalStore { * @param { StoreConfig } config - * Indicates the {@link StoreConfig} configuration of the database related to this RDB store. * @param { string } attachName - Indicates the alias of the database. - * @param { number } waitTime - Indicates the maximum time allowed for attaching the database file. - * @returns { Promise } Promise used to return the number of attached databases. + * @param { long } waitTime - Indicates the maximum time allowed for attaching the database file. + * @returns { Promise } Promise used to return the number of attached databases. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 801 - Capability not supported. @@ -8517,14 +8553,14 @@ declare namespace relationalStore { * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 12 */ - attach(context: Context, config: StoreConfig, attachName: string, waitTime?: number) : Promise; + attach(context: Context, config: StoreConfig, attachName: string, waitTime?: long) : Promise; /** * Detaches a database from this database. * * @param { string } attachName - Indicates the alias of the database. - * @param { number } waitTime - Indicates the maximum time allowed for detaching the database. - * @returns { Promise } Return the current number of attached databases. + * @param { long } waitTime - Indicates the maximum time allowed for detaching the database. + * @returns { Promise } Return the current number of attached databases. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -8549,7 +8585,7 @@ declare namespace relationalStore { * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @since 12 */ - detach(attachName: string, waitTime?: number) : Promise; + detach(attachName: string, waitTime?: long) : Promise; /** * Locks data from the database based on a specified instance object of RdbPredicates. @@ -8656,14 +8692,15 @@ declare namespace relationalStore { /** * Lock cloud container before non-auto cloud sync. * - * @returns { Promise } The expired time of the lock. + * @returns { Promise } The expired time of the lock. * @throws { BusinessError } 202 - Permission verification failed, * application which is not a system application uses system API. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - lockCloudContainer(): Promise; + lockCloudContainer(): Promise; /** * Unlock cloud container. @@ -8783,7 +8820,7 @@ declare namespace relationalStore { * @param { string } table - Indicates the target table. * @param { ValuesBucket } values - Indicates the row of data {@link ValuesBucket} to be inserted into the table. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { Promise } The row ID if the operation is successful. return -1 otherwise. + * @returns { Promise } The row ID if the operation is successful. return -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -8806,7 +8843,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - insert(table: string, values: ValuesBucket, conflict?: ConflictResolution): Promise; + insert(table: string, values: ValuesBucket, conflict?: ConflictResolution): Promise; /** * Inserts a row of data into the target table with sync interface, just use in TaskPool or Worker. @@ -8838,13 +8875,44 @@ declare namespace relationalStore { */ insertSync(table: string, values: ValuesBucket | sendableRelationalStore.ValuesBucket, conflict?: ConflictResolution): number; + /** + * Inserts a row of data into the target table with sync interface, just use in TaskPool or Worker. + * + * @param { string } table - Indicates the target table. + * @param { ValuesBucket } values - Indicates the row of data {@link ValuesBucket} to be inserted into the table. + * @param { ConflictResolution } [conflict] - Indicates the {@link ConflictResolution} to insert data into the table. + * @returns { long } The row ID if the operation is successful. return -1 otherwise. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @throws { BusinessError } 14800000 - Inner error. + * @throws { BusinessError } 14800011 - Failed to open the database because it is corrupted. + * @throws { BusinessError } 14800014 - The RdbStore or ResultSet is already closed. + * @throws { BusinessError } 14800021 - SQLite: Generic error. + * Possible causes: Insert failed or the updated data does not exist. + * @throws { BusinessError } 14800023 - SQLite: Access permission denied. + * @throws { BusinessError } 14800024 - SQLite: The database file is locked. + * @throws { BusinessError } 14800025 - SQLite: A table in the database is locked. + * @throws { BusinessError } 14800026 - SQLite: The database is out of memory. + * @throws { BusinessError } 14800027 - SQLite: Attempt to write a readonly database. + * @throws { BusinessError } 14800028 - SQLite: Some kind of disk I/O error occurred. + * @throws { BusinessError } 14800029 - SQLite: The database is full. + * @throws { BusinessError } 14800031 - SQLite: TEXT or BLOB exceeds size limit. + * @throws { BusinessError } 14800033 - SQLite: Data type mismatch. + * @throws { BusinessError } 14800047 - The WAL file size exceeds the default limit. + * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + insertSync(table: string, values: ValuesBucket, conflict?: ConflictResolution): long; + /** * Inserts a batch of data into the target table. * * @param { string } table - Indicates the target table. * @param { Array } values - * Indicates the rows of data {@link ValuesBucket} to be inserted into the table. - * @returns { Promise } The number of values that were inserted if the operation is successful. + * @returns { Promise } The number of values that were inserted if the operation is successful. * returns -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -8868,7 +8936,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - batchInsert(table: string, values: Array): Promise; + batchInsert(table: string, values: Array): Promise; /** * Inserts a batch of data into the target table. @@ -8876,7 +8944,7 @@ declare namespace relationalStore { * @param { string } table - Indicates the target table. * @param { Array } values - * Indicates the rows of data {@link ValuesBucket} to be inserted into the table. - * @returns { number } The number of values that were inserted if the operation is successful. returns -1 otherwise. + * @returns { long } The number of values that were inserted if the operation is successful. returns -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -8896,9 +8964,10 @@ declare namespace relationalStore { * @throws { BusinessError } 14800047 - The WAL file size exceeds the default limit. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ - batchInsertSync(table: string, values: Array): number; + batchInsertSync(table: string, values: Array): long; /** * Inserts a batch of data into the target table. @@ -8907,7 +8976,7 @@ declare namespace relationalStore { * @param { Array } values - * Indicates the rows of data {@link ValuesBucket} to be inserted into the table. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { Promise } The number of values that were inserted if the operation is successful. + * @returns { Promise } The number of values that were inserted if the operation is successful. * returns -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -8933,7 +9002,7 @@ declare namespace relationalStore { * @crossplatform * @since 18 */ - batchInsertWithConflictResolution(table: string, values: Array, conflict: ConflictResolution): Promise; + batchInsertWithConflictResolution(table: string, values: Array, conflict: ConflictResolution): Promise; /** * Inserts a batch of data into the target table. @@ -8942,7 +9011,7 @@ declare namespace relationalStore { * @param { Array } values - * Indicates the rows of data {@link ValuesBucket} to be inserted into the table. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { number } The number of values that were inserted if the operation is successful. returns -1 otherwise. + * @returns { long } The number of values that were inserted if the operation is successful. returns -1 otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -8967,7 +9036,7 @@ declare namespace relationalStore { * @crossplatform * @since 18 */ - batchInsertWithConflictResolutionSync(table: string, values: Array, conflict: ConflictResolution): number; + batchInsertWithConflictResolutionSync(table: string, values: Array, conflict: ConflictResolution): long; /** * Updates data in the database based on a specified instance object of RdbPredicates. @@ -8977,7 +9046,7 @@ declare namespace relationalStore { * @param { RdbPredicates } predicates - * Indicates the specified update condition by the instance object of {@link RdbPredicates}. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { Promise } The number of affected rows. + * @returns { Promise } The number of affected rows. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -9000,7 +9069,7 @@ declare namespace relationalStore { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - update(values: ValuesBucket, predicates: RdbPredicates, conflict?: ConflictResolution): Promise; + update(values: ValuesBucket, predicates: RdbPredicates, conflict?: ConflictResolution): Promise; /** * Updates data in the database based on a specified instance object of RdbPredicates with sync interface. @@ -9010,7 +9079,7 @@ declare namespace relationalStore { * @param { RdbPredicates } predicates - * Indicates the specified update condition by the instance object of {@link RdbPredicates}. * @param { ConflictResolution } conflict - Indicates the {@link ConflictResolution} to insert data into the table. - * @returns { number } The number of affected rows. + * @returns { long } The number of affected rows. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -9030,16 +9099,17 @@ declare namespace relationalStore { * @throws { BusinessError } 14800047 - The WAL file size exceeds the default limit. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ - updateSync(values: ValuesBucket, predicates: RdbPredicates, conflict?: ConflictResolution): number; + updateSync(values: ValuesBucket, predicates: RdbPredicates, conflict?: ConflictResolution): long; /** * Deletes data from the database based on a specified instance object of RdbPredicates. * * @param { RdbPredicates } predicates - * The specified delete condition by the instance object of {@link RdbPredicates}. - * @returns { Promise } return the number of affected rows. + * @returns { Promise } return the number of affected rows. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -9062,14 +9132,14 @@ declare namespace relationalStore { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - delete(predicates: RdbPredicates): Promise; + delete(predicates: RdbPredicates): Promise; /** * Deletes data from the database based on a specified instance object of RdbPredicates with sync interface. * * @param { RdbPredicates } predicates - * The specified delete condition by the instance object of {@link RdbPredicates}. - * @returns { number } return the number of rows deleted. + * @returns { long } return the number of rows deleted. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 14800000 - Inner error. @@ -9089,9 +9159,10 @@ declare namespace relationalStore { * @throws { BusinessError } 14800047 - The WAL file size exceeds the default limit. * @syscap SystemCapability.DistributedDataManager.RelationalStore.Core * @crossplatform - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ - deleteSync(predicates: RdbPredicates): number; + deleteSync(predicates: RdbPredicates): long; /** * Queries data in the database based on specified conditions. diff --git a/api/@ohos.deviceInfo.d.ets b/api/@ohos.deviceInfo.d.ets index 0297a224dab9f5f109e7db8542df94f230ee6e1d..e23c3aaf8a6e29c3369005ad8cfa12860fa46cc7 100644 --- a/api/@ohos.deviceInfo.d.ets +++ b/api/@ohos.deviceInfo.d.ets @@ -481,7 +481,7 @@ declare class deviceInfo { * * @syscap SystemCapability.Startup.SystemInfo * @crossplatform - * @since 20 + * @since 21 * @arkts 1.2 */ static get sdkMinorApiVersion(): int; @@ -491,7 +491,7 @@ declare class deviceInfo { * * @syscap SystemCapability.Startup.SystemInfo * @crossplatform - * @since 20 + * @since 21 * @arkts 1.2 */ static get sdkPatchApiVersion(): int; diff --git a/api/@ohos.display.d.ts b/api/@ohos.display.d.ts index d4f7b43605de8bdf4c0da0a61c0bc43b598ffc6b..cbd6182e2ff6a14f00c5966b95791ed17678812c 100644 --- a/api/@ohos.display.d.ts +++ b/api/@ohos.display.d.ts @@ -98,11 +98,12 @@ declare namespace display { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - export function getDefaultDisplaySync(): Display; + function getDefaultDisplaySync(): Display; /** * Obtain the primary display. For devices other than 2in1 devices, the Display object obtained is the built-in screen. - * For 2in1 devices with an external screen, the Display object obtained is the primary screen. For 2in1 devices without an external screen, the Display object obtained is the built-in screen. + * For 2in1 devices with an external screen, the Display object obtained is the primary screen. + * For 2in1 devices without an external screen, the Display object obtained is the built-in screen. * * @returns { Display } the result of primary display * @throws { BusinessError } 1400001 - Invalid display or screen. @@ -116,7 +117,7 @@ declare namespace display { /** * Obtain the target display. * - * @param { number } displayId Display id to query. This parameter should be greater than or equal to 0. + * @param { long } displayId Display id to query. This parameter should be greater than or equal to 0. * @returns { Display } the result of display * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. * 2. Incorrect parameter types. @@ -127,7 +128,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export function getDisplayByIdSync(displayId: number): Display; + function getDisplayByIdSync(displayId: long): Display; /** * Obtain all displays. @@ -138,7 +139,7 @@ declare namespace display { * @deprecated since 9 * @useinstead ohos.display#getAllDisplays */ - export function getAllDisplay(callback: AsyncCallback>): void; + function getAllDisplay(callback: AsyncCallback>): void; /** * Obtain all displays. @@ -169,7 +170,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export function getAllDisplays(callback: AsyncCallback>): void; + function getAllDisplays(callback: AsyncCallback>): void; /** * Obtain all displays. @@ -201,12 +202,12 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export function getAllDisplayPhysicalResolution(): Promise>; + function getAllDisplayPhysicalResolution(): Promise>; /** * Check whether there is a privacy window on the current display. * - * @param { number } displayId Display id to query. This parameter should be greater than or equal to 0. + * @param { long } displayId Display id to query. This parameter should be greater than or equal to 0. * @returns { boolean } true means there is a privacy window on the current display * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. @@ -217,13 +218,13 @@ declare namespace display { * @since arkts {'1.1':'9', '1.2':'20'} * @arkts 1.1&1.2 */ - export function hasPrivateWindow(displayId: number): boolean; + function hasPrivateWindow(displayId: long): boolean; /** * Register the callback for display changes. * * @param { 'add' | 'remove' | 'change' } type the event of display change - * @param { Callback } callback the display id of changed + * @param { Callback } callback the display id of changed * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. * @syscap SystemCapability.WindowManager.WindowManager.Core @@ -233,7 +234,7 @@ declare namespace display { * Register the callback for display changes. * * @param { 'add' | 'remove' | 'change' } type the event of display change - * @param { Callback } callback the display id of changed + * @param { Callback } callback the display id of changed * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. * @syscap SystemCapability.WindowManager.WindowManager.Core @@ -244,22 +245,22 @@ declare namespace display { * Register the callback for display changes. * * @param { 'add' | 'remove' | 'change' } type the event of display change - * @param { Callback } callback the display id of changed + * @param { Callback } callback the display id of changed * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - export function on(type: 'add' | 'remove' | 'change', callback: Callback): void; + function on(type: 'add' | 'remove' | 'change', callback: Callback): void; /** * Unregister the callback for display changes. * * @param { 'add' | 'remove' | 'change' } type the event of display change event - * @param { Callback } callback the display id of changed + * @param { Callback } callback the display id of changed * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. * @syscap SystemCapability.WindowManager.WindowManager.Core @@ -269,7 +270,7 @@ declare namespace display { * Unregister the callback for display changes. * * @param { 'add' | 'remove' | 'change' } type the event of display change event - * @param { Callback } callback the display id of changed + * @param { Callback } callback the display id of changed * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. * @syscap SystemCapability.WindowManager.WindowManager.Core @@ -280,16 +281,16 @@ declare namespace display { * Unregister the callback for display changes. * * @param { 'add' | 'remove' | 'change' } type the event of display change event - * @param { Callback } callback the display id of changed + * @param { Callback } callback the display id of changed * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - export function off(type: 'add' | 'remove' | 'change', callback?: Callback): void; + function off(type: 'add' | 'remove' | 'change', callback?: Callback): void; /** * Register the callback for private mode changes. @@ -304,7 +305,7 @@ declare namespace display { * @since arkts {'1.1':'10', '1.2':'20'} * @arkts 1.1&1.2 */ - export function on(type: 'privateModeChange', callback: Callback): void; + function on(type: 'privateModeChange', callback: Callback): void; /** * Unregister the callback for private mode changes. @@ -319,7 +320,7 @@ declare namespace display { * @since arkts {'1.1':'10', '1.2':'20'} * @arkts 1.1&1.2 */ - export function off(type: 'privateModeChange', callback?: Callback): void; + function off(type: 'privateModeChange', callback?: Callback): void; /** * Check whether the device is foldable. @@ -346,10 +347,10 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - export function isFoldable(): boolean; + function isFoldable(): boolean; /** * Get the current fold status of the foldable device. @@ -376,10 +377,10 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - export function getFoldStatus(): FoldStatus; + function getFoldStatus(): FoldStatus; /** * Register the callback for fold status changes. @@ -415,10 +416,10 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - export function on(type: 'foldStatusChange', callback: Callback): void; + function on(type: 'foldStatusChange', callback: Callback): void; /** * Unregister the callback for fold status changes. @@ -454,40 +455,66 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - export function off(type: 'foldStatusChange', callback?: Callback): void; + function off(type: 'foldStatusChange', callback?: Callback): void; /** * Register the callback for fold angle changes. * * @param { 'foldAngleChange' } type the event of fold angle changes. - * @param { Callback> } callback Callback used to return the current fold angle of device. + * @param { Callback> } callback Callback used to return the current fold angle of device. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. - *
2. Incorrect parameter types. + * 2. Incorrect parameter types. * @throws { BusinessError } 1400003 - This display manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} + * @since 12 + */ + /** + * Register the callback for fold angle changes. + * + * @param { 'foldAngleChange' } type the event of fold angle changes. + * @param { Callback> } callback Callback used to return the current fold angle of device. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. + * 2. Incorrect parameter types. + * @throws { BusinessError } 1400003 - This display manager service works abnormally. + * @syscap SystemCapability.Window.SessionManager + * @crossplatform + * @atomicservice + * @since 20 * @arkts 1.1&1.2 */ - export function on(type: 'foldAngleChange', callback: Callback>): void; + function on(type: 'foldAngleChange', callback: Callback>): void; /** * Unregister the callback for fold angle changes. * * @param { 'foldAngleChange' } type the event of fold angle changes. - * @param { Callback> } callback Callback used to return the current fold angle of device. + * @param { Callback> } callback Callback used to return the current fold angle of device. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. - *
2. Incorrect parameter types. + * 2. Incorrect parameter types. * @throws { BusinessError } 1400003 - This display manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} + * @since 12 + */ + /** + * Unregister the callback for fold angle changes. + * + * @param { 'foldAngleChange' } type the event of fold angle changes. + * @param { Callback> } callback Callback used to return the current fold angle of device. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. + * 2. Incorrect parameter types. + * @throws { BusinessError } 1400003 - This display manager service works abnormally. + * @syscap SystemCapability.Window.SessionManager + * @crossplatform + * @atomicservice + * @since 20 * @arkts 1.1&1.2 */ - export function off(type: 'foldAngleChange', callback?: Callback>): void; + function off(type: 'foldAngleChange', callback?: Callback>): void; /** * Register the callback for device capture, casting, or recording status changes. @@ -502,7 +529,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export function on(type: 'captureStatusChange', callback: Callback): void; + function on(type: 'captureStatusChange', callback: Callback): void; /** * Unregister the callback for device capture, casting, or recording status changes. @@ -517,7 +544,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export function off(type: 'captureStatusChange', callback?: Callback): void; + function off(type: 'captureStatusChange', callback?: Callback): void; /** @@ -530,7 +557,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export function isCaptured(): boolean; + function isCaptured(): boolean; /** * Get the display mode of the foldable device. @@ -547,10 +574,20 @@ declare namespace display { * @throws { BusinessError } 1400003 - This display manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} + * @since 12 + */ + /** + * Get the display mode of the foldable device. + * + * @returns { FoldDisplayMode } display mode of the foldable device. + * @throws { BusinessError } 1400003 - This display manager service works abnormally. + * @syscap SystemCapability.Window.SessionManager + * @crossplatform + * @atomicservice + * @since 20 * @arkts 1.1&1.2 */ - export function getFoldDisplayMode(): FoldDisplayMode; + function getFoldDisplayMode(): FoldDisplayMode; /** * Change the display mode of the foldable device. @@ -565,7 +602,7 @@ declare namespace display { * @since arkts {'1.1':'10', '1.2':'20'} * @arkts 1.1&1.2 */ - export function setFoldDisplayMode(mode: FoldDisplayMode): void; + function setFoldDisplayMode(mode: FoldDisplayMode): void; /** * Change the display mode of the foldable device. @@ -579,7 +616,7 @@ declare namespace display { * @since arkts {'1.1':'19', '1.2':'20'} * @arkts 1.1&1.2 */ - export function setFoldDisplayMode(mode: FoldDisplayMode, reason: string): void; + function setFoldDisplayMode(mode: FoldDisplayMode, reason: string): void; /** * Register the callback for fold display mode changes. @@ -587,7 +624,7 @@ declare namespace display { * @param { 'foldDisplayModeChange' } type the event of fold display mode changes * @param { Callback } callback Callback used to return the current fold display mode * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. - *
2. Incorrect parameter types. + * 2. Incorrect parameter types. * @throws { BusinessError } 1400003 - This display manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @since 10 @@ -598,14 +635,27 @@ declare namespace display { * @param { 'foldDisplayModeChange' } type the event of fold display mode changes * @param { Callback } callback Callback used to return the current fold display mode * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. - *
2. Incorrect parameter types. + * 2. Incorrect parameter types. * @throws { BusinessError } 1400003 - This display manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} + * @since 12 + */ + /** + * Register the callback for fold display mode changes. + * + * @param { 'foldDisplayModeChange' } type the event of fold display mode changes + * @param { Callback } callback Callback used to return the current fold display mode + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. + * 2. Incorrect parameter types. + * @throws { BusinessError } 1400003 - This display manager service works abnormally. + * @syscap SystemCapability.Window.SessionManager + * @crossplatform + * @atomicservice + * @since 20 * @arkts 1.1&1.2 */ - export function on(type: 'foldDisplayModeChange', callback: Callback): void; + function on(type: 'foldDisplayModeChange', callback: Callback): void; /** * Unregister the callback for fold display mode changes. @@ -613,7 +663,7 @@ declare namespace display { * @param { 'foldDisplayModeChange' } type the event of fold display mode changes * @param { Callback } callback Callback used to return the current fold display mode * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. - *
2. Incorrect parameter types. + * 2. Incorrect parameter types. * @throws { BusinessError } 1400003 - This display manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @since 10 @@ -624,14 +674,27 @@ declare namespace display { * @param { 'foldDisplayModeChange' } type the event of fold display mode changes * @param { Callback } callback Callback used to return the current fold display mode * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. - *
2. Incorrect parameter types. + * 2. Incorrect parameter types. * @throws { BusinessError } 1400003 - This display manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} + * @since 12 + */ + /** + * Unregister the callback for fold display mode changes. + * + * @param { 'foldDisplayModeChange' } type the event of fold display mode changes + * @param { Callback } callback Callback used to return the current fold display mode + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. + * 2. Incorrect parameter types. + * @throws { BusinessError } 1400003 - This display manager service works abnormally. + * @syscap SystemCapability.Window.SessionManager + * @crossplatform + * @atomicservice + * @since 20 * @arkts 1.1&1.2 */ - export function off(type: 'foldDisplayModeChange', callback?: Callback): void; + function off(type: 'foldDisplayModeChange', callback?: Callback): void; /** * Get the fold crease region in the current display mode. @@ -651,7 +714,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export function getCurrentFoldCreaseRegion(): FoldCreaseRegion; + function getCurrentFoldCreaseRegion(): FoldCreaseRegion; /** * set fold status locked or not. @@ -666,14 +729,14 @@ declare namespace display { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - export function setFoldStatusLocked(locked: boolean): void; + function setFoldStatusLocked(locked: boolean): void; /** * Create virtual screen. * * @permission ohos.permission.ACCESS_VIRTUAL_SCREEN * @param { VirtualScreenConfig } config Indicates the options of the virtual screen. - * @returns { Promise } Promise used to return the created virtual screen id + * @returns { Promise } Promise used to return the created virtual screen id * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. @@ -682,13 +745,13 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @since 16 */ - function createVirtualScreen(config: VirtualScreenConfig): Promise; + function createVirtualScreen(config: VirtualScreenConfig): Promise; /** * Destroy virtual screen. * * @permission ohos.permission.ACCESS_VIRTUAL_SCREEN - * @param { number } screenId Indicates the screen id of the virtual screen. + * @param { long } screenId Indicates the screen id of the virtual screen. * @returns { Promise } Promise that returns no value. * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. @@ -699,13 +762,13 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @since 16 */ - function destroyVirtualScreen(screenId: number): Promise; + function destroyVirtualScreen(screenId: long): Promise; /** * Set surface for the virtual screen. * * @permission ohos.permission.ACCESS_VIRTUAL_SCREEN - * @param { number } screenId Indicates the screen id of the virtual screen. + * @param { long } screenId Indicates the screen id of the virtual screen. * @param { string } surfaceId Indicates the surface id. * @returns { Promise } Promise that returns no value * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API. @@ -717,13 +780,13 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @since 16 */ - function setVirtualScreenSurface(screenId: number, surfaceId: string): Promise; + function setVirtualScreenSurface(screenId: long, surfaceId: string): Promise; /** * Make screen as unique-screen * * @permission ohos.permission.ACCESS_VIRTUAL_SCREEN - * @param { number } screenId Indicates the unique screen id. It's type should be int. + * @param { long } screenId Indicates the unique screen id. It's type should be int. * @returns { Promise } Promise that returns no value * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. @@ -734,12 +797,13 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @since 16 */ - function makeUnique(screenId: number): Promise; + function makeUnique(screenId: long): Promise; /** * Add the list of window ids to the block list which won't display on the virtual screen * - * @param { Array } windowIds - The list of window ids that do not want to display on the virtual screen + * @param { Array } windowIds - The list of window ids that do not want to display on the virtual screen + * @returns { Promise } Promise that returns no value * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. 3. Parameter verification failed. @@ -749,12 +813,13 @@ declare namespace display { * @systemapi Hide this for inner system use. * @since 18 */ - function addVirtualScreenBlocklist(windowIds: Array): Promise; + function addVirtualScreenBlocklist(windowIds: Array): Promise; /** * Remove the list of window ids from the block list which won't display on the virtual screen * - * @param { Array } windowIds - The list of window ids that want to display on the virtual screen + * @param { Array } windowIds - The list of window ids that want to display on the virtual screen + * @returns { Promise } Promise that returns no value * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified. *
2. Incorrect parameter types. 3. Parameter verification failed. @@ -764,13 +829,13 @@ declare namespace display { * @systemapi Hide this for inner system use. * @since 18 */ - function removeVirtualScreenBlocklist(windowIds: Array): Promise; + function removeVirtualScreenBlocklist(windowIds: Array): Promise; /** * Convert global coordinates to relative coordinates. * * @param { Position } position - The global coordinates to be converted. - * @param { number } [displayId] - The optional display id indicate the display relative to. + * @param { long } [displayId] - The optional display id indicate the display relative to. * If not specified,use the display where the coodinates are located. * @returns { RelativePosition } The relative coordinates. * @throws { BusinessError } 801 - Capability not supported. @@ -780,7 +845,7 @@ declare namespace display { * @atomicservice * @since 20 */ - function convertGlobalToRelativeCoordinate(position: Position, displayId?: number): RelativePosition; + function convertGlobalToRelativeCoordinate(position: Position, displayId?: long): RelativePosition; /** * Convert relative coordinates to global coordinates. @@ -816,31 +881,31 @@ declare namespace display { /** * Indicates the width of the virtual screen. * - * @type { number } + * @type { long } * @syscap SystemCapability.Window.SessionManager * @since arkts {'1.1':'16', '1.2':'20'} * @arkts 1.1&1.2 */ - width: number; + width: long; /** * Indicates the height of the virtual screen. * - * @type { number } + * @type { long } * @syscap SystemCapability.Window.SessionManager * @since arkts {'1.1':'16', '1.2':'20'} * @arkts 1.1&1.2 */ - height: number; + height: long; /** * Indicates the density of the virtual screen. * - * @type { number } + * @type { double } * @syscap SystemCapability.Window.SessionManager * @since 16 */ - density: number; + density: double; /** * Indicates the surface id of the virtual screen. @@ -853,14 +918,16 @@ declare namespace display { } /** - * Enumerates the fold status. For dual-fold axis devices, when oriented with the charging port at the bottom, the hinges are identified from right to left as the first and second fold axes, respectively. + * Enumerates the fold status. For dual-fold axis devices, when oriented with the charging port at the bottom, + * the hinges are identified from right to left as the first and second fold axes, respectively. * * @enum { number } * @syscap SystemCapability.Window.SessionManager * @since 10 */ /** - * Enumerates the fold status.For dual-fold axis devices, when oriented with the charging port at the bottom, the hinges are identified from right to left as the first and second fold axes, respectively. + * Enumerates the fold status.For dual-fold axis devices, when oriented with the charging port at the bottom, + * the hinges are identified from right to left as the first and second fold axes, respectively. * * @enum { number } * @syscap SystemCapability.Window.SessionManager @@ -874,10 +941,10 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - export enum FoldStatus { + enum FoldStatus { /** * Fold Status Unknown. * @@ -897,7 +964,7 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ FOLD_STATUS_UNKNOWN = 0, @@ -920,7 +987,7 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ FOLD_STATUS_EXPANDED = 1, @@ -940,13 +1007,15 @@ declare namespace display { */ FOLD_STATUS_FOLDED = 2, /** - * Fold Status Half Folded, somehow between fully open and completely closed. For dual-fold axis devices, the first fold axis is half-folded, and the second fold axis is folded. + * Fold Status Half Folded, somehow between fully open and completely closed. + * For dual-fold axis devices, the first fold axis is half-folded, and the second fold axis is folded. * * @syscap SystemCapability.Window.SessionManager * @since 10 */ /** - * Fold Status Half Folded, somehow between fully open and completely closed. For dual-fold axis devices, the first fold axis is half-folded, and the second fold axis is folded. + * Fold Status Half Folded, somehow between fully open and completely closed. + * For dual-fold axis devices, the first fold axis is half-folded, and the second fold axis is folded. * * @syscap SystemCapability.Window.SessionManager * @atomicservice @@ -958,7 +1027,7 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ FOLD_STATUS_HALF_FOLDED = 3, @@ -1040,10 +1109,10 @@ declare namespace display { * @syscap SystemCapability.Window.SessionManager * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - export enum FoldDisplayMode { + enum FoldDisplayMode { /** * Unknown Display. * @@ -1137,7 +1206,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export enum DisplayState { + enum DisplayState { /** * Unknown. * @@ -1337,21 +1406,23 @@ declare namespace display { LANDSCAPE_INVERTED = 3 } - /** - * Indicate the source mode of the display - * - * @enum { number } - * @syscap SystemCapability.Window.SessionManager - * @atomicservice - * @since 19 - */ + /** + * Indicate the source mode of the display + * + * @enum { number } + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 + */ enum DisplaySourceMode { /** * Indicate that the display is not in use. * * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ NONE = 0, @@ -1360,7 +1431,8 @@ declare namespace display { * * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ MAIN = 1, @@ -1369,7 +1441,8 @@ declare namespace display { * * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ MIRROR = 2, @@ -1378,7 +1451,8 @@ declare namespace display { * * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ EXTEND = 3, @@ -1387,7 +1461,8 @@ declare namespace display { * * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ ALONE = 4 } @@ -1398,7 +1473,8 @@ declare namespace display { * @enum { number } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ enum ScreenShape { /** @@ -1406,7 +1482,8 @@ declare namespace display { * * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ RECTANGLE = 0, /** @@ -1414,7 +1491,8 @@ declare namespace display { * * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ ROUND = 1 } @@ -1435,11 +1513,11 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export interface FoldCreaseRegion { + interface FoldCreaseRegion { /** * The display ID is used to identify the screen where the crease is located. * - * @type { number } + * @type { long } * @readonly * @syscap SystemCapability.Window.SessionManager * @since 10 @@ -1447,14 +1525,14 @@ declare namespace display { /** * The display ID is used to identify the screen where the crease is located. * - * @type { number } + * @type { long } * @readonly * @syscap SystemCapability.Window.SessionManager * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - readonly displayId: number; + readonly displayId: long; /** * Crease Region. @@ -1497,74 +1575,74 @@ declare namespace display { /** * The X-axis coordinate of the upper left vertex of the rectangle, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 9 */ /** * The X-axis coordinate of the upper left vertex of the rectangle, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - left: number; + left: long; /** * The Y-axis coordinate of the upper left vertex of the rectangle, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 9 */ /** * The Y-axis coordinate of the upper left vertex of the rectangle, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - top: number; + top: long; /** * Width of the rectangle, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 9 */ /** * Width of the rectangle, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - width: number; + width: long; /** * Height of the rectangle, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 9 */ /** * Height of the rectangle, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - height: number; + height: long; } /** @@ -1583,7 +1661,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export interface WaterfallDisplayAreaRects { + interface WaterfallDisplayAreaRects { /** * Indicates the size of left side curved area of the waterfall screen. * @@ -1681,7 +1759,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export interface CutoutInfo { + interface CutoutInfo { /** * Bounding rectangles of the cutout areas of the display. * @@ -1733,7 +1811,7 @@ declare namespace display { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - export interface DisplayPhysicalResolution { + interface DisplayPhysicalResolution { /** * fold display mode. * @@ -1748,26 +1826,26 @@ declare namespace display { /** * Display physical width, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - physicalWidth: number; + physicalWidth: long; /** * Display physical height, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - physicalHeight: number; + physicalHeight: long; } /** @@ -1795,18 +1873,18 @@ declare namespace display { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - export interface Display { + interface Display { /** * Display ID. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * Display ID. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @since 10 @@ -1814,14 +1892,14 @@ declare namespace display { /** * Display ID. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - id: number; + id: long; /** * Display name. @@ -1880,25 +1958,25 @@ declare namespace display { /** * Refresh rate, in Hz. * - * @type { number } + * @type { int } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * Refresh rate, in Hz. * - * @type { number } + * @type { int } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - refreshRate: number; + refreshRate: int; /** * Rotation degrees of the display. * - * @type { number } + * @type { int } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ @@ -1909,25 +1987,25 @@ declare namespace display { * The value 2 indicates that the screen of the display rotates clockwise by 180°. * The value 3 indicates that the screen of the display rotates clockwise by 270°. * - * @type { number } + * @type { int } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - rotation: number; + rotation: int; /** * Display width, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * Display width, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @since 10 @@ -1935,26 +2013,26 @@ declare namespace display { /** * Display width, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - width: number; + width: long; /** * Display height, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * Display height, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @since 10 @@ -1962,50 +2040,50 @@ declare namespace display { /** * Display height, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - height: number; + height: long; /** * Display available width, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - availableWidth: number; + availableWidth: long; /** * Display available height, in pixels. * - * @type { number } + * @type { long } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - availableHeight: number; + availableHeight: long; /** * Display resolution, that is, the number of pixels per inch. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * Display resolution, that is, the number of pixels per inch. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @since 11 @@ -2013,14 +2091,14 @@ declare namespace display { /** * Display resolution, that is, the number of pixels per inch. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - densityDPI: number; + densityDPI: double; /** * Display orientation. @@ -2045,33 +2123,33 @@ declare namespace display { /** * Display density, in pixels. which is the scaling coefficient between physical pixels and logical pixels. The value for a low-resolution display is 1.0. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * Display density, in pixels. which is the scaling coefficient between physical pixels and logical pixels. The value for a low-resolution display is 1.0. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - densityPixels: number; + densityPixels: double; /** * Text scale density of the display. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * Text scale density of the display. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @since 11 @@ -2079,26 +2157,26 @@ declare namespace display { /** * Text scale density of the display. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - scaledDensity: number; + scaledDensity: double; /** * DPI on the x-axis. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * DPI on the x-axis. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since 12 @@ -2106,26 +2184,26 @@ declare namespace display { /** * DPI on the x-axis. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'20', '1.2':'20'} + * @since 20 * @arkts 1.1&1.2 */ - xDPI: number; + xDPI: double; /** * DPI on the y-axis. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @since 7 */ /** * DPI on the y-axis. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice * @since 12 @@ -2133,13 +2211,14 @@ declare namespace display { /** * DPI on the y-axis. * - * @type { number } + * @type { double } * @syscap SystemCapability.WindowManager.WindowManager.Core * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ - yDPI: number; + yDPI: double; /** * The shape of screen @@ -2147,7 +2226,8 @@ declare namespace display { * @type { ?ScreenShape } * @syscap SystemCapability.WindowManager.WindowManager.Core * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ screenShape?: ScreenShape; @@ -2191,39 +2271,43 @@ declare namespace display { * @type { ?DisplaySourceMode } * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ sourceMode?: DisplaySourceMode; /** * Coordinates of the top-left corner of the display relative to the main display. * - * @type { ?number } + * @type { ?long } * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ - x?: number; + x?: long; /** * Coordinates of the top-left corner of the display relative to the main display. * - * @type { ?number } + * @type { ?long } * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ - y?: number; + y?: long; /** * All supported refresh rates. * - * @type { ?Array } + * @type { ?Array } * @syscap SystemCapability.Window.SessionManager * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ - supportedRefreshRates?: Array; + supportedRefreshRates?: Array; /** * Obtain the cutout info of the display. @@ -2366,20 +2450,20 @@ declare namespace display { /** * Indicates the x-axis coordinates * - * @type { number } + * @type { long } * @syscap SystemCapability.Window.SessionManager * @since 20 */ - x: number; + x: long; /** * Indicates the y-axis coordinates * - * @type { number } + * @type { long } * @syscap SystemCapability.Window.SessionManager * @since 20 */ - y: number; + y: long; } /** @@ -2393,11 +2477,11 @@ declare namespace display { /** * Indicates the display. * - * @type { number } + * @type { long } * @syscap SystemCapability.Window.SessionManager * @since 20 */ - displayId: number; + displayId: long; /** * Indicates the coordinates relative to the display. diff --git a/api/@ohos.distributedDeviceManager.d.ts b/api/@ohos.distributedDeviceManager.d.ts index 31588f25ed45f2f2c0d5a5eebc92df4ae519aa39..992fc64a9eebd6bc7a245e8106d9b21260f2ce32 100644 --- a/api/@ohos.distributedDeviceManager.d.ts +++ b/api/@ohos.distributedDeviceManager.d.ts @@ -103,6 +103,103 @@ declare namespace distributedDeviceManager { UNAVAILABLE = 2, } + /** + * Device status change result. + * @interface DeviceStateChangeResult + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + interface DeviceStateChangeResult { + /** + * The state of the nearby devices. + * @type { DeviceStateChange } + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + action: DeviceStateChange; + /** + * Basic description information of a distributed device. + * @type { DeviceBasicInfo } + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + device: DeviceBasicInfo; + } + + /** + * Device name change result. + * @interface DeviceNameChangeResult + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + interface DeviceNameChangeResult { + /** + * Device name. + * @type { string } + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + deviceName: string; + } + + /** + * Discovery failure result. + * @interface DiscoveryFailureResult + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + interface DiscoveryFailureResult { + /** + * Discovery failure cause code. + * @type { int } + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + reason: int; + } + + /** + * Discovery successful result. + * @interface DiscoverySuccessResult + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + interface DiscoverySuccessResult { + /** + * Basic description information of a distributed device. + * @type { DeviceBasicInfo } + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + device: DeviceBasicInfo; + } + + /** + * Reply result. + * @interface ReplyResult + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @systemapi + * @since 10 + */ + interface ReplyResult { + /** + * Param of ui state changes. + * @type { string } + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @systemapi + * @since 10 + */ + param: string; + } + + /** + * ServiceDie data. + * @interface ServiceDieData + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + interface ServiceDieData {} + /** * Device profile information filter options. * @interface DeviceProfileInfoFilterOptions @@ -753,7 +850,7 @@ declare namespace distributedDeviceManager { * * @permission ohos.permission.DISTRIBUTED_DATASYNC * @param { string } networkId - Device network id. - * @returns { number } - Returns device type. + * @returns { int } - Returns device type. * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API. * @throws { BusinessError } 401 - Parameter error. Possible causes: * 1. Mandatory parameters are left unspecified; @@ -764,7 +861,7 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - getDeviceType(networkId: string): number; + getDeviceType(networkId: string): int; /** * Start to discover nearby devices. @@ -889,7 +986,25 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - on(type: 'deviceStateChange', callback: Callback<{ action: DeviceStateChange; device: DeviceBasicInfo; }>): void; + /** + * Register a device state callback so that the application can be notified upon device state changes based on + * the application bundle name. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'deviceStateChange' } type - Device state change. + * @param { Callback } callback + * Indicates the device state callback to register. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + on(type: 'deviceStateChange', callback: Callback): void; /** * UnRegister device state callback based on the application bundle name. @@ -907,7 +1022,24 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - off(type: 'deviceStateChange', callback?: Callback<{ action: DeviceStateChange; device: DeviceBasicInfo; }>): void; + /** + * UnRegister device state callback based on the application bundle name. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'deviceStateChange' } type - Device state change. + * @param { Callback } [callback] + * Indicates the device state callback to unregister. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + off(type: 'deviceStateChange', callback?: Callback): void; /** * Register a device discovery result callback so that the application can be notified when discovery success. @@ -924,7 +1056,23 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - on(type: 'discoverSuccess', callback: Callback<{ device: DeviceBasicInfo; }>): void; + /** + * Register a device discovery result callback so that the application can be notified when discovery success. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'discoverSuccess' } type - Successfully discovered device. + * @param { Callback } callback - Indicates the device discovery callback to register. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + on(type: 'discoverSuccess', callback: Callback): void; /** * UnRegister the device discovery result callback. @@ -941,7 +1089,23 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - off(type: 'discoverSuccess', callback?: Callback<{ device: DeviceBasicInfo; }>): void; + /** + * UnRegister the device discovery result callback. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'discoverSuccess' } type - Successfully discovered device. + * @param { Callback } [callback] - Indicates the device discovery callback to unregister. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + off(type: 'discoverSuccess', callback?: Callback): void; /** * Register a device name change callback so that the application can be notified when discovery success. @@ -958,7 +1122,23 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - on(type: 'deviceNameChange', callback: Callback<{ deviceName: string; }>): void; + /** + * Register a device name change callback so that the application can be notified when discovery success. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'deviceNameChange' } type - Changed device name. + * @param { Callback } callback - Indicates the device name change callback to register. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + on(type: 'deviceNameChange', callback: Callback): void; /** * UnRegister the device name change result callback. @@ -975,7 +1155,23 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - off(type: 'deviceNameChange', callback?: Callback<{ deviceName: string; }>): void; + /** + * UnRegister the device name change result callback. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'deviceNameChange' } type - Changed device name. + * @param { Callback } [callback] - Indicates the device name change callback to unregister. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + off(type: 'deviceNameChange', callback?: Callback): void; /** * Register a device discovery result callback so that the application can be notified when discover failed. @@ -993,7 +1189,24 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - on(type: 'discoverFailure', callback: Callback<{ reason: number; }>): void; + /** + * Register a device discovery result callback so that the application can be notified when discover failed. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'discoverFailure' } type - Discovery Device Failure. + * @param { Callback } callback + * Indicates the device found result callback to register. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + on(type: 'discoverFailure', callback: Callback): void; /** * UnRegister the device discovery result callback. @@ -1011,7 +1224,24 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - off(type: 'discoverFailure', callback?: Callback<{ reason: number; }>): void; + /** + * UnRegister the device discovery result callback. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'discoverFailure' } type - Discovery Device Failure. + * @param { Callback } [callback] + * Indicates the device found result callback to unregister. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + off(type: 'discoverFailure', callback?: Callback): void; /** * Register a serviceError callback so that the application can be notified when devicemanager service died @@ -1028,7 +1258,23 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - on(type: 'serviceDie', callback?: Callback<{}>): void; + /** + * Register a serviceError callback so that the application can be notified when devicemanager service died + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'serviceDie' } type - Service death. + * @param { Callback } [callback] - Indicates the service error callback to register. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + on(type: 'serviceDie', callback?: Callback): void; /** * UnRegister the service error callback. @@ -1045,7 +1291,23 @@ declare namespace distributedDeviceManager { * @syscap SystemCapability.DistributedHardware.DeviceManager * @since 10 */ - off(type: 'serviceDie', callback?: Callback<{}>): void; + /** + * UnRegister the service error callback. + * + * @permission ohos.permission.DISTRIBUTED_DATASYNC + * @param { 'serviceDie' } type - Service death. + * @param { Callback } [callback] - Indicates the service error callback to unregister. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @since 10 + */ + off(type: 'serviceDie', callback?: Callback): void; /** * Register a callback from deviceManager service so that the devicemanager ui can be notified when uiStateChanges. @@ -1058,12 +1320,31 @@ declare namespace distributedDeviceManager { * 2. Incorrect parameter type; * 3. Parameter verification failed; * 4. The size of specified type is greater than 255. + * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API. * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @syscap SystemCapability.DistributedHardware.DeviceManager * @systemapi this method can be used only by system applications. * @since 10 */ - on(type: 'replyResult', callback: Callback<{ param: string; }>): void; + /** + * Register a callback from deviceManager service so that the devicemanager ui can be notified when uiStateChanges. + * + * @permission ohos.permission.ACCESS_SERVICE_DM + * @param { 'replyResult' } type - Ui reply result to register. + * @param { Callback } callback - Indicates the devicemanager ui state to register. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @systemapi this method can be used only by system applications. + * @since 10 + */ + on(type: 'replyResult', callback: Callback): void; /** * Unregister uiStateChange, this interface can only be used by devicemanager ui. @@ -1076,12 +1357,31 @@ declare namespace distributedDeviceManager { * 2. Incorrect parameter type; * 3. Parameter verification failed; * 4. The size of specified type is greater than 255. + * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API. * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @syscap SystemCapability.DistributedHardware.DeviceManager * @systemapi this method can be used only by system applications. * @since 10 */ - off(type: 'replyResult', callback?: Callback<{ param: string; }>): void; + /** + * Unregister uiStateChange, this interface can only be used by devicemanager ui. + * + * @permission ohos.permission.ACCESS_SERVICE_DM + * @param { 'replyResult' } type - Ui reply result to unregister. + * @param { Callback } [callback] - Indicates the devicemanager ui state to unregister. + * @throws { BusinessError } 401 - Parameter error. Possible causes: + * 1. Mandatory parameters are left unspecified; + * 2. Incorrect parameter type; + * 3. Parameter verification failed; + * 4. The size of specified type is greater than 255. + * @throws { BusinessError } 201 - Permission verification failed. + * The application does not have the permission required to call the API. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.DistributedHardware.DeviceManager + * @systemapi this method can be used only by system applications. + * @since 10 + */ + off(type: 'replyResult', callback?: Callback): void; /** * Get the device list under the same account. diff --git a/api/@ohos.distributedHardware.mechanicManager.d.ts b/api/@ohos.distributedHardware.mechanicManager.d.ts deleted file mode 100644 index 58456bc01c15a0a6075deaecb96b8870d6a1ad93..0000000000000000000000000000000000000000 --- a/api/@ohos.distributedHardware.mechanicManager.d.ts +++ /dev/null @@ -1,885 +0,0 @@ -/* - * Copyright (c) 2025 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"), - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit MechanicKit - * @arkts 1.1&1.2 - */ - -import type { Callback } from './@ohos.base'; - -/** - * Provides capabilities for controlling and interacting with mechanical devices connected to this device. - * The capabilities cover connection management, control, and monitoring. - * - * @namespace mechanicManager - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - -declare namespace mechanicManager { - - /** - * Subscribes to device attachment state change events. - * @param { 'attachStateChange' } type Event type. - * @param { Callback } callback Callback used to return the state change. - * @throws { BusinessError } 33300001 - Service exception. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - function on(type: 'attachStateChange', callback: Callback): void; - - /** - * Unsubscribes from device attachment state change events. - * @param { 'attachStateChange' } type Event type. - * @param { Callback } [callback] Callback used to return the state change. - * @throws { BusinessError } 33300001 - Service exception. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - function off(type: 'attachStateChange', callback?: Callback): void; - - /** - * Obtain the list of connected mechanical devices. - * @returns { MechInfo[] } List of connected mechanical devices. - * @throws { BusinessError } 33300001 - Service exception. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - function getAttachedMechDevices(): MechInfo[]; - - /** - * Sets a user operation. - * @permission ohos.permission.CONNECT_MECHANIC_HARDWARE - * @param { Operation } operation Operation type. - * @param { string } mac MAC address. - * @param { string } params Operation parameters. - * @throws { BusinessError } 201 - Permission denied. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - function setUserOperation(operation: Operation, mac: string, params: string): void; - - /** - * Enables or disables camera tracking. - * @param { boolean } isEnabled Whether to enable camera tracking. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @throws { BusinessError } 33300003 - Feature not supported. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - - function setCameraTrackingEnabled(isEnabled: boolean): void; - - /** - * Checks whether camera tracking is enabled for this mechanical device. - * @returns { boolean } Enabled status. The value true means that camera tracking is enabled, and false means - * the opposite. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - - function getCameraTrackingEnabled(): boolean; - - /** - * Subscribes to tracking events. - * @param { 'trackingStateChange' } type Event type. - * @param { Callback } callback Callback used to return the tracking event information. - * @throws { BusinessError } 33300001 - Service exception. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - function on(type: 'trackingStateChange', callback: Callback): void; - - /** - * Unsubscribes from tracking events. - * @param { 'trackingStateChange' } type Event type. - * @param { Callback } [callback] Callback used to return the tracking event information. - * @throws { BusinessError } 33300001 - Service exception. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - function off(type: 'trackingStateChange', callback?: Callback): void; - - /** - * Sets the camera tracking layout for this mechanical device. - * @param { CameraTrackingLayout } trackingLayout Camera tracking layout. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @throws { BusinessError } 33300003 - Feature not supported. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - function setCameraTrackingLayout(trackingLayout: CameraTrackingLayout): void; - - /** - * Obtains the camera tracking layout of this mechanical device. - * @returns { CameraTrackingLayout } Camera tracking layout obtained. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - function getCameraTrackingLayout(): CameraTrackingLayout; - - /** - * Rotates a mechanical device to the relative angles. - * @param { number } mechId ID of the mechanical device. - * @param { RotationAngles } angles Relative angles. - * @param { number } duration Rotation duration. Unit: millisecond. - * @returns { Promise } Promise that return the execution result. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - function rotate(mechId: number, angles: RotationAngles, duration: number): Promise; - - /** - * Rotates a mechanical device to the absolute angles. - * @param { number } mechId ID of the mechanical device. - * @param { EulerAngles } angles Absolute angles. - * @param { number } duration Rotation duration. Unit: millisecond. - * @returns { Promise } Promise that return the execution result. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - function rotateToEulerAngles(mechId: number, angles: EulerAngles, duration: number): Promise; - - /** - * Obtains the maximum continuous rotation duration of a mechanical device. - * - * @param { number } mechId ID of the mechanical device. - * @returns { number } Maximum rotation duration. Unit: millisecond. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - function getMaxRotationTime(mechId: number): number; - - /** - * Obtains the maximum rotation speed of a mechanical device. - * - * @param { number } mechId ID of the mechanical device. - * @returns { RotationSpeed } Maximum speed. Only the absolute value of the speed is returned. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - function getMaxRotationSpeed(mechId: number): RotationSpeed; - - /** - * Rotates a mechanical device at the specified speed. - * @param { number } mechId ID of the mechanical device. - * @param { RotationSpeed } speed Rotation speed. - * @param { number } duration Rotation duration. Unit: millisecond. - * @returns { Promise } Promise that return the execution result. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - function rotateBySpeed(mechId: number, speed: RotationSpeed, duration: number): Promise; - - /** - * Stops a mechanical device from moving. - * @param { number } mechId ID of the mechanical device. - * @returns { Promise } Promise that returns no value. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - function stopMoving(mechId: number): Promise; - - /** - * Obtains the current angles of a mechanical device. - * @param { number } mechId ID of the mechanical device. - * @returns { EulerAngles } Rotation angles. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - function getCurrentAngles(mechId: number): EulerAngles; - - /** - * Obtains the maximum rotation angles relative to the reference point for the specified mechanical device. - * - * @param { number } mechId ID of the mechanical device. - * @returns { RotationLimits } Maximum rotation angles. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - function getRotationLimits(mechId: number): RotationLimits; - - /** - * Obtains the status of the rotation axes. - * @param { number } mechId ID of the mechanical device. - * @returns { RotationAxesStatus } Rotation axis status. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @throws { BusinessError } 33300002 - Device not connected. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - function getRotationAxesStatus(mechId: number): RotationAxesStatus; - - - /** - * Register a listener for axis state changes. - * The status of the rotation axis changes dynamically, which needs to be monitored. - * - * @param { 'rotationAxesStatusChange' } type - Event type. - * @param { Callback } callback - Rotate axis state changes callback. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - function on(type: 'rotationAxesStatusChange', callback: Callback): void; - - /** - * Unregister a listener for axis state changes. - * - * @param { 'rotationAxesStatusChange' } type - Event type. - * @param { Callback } [callback] - Rotate axis state changes callback. - * @throws { BusinessError } 202 - Not system application. - * @throws { BusinessError } 33300001 - Service exception. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - function off(type: 'rotationAxesStatusChange', callback?: Callback): void; - - /** - * Mechanical device information. - * @typedef MechInfo - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - export interface MechInfo { - /** - * ID of the mechanical device. - * @type { number } - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - mechId: number; - - - /** - * Type of the mechanical device. - * @type { MechDeviceType } - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - mechDeviceType: MechDeviceType; - - /** - * Name of the mechanical device. - * @type { string } - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - mechName: string; - } - - - /** - * The rotion angles, relative to the current position. - * @typedef RotationAngles - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - export interface RotationAngles { - /** - * Yaw angle, ranging from -2*Math.PI to 2*Math.PI, measured in radians. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - yaw?: number; - - /** - * Roll angle, ranging from -2*Math.PI to 2*Math.PI, measured in radians. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - roll?: number; - - /** - * Pitch angle, ranging from -2*Math.PI to 2*Math.PI, measured in radians. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - pitch?: number; - } - - /** - * Absolute euler angles relative to the home position. - * - * @typedef EulerAngles - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - export interface EulerAngles { - /** - * Yaw angle, ranging from -Math.PI to Math.PI, measured in radians. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - yaw?: number; - - /** - * Roll angle, ranging from -Math.PI to Math.PI, measured in radians. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - roll?: number; - - /** - * Pitch angle, ranging from -Math.PI to Math.PI, measured in radians. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - pitch?: number; - } - - /** - * Rotational speed. A negative value indicates a clockwise rotation, and a positive value indicates a - * counterclockwise rotation. - * @typedef RotationSpeed - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - export interface RotationSpeed { - /** - * Yaw speed, measured in radians per second. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - yawSpeed?: number; - - /** - * Roll speed, measured in radians per second. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - rollSpeed?: number; - - /** - * Pitch speed, measured in radians per second. - * @type { ?number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - pitchSpeed?: number; - } - - - /** - * Rotation angle limits relative to the reference point. - * @typedef RotationLimits - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - - export interface RotationLimits { - /** - * Maximum yaw rotation angles in the negative direction, ranging from -2*Math.PI to 0, measured in radians. - * If the value is less than or equal to -2*Math.PI, there is no restriction. - * @type { number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - negativeYawMax: number; - - /** - * Maximum yaw rotation angles in the positive direction, ranging from 0 to 2*Math.PI, measured in radians. - * If the value is greater than or equal to 2*Math.PI, there is no restriction. - * @type { number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - positiveYawMax: number; - - /** - * Maximum roll rotation angles in the negative direction, ranging from -2*Math.PI to 0, measured in radians. - * If the value is less than or equal to -2*Math.PI, there is no restriction. - * @type { number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - negativeRollMax: number; - - /** - * Maximum roll rotation angles in the positive direction, ranging from 0 to 2*Math.PI, measured in radians. - * If the value is greater than or equal to 2*Math.PI, there is no restriction. - * @type { number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - positiveRollMax: number; - - /** - * Maximum pitch rotation angles in the negative direction, ranging from -2*Math.PI to 0, measured in radians. - * If the value is less than or equal to -2*Math.PI, there is no restriction. - * @type { number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - negativePitchMax: number; - - /** - * Maximum pitch rotation angles in the positive direction, ranging from 0 to 2*Math.PI, measured in radians. - * If the value is greater than or equal to 2*Math.PI, there is no restriction. - * @type { number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - positivePitchMax: number; - } - - /** - * Rotation axes status - * - * @typedef RotationAxesStatus - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - export interface RotationAxesStatus { - /** - * Whether the yaw axis is enabled. - * @type { boolean } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - yawEnabled: boolean; - - /** - * Whether the roll axis is enabled. - * @type { boolean } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - rollEnabled: boolean; - - /** - * Whether the pitch axis is enabled. - * @type { boolean } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - pitchEnabled: boolean; - - /** - * Whether the yaw axis is limited. - * @type { ?RotationAxisLimited } RotationAxisLimited - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - yawLimited?: RotationAxisLimited; - - /** - * Whether the roll axis is limited. - * @type { ?RotationAxisLimited } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - rollLimited?: RotationAxisLimited; - - /** - * Whether the pitch axis is limited. - * @type { ?RotationAxisLimited } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - pitchLimited?: RotationAxisLimited; - } - - /** - * Enumerates the rotation axis limit states. - * @enum { int } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - export enum RotationAxisLimited { - /** - * Not limited. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - NOT_LIMITED = 0, - - /** - * Negative limited. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - NEGATIVE_LIMITED = 1, - - /** - * Positive limited. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - POSITIVE_LIMITED = 2, - } - - /** - * Rotation axes state change information. - * @typedef RotationAxesStateChangeInfo - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - export interface RotationAxesStateChangeInfo { - /** - * ID of the mechanical device. - * @type { number } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - mechId: number; - - /** - * Rotate axis status. - * @type { RotationAxesStatus } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - status: RotationAxesStatus, - } - - /** - * Tracking event callback info. - * - * @typedef TrackingEventInfo - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - export interface TrackingEventInfo { - /** - * Tracking event. - * @type { TrackingEvent } Tracking event. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - event: TrackingEvent; - } - - /** - * Callback information about the device attachment state change. - * @typedef AttachStateChangeInfo - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - export interface AttachStateChangeInfo { - - /** - * Device attachment state. - * @type { AttachState } - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - state: AttachState; - - /** - * Mechanical device information. - * @type { MechInfo } - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - mechInfo: MechInfo, - } - - /** - * Enumerates the user operations. - * @enum { int } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - export enum Operation { - /** - * Connection operation. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - CONNECT = 0, - - /** - * Disconnection operation. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - DISCONNECT = 1 - } - - /** - * Enumerates the tracking events. - * @enum { int } - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - - export enum TrackingEvent { - /** - * Camera tracking enabled by user. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - CAMERA_TRACKING_USER_ENABLED = 0, - - /** - * Camera tracking disabled by user. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - CAMERA_TRACKING_USER_DISABLED = 1, - - /** - * Camera tracking layout changed. You can call getCameraTrackingLayout to obtain the new layout. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - CAMERA_TRACKING_LAYOUT_CHANGED = 2, - } - - /** - * Rotation execution results. - * - * @enum { int } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - export enum Result { - /** - * Rotation completed. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - COMPLETED = 0, - - /** - * Rotation was interrupted. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - INTERRUPTED = 1, - - /** - * Device reached limitation. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - LIMITED = 2, - - /** - * Rotation time out. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - TIMEOUT = 3, - - /** - * Rotation failed due to system error. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - SYSTEM_ERROR = 100 - } - - /** - * Enumerates the mechanical device types. - * @enum { int } - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - - export enum MechDeviceType { - /** - * Gimbal device. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - - GIMBAL_DEVICE = 0 - } - - /** - * Device attach states. - * - * @enum { int } - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - export enum AttachState { - - /** - * Device attached. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - ATTACHED = 0, - - /** - * Device detached. - * @syscap SystemCapability.Mechanic.Core - * @since 20 - */ - DETACHED = 1 - } - - /** - * Enumerates the camera tracking layouts. - * @enum { int } - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - export enum CameraTrackingLayout { - /** - * Default layout. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - DEFAULT = 0, - - /** - * Left-side layout. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - LEFT = 1, - - /** - * Middle layout. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - MIDDLE = 2, - - /** - * Right-side layout. - * @syscap SystemCapability.Mechanic.Core - * @systemapi - * @since 20 - */ - RIGHT = 3 - } - -} - -export default mechanicManager; \ No newline at end of file diff --git a/api/@ohos.effectKit.d.ts b/api/@ohos.effectKit.d.ts index 507f0c73b87caa61f0c1e72090127a260c370f06..47a801c3c5d139ebb7c7970b97745c797187e484 100644 --- a/api/@ohos.effectKit.d.ts +++ b/api/@ohos.effectKit.d.ts @@ -72,14 +72,14 @@ declare namespace effectKit { /** * A blur effect is added to the image. - * @param { number } radius - The degree of blur, the value is measured in pixels. + * @param { double } radius - The degree of blur, the value is measured in pixels. * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @since 9 */ /** * A blur effect is added to the image. - * @param { number } radius - The degree of blur, the value is measured in pixels. + * @param { double } radius - The degree of blur, the value is measured in pixels. * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @form @@ -88,7 +88,7 @@ declare namespace effectKit { */ /** * A blur effect is added to the image. - * @param { number } radius - The degree of blur, the value is measured in pixels. + * @param { double } radius - The degree of blur, the value is measured in pixels. * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform @@ -97,29 +97,29 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - blur(radius: number): Filter; + blur(radius: double): Filter; /** * A blur effect is added to the image. - * @param { number } radius - The degree of blur, the value is measured in pixels. + * @param { double } radius - The degree of blur, the value is measured in pixels. * @param { TileMode } tileMode - The tile mode of blur. * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - blur(radius: number, tileMode: TileMode): Filter; + blur(radius: double, tileMode: TileMode): Filter; /** * A Brightness effect is added to the image. - * @param { number } bright - The degree of light and darkness,the value range is 0 to 1. + * @param { double } bright - The degree of light and darkness,the value range is 0 to 1. * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @since 9 */ /** * A Brightness effect is added to the image. - * @param { number } bright - The degree of light and darkness,the value range is 0 to 1. + * @param { double } bright - The degree of light and darkness,the value range is 0 to 1. * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @form @@ -128,7 +128,7 @@ declare namespace effectKit { */ /** * A Brightness effect is added to the image. - * @param { number } bright - The degree of light and darkness,the value range is 0 to 1. + * @param { double } bright - The degree of light and darkness,the value range is 0 to 1. * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform @@ -137,7 +137,7 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - brightness(bright: number): Filter; + brightness(bright: double): Filter; /** * A Grayscale effect is added to the image. @@ -184,7 +184,7 @@ declare namespace effectKit { /** * A custom effect is added to the image. * - * @param { Array } colorMatrix - A matrix of 5x4 size for create effect filter. + * @param { Array } colorMatrix - A matrix of 5x4 size for create effect filter. * @returns { Filter } Filters for the current effect have been added. * @throws { BusinessError } 401 - Input parameter error. * @syscap SystemCapability.Multimedia.Image.Core @@ -193,7 +193,7 @@ declare namespace effectKit { /** * A custom effect is added to the image. * - * @param { Array } colorMatrix - A matrix of 5x4 size for create effect filter. + * @param { Array } colorMatrix - A matrix of 5x4 size for create effect filter. * @returns { Filter } Filters for the current effect have been added. * @throws { BusinessError } 401 - Input parameter error. * @syscap SystemCapability.Multimedia.Image.Core @@ -201,7 +201,7 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - setColorMatrix(colorMatrix: Array): Filter; + setColorMatrix(colorMatrix: Array): Filter; /** * Gets the PixelMap where all filter effects have been added to the image. @@ -346,7 +346,7 @@ declare namespace effectKit { /** * Get top proportion color of an image - * @param { number } colorCount - The number of colors to require, the value is 1 to 10. + * @param { int } colorCount - The number of colors to require, the value is 1 to 10. * @returns { Array } An array of feature colors sorted by proportion, with a size equal to * the minimum of colorCount and the actual number of extracted feature colors. * @syscap SystemCapability.Multimedia.Image.Core @@ -356,7 +356,7 @@ declare namespace effectKit { */ /** * Get top proportion color of an image - * @param { number } colorCount - The number of colors to require, the value is 1 to 10. + * @param { int } colorCount - The number of colors to require, the value is 1 to 10. * @returns { Array } An array of feature colors sorted by proportion, with a size equal to * the minimum of colorCount and the actual number of extracted feature colors. * @syscap SystemCapability.Multimedia.Image.Core @@ -366,7 +366,7 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - getTopProportionColors(colorCount: number): Array; + getTopProportionColors(colorCount: int): Array; /** * Get highest saturation color of an image @@ -422,14 +422,14 @@ declare namespace effectKit { /** * Determine whether the color is black or white or gray - * @param { number } color - The 32 bit ARGB color to discriminate. + * @param { int } color - The 32 bit ARGB color to discriminate. * @returns { boolean } Result of judging black, white and gray. * @syscap SystemCapability.Multimedia.Image.Core * @since 10 */ /** * Determine whether the color is black or white or gray - * @param { number } color - The 32 bit ARGB color to discriminate. + * @param { int } color - The 32 bit ARGB color to discriminate. * @returns { boolean } Result of judging black, white and gray. * @syscap SystemCapability.Multimedia.Image.Core * @form @@ -438,7 +438,7 @@ declare namespace effectKit { */ /** * Determine whether the color is black or white or gray - * @param { number } color - The 32 bit ARGB color to discriminate. + * @param { int } color - The 32 bit ARGB color to discriminate. * @returns { boolean } Result of judging black, white and gray. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform @@ -447,7 +447,7 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - isBlackOrWhiteOrGrayColor(color: number): boolean; + isBlackOrWhiteOrGrayColor(color: int): boolean; } /** @@ -478,13 +478,13 @@ declare namespace effectKit { /** * Red - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @since 9 */ /** * Red - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @form * @atomicservice @@ -492,7 +492,7 @@ declare namespace effectKit { */ /** * Red - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form @@ -500,17 +500,17 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - red: number; + red: int; /** * Green - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @since 9 */ /** * Green - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @form * @atomicservice @@ -518,7 +518,7 @@ declare namespace effectKit { */ /** * Green - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form @@ -526,17 +526,17 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - green: number; + green: int; /** * Blue - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @since 9 */ /** * Blue - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @form * @atomicservice @@ -544,7 +544,7 @@ declare namespace effectKit { */ /** * Blue - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form @@ -552,17 +552,17 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - blue: number; + blue: int; /** * Alpha - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @since 9 */ /** * Alpha - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @form * @atomicservice @@ -570,7 +570,7 @@ declare namespace effectKit { */ /** * Alpha - * @type { number } + * @type { int } * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form @@ -578,7 +578,7 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - alpha: number; + alpha: int; } /** @@ -645,7 +645,7 @@ declare namespace effectKit { /** * Create a color picker to get color of an image. * @param { image.PixelMap } source - the source pixelmap. - * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, + * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, * default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap. * @returns { Promise } - returns the ColorPicker generated. * @throws { BusinessError } 401 - Input parameter error. @@ -655,7 +655,7 @@ declare namespace effectKit { /** * Create a color picker to get color of an image. * @param { image.PixelMap } source - the source pixelmap. - * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, + * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, * default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap. * @returns { Promise } - returns the ColorPicker generated. * @throws { BusinessError } 401 - Input parameter error. @@ -667,7 +667,7 @@ declare namespace effectKit { /** * Create a color picker to get color of an image. * @param { image.PixelMap } source - the source pixelmap. - * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, + * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, * default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap. * @returns { Promise } - returns the ColorPicker generated. * @throws { BusinessError } 401 - Input parameter error. @@ -678,7 +678,7 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - function createColorPicker(source: image.PixelMap, region: Array): Promise; + function createColorPicker(source: image.PixelMap, region: Array): Promise; /** * Create a color picker to get color of an image. @@ -715,7 +715,7 @@ declare namespace effectKit { /** * Create a color picker to get color of an image. * @param { image.PixelMap } source - the source pixelmap. - * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, + * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, * default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap. * @param { AsyncCallback } callback - the callback of createColorPicker. * @throws { BusinessError } 401 - Input parameter error. @@ -725,7 +725,7 @@ declare namespace effectKit { /** * Create a color picker to get color of an image. * @param { image.PixelMap } source - the source pixelmap. - * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, + * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, * default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap. * @param { AsyncCallback } callback - the callback of createColorPicker. * @throws { BusinessError } 401 - Input parameter error. @@ -737,7 +737,7 @@ declare namespace effectKit { /** * Create a color picker to get color of an image. * @param { image.PixelMap } source - the source pixelmap. - * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, + * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, * default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap. * @param { AsyncCallback } callback - the callback of createColorPicker. * @throws { BusinessError } 401 - Input parameter error. @@ -748,12 +748,12 @@ declare namespace effectKit { * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 */ - function createColorPicker(source: image.PixelMap, region: Array, callback: AsyncCallback): void; + function createColorPicker(source: image.PixelMap, region: Array, callback: AsyncCallback): void; /** * TileMode enumeration description * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Multimedia.Image.Core * @since arkts {'1.1':'14', '1.2':'20'} * @arkts 1.1&1.2 @@ -797,4 +797,4 @@ declare namespace effectKit { } } -export default effectKit; +export default effectKit; \ No newline at end of file diff --git a/api/@ohos.events.emitter.d.ts b/api/@ohos.events.emitter.d.ts index f2af6c2e11d3cbe4dfed59d243492030d5a4216f..b196a3673cc9c986a7cfcace17dddfc97847c473 100644 --- a/api/@ohos.events.emitter.d.ts +++ b/api/@ohos.events.emitter.d.ts @@ -71,11 +71,22 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function on(event: InnerEvent, callback: Callback): void; + /** + * Subscribes to an event in persistent manner and executes a callback after the event is received. + * + * @param { InnerEvent } event - Event to subscribe to in persistent manner. The EventPriority parameter is not required and does not take effect. + * @param { Callback } callback - Callback to be executed when the event is received. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function onWithEventTypeInnerEventCallback(event: InnerEvent, callback: Callback): void; + /** * Subscribes to an event in persistent manner and executes a callback after the event is received. * @@ -93,11 +104,22 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function on(eventId: string, callback: Callback): void; + /** + * Subscribes to an event in persistent manner and executes a callback after the event is received. + * + * @param { string } eventId - Event to subscribe to in persistent manner. The value cannot be an empty string and exceed 10240 bytes. + * @param { Callback } callback - Callback to be executed when the event is received. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function onWithEventIdTypeStringCallback(eventId: string, callback: Callback): void; + /** * Subscribes to an event in persistent manner and executes a callback after the event is received. * @@ -111,17 +133,22 @@ declare namespace emitter { function on(eventId: string, callback: Callback>): void; /** - * Subscribe to a event by specific id in persistent manner and receives the event callback. + * Subscribes to an event in persistent manner and executes a callback after the event is received. * - * @param { string } eventId - indicate ID of the event to subscribe to. - * @param { Callback | Callback> } callback - indicate callback used to receive the event. + * @param { string } eventId - Event to subscribe to in persistent manner. The value cannot be an empty string and exceed 10240 bytes. + * @param { Callback> } callback - Callback to be executed when the event is received. * @syscap SystemCapability.Notification.Emitter * @crossplatform - * @atomicservice * @since 20 * @arkts 1.2 */ - function on(eventId: string, callback: Callback | Callback>): void; + function onWithEventIdTypeStringCallbackTypeGenericEventData(eventId: string, callback: Callback>): void; + + /** + * @since 20 + * @arkts 1.2 + */ + overload on { onWithEventTypeInnerEventCallback, onWithEventIdTypeStringCallback, onWithEventIdTypeStringCallbackTypeGenericEventData }; /** * Subscribes to an event in one-shot manner and unsubscribes from it after the event callback is executed. @@ -148,11 +175,22 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function once(event: InnerEvent, callback: Callback): void; + /** + * Subscribes to an event in one-shot manner and unsubscribes from it after the event callback is executed. + * + * @param { InnerEvent } event - Event to subscribe to in one-shot manner. The EventPriority parameter is not required and does not take effect. + * @param { Callback } callback - Callback to be executed when the event is received. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function onceWithEventTypeInnerEventCallback(event: InnerEvent, callback: Callback): void; + /** * Subscribes to an event in one-shot manner and unsubscribes from it after the event callback is executed. * @@ -170,11 +208,22 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function once(eventId: string, callback: Callback): void; + /** + * Subscribes to an event in one-shot manner and unsubscribes from it after the event callback is executed. + * + * @param { string } eventId - Event to subscribe to in one-shot manner. The value cannot be an empty string and exceed 10240 bytes. + * @param { Callback } callback - Callback to be executed when the event is received. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function onceWithEventIdTypeStringCallback(eventId: string, callback: Callback): void; + /** * Subscribes to an event in one-shot manner and unsubscribes from it after the event callback is executed. * @@ -187,6 +236,24 @@ declare namespace emitter { */ function once(eventId: string, callback: Callback>): void; + /** + * Subscribes to an event in one-shot manner and unsubscribes from it after the event callback is executed. + * + * @param { string } eventId - Event to subscribe to in one-shot manner. The value cannot be an empty string and exceed 10240 bytes. + * @param { Callback> } callback - Callback to be executed when the event is received. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function onceWithEventIdTypeStringCallbackTypeGenericEventData(eventId: string, callback: Callback>): void; + + /** + * @since 20 + * @arkts 1.2 + */ + overload once { onceWithEventTypeInnerEventCallback, onceWithEventIdTypeStringCallback, onceWithEventIdTypeStringCallbackTypeGenericEventData }; + /** * Unsubscribes from all events with the specified event ID. * @@ -209,11 +276,21 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function off(eventId: long): void; + /** + * Unsubscribes from all events with the specified event ID. + * + * @param { long } eventId - Event ID. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function offWithEventIdTypeLong(eventId: long): void; + /** * Unsubscribes from all events with the specified event ID. * @@ -229,11 +306,21 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function off(eventId: string): void; + /** + * Unsubscribes from all events with the specified event ID. + * + * @param { string } eventId - Event ID. The value cannot be an empty string and exceed 10240 bytes. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function offWithEventIdTypeString(eventId: string): void; + /** * Unsubscribes from an event with the specified event ID and processed by the specified callback. * @@ -259,11 +346,22 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function off(eventId: long, callback: Callback): void; + /** + * Unsubscribes from an event with the specified event ID and processed by the specified callback. + * + * @param { long } eventId - Event ID. + * @param { Callback } callback - Callback to unregister. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function offWithEventIdTypeLongCallback(eventId: long, callback: Callback): void; + /** * Unsubscribes from an event with the specified event ID and processed by the specified callback. * @@ -281,11 +379,22 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function off(eventId: string, callback: Callback): void; + /** + * Unsubscribes from an event with the specified event ID and processed by the specified callback. + * + * @param { string } eventId - Event ID. The value cannot be an empty string and exceed 10240 bytes. + * @param { Callback } callback - Callback to unregister. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function offWithEventIdTypeStringCallback(eventId: string, callback: Callback): void; + /** * Unsubscribes from an event with the specified event ID and processed by the specified callback. * @@ -299,17 +408,22 @@ declare namespace emitter { function off(eventId: string, callback: Callback>): void; /** - * Unsubscribe specified callback function from an event. + * Unsubscribes from an event with the specified event ID and processed by the specified callback. * - * @param { string } eventId - indicates ID of the event to unsubscribe from. - * @param { Callback | Callback> } callback - indicates callback used to receive the event. + * @param { string } eventId - Event ID. The value cannot be an empty string and exceed 10240 bytes. + * @param { Callback> } callback - Callback to unregister. * @syscap SystemCapability.Notification.Emitter * @crossplatform - * @atomicservice * @since 20 * @arkts 1.2 */ - function off(eventId: string, callback: Callback | Callback>): void; + function offWithEventIdTypeStringCallbackTypeGenericEventData(eventId: string, callback: Callback>): void; + + /** + * @since 20 + * @arkts 1.2 + */ + overload off { offWithEventIdTypeLong, offWithEventIdTypeString, offWithEventIdTypeLongCallback, offWithEventIdTypeStringCallback, offWithEventIdTypeStringCallbackTypeGenericEventData }; /** * Emits the specified event. @@ -336,11 +450,22 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function emit(event: InnerEvent, data?: EventData): void; + /** + * Emits the specified event. + * + * @param { InnerEvent } event - Event to emit, where EventPriority specifies the emit priority of the event. + * @param { EventData } [data] - Data passed in the event. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function emitWithEventTypeInnerEventDataTypeEventData(event: InnerEvent, data?: EventData): void; + /** * Emits the specified event. * @@ -358,11 +483,22 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function emit(eventId: string, data?: EventData): void; + /** + * Emits the specified event. + * + * @param { string } eventId - ID of the event to emit. The value cannot be an empty string and exceed 10240 bytes. + * @param { EventData } [data] - Data passed in the event. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function emitWithEventIdTypeStringDataTypeEventData(eventId: string, data?: EventData): void; + /** * Emits the specified event. * @@ -371,23 +507,21 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function emit(eventId: string, data?: GenericEventData): void; /** - * Emits an event by specific id to the event queue. + * Emits the specified event. * - * @param { string } eventId - indicate ID of the event to emit. - * @param { EventData | GenericEventData } [data] - indicate data carried by the event. + * @param { string } eventId - ID of the event to emit. The value cannot be an empty string and exceed 10240 bytes. + * @param { GenericEventData } [data] - Data passed in the event. * @syscap SystemCapability.Notification.Emitter * @crossplatform - * @atomicservice * @since 20 * @arkts 1.2 */ - function emit(eventId: string, data?: EventData | GenericEventData): void; + function emitWithEventIdTypeStringDataTypeGenericEventData(eventId: string, data?: GenericEventData): void; /** * Emits an event of a specified priority. @@ -408,11 +542,23 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function emit(eventId: string, options: Options, data?: EventData): void; + /** + * Emits an event of a specified priority. + * + * @param { string } eventId - ID of the event to emit. The value cannot be an empty string and exceed 10240 bytes. + * @param { Options } options - Event emit priority. + * @param { EventData } [data] - Data passed in the event. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function emitWithEventIdTypeStringOptionsDataTypeEventData(eventId: string, options: Options, data?: EventData): void; + /** * Emits an event of a specified priority. * @@ -422,11 +568,29 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function emit(eventId: string, options: Options, data?: GenericEventData): void; + /** + * Emits an event of a specified priority. + * + * @param { string } eventId - ID of the event to emit. The value cannot be an empty string and exceed 10240 bytes. + * @param { Options } options - Event emit priority. + * @param { GenericEventData } [data] - Data passed in the event. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function emitWithEventIdTypeStringOptionsDataTypeGenericEventData(eventId: string, options: Options, data?: GenericEventData): void; + + /** + * @since 20 + * @arkts 1.2 + */ + overload emit { emitWithEventTypeInnerEventDataTypeEventData, emitWithEventIdTypeStringDataTypeEventData, emitWithEventIdTypeStringDataTypeGenericEventData, emitWithEventIdTypeStringOptionsDataTypeEventData, emitWithEventIdTypeStringOptionsDataTypeGenericEventData }; + /** * Obtains the number of subscriptions to a specified event. * @@ -444,11 +608,40 @@ declare namespace emitter { * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function getListenerCount(eventId: long | string): long; + /** + * Obtains the number of subscriptions to a specified event. + * + * @param { long } eventId - Event ID. The value of the string type cannot be an empty string. + * @returns { long } Returns the number of listener count. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function getListenerCountWithEventIdTypeLong(eventId: long): long; + + /** + * Obtains the number of subscriptions to a specified event. + * + * @param { string } eventId - Event ID. The value of the string type cannot be an empty string. + * @returns { long } Returns the number of listener count. + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + function getListenerCountWithEventIdTypeString(eventId: string): long; + + /** + * @since 20 + * @arkts 1.2 + */ + overload getListenerCount { getListenerCountWithEventIdTypeLong, getListenerCountWithEventIdTypeString }; + /** * Describes data passed in the event. * @@ -504,13 +697,13 @@ declare namespace emitter { /** * Data carried by the event. * - * @type { ?Record } + * @type { ?(Record | ESObject) } * @syscap SystemCapability.Notification.Emitter * @crossplatform * @since 20 * @arkts 1.2 */ - data?: Record; + data?: Record | ESObject; } /** @@ -768,16 +961,26 @@ declare namespace emitter { */ export interface GenericEventData { /** - * Data passed in the event. T: generic type. + * Data carried by the event. * * @type { ?T } * @syscap SystemCapability.Notification.Emitter * @crossplatform * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ data?: T; + + /** + * Data carried by the event. + * + * @type { ?(T | ESObject) } + * @syscap SystemCapability.Notification.Emitter + * @crossplatform + * @since 20 + * @arkts 1.2 + */ + data?: T | ESObject; } } diff --git a/api/@ohos.file.cloudSync.d.ts b/api/@ohos.file.cloudSync.d.ts index 04e7c17c0fa14b580dc6d8e200c001a1e546b507..f5c0636f90f19e1f1512b26266300a2279ffce01 100644 --- a/api/@ohos.file.cloudSync.d.ts +++ b/api/@ohos.file.cloudSync.d.ts @@ -1311,7 +1311,6 @@ declare namespace cloudSync { * @typedef HistoryVersion * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ interface HistoryVersion { /** @@ -1319,7 +1318,6 @@ declare namespace cloudSync { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ editedTime: number; /** @@ -1327,7 +1325,6 @@ declare namespace cloudSync { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ fileSize: number; /** @@ -1335,7 +1332,6 @@ declare namespace cloudSync { * @type { string } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ versionId: string; /** @@ -1343,7 +1339,6 @@ declare namespace cloudSync { * @type { string } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ originalFileName: string; /** @@ -1351,7 +1346,6 @@ declare namespace cloudSync { * @type { string } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ sha256: string; /** @@ -1359,7 +1353,6 @@ declare namespace cloudSync { * @type { boolean } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ autoResolved: boolean; } @@ -1369,7 +1362,6 @@ declare namespace cloudSync { * @typedef VersionDownloadProgress * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ interface VersionDownloadProgress { /** @@ -1377,7 +1369,6 @@ declare namespace cloudSync { * @type { State } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ state: State; /** @@ -1385,7 +1376,6 @@ declare namespace cloudSync { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ progress: number; /** @@ -1393,7 +1383,6 @@ declare namespace cloudSync { * @type { DownloadErrorType } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ errType: DownloadErrorType; } @@ -1402,7 +1391,6 @@ declare namespace cloudSync { * FileVersion object. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ class FileVersion { /** @@ -1413,7 +1401,6 @@ declare namespace cloudSync { *
2.System error, such as a null pointer, insufficient memory or a JS engine exception. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ constructor(); /** @@ -1436,7 +1423,6 @@ declare namespace cloudSync { *
2.System error, such as a null pointer, insufficient memory or a JS engine exception. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ getHistoryVersionList(uri: string, versionNumLimit: number): Promise>; /** @@ -1460,7 +1446,6 @@ declare namespace cloudSync { *
2.System error, such as a null pointer, insufficient memory or a JS engine exception. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ downloadHistoryVersion(uri: string, versionId: string, callback: Callback): Promise; /** @@ -1485,7 +1470,6 @@ declare namespace cloudSync { * @throws { BusinessError } 22400007 - The version file specified to replace the original file does not exist. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ replaceFileWithHistoryVersion(originalUri: string, versionUri: string): Promise; /** @@ -1506,7 +1490,6 @@ declare namespace cloudSync { *
2.System error, such as a null pointer, insufficient memory or a JS engine exception. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ isFileConflict(uri: string): Promise; /** @@ -1527,7 +1510,6 @@ declare namespace cloudSync { *
2.System error, such as a null pointer, insufficient memory or a JS engine exception. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core * @since 20 - * @arkts 1.1&1.2 */ clearFileConflict(uri: string): Promise; } diff --git a/api/@ohos.file.cloudSyncManager.d.ts b/api/@ohos.file.cloudSyncManager.d.ts index 16db44010cbf80b57e54aa6a41dc0b6230971dc9..6a7622731403f0f1f9960d875644a5c11f44d669 100644 --- a/api/@ohos.file.cloudSyncManager.d.ts +++ b/api/@ohos.file.cloudSyncManager.d.ts @@ -316,7 +316,6 @@ declare namespace cloudSyncManager { * @enum { number } DownloadStopReason * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ enum DownloadStopReason { @@ -324,7 +323,6 @@ declare namespace cloudSyncManager { * download task is not stopped. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ NO_STOP = 0, @@ -332,7 +330,6 @@ declare namespace cloudSyncManager { * Network is unavailable. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ NETWORK_UNAVAILABLE = 1, @@ -340,7 +337,6 @@ declare namespace cloudSyncManager { * The local storage space is full. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ LOCAL_STORAGE_FULL = 2, @@ -348,7 +344,6 @@ declare namespace cloudSyncManager { * Temperature control Limits. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ TEMPERATURE_LIMIT = 3, @@ -356,7 +351,6 @@ declare namespace cloudSyncManager { * User stopped the download task. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ USER_STOPPED = 4, @@ -364,7 +358,6 @@ declare namespace cloudSyncManager { * The local application has been unloaded. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ APP_UNLOAD = 5, @@ -372,7 +365,6 @@ declare namespace cloudSyncManager { * Other reasons of some internal error. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ OTHER_REASON = 6 } @@ -382,7 +374,6 @@ declare namespace cloudSyncManager { * @enum { number } DownloadState * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ enum DownloadState { @@ -390,7 +381,6 @@ declare namespace cloudSyncManager { * Indicates that the download task in process now. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ RUNNING = 0, @@ -398,7 +388,6 @@ declare namespace cloudSyncManager { * Indicates that the download task finished. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ COMPLETED = 1, @@ -406,7 +395,6 @@ declare namespace cloudSyncManager { * Indicates that the download task stopped. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ STOPPED = 2 } @@ -416,7 +404,6 @@ declare namespace cloudSyncManager { * @typedef CloudFileInfo * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ interface CloudFileInfo { @@ -425,7 +412,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ cloudFileCount: number; @@ -434,7 +420,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ cloudFileTotalSize: number; @@ -443,7 +428,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ localFileCount: number; @@ -452,7 +436,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ localFileTotalSize: number; @@ -461,7 +444,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ bothFileCount: number; @@ -470,7 +452,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ bothFileTotalSize: number; } @@ -479,7 +460,6 @@ declare namespace cloudSyncManager { * Defines DownloadProgress object. * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ class DownloadProgress { @@ -488,7 +468,6 @@ declare namespace cloudSyncManager { * @type { DownloadState } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ state: DownloadState; @@ -497,7 +476,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ successfulCount: number; @@ -506,7 +484,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ failedCount: number; @@ -515,7 +492,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ totalCount: number; @@ -524,7 +500,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ downloadedSize: number; @@ -533,7 +508,6 @@ declare namespace cloudSyncManager { * @type { number } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ totalSize: number; @@ -542,7 +516,6 @@ declare namespace cloudSyncManager { * @type { DownloadStopReason } * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @since 20 - * @arkts 1.1&1.2 */ stopReason: DownloadStopReason; } @@ -553,7 +526,6 @@ declare namespace cloudSyncManager { * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @systemapi * @since 20 - * @arkts 1.1&1.2 */ class DowngradeDownload { @@ -572,7 +544,6 @@ declare namespace cloudSyncManager { * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @systemapi * @since 20 - * @arkts 1.1&1.2 */ constructor(bundleName: string); @@ -592,7 +563,6 @@ declare namespace cloudSyncManager { * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @systemapi * @since 20 - * @arkts 1.1&1.2 */ getCloudFileInfo(): Promise; @@ -616,7 +586,6 @@ declare namespace cloudSyncManager { * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @systemapi * @since 20 - * @arkts 1.1&1.2 */ startDownload(callback: Callback): Promise; @@ -635,7 +604,6 @@ declare namespace cloudSyncManager { * @syscap SystemCapability.FileManagement.DistributedFileService.CloudSyncManager * @systemapi * @since 20 - * @arkts 1.1&1.2 */ stopDownload(): Promise; } diff --git a/api/@ohos.file.fileuri.d.ts b/api/@ohos.file.fileuri.d.ts index 93d80cdf64aa42c0169194334971d62132cc18d2..462c9c3d1de0deb3ede8be0b2bb9eeaa65bb07aa 100644 --- a/api/@ohos.file.fileuri.d.ts +++ b/api/@ohos.file.fileuri.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (C) 2022-2023 Huawei Device Co., Ltd. + * Copyright (C) 2022-2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -84,7 +84,8 @@ declare namespace fileUri { /** * Obtains the file name of uri. * - * @type { string } + * @returns { string } + * string: Return the file name of uri. * @readonly * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error @@ -94,15 +95,17 @@ declare namespace fileUri { /** * Obtains the file name of uri. * - * @type { string } + * @returns { string } + * string: Return the file name of uri. * @readonly * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.AppFileService * @atomicservice - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ - readonly name: string; + get name(): string; /** * Get the full directory uri where the file URI is located diff --git a/api/@ohos.file.fs.d.ets b/api/@ohos.file.fs.d.ets index 735f45cac824afe38c3631439c4191088bb3f83d..1245f6b12b3a91704aad5a8bdcbef3a5d1118587 100644 --- a/api/@ohos.file.fs.d.ets +++ b/api/@ohos.file.fs.d.ets @@ -27,8 +27,6 @@ import stream from './@ohos.util.stream'; * * @namespace fileIo * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ declare namespace fileIo { @@ -38,8 +36,6 @@ declare namespace fileIo { * * @namespace OpenMode * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ namespace OpenMode { @@ -48,8 +44,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ const READ_ONLY = 0o0; @@ -58,8 +52,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ const WRITE_ONLY = 0o1; @@ -68,8 +60,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ const READ_WRITE = 0o2; @@ -78,8 +68,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ const CREATE = 0o100; @@ -88,8 +76,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ const TRUNC = 0o1000; @@ -98,8 +84,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ const APPEND = 0o2000; @@ -108,7 +92,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ const NONBLOCK = 0o4000; @@ -117,7 +100,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ const DIR = 0o200000; @@ -126,7 +108,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ const NOFOLLOW = 0o400000; @@ -135,7 +116,6 @@ declare namespace fileIo { * * @constant * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ const SYNC = 0o4010000; @@ -160,8 +140,6 @@ declare namespace fileIo { * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function access(path: string, mode?: AccessModeType): Promise; @@ -184,8 +162,6 @@ function access(path: string, mode?: AccessModeType): Promise; * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function access(path: string, callback: AsyncCallback): void; @@ -233,8 +209,6 @@ function access(path: string, mode: AccessModeType, flag: AccessFlagType): Promi * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function accessSync(path: string, mode?: AccessModeType): boolean; @@ -274,8 +248,6 @@ function accessSync(path: string, mode: AccessModeType, flag: AccessFlagType): b * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function close(file: int | File): Promise; @@ -292,8 +264,6 @@ function close(file: int | File): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function close(file: int | File, callback: AsyncCallback): void; @@ -309,8 +279,6 @@ function close(file: int | File, callback: AsyncCallback): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function closeSync(file: int | File): void; @@ -487,18 +455,6 @@ function copyDir(src: string, dest: string, mode?: int): Promise; */ function copyDir(src: string, dest: string, callback: AsyncCallback): void; -/** - * Copy directory. - * - * @param { string } src - source path. - * @param { string } dest - destination path. - * @param { AsyncCallback> } callback - Return the callback function. - * @throws { BusinessError } 13900015 - File exists - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ -function copyDir(src: string, dest: string, callback: AsyncCallback>): void; - /** * Copy directory. * @@ -528,19 +484,6 @@ function copyDir(src: string, dest: string, callback: AsyncCallback): void; -/** - * Copy directory. - * - * @param { string } src - source path. - * @param { string } dest - destination path. - * @param { int } mode - mode. - * @param { AsyncCallback> } callback - Return the callback function. - * @throws { BusinessError } 13900015 - File exists - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ -function copyDir(src: string, dest: string, mode: int, callback: AsyncCallback>): void; - /** * Copy directory with sync interface. * @@ -597,8 +540,6 @@ function copyDirSync(src: string, dest: string, mode?: int): void; * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 13900044 - Network is unreachable * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function copyFile(src: string | int, dest: string | int, mode?: int): Promise; @@ -627,8 +568,6 @@ function copyFile(src: string | int, dest: string | int, mode?: int): Promise): void; @@ -658,8 +597,6 @@ function copyFile(src: string | int, dest: string | int, callback: AsyncCallback * @throws { BusinessError } 13900038 - Value too large for defined data type * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function copyFile( @@ -694,8 +631,6 @@ function copyFile( * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 13900044 - Network is unreachable * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function copyFileSync(src: string | int, dest: string | int, mode?: int): void; @@ -1077,7 +1012,6 @@ function dup(fd: int): File; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function fdatasync(fd: int): Promise; @@ -1095,7 +1029,6 @@ function fdatasync(fd: int): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function fdatasync(fd: int, callback: AsyncCallback): void; @@ -1112,7 +1045,6 @@ function fdatasync(fd: int, callback: AsyncCallback): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function fdatasyncSync(fd: int): void; @@ -1244,7 +1176,6 @@ function fdopenStreamSync(fd: int, mode: string): Stream; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function fsync(fd: int): Promise; @@ -1262,7 +1193,6 @@ function fsync(fd: int): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function fsync(fd: int, callback: AsyncCallback): void; @@ -1279,7 +1209,6 @@ function fsync(fd: int, callback: AsyncCallback): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function fsyncSync(fd: int): void; @@ -1297,8 +1226,6 @@ function fsyncSync(fd: int): void; * @throws { BusinessError } 13900018 - Not a directory * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function listFile( @@ -1318,8 +1245,6 @@ function listFile( * @throws { BusinessError } 13900018 - Not a directory * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function listFile(path: string, callback: AsyncCallback): void; @@ -1337,8 +1262,6 @@ function listFile(path: string, callback: AsyncCallback): void; * @throws { BusinessError } 13900018 - Not a directory * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function listFile( @@ -1359,8 +1282,6 @@ function listFile( * @throws { BusinessError } 13900018 - Not a directory * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function listFileSync( @@ -1381,7 +1302,6 @@ function listFileSync( * @throws { BusinessError } 13900038 - Value too large for defined data type * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function lseek(fd: int, offset: long, whence?: WhenceType): long; @@ -1467,8 +1387,6 @@ function lstatSync(path: string): Stat; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function mkdir(path: string): Promise; @@ -1495,8 +1413,6 @@ function mkdir(path: string): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function mkdir(path: string, recursion: boolean): Promise; @@ -1522,8 +1438,6 @@ function mkdir(path: string, recursion: boolean): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function mkdir(path: string, callback: AsyncCallback): void; @@ -1550,8 +1464,6 @@ function mkdir(path: string, callback: AsyncCallback): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function mkdir(path: string, recursion: boolean, callback: AsyncCallback): void; @@ -1576,8 +1488,6 @@ function mkdir(path: string, recursion: boolean, callback: AsyncCallback): * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function mkdirSync(path: string): void; @@ -1603,8 +1513,6 @@ function mkdirSync(path: string): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function mkdirSync(path: string, recursion: boolean): void; @@ -1630,7 +1538,6 @@ function mkdirSync(path: string, recursion: boolean): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function mkdtemp(prefix: string): Promise; @@ -1656,7 +1563,6 @@ function mkdtemp(prefix: string): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function mkdtemp(prefix: string, callback: AsyncCallback): void; @@ -1682,7 +1588,6 @@ function mkdtemp(prefix: string, callback: AsyncCallback): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function mkdtempSync(prefix: string): string; @@ -1747,18 +1652,6 @@ function moveDir(src: string, dest: string, mode?: int): Promise; */ function moveDir(src: string, dest: string, callback: AsyncCallback): void; -/** - * Move directory. - * - * @param { string } src - source file path. - * @param { string } dest - destination file path. - * @param { AsyncCallback> } callback - Return the callback function. - * @throws { BusinessError } 13900015 - File exists - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ -function moveDir(src: string, dest: string, callback: AsyncCallback>): void; - /** * Move directory. * @@ -1789,19 +1682,6 @@ function moveDir(src: string, dest: string, callback: AsyncCallback): void; -/** - * Move directory. - * - * @param { string } src - source file path. - * @param { string } dest - destination file path. - * @param { int } mode - move mode when duplicate file name exists. - * @param { AsyncCallback> } callback - Return the callback function. - * @throws { BusinessError } 13900015 - File exists - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ -function moveDir(src: string, dest: string, mode: int, callback: AsyncCallback>): void; - /** * Move directory with sync interface. * @@ -1859,7 +1739,6 @@ function moveDirSync(src: string, dest: string, mode?: int): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function moveFile(src: string, dest: string, mode?: int): Promise; @@ -1890,7 +1769,6 @@ function moveFile(src: string, dest: string, mode?: int): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function moveFile(src: string, dest: string, callback: AsyncCallback): void; @@ -1922,7 +1800,6 @@ function moveFile(src: string, dest: string, callback: AsyncCallback): voi * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function moveFile(src: string, dest: string, mode: int, callback: AsyncCallback): void; @@ -1953,7 +1830,6 @@ function moveFile(src: string, dest: string, mode: int, callback: AsyncCallback< * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function moveFileSync(src: string, dest: string, mode?: int): void; @@ -1992,8 +1868,6 @@ function moveFileSync(src: string, dest: string, mode?: int): void; * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 13900044 - Network is unreachable * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function open(path: string, mode?: int): Promise; @@ -2030,8 +1904,6 @@ function open(path: string, mode?: int): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function open(path: string, callback: AsyncCallback): void; @@ -2069,8 +1941,6 @@ function open(path: string, callback: AsyncCallback): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function open(path: string, mode: int, callback: AsyncCallback): void; @@ -2109,8 +1979,6 @@ function open(path: string, mode: int, callback: AsyncCallback): void; * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 13900044 - Network is unreachable * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function openSync(path: string, mode?: int): File; @@ -2133,8 +2001,6 @@ function openSync(path: string, mode?: int): File; * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 13900044 - Network is unreachable * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function read( @@ -2159,8 +2025,6 @@ function read( * @throws { BusinessError } 13900034 - Operation would block * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function read(fd: int, buffer: ArrayBuffer, callback: AsyncCallback): void; @@ -2182,8 +2046,6 @@ function read(fd: int, buffer: ArrayBuffer, callback: AsyncCallback): void * @throws { BusinessError } 13900034 - Operation would block * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function read( @@ -2211,8 +2073,6 @@ function read( * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 13900044 - Network is unreachable * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function readSync( @@ -2335,8 +2195,6 @@ function readLinesSync(filePath: string, options?: Options): ReaderIterator; * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 13900044 - Network is unreachable * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function readText( @@ -2363,8 +2221,6 @@ function readText( * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function readText(filePath: string, callback: AsyncCallback): void; @@ -2389,8 +2245,6 @@ function readText(filePath: string, callback: AsyncCallback): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function readText( @@ -2420,8 +2274,6 @@ function readText( * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 13900044 - Network is unreachable * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function readTextSync( @@ -2455,8 +2307,6 @@ function readTextSync( * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function rename(oldPath: string, newPath: string): Promise; @@ -2487,8 +2337,6 @@ function rename(oldPath: string, newPath: string): Promise; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function rename(oldPath: string, newPath: string, callback: AsyncCallback): void; @@ -2518,8 +2366,6 @@ function rename(oldPath: string, newPath: string, callback: AsyncCallback) * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function renameSync(oldPath: string, newPath: string): void; @@ -2542,8 +2388,6 @@ function renameSync(oldPath: string, newPath: string): void; * @throws { BusinessError } 13900032 - Directory not empty * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function rmdir(path: string): Promise; @@ -2566,8 +2410,6 @@ function rmdir(path: string): Promise; * @throws { BusinessError } 13900032 - Directory not empty * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function rmdir(path: string, callback: AsyncCallback): void; @@ -2589,8 +2431,6 @@ function rmdir(path: string, callback: AsyncCallback): void; * @throws { BusinessError } 13900032 - Directory not empty * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function rmdirSync(path: string): void; @@ -2614,8 +2454,6 @@ function rmdirSync(path: string): void; * @throws { BusinessError } 13900038 - Value too large for defined data type * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function stat(file: string | int): Promise; @@ -2639,8 +2477,6 @@ function stat(file: string | int): Promise; * @throws { BusinessError } 13900038 - Value too large for defined data type * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function stat(file: string | int, callback: AsyncCallback): void; @@ -2664,8 +2500,6 @@ function stat(file: string | int, callback: AsyncCallback): void; * @throws { BusinessError } 13900038 - Value too large for defined data type * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function statSync(file: string | int): Stat; @@ -2767,8 +2601,6 @@ function symlinkSync(target: string, srcPath: string): void; * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function truncate(file: string | int, len?: long): Promise; @@ -2795,8 +2627,6 @@ function truncate(file: string | int, len?: long): Promise; * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function truncate(file: string | int, callback: AsyncCallback): void; @@ -2824,8 +2654,6 @@ function truncate(file: string | int, callback: AsyncCallback): void; * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function truncate(file: string | int, len: long, callback: AsyncCallback): void; @@ -2852,8 +2680,6 @@ function truncate(file: string | int, len: long, callback: AsyncCallback): * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function truncateSync(file: string | int, len?: long): void; @@ -2879,8 +2705,6 @@ function truncateSync(file: string | int, len?: long): void; * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function unlink(path: string): Promise; @@ -2906,8 +2730,6 @@ function unlink(path: string): Promise; * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function unlink(path: string, callback: AsyncCallback): void; @@ -2932,8 +2754,6 @@ function unlink(path: string, callback: AsyncCallback): void; * @throws { BusinessError } 13900033 - Too many symbolic links encountered * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function unlinkSync(path: string): void; @@ -2950,7 +2770,6 @@ function unlinkSync(path: string): void; * @throws { BusinessError } 13900027 - Read-only file system * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ function utimes(path: string, mtime: double): void; @@ -2975,8 +2794,6 @@ function utimes(path: string, mtime: double): void; * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function write( @@ -3004,8 +2821,6 @@ function write( * @throws { BusinessError } 13900041 - Quota exceeded * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ function write(fd: int, buffer: ArrayBuffer | string, callback: AsyncCallback): void; @@ -3030,8 +2845,6 @@ function write(fd: int, buffer: ArrayBuffer | string, callback: AsyncCallback } The promise returned by the function. - * @throws { BusinessError } 201 - Permission denied. - * @throws { BusinessError } 401 - The parameter check failed.Possible causes:1.Mandatory parameters are left unspecified; - *
2.Incorrect parameter types. - * @throws { BusinessError } 13900045 - Connection failed. - * @throws { BusinessError } 13900046 - Software caused connection abort. - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ -function connectDfs(networkId: string, listeners: DfsListeners): Promise; - -/** - * Disconnect Distributed File System. - * - * @permission ohos.permission.DISTRIBUTED_DATASYNC - * @param { string } networkId - The networkId of device. - * @returns { Promise } The promise returned by the function. - * @throws { BusinessError } 201 - Permission denied. - * @throws { BusinessError } 401 - The parameter check failed.Possible causes:1.Mandatory parameters are left unspecified; - *
2.Incorrect parameter types. - * @throws { BusinessError } 13600004 - Unmount failed. - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ -function disconnectDfs(networkId: string): Promise; - /** * Set extended attributes information of the file. * @@ -3286,8 +3065,6 @@ type ProgressListener = (progress: Progress) => void; * * @interface File * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ interface File { @@ -3296,8 +3073,6 @@ interface File { * @type { int } * @readonly * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ readonly fd: int; @@ -3311,7 +3086,6 @@ interface File { * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 14300002 - Invalid URI * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ readonly path: string; @@ -3324,7 +3098,6 @@ interface File { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ readonly name: string; @@ -3337,7 +3110,6 @@ interface File { * @throws { BusinessError } 13900042 - Unknown error * @throws { BusinessError } 14300002 - Invalid URI * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ getParent(): string; @@ -3931,8 +3703,6 @@ export class AtomicFile { * * @interface Stat * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ interface Stat { @@ -3943,7 +3713,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ readonly ino: bigint; @@ -3954,8 +3723,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ readonly mode: long; @@ -3968,7 +3735,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ readonly uid: long; @@ -3979,7 +3745,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ readonly gid: long; @@ -3990,8 +3755,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ readonly size: long; @@ -4002,8 +3765,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ readonly atime: long; @@ -4014,8 +3775,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ readonly mtime: long; @@ -4026,7 +3785,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ readonly ctime: long; @@ -4078,7 +3836,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ isBlockDevice(): boolean; @@ -4090,7 +3847,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ isCharacterDevice(): boolean; @@ -4102,8 +3858,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ isDirectory(): boolean; @@ -4115,7 +3869,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ isFIFO(): boolean; @@ -4127,8 +3880,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ isFile(): boolean; @@ -4140,7 +3891,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ isSocket(): boolean; @@ -4152,7 +3902,6 @@ interface Stat { * @throws { BusinessError } 13900005 - I/O error * @throws { BusinessError } 13900042 - Unknown error * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ isSymbolicLink(): boolean; @@ -4579,8 +4328,6 @@ enum LocationType { * * @enum { int } access mode type * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ enum AccessModeType { @@ -4588,8 +4335,6 @@ enum AccessModeType { * Check if the file exists. * * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ EXIST = 0, @@ -4598,8 +4343,6 @@ enum AccessModeType { * Check if the file has write permission. * * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ WRITE = 2, @@ -4608,8 +4351,6 @@ enum AccessModeType { * Check if the file has read permission. * * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ READ = 4, @@ -4618,8 +4359,6 @@ enum AccessModeType { * Check if the file has read and write permission. * * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ READ_WRITE = 6, @@ -4746,8 +4485,6 @@ export interface ReaderIteratorResult { * * @interface Filter * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ export interface Filter { @@ -4757,8 +4494,6 @@ export interface Filter { * * @type { ?Array } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ suffix?: Array; @@ -4768,8 +4503,6 @@ export interface Filter { * * @type { ?Array } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ displayName?: Array; @@ -4779,8 +4512,6 @@ export interface Filter { * * @type { ?Array } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ mimeType?: Array; @@ -4790,8 +4521,6 @@ export interface Filter { * * @type { ?long } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ fileSizeOver?: long; @@ -4801,8 +4530,6 @@ export interface Filter { * * @type { ?double } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ lastModifiedAfter?: double; @@ -4812,47 +4539,16 @@ export interface Filter { * * @type { ?boolean } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ excludeMedia?: boolean; } -/** - * Conflict Files type - * - * @interface ConflictFiles - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ -export interface ConflictFiles { - - /** - * The path of the source file. - * - * @type { string } - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ - srcFile: string; - - /** - * The path of the destination file. - * - * @type { string } - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ - destFile: string; -} - /** * Options type * * @interface Options * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ export interface Options { @@ -4861,7 +4557,6 @@ export interface Options { * * @type { ?string } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform * @since 20 */ encoding?: string; @@ -4872,8 +4567,6 @@ export interface Options { * * @interface ReadOptions * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ export interface ReadOptions { @@ -4882,8 +4575,6 @@ export interface ReadOptions { * * @type { ?long } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ offset?: long; @@ -4892,8 +4583,6 @@ export interface ReadOptions { * * @type { ?long } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ length?: long; @@ -4905,8 +4594,6 @@ export interface ReadOptions { * @extends ReadOptions * @interface ReadTextOptions * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ export interface ReadTextOptions extends ReadOptions { @@ -4915,8 +4602,6 @@ export interface ReadTextOptions extends ReadOptions { * * @type { ?string } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ encoding?: string; @@ -4928,8 +4613,6 @@ export interface ReadTextOptions extends ReadOptions { * @extends Options * @interface WriteOptions * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ export interface WriteOptions extends Options { @@ -4938,8 +4621,6 @@ export interface WriteOptions extends Options { * * @type { ?long } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ offset?: long; @@ -4948,8 +4629,6 @@ export interface WriteOptions extends Options { * * @type { ?long } * @syscap SystemCapability.FileManagement.File.FileIO - * @crossplatform - * @atomicservice * @since 20 */ length?: long; @@ -4960,7 +4639,6 @@ export interface WriteOptions extends Options { * * @interface ListFileOptions * @syscap SystemCapability.FileManagement.File.FileIO - * @atomicservice * @since 20 */ export interface ListFileOptions { @@ -4969,7 +4647,6 @@ export interface ListFileOptions { * * @type { ?boolean } * @syscap SystemCapability.FileManagement.File.FileIO - * @atomicservice * @since 20 */ recursion?: boolean; @@ -4979,7 +4656,6 @@ export interface ListFileOptions { * * @type { ?long } * @syscap SystemCapability.FileManagement.File.FileIO - * @atomicservice * @since 20 */ listNum?: long; @@ -4989,7 +4665,6 @@ export interface ListFileOptions { * * @type { ?Filter } * @syscap SystemCapability.FileManagement.File.FileIO - * @atomicservice * @since 20 */ filter?: Filter; @@ -5075,25 +4750,6 @@ export interface WriteStreamOptions { start?: long; } -/** - * The listeners of Distributed File System. - * - * @typedef DfsListeners - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ -export interface DfsListeners { - /** - * The Listener of Distributed File System status - * - * @param { string } networkId - The networkId of device. - * @param { number } status - The status code of Distributed File System. - * @syscap SystemCapability.FileManagement.File.FileIO - * @since 20 - */ - onStatus(networkId: string, status: number): void; -} - /** * Task signal. * @typedef { fileIo.TaskSignal } diff --git a/api/@ohos.file.keyManager.d.ts b/api/@ohos.file.keyManager.d.ts index 058ad8dd99c542845ec486d06e0eba73e8c6f1a1..864eeabb70a4aa8edcaed94535c23ed4f476c749 100644 --- a/api/@ohos.file.keyManager.d.ts +++ b/api/@ohos.file.keyManager.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (c) 2024 Huawei Device Co., Ltd. + * Copyright (c) 2024-2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -23,26 +23,28 @@ * * @namespace keyManager * @syscap SystemCapability.FileManagement.StorageService.Encryption - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace keyManager { /** * Initiate the deactivation of user key for the specified user when user screen is locked. * * @permission ohos.permission.STORAGE_MANAGER_CRYPT - * @param { number } userId + * @param { long } userId * @throws { BusinessError } 201 - Permission verification failed. * @throws { BusinessError } 202 - The caller is not a system application. * @throws { BusinessError } 401 - The input parameter is invalid. Possible causes: Mandatory - parameters are left unspecified; Or input parameter has type different from the type the interface requires. + * parameters are left unspecified; Or input parameter has type different from the type the interface requires. * @throws { BusinessError } 13600001 - IPC error. * @throws { BusinessError } 13600008 - No such object. Possible causes: Cannot find userkey for the specified user. * @throws { BusinessError } 13600009 - User ID out of range. Possible causes: input parameter userId < 100 or userId > 10736. * @syscap SystemCapability.FileManagement.StorageService.Encryption * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ - function deactivateUserKey(userId: number):void; + function deactivateUserKey(userId: long):void; } export default keyManager; \ No newline at end of file diff --git a/api/@ohos.file.photoAccessHelper.d.ts b/api/@ohos.file.photoAccessHelper.d.ts index 8845d4c861735afefd6d6aede3ec91c9af267d5b..9c482d200e4db25b39e2182373db0cf206cd99db 100644 --- a/api/@ohos.file.photoAccessHelper.d.ts +++ b/api/@ohos.file.photoAccessHelper.d.ts @@ -90,11 +90,11 @@ declare namespace photoAccessHelper { function getPhotoAccessHelper(context: Context): PhotoAccessHelper; /** - * Returns an instance of PhotoAccessHelper + * Obtains a PhotoAccessHelper instance for accessing and modifying media files in the album. * * @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS * @param { Context } context - Hap context information - * @param { number } userId - Target userId + * @param { int } userId - Target userId * @returns { PhotoAccessHelper } Instance of PhotoAccessHelper * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application @@ -102,11 +102,10 @@ declare namespace photoAccessHelper { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @StageModelOnly - * @crossplatform * @since arkts {'1.1':'19','1.2':'20'} * @arkts 1.1&1.2 */ - function getPhotoAccessHelper(context: Context, userId: number): PhotoAccessHelper; + function getPhotoAccessHelper(context: Context, userId: int): PhotoAccessHelper; /** * Enumerates the types of av file format. @@ -132,14 +131,14 @@ declare namespace photoAccessHelper { /** * Enumerates media file types. * - * @enum { number } PhotoType + * @enum { int } PhotoType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since 10 */ /** * Enumerates media file types. * - * @enum { number } PhotoType + * @enum { int } PhotoType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice * @since 11 @@ -147,7 +146,7 @@ declare namespace photoAccessHelper { /** * Enumerates media file types. * - * @enum { number } PhotoType + * @enum { int } PhotoType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice @@ -206,7 +205,7 @@ declare namespace photoAccessHelper { /** * Enumerates the PhotoAsset types. * - * @enum { number } PhotoSubtype + * @enum { int } PhotoSubtype * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since 10 @@ -214,7 +213,7 @@ declare namespace photoAccessHelper { /** * Enumerates the PhotoAsset types. * - * @enum { number } PhotoSubtype + * @enum { int } PhotoSubtype * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} @@ -269,7 +268,7 @@ declare namespace photoAccessHelper { /** * Enumerates the formats for displaying media assets. * - * @enum { number } DynamicRangeType + * @enum { int } DynamicRangeType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 @@ -296,7 +295,7 @@ declare namespace photoAccessHelper { /** * Ability to access thumbnail * - * @enum { number } ThumbnailVisibility + * @enum { int } ThumbnailVisibility * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} @@ -326,7 +325,7 @@ declare namespace photoAccessHelper { /** * Enumerates the file locations. * - * @enum { number } Photo asset position, such as local device or cloud + * @enum { int } Photo asset position, such as local device or cloud * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since 10 @@ -334,7 +333,7 @@ declare namespace photoAccessHelper { /** * Enumerates the file locations. * - * @enum { number } Photo asset position, such as local device or cloud + * @enum { int } Photo asset position, such as local device or cloud * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since arkts {'1.1':'16','1.2':'20'} * @arkts 1.1&1.2 @@ -383,7 +382,7 @@ declare namespace photoAccessHelper { /** * Analysis type * - * @enum { number } AnalysisType + * @enum { int } AnalysisType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'11','1.2':'20'} @@ -548,7 +547,7 @@ declare namespace photoAccessHelper { /** * Enumerates the types of recommended images. * - * @enum { number } RecommendationType + * @enum { int } RecommendationType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} @@ -669,7 +668,7 @@ declare namespace photoAccessHelper { /** * Enumerates the asset delivery modes. * - * @enum { number } DeliveryMode + * @enum { int } DeliveryMode * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 @@ -706,7 +705,7 @@ declare namespace photoAccessHelper { /** * Enumerates the video transcoding mode. * - * @enum { number } CompatibleMode + * @enum { int } CompatibleMode * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since arkts {'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 @@ -743,18 +742,18 @@ declare namespace photoAccessHelper { /** * Indicates the progress of required media asset data * - * @param { number } progress - Progress in percentage. Value range: 0 to 100 + * @param { int } progress - Progress in percentage. Value range: 0 to 100 * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since arkts {'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ - onProgress(progress: number): void; + onProgress(progress: int): void; } /** * Enumerates the types of the file to read. * - * @enum { number } SourceMode + * @enum { int } SourceMode * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'11','1.2':'20'} @@ -785,7 +784,7 @@ declare namespace photoAccessHelper { /** * Enumeration type of permissions for accessing asset uri. * - * @enum { number } PhotoPermissionType + * @enum { int } PhotoPermissionType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'12','1.2':'20'} @@ -816,7 +815,7 @@ declare namespace photoAccessHelper { /** * Enumerates the types of media resource information to be hidden from an application. * - * @enum { number } HideSensitiveType + * @enum { int } HideSensitiveType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'12','1.2':'20'} @@ -867,7 +866,7 @@ declare namespace photoAccessHelper { /** * Enumerates the authorization modes. * - * @enum { number } AuthorizationMode + * @enum { int } AuthorizationMode * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'12','1.2':'20'} @@ -888,7 +887,7 @@ declare namespace photoAccessHelper { /** * Enumerates the watermark editable flags. * - * @enum { number } WatermarkType + * @enum { int } WatermarkType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} @@ -939,7 +938,7 @@ declare namespace photoAccessHelper { /** * Enum: complete button text * - * @enum { number } CompleteButtonText + * @enum { int } CompleteButtonText * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice * @since arkts {'1.1':'14','1.2':'20'} @@ -1324,20 +1323,20 @@ declare namespace photoAccessHelper { /** * Indicates the type of photo asset member. * - * @typedef { number | string | boolean } MemberType + * @typedef { int | long | double | string | boolean } MemberType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since 10 */ /** * Indicates the type of photo asset member. * - * @typedef { number | string | boolean } MemberType + * @typedef { int | long | double | string | boolean } MemberType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - type MemberType = number | string | boolean; + type MemberType = int | long | double | string | boolean; /** * Provides APIs for encapsulating file asset attributes. @@ -2046,7 +2045,7 @@ declare namespace photoAccessHelper { * Opens the source file to obtain the FD. This API uses an asynchronous callback to return the result. * * @permission ohos.permission.READ_IMAGEVIDEO - * @param { AsyncCallback } callback - Callback used to return the FD. + * @param { AsyncCallback } callback - Callback used to return the FD. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 202 - Called by non-system application. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -2057,12 +2056,12 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - requestSource(callback: AsyncCallback): void; + requestSource(callback: AsyncCallback): void; /** * Opens the source file to obtain the FD. This API uses a promise to return the result. * * @permission ohos.permission.READ_IMAGEVIDEO - * @returns { Promise } Returns opened source asset fd. + * @returns { Promise } Returns opened source asset fd. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 202 - Called by non-system application. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -2073,7 +2072,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - requestSource(): Promise; + requestSource(): Promise; /** * Commits the edited image or video asset. This API uses an asynchronous callback to return the result. * @@ -2197,7 +2196,7 @@ declare namespace photoAccessHelper { * Obtains the thumbnail of the specified type for the key frame. This API uses a promise to return the result. * * @permission ohos.permission.READ_IMAGEVIDEO - * @param { number } beginFrameTimeMs - Time of the start frame, in ms. The value 0 indicates the cover frame. + * @param { long } beginFrameTimeMs - Time of the start frame, in ms. The value 0 indicates the cover frame. * @param { ThumbnailType } type - Type of the thumbnail. * @returns { Promise } Returns the thumbnail's pixelMap. * @throws { BusinessError } 201 - Permission denied @@ -2210,7 +2209,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - getKeyFrameThumbnail(beginFrameTimeMs: number, type: ThumbnailType): Promise; + getKeyFrameThumbnail(beginFrameTimeMs: long, type: ThumbnailType): Promise; } /** @@ -2977,7 +2976,7 @@ declare namespace photoAccessHelper { /** * Enumerates the display modes of hidden files in the system. * - * @enum { number } HiddenPhotosDisplayMode + * @enum { int } HiddenPhotosDisplayMode * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'11','1.2':'20'} @@ -3117,12 +3116,12 @@ declare namespace photoAccessHelper { /** * User id * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since 19 */ - userId?: number; + userId?: int; } /** @@ -3301,13 +3300,13 @@ declare namespace photoAccessHelper { /** * Token ID of the target application * - * @type { ?number } + * @type { ?long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - tokenId?: number; + tokenId?: long; } /** @@ -3339,7 +3338,7 @@ declare namespace photoAccessHelper { /** * Obtains the total number of files in the result set. * - * @returns { number } Total number of objects. + * @returns { int } Total number of objects. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument @@ -3350,7 +3349,7 @@ declare namespace photoAccessHelper { /** * Obtains the total number of files in the result set. * - * @returns { number } Total number of objects. + * @returns { int } Total number of objects. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument @@ -3362,7 +3361,7 @@ declare namespace photoAccessHelper { /** * Obtains the total number of objects in the fetch result. * - * @returns { number } Total number of objects. + * @returns { int } Total number of objects. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3371,7 +3370,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - getCount(): number; + getCount(): int; /** * Checks whether the cursor is in the last row of the result set. * You need to check whether the object is the last one before calling getNextObject. @@ -3638,7 +3637,7 @@ declare namespace photoAccessHelper { /** * Obtains a file asset with the specified index in the result set. This API uses an asynchronous callback to return the result. * - * @param { number } index - Index of the file asset to obtain. The value starts from 0. + * @param { int } index - Index of the file asset to obtain. The value starts from 0. * @param { AsyncCallback } callback - Callback used to return the file asset obtained. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -3650,7 +3649,7 @@ declare namespace photoAccessHelper { /** * Obtains a file asset with the specified index in the result set. This API uses an asynchronous callback to return the result. * - * @param { number } index - Index of the file asset to obtain. The value starts from 0. + * @param { int } index - Index of the file asset to obtain. The value starts from 0. * @param { AsyncCallback } callback - Callback used to return the file asset obtained. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -3663,7 +3662,7 @@ declare namespace photoAccessHelper { /** * Obtains the object with the specified index in the result set. * - * @param { number } index - Index of the file asset to obtain. The value starts from 0. + * @param { int } index - Index of the file asset to obtain. The value starts from 0. * @param { AsyncCallback } callback - Callback used to return the file asset obtained. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail @@ -3673,11 +3672,11 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - getObjectByPosition(index: number, callback: AsyncCallback): void; + getObjectByPosition(index: int, callback: AsyncCallback): void; /** * Obtains a file asset with the specified index in the result set. This API uses a promise to return the result. * - * @param { number } index - Index of the file asset to obtain. The value starts from 0. + * @param { int } index - Index of the file asset to obtain. The value starts from 0. * @returns { Promise } Returns the object * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -3689,7 +3688,7 @@ declare namespace photoAccessHelper { /** * Obtains a file asset with the specified index in the result set. This API uses a promise to return the result. * - * @param { number } index - Index of the file asset to obtain. The value starts from 0. + * @param { int } index - Index of the file asset to obtain. The value starts from 0. * @returns { Promise } Returns the object * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -3702,7 +3701,7 @@ declare namespace photoAccessHelper { /** * Obtains the object with the specified index in the result set. * - * @param { number } index - Index of the file asset to obtain. The value starts from 0. + * @param { int } index - Index of the file asset to obtain. The value starts from 0. * @returns { Promise } Returns the object * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail @@ -3712,7 +3711,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - getObjectByPosition(index: number): Promise; + getObjectByPosition(index: int): Promise; /** * Obtains all the file assets in the result set. This API uses an asynchronous callback to return the result. * @@ -3823,14 +3822,14 @@ declare namespace photoAccessHelper { /** * Enumerates the album types. * - * @enum { number } AlbumType + * @enum { int } AlbumType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since 10 */ /** * Enumerates the album types. * - * @enum { number } AlbumType + * @enum { int } AlbumType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @since arkts {'1.1':'12','1.2':'20'} @@ -3890,14 +3889,14 @@ declare namespace photoAccessHelper { /** * Enumerate the album subtypes. * - * @enum { number } AlbumSubtype + * @enum { int } AlbumSubtype * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since 10 */ /** * Enumerate the album subtypes. * - * @enum { number } AlbumSubtype + * @enum { int } AlbumSubtype * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @since arkts {'1.1':'12','1.2':'20'} @@ -4110,7 +4109,7 @@ declare namespace photoAccessHelper { /** * Enumerates the types of the operation for obtaining image or video thumbnails. * - * @enum { number } RequestPhotoType + * @enum { int } RequestPhotoType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'11','1.2':'20'} @@ -4271,7 +4270,7 @@ declare namespace photoAccessHelper { /** * Number of assets in the album * - * @type { number } + * @type { int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since 10 @@ -4279,14 +4278,14 @@ declare namespace photoAccessHelper { /** * Number of assets in the album * - * @type { number } + * @type { int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - readonly count: number; + readonly count: int; /** * Cover uri for the album * @@ -4469,7 +4468,7 @@ declare namespace photoAccessHelper { /** * Number of image assets in the album * - * @type { ?number } + * @type { ?int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since 11 @@ -4477,18 +4476,18 @@ declare namespace photoAccessHelper { /** * Number of image assets in the album * - * @type { ?number } + * @type { ?int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - readonly imageCount?: number; + readonly imageCount?: int; /** * Number of video assets in the album * - * @type { ?number } + * @type { ?int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since 11 @@ -4496,36 +4495,36 @@ declare namespace photoAccessHelper { /** * Number of video assets in the album * - * @type { ?number } + * @type { ?int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - readonly videoCount?: number; + readonly videoCount?: int; /** * Album dateAdded * - * @type { ?number } + * @type { ?long } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - readonly dateAdded?: number; + readonly dateAdded?: long; /** * Album dateModified * - * @type { ?number } + * @type { ?long } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - readonly dateModified?: number; + readonly dateModified?: long; /** * Modify metadata for the album * @@ -5536,7 +5535,7 @@ declare namespace photoAccessHelper { * @permission ohos.permission.WRITE_IMAGEVIDEO * @param { string } bundleName - BundleName of the application which called the save dialog * @param { string } appName - AppName of the application which called the save dialog - * @param { number } tokenId - TokenId of the application which called the save dialog + * @param { long } tokenId - TokenId of the application which called the save dialog * @param { Array } photoCreationConfigs - List of the photo asset creation configs * @returns { Promise> } - Returns the media library file uri list to application which has been authorized * @throws { BusinessError } 201 - Permission denied @@ -5549,7 +5548,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'19','1.2':'20'} * @arkts 1.1&1.2 */ - createAssetsForApp(bundleName: string, appName: string, tokenId: number, photoCreationConfigs: Array): Promise>; + createAssetsForApp(bundleName: string, appName: string, tokenId: long, photoCreationConfigs: Array): Promise>; /** * Create asset and grant short term permission to the application. * @@ -5571,7 +5570,7 @@ declare namespace photoAccessHelper { * @param { string } bundleName - Bundle name of the target application. * @param { string } appName - Name of the target application. * @param { string } appId - ID of the target application. - * @param { number } tokenId - Unique identifier for the temporary authorization. + * @param { long } tokenId - Unique identifier for the temporary authorization. * @param { AuthorizationMode } authorizationMode - Mode of authorization * @param { Array } photoCreationConfigs - Configuration for creating (saving) the media assets in the media library. * @returns { Promise> } - Returns the media library file uri list to application which has been authorized @@ -5589,7 +5588,7 @@ declare namespace photoAccessHelper { bundleName: string, appName: string, appId: string, - tokenId: number, + tokenId: long, authorizationMode: AuthorizationMode, photoCreationConfigs: Array ): Promise>; @@ -5615,7 +5614,7 @@ declare namespace photoAccessHelper { *
If it is an empty string, all the media assets in the Gallery are obtained by default. * @param { FetchOptions } options - Fetch options. Only one search condition or sorting mode must be set in predicates. *
If no value is set or multiple search criteria or sorting modes are set, the API cannot be called successfully. - * @param { AsyncCallback } callback - Callback used to return the index obtained. + * @param { AsyncCallback } callback - Callback used to return the index obtained. * @throws { BusinessError } 202 - Called by non-system application. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -5627,7 +5626,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - getPhotoIndex(photoUri: string, albumUri: string, options: FetchOptions, callback: AsyncCallback): void; + getPhotoIndex(photoUri: string, albumUri: string, options: FetchOptions, callback: AsyncCallback): void; /** * Obtains the index of an image or video in an album. This API uses a promise to return the result. * @@ -5636,7 +5635,7 @@ declare namespace photoAccessHelper { * @param { string } albumUri - Album URI, which can be an empty string. If it is an empty string, all the media assets in the Gallery are obtained by default. * @param { FetchOptions } options - Fetch options. Only one search condition or sorting mode must be set in predicates. *
If no value is set or multiple search criteria or sorting modes are set, the API cannot be called successfully. - * @returns { Promise } - Returns the index of the asset in the album + * @returns { Promise } - Returns the index of the asset in the album * @throws { BusinessError } 202 - Called by non-system application. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -5648,7 +5647,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - getPhotoIndex(photoUri: string, albumUri: string, options: FetchOptions): Promise; + getPhotoIndex(photoUri: string, albumUri: string, options: FetchOptions): Promise; /** * Releases this PhotoAccessHelper instance. This API uses an asynchronous callback to return the result. * Call this API when the APIs of the PhotoAccessHelper instance are no longer used. @@ -5830,12 +5829,12 @@ declare namespace photoAccessHelper { * Grants an application the permission to access multiple URIs. This API uses a promise to return the result. * * @permission ohos.permission.READ_IMAGEVIDEO - * @param { number } tokenId - ID of the target application. + * @param { long } tokenId - ID of the target application. * @param { Array } uriList - A list of URIs, which cannot exceed 1000. * @param { PhotoPermissionType } photoPermissionType - Type of the permission to be granted. For details, see the enum. * @param { HideSensitiveType } hideSensitiveType - Type of the information to hide. *
This parameter is reserved. Currently, any enumerated value of HideSensitiveType can be passed in. - * @returns { Promise } Returns result of grant permission + * @returns { Promise } Returns result of grant permission * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 13900020 - Invalid argument. Possible causes: 1. Incorrect uri format; @@ -5846,17 +5845,17 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'19','1.2':'20'} * @arkts 1.1&1.2 */ - grantPhotoUrisPermission(tokenId: number, uriList: Array, photoPermissionType: PhotoPermissionType, hideSensitiveType: HideSensitiveType): Promise; + grantPhotoUrisPermission(tokenId: long, uriList: Array, photoPermissionType: PhotoPermissionType, hideSensitiveType: HideSensitiveType): Promise; /** * Grants an application the permission to access a URI. This API uses a promise to return the result. * * @permission ohos.permission.READ_IMAGEVIDEO - * @param { number } tokenId - ID of the target application. + * @param { long } tokenId - ID of the target application. * @param { string } uri - URI of the media asset. * @param { PhotoPermissionType } photoPermissionType - Type of the permission to be granted. For details, see the enum. * @param { HideSensitiveType } hideSensitiveType - Type of the information to hide. *
This parameter is reserved. Currently, any enumerated value of HideSensitiveType can be passed in. - * @returns { Promise } Returns result of grant permission + * @returns { Promise } Returns result of grant permission * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 13900020 - Invalid argument. Possible causes: 1. Incorrect uri format; @@ -5867,15 +5866,15 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'19','1.2':'20'} * @arkts 1.1&1.2 */ - grantPhotoUriPermission(tokenId: number, uri: string, photoPermissionType: PhotoPermissionType, hideSensitiveType: HideSensitiveType): Promise; + grantPhotoUriPermission(tokenId: long, uri: string, photoPermissionType: PhotoPermissionType, hideSensitiveType: HideSensitiveType): Promise; /** * Cancels the permission for accessing an URI from an application. This API uses a promise to return the result. * * @permission ohos.permission.READ_IMAGEVIDEO - * @param { number } tokenId - ID of the target application. + * @param { long } tokenId - ID of the target application. * @param { string } uri - URI of the media asset. * @param { PhotoPermissionType } photoPermissionType - Permission type. - * @returns { Promise } Returns result of cancel permission + * @returns { Promise } Returns result of cancel permission * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 13900020 - Invalid argument. Possible causes: 1. Incorrect uri format; @@ -5886,14 +5885,14 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'19','1.2':'20'} * @arkts 1.1&1.2 */ - cancelPhotoUriPermission(tokenId: number, uri: string, photoPermissionType: PhotoPermissionType): Promise; + cancelPhotoUriPermission(tokenId: long, uri: string, photoPermissionType: PhotoPermissionType): Promise; /** * Provides the capability of thumbnail generation according to specified rules. * * @permission ohos.permission.READ_IMAGEVIDEO * @param { dataSharePredicates.DataSharePredicates } predicate - Rule options for generating thumbnails. * @param { AsyncCallback } callback - Returns void when the task is completed. - * @returns { number } Create task id for generating thumbnails + * @returns { int } Create task id for generating thumbnails * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -5904,12 +5903,12 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - startThumbnailCreationTask(predicate: dataSharePredicates.DataSharePredicates, callback: AsyncCallback): number; + startThumbnailCreationTask(predicate: dataSharePredicates.DataSharePredicates, callback: AsyncCallback): int; /** * Provides the capability of stop generating thumbnails. * * @permission ohos.permission.READ_IMAGEVIDEO - * @param { number } taskId - Stop generating thumbnail task id. + * @param { int } taskId - Stop generating thumbnail task id. * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -5920,7 +5919,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - stopThumbnailCreationTask(taskId: number): void; + stopThumbnailCreationTask(taskId: int): void; /** * Fetch shared photo assets. * @@ -5957,7 +5956,7 @@ declare namespace photoAccessHelper { * @permission ohos.permission.WRITE_IMAGEVIDEO * @param { AnalysisType } type - Smart analysis type. * @param { Array } assetUris - Array of asset URIs. - * @returns { Promise } Returns the task id of the service. + * @returns { Promise } Returns the task id of the service. * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -5967,13 +5966,13 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - startAssetAnalysis(type: AnalysisType, assetUris?: Array): Promise; + startAssetAnalysis(type: AnalysisType, assetUris?: Array): Promise; /** * Obtains album information by album IDs. This API uses a promise to return the result. * * @permission ohos.permission.READ_IMAGEVIDEO - * @param { Array } albumIds - Array of album IDs. - * @returns { Promise> } - Return the map of albums + * @param { Array } albumIds - Array of album IDs. + * @returns { Promise> } - Return the map of albums * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -5984,7 +5983,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - getAlbumsByIds(albumIds: Array): Promise>; + getAlbumsByIds(albumIds: Array): Promise>; /** * Creates assets for the current application or other applications in the specified source or user album. This API uses a promise to return the result. * @@ -6864,7 +6863,7 @@ declare namespace photoAccessHelper { /** * Enumeration types of data change. * - * @enum { number } NotifyType + * @enum { int } NotifyType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 @@ -7126,7 +7125,7 @@ declare namespace photoAccessHelper { /** * Enumeration type of filter operator. * - * @enum { number } FilterOperator + * @enum { int } FilterOperator * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice * @since 19 @@ -7265,14 +7264,14 @@ declare namespace photoAccessHelper { /** * Maximum number of images for a single selection. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since 10 */ /** * Maximum number of images for a single selection. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice * @since 11 @@ -7281,12 +7280,12 @@ declare namespace photoAccessHelper { * Maximum number of images for a single selection. * Move from class PhotoSelectOptions to it's base class BaseSelectOptions * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice * @since 12 */ - maxSelectNumber?: number; + maxSelectNumber?: int; /** * Support search. @@ -7939,7 +7938,7 @@ declare namespace photoAccessHelper { /** * Enumerates the types of the resources to write. * - * @enum { number } ResourceType + * @enum { int } ResourceType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} @@ -8000,7 +7999,7 @@ declare namespace photoAccessHelper { /** * Enumerates the types of image files to save. * - * @enum { number } ImageFileType + * @enum { int } ImageFileType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 @@ -8028,7 +8027,7 @@ declare namespace photoAccessHelper { /** * Enumeration of moving photo effect mode. * - * @enum { number } MovingPhotoEffectMode + * @enum { int } MovingPhotoEffectMode * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'12','1.2':'20'} @@ -8109,7 +8108,7 @@ declare namespace photoAccessHelper { /** * Enumerates the types of segmented video enhancement. * - * @enum { number } VideoEnhancementType + * @enum { int } VideoEnhancementType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} @@ -8389,8 +8388,8 @@ declare namespace photoAccessHelper { /** * Sets location information. * - * @param { number } longitude - Longitude. - * @param { number } latitude - Latitude. + * @param { double } longitude - Longitude. + * @param { double } latitude - Latitude. * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -8400,7 +8399,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - setLocation(longitude: number, latitude: number): void; + setLocation(longitude: double, latitude: double): void; /** * Sets the media asset title. @@ -8445,7 +8444,7 @@ declare namespace photoAccessHelper { * Obtains the handler used for writing a file to cache. * * @permission ohos.permission.WRITE_IMAGEVIDEO - * @returns { Promise } Returns the write cache handler + * @returns { Promise } Returns the write cache handler * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. @@ -8455,7 +8454,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - getWriteCacheHandler(): Promise; + getWriteCacheHandler(): Promise; /** * Adds a resource using fileUri. @@ -8576,7 +8575,7 @@ declare namespace photoAccessHelper { /** * Sets the orientation of this image. * - * @param { number } orientation - Rotation angle of the image to set. The value can only be 0, 90, 180, or 270. + * @param { int } orientation - Rotation angle of the image to set. The value can only be 0, 90, 180, or 270. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 14000011 - Internal system error @@ -8584,7 +8583,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ - setOrientation(orientation: number): void; + setOrientation(orientation: int): void; /** * Set video enhancement attribute @@ -9006,7 +9005,7 @@ declare namespace photoAccessHelper { /** * Set display level of the portrait album * - * @param { number } displayLevel - The level of display interface for portrait albums, such as homepage and more pages + * @param { int } displayLevel - The level of display interface for portrait albums, such as homepage and more pages * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -9016,7 +9015,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - setDisplayLevel(displayLevel: number): void; + setDisplayLevel(displayLevel: int): void; /** * Remove assets from the smart album @@ -9106,13 +9105,13 @@ declare namespace photoAccessHelper { /** * File id of photo asset * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - fileId: number; + fileId: int; /** * URI of photo asset * @@ -9156,83 +9155,83 @@ declare namespace photoAccessHelper { /** * Size of photo asset * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - size: number; + size: long; /** * Added date of photo asset * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - dateAdded: number; + dateAdded: long; /** * Modify date of photo asset * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - dateModified: number; + dateModified: long; /** * Duration of video photo asset * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - duration: number; + duration: int; /** * Width of photo asset * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - width: number; + width: int; /** * Height of photo asset * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - height: number; + height: int; /** * DateTaken of photo asset * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - dateTaken: number; + dateTaken: long; /** * Orientation of photo asset * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - orientation: number; + orientation: int; /** * Favorite state of photo asset * @@ -9266,13 +9265,13 @@ declare namespace photoAccessHelper { /** * Trashed date of photo asset * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - dateTrashed: number; + dateTrashed: long; /** * Hidden state of photo asset * @@ -9346,33 +9345,33 @@ declare namespace photoAccessHelper { /** * Added date of photo asset in milliseconds * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - dateAddedMs: number; + dateAddedMs: long; /** * Modified time of the asset in milliseconds * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - dateModifiedMs: number; + dateModifiedMs: long; /** * Trashed time of the asset in milliseconds * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - dateTrashedMs: number; + dateTrashedMs: long; /** * Subtype of photo asset * @@ -9436,13 +9435,13 @@ declare namespace photoAccessHelper { /** * modified time of thumbnail status * - * @type { ?number } + * @type { ?long } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 */ - thumbnailModifiedMs?: number; + thumbnailModifiedMs?: long; /** * visibility of thumbnails * @@ -9468,13 +9467,13 @@ declare namespace photoAccessHelper { /** * album id of album asset * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 */ - albumId: number; + albumId: int; /** * type of album asset * @@ -9518,33 +9517,33 @@ declare namespace photoAccessHelper { /** * number of assets in this album * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 */ - count: number; + count: int; /** * number of photo assets in this album * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 */ - imageCount: number; + imageCount: int; /** * number of video assets in this album * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 */ - videoCount: number; + videoCount: int; } /** @@ -9644,7 +9643,7 @@ declare namespace photoAccessHelper { /** * Enumerates the types of the highlights album information. * - * @enum { number } HighlightAlbumInfoType + * @enum { int } HighlightAlbumInfoType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'12','1.2':'20'} @@ -9674,7 +9673,7 @@ declare namespace photoAccessHelper { /** * Enumerates the user behavior types of the highlights album. * - * @enum { number } HighlightUserActionType + * @enum { int } HighlightUserActionType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'12','1.2':'20'} @@ -9776,7 +9775,7 @@ declare namespace photoAccessHelper { /** * Enumerates thumbnail types. * - * @enum { number } ThumbnailType + * @enum { int } ThumbnailType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} @@ -9832,7 +9831,7 @@ declare namespace photoAccessHelper { * * @permission ohos.permission.WRITE_IMAGEVIDEO * @param { Array } assets - Assets in the album for which the sequence needs to be set. - * @param { Array } position - Sequence of assets in the album. + * @param { Array } position - Sequence of assets in the album. * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -9844,7 +9843,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - setOrderPosition(assets: Array, position: Array): void; + setOrderPosition(assets: Array, position: Array): void; } /** @@ -9874,7 +9873,7 @@ declare namespace photoAccessHelper { * * @permission ohos.permission.READ_IMAGEVIDEO * @param { Array } assets - Assets in the album whose sequence needs to be obtained. - * @returns { Promise> } Returns the order of positions of assets + * @returns { Promise> } Returns the order of positions of assets * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -9886,7 +9885,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - getOrderPosition(assets: Array): Promise>; + getOrderPosition(assets: Array): Promise>; } /** @@ -9954,7 +9953,7 @@ declare namespace photoAccessHelper { * * @permission ohos.permission.WRITE_IMAGEVIDEO * @param { HighlightUserActionType } type - Type of the user behavior data to set. - * @param { number } actionData - Behavior data. + * @param { int } actionData - Behavior data. * @returns { Promise } Returns void * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application @@ -9966,7 +9965,7 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - setHighlightUserActionData(type: HighlightUserActionType, actionData: number): Promise; + setHighlightUserActionData(type: HighlightUserActionType, actionData: int): Promise; /** * Set highlight sub title @@ -9993,7 +9992,7 @@ declare namespace photoAccessHelper { * @permission ohos.permission.WRITE_IMAGEVIDEO * @param { Context } context - Context of the ability instance. * @param { Array } albums - Array of highlight albums to delete. - * @returns { Promise } Returns result of delete highlight album + * @returns { Promise } Returns result of delete highlight album * @throws { BusinessError } 201 - Permission denied * @throws { BusinessError } 202 - Called by non-system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -10006,13 +10005,13 @@ declare namespace photoAccessHelper { * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ - static deleteHighlightAlbums(context: Context, albums: Array): Promise; + static deleteHighlightAlbums(context: Context, albums: Array): Promise; } /** * Enumerates the cloud enhancement task states, which are returned by CloudEnhancementTaskState. * - * @enum { number } CloudEnhancementTaskStage + * @enum { int } CloudEnhancementTaskStage * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} @@ -10109,47 +10108,47 @@ declare namespace photoAccessHelper { /** * Indicates the transferred file size. * - * @type { ?number } + * @type { ?int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - readonly transferredFileSize?: number; + readonly transferredFileSize?: int; /** * Indicates the total file size. * - * @type { ?number } + * @type { ?int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - readonly totalFileSize?: number; + readonly totalFileSize?: int; /** * Indicates the expected duration of cloud enhancement queue time. * - * @type { ?number } + * @type { ?int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - readonly expectedDuration?: number; + readonly expectedDuration?: int; /** * Status code when failed in cloud enhancement. * - * @type { ?number } + * @type { ?int } * @readonly * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} * @arkts 1.1&1.2 */ - readonly statusCode?: number; + readonly statusCode?: int; } /** @@ -10206,7 +10205,7 @@ declare namespace photoAccessHelper { * @param { Array } photoAssets - PhotoAsset to enhance. * @param { boolean } hasCloudWatermark - Whether to add a cloud watermark to the enhanced image. * The value true means to add the watermark, and false means the opposite. - * @param { number } [triggerMode] - Trigger mode of the cloud enhancement task. + * @param { int } [triggerMode] - Trigger mode of the cloud enhancement task. * 0: manually triggered. 1: automatically triggered. The default value is 0. * @returns { Promise } Returns void * @throws { BusinessError } 201 - Permission denied @@ -10222,7 +10221,7 @@ declare namespace photoAccessHelper { submitCloudEnhancementTasks( photoAssets: Array, hasCloudWatermark: boolean, - triggerMode?: number + triggerMode?: int ): Promise; /** @@ -10331,7 +10330,7 @@ declare namespace photoAccessHelper { /** * Enumerates the cloud enhancement states. * - * @enum { number } CloudEnhancementState + * @enum { int } CloudEnhancementState * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'13','1.2':'20'} @@ -10379,7 +10378,7 @@ declare namespace photoAccessHelper { /** * Enumerates the statuses of tasks used for downloading cloud media assets. * - * @enum { number } CloudMediaAssetTaskStatus + * @enum { int } CloudMediaAssetTaskStatus * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} @@ -10418,7 +10417,7 @@ declare namespace photoAccessHelper { /** * Enumerates the reasons why a cloud media asset download task is paused. * - * @enum { number } CloudMediaTaskPauseCause + * @enum { int } CloudMediaTaskPauseCause * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} @@ -10567,7 +10566,7 @@ declare namespace photoAccessHelper { /** * Enumerates the types of download tasks. * - * @enum { number } CloudMediaDownloadType + * @enum { int } CloudMediaDownloadType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} @@ -10597,7 +10596,7 @@ declare namespace photoAccessHelper { /** * Enumerates the modes used for deleting cloud media assets. * - * @enum { number } CloudMediaRetainType + * @enum { int } CloudMediaRetainType * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi * @since arkts {'1.1':'14','1.2':'20'} diff --git a/api/@ohos.file.storageStatistics.d.ts b/api/@ohos.file.storageStatistics.d.ts index 0bcb09387a7bd35c7c3b6d89f5f3b2ecf84a6964..7d8cf858eb5476fb055b66d070211d0c8e662ec8 100644 --- a/api/@ohos.file.storageStatistics.d.ts +++ b/api/@ohos.file.storageStatistics.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (C) 2022-2023 Huawei Device Co., Ltd. + * Copyright (C) 2022-2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -25,7 +25,8 @@ import { AsyncCallback, Callback } from './@ohos.base'; * * @namespace storageStatistics * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace storageStatistics { /** @@ -112,35 +113,39 @@ parameters are left unspecified; * * @interface BundleStats * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface BundleStats { /** * The size of application installation data. * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ - appSize: number; + appSize: long; /** * The size of application cache data. * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ - cacheSize: number; + cacheSize: long; /** * The size of application local data, distributed data and database data. * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ - dataSize: number; + dataSize: long; } /** * Get the bundle statistics. @@ -225,7 +230,8 @@ parameters are left unspecified; * @throws { BusinessError } 13600001 - IPC error. * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getCurrentBundleStats(callback: AsyncCallback): void; @@ -238,7 +244,8 @@ parameters are left unspecified; * @throws { BusinessError } 13600001 - IPC error. * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getCurrentBundleStats(): Promise; @@ -282,18 +289,20 @@ parameters are left unspecified; * @interface StorageStats * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface StorageStats { /** * The total size of device. * - * @type { number } + * @type { long } * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ - total: number; + total: long; /** * The size of audio file. @@ -360,7 +369,8 @@ parameters are left unspecified; * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getUserStorageStats(): Promise; @@ -378,7 +388,8 @@ parameters are left unspecified; * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getUserStorageStats(callback: AsyncCallback): void; @@ -386,7 +397,7 @@ parameters are left unspecified; * Get the user storage statistics. * * @permission ohos.permission.STORAGE_MANAGER - * @param { number } userId - The id of the user + * @param { long } userId - The id of the user * @returns { Promise } return Promise * @throws { BusinessError } 201 - Permission verification failed. * @throws { BusinessError } 202 - The caller is not a system application. @@ -398,15 +409,16 @@ parameters are left unspecified; * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ - function getUserStorageStats(userId: number): Promise; + function getUserStorageStats(userId: long): Promise; /** * Get the user storage statistics. * * @permission ohos.permission.STORAGE_MANAGER - * @param { number } userId - The id of the user + * @param { long } userId - The id of the user * @param { AsyncCallback } callback - callback * @throws { BusinessError } 201 - Permission verification failed. * @throws { BusinessError } 202 - The caller is not a system application. @@ -418,15 +430,16 @@ parameters are left unspecified; * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ - function getUserStorageStats(userId: number, callback: AsyncCallback): void; + function getUserStorageStats(userId: long, callback: AsyncCallback): void; /** * Get the total size. * * @permission ohos.permission.STORAGE_MANAGER - * @param { AsyncCallback } callback - callback + * @param { AsyncCallback } callback - callback * @throws { BusinessError } 201 - Permission verification failed. * @throws { BusinessError } 202 - The caller is not a system application. * @throws { BusinessError } 401 - The input parameter is invalid.Possible causes:Mandatory @@ -440,21 +453,22 @@ parameters are left unspecified; /** * Get the total size. * - * @param { AsyncCallback } callback - callback + * @param { AsyncCallback } callback - callback * @throws { BusinessError } 401 - The input parameter is invalid.Possible causes:Mandatory parameters are left unspecified; * @throws { BusinessError } 13600001 - IPC error. * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ - function getTotalSize(callback: AsyncCallback): void; + function getTotalSize(callback: AsyncCallback): void; /** * Get the total size. * * @permission ohos.permission.STORAGE_MANAGER - * @returns { Promise } return Promise + * @returns { Promise } return Promise * @throws { BusinessError } 201 - Permission verification failed. * @throws { BusinessError } 202 - The caller is not a system application. * @throws { BusinessError } 401 - The input parameter is invalid.Possible causes:Mandatory @@ -468,13 +482,14 @@ parameters are left unspecified; /** * Get the total size. * - * @returns { Promise } return Promise + * @returns { Promise } return Promise * @throws { BusinessError } 13600001 - IPC error. * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ - function getTotalSize(): Promise; + function getTotalSize(): Promise; /** * Get the total size with sync interface @@ -506,7 +521,7 @@ parameters are left unspecified; * Get the free size. * * @permission ohos.permission.STORAGE_MANAGER - * @param { AsyncCallback } callback - callback + * @param { AsyncCallback } callback - callback * @throws { BusinessError } 201 - Permission verification failed. * @throws { BusinessError } 202 - The caller is not a system application. * @throws { BusinessError } 401 - The input parameter is invalid.Possible causes:Mandatory @@ -520,21 +535,22 @@ parameters are left unspecified; /** * Get the free size. * - * @param { AsyncCallback } callback - callback + * @param { AsyncCallback } callback - callback * @throws { BusinessError } 401 - The input parameter is invalid.Possible causes:Mandatory parameters are left unspecified; * @throws { BusinessError } 13600001 - IPC error. * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ - function getFreeSize(callback: AsyncCallback): void; + function getFreeSize(callback: AsyncCallback): void; /** * Get the free size. * * @permission ohos.permission.STORAGE_MANAGER - * @returns { Promise } return Promise + * @returns { Promise } return Promise * @throws { BusinessError } 201 - Permission verification failed. * @throws { BusinessError } 202 - The caller is not a system application. * @throws { BusinessError } 401 - The input parameter is invalid.Possible causes:Mandatory @@ -548,13 +564,14 @@ parameters are left unspecified; /** * Get the free size. * - * @returns { Promise } return Promise + * @returns { Promise } return Promise * @throws { BusinessError } 13600001 - IPC error. * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.SpatialStatistics - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ - function getFreeSize(): Promise; + function getFreeSize(): Promise; /** * Get the free size with sync interface. diff --git a/api/@ohos.file.volumeManager.d.ts b/api/@ohos.file.volumeManager.d.ts index 87377b26908cc65d6daff6a84b7ff7bbb5ff8c44..1b90ba7c3f8e84830c3161ba288037868bbb7ff5 100644 --- a/api/@ohos.file.volumeManager.d.ts +++ b/api/@ohos.file.volumeManager.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (C) 2022-2023 Huawei Device Co., Ltd. + * Copyright (C) 2022-2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -26,7 +26,8 @@ import { AsyncCallback, Callback } from './@ohos.base'; * @namespace volumeManager * @syscap SystemCapability.FileManagement.StorageService.Volume * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace volumeManager { /** @@ -35,7 +36,8 @@ declare namespace volumeManager { * @interface Volume * @syscap SystemCapability.FileManagement.StorageService.Volume * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface Volume { /** @@ -54,7 +56,8 @@ declare namespace volumeManager { * @type { string } * @syscap SystemCapability.FileManagement.StorageService.Volume * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ uuid: string; @@ -74,7 +77,8 @@ declare namespace volumeManager { * @type { string } * @syscap SystemCapability.FileManagement.StorageService.Volume * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ description: string; @@ -131,7 +135,8 @@ parameters are left unspecified; * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.Volume * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllVolumes(callback: AsyncCallback>): void; @@ -148,7 +153,8 @@ parameters are left unspecified; * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.Volume * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllVolumes(): Promise>; @@ -260,7 +266,8 @@ parameters are left unspecified; * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.Volume * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getVolumeByUuid(uuid: string, callback: AsyncCallback): void; @@ -280,7 +287,8 @@ parameters are left unspecified; * @throws { BusinessError } 13900042 - Unknown error. * @syscap SystemCapability.FileManagement.StorageService.Volume * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getVolumeByUuid(uuid: string): Promise; diff --git a/api/@ohos.fileshare.d.ts b/api/@ohos.fileshare.d.ts index 2eed8dfe4473678478dcf8418d4ec86ee4ecdc9b..2990e3bfb95907ef4831e7719276d0e9cd4244dc 100644 --- a/api/@ohos.fileshare.d.ts +++ b/api/@ohos.fileshare.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (C) 2022-2024 Huawei Device Co., Ltd. + * Copyright (C) 2022-2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -38,7 +38,7 @@ declare namespace fileShare { /** * Enumerates the uri operate mode types. * - * @enum { number } OperationMode + * @enum { int } OperationMode * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 @@ -186,12 +186,12 @@ declare namespace fileShare { /** * Indicates the mode of operation for the URI, example { OperationMode.READ_MODE } or { OperationMode.READ_MODE | OperationMode.WRITE_MODE } * - * @type { number } + * @type { int } * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - operationMode: number; + operationMode: int; } /** @@ -199,8 +199,7 @@ declare namespace fileShare { * * @interface PathPolicyInfo * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ export interface PathPolicyInfo { /** @@ -208,8 +207,7 @@ declare namespace fileShare { * * @type { string } * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ path: string; @@ -218,8 +216,7 @@ declare namespace fileShare { * * @type { OperationMode } * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ operationMode: OperationMode; } @@ -229,16 +226,14 @@ declare namespace fileShare { * * @enum { number } policyType * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ export enum PolicyType { /** * Indicates that the policy is temporary. * * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ TEMPORARY_TYPE = 0, @@ -246,8 +241,7 @@ declare namespace fileShare { * Indicates that the policy is persistent. * * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ PERSISTENT_TYPE = 1, } @@ -363,7 +357,8 @@ declare namespace fileShare { * @throws { BusinessError } 13900001 - Operation not permitted. * @throws { BusinessError } 13900042 - Out of memory * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function activatePermission(policies: Array): Promise; @@ -380,7 +375,8 @@ declare namespace fileShare { * @throws { BusinessError } 13900001 - Operation not permitted. * @throws { BusinessError } 13900042 - Out of memory * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function deactivatePermission(policies: Array): Promise; @@ -427,8 +423,7 @@ declare namespace fileShare { * @throws { BusinessError } 801 - Capability not supported. * @syscap SystemCapability.FileManagement.AppFileService.FolderAuthorization * @systemapi - * @since arkts {'1.1':'15', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ function checkPathPermission(tokenID: int, policies: Array, policyType: PolicyType): Promise>; } diff --git a/api/@ohos.font.d.ets b/api/@ohos.font.d.ets deleted file mode 100644 index 13654ce8ed0c457d28cfc7973a7b905236b75c24..0000000000000000000000000000000000000000 --- a/api/@ohos.font.d.ets +++ /dev/null @@ -1,798 +0,0 @@ -/* - * Copyright (c) 2022-2024 Shenzhen Kaihong Digital Industry Development Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit ArkUI - */ -import { Resource } from './global/resource' -/** - * @namespace font - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ -/** - * @namespace font - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ -/** - * @namespace font - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - declare namespace font { - /** - * @typedef FontOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * @typedef FontOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * @typedef FontOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - export interface FontOptions { - - /** - * The font name to register. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * The font name to register. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * The font name to register. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * The font name to register. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - familyName: string | Resource; - - /** - * The path of the font file. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * The path of the font file. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * The path of the font file. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * The path of the font file. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - familySrc: string | Resource; - } - - /** - * @typedef FontInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * @typedef FontInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * @typedef FontInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - export interface FontInfo { - - /** - * The path of the font file. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * The path of the font file. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * The path of the font file. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - path: string; - - /** - * The name of postscript. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * The name of postscript. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * The name of postscript. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - postScriptName: string; - - /** - * The font name. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * The font name. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * The font name. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - fullName: string; - - /** - * A set of fonts with a common design. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * A set of fonts with a common design. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * A set of fonts with a common design. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - family: string; - - /** - * A subset of the font family. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * A subset of the font family. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * A subset of the font family. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - subfamily: string; - - /** - * The weight of the font. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * The weight of the font. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * The weight of the font. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - weight: number; - - /** - * The width of the font style. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * The width of the font style. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * The width of the font style. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - width: number; - - /** - * Whether it is italic. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Whether it is italic. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * Whether it is italic. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - italic: boolean; - - /** - * Whether it is compact. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Whether it is compact. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * Whether it is compact. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - monoSpace: boolean; - - /** - * Whether symbol fonts are supported. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Whether symbol fonts are supported. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * Whether symbol fonts are supported. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - symbolic: boolean; - } - - /** - * @typedef UIFontConfig - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * @typedef UIFontConfig - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - export interface UIFontConfig { - /** - * The paths of system font files. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * The paths of system font files. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - fontDir: Array; - - /** - * The generic font info. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * The generic font info. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - generic: Array; - - /** - * The fallback font info. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * The fallback font info. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - fallbackGroups: Array; - } - - /** - * @typedef UIFontGenericInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * @typedef UIFontGenericInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - export interface UIFontGenericInfo { - /** - * Name of the font set. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Name of the font set. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - family: string; - - /** - * Alias info of the font set. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Alias info of the font set. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - alias: Array; - - /** - * Adjust info of the font set. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Adjust info of the font set. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - adjust: Array; - } - - /** - * @typedef UIFontAliasInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * @typedef UIFontAliasInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - export interface UIFontAliasInfo { - /** - * Font set name. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Font set name. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - name: string; - - /** - * Weight the font set contains only fonts with, if weight = 0, - * this font set can contain fonts with any weight. - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Weight the font set contains only fonts with, if weight = 0, - * this font set can contain fonts with any weight. - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - weight: number; - } - - /** - * @typedef UIFontAdjustInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * @typedef UIFontAdjustInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - export interface UIFontAdjustInfo { - /** - * Original weight of the font - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Original weight of the font - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - weight: number; - /** - * Font weight displayed in the app - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Font weight displayed in the app - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - to: number; - } - - /** - * @typedef UIFontFallbackGroupInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * @typedef UIFontFallbackGroupInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - export interface UIFontFallbackGroupInfo { - /** - * Indicates which font set uses following list for fallback font - * if the font set name is "", it means that the following list can be fallback font for all font sets. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Indicates which font set uses following list for fallback font - * if the font set name is "", it means that the following list can be fallback font for all font sets. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - fontSetName: string; - - /** - * Fallback font list related. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Fallback font list related. - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - fallback: Array; - } - - /** - * @typedef UIFontFallbackInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * @typedef UIFontFallbackInfo - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - export interface UIFontFallbackInfo { - /** - * Language that font set support. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Language that font set support. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - language: string; - - /** - * Font name related. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Font name related. - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - family: string; - } - - /** - * Register a customized font in the FontManager. - * - * @param { FontOptions } options - FontOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Register a customized font in the FontManager. - * - * @param { FontOptions } options - FontOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * Register a customized font in the FontManager. - * - * @param { FontOptions } options - FontOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - export function registerFont(options: FontOptions): void; - - /** - * Gets a list of fonts supported by system. - * - * @returns { Array } A list of font names - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Gets a list of fonts supported by system. - * - * @returns { Array } A list of font names - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * Gets a list of fonts supported by system. - * - * @returns { Array } A list of font names - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - export function getSystemFontList(): Array; - - /** - * Get font details according to the font name. - * - * @param { string } fontName - font name - * @returns { FontInfo } Returns the font info - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Get font details according to the font name. - * - * @param { string } fontName - font name - * @returns { FontInfo } Returns the font info - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 11 - */ - /** - * Get font details according to the font name. - * - * @param { string } fontName - font name - * @returns { FontInfo } Returns the font info - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - export function getFontByName(fontName: string): FontInfo; - - /** - * Get font details according to the font name. - * - * @returns { UIFontConfig } Returns the ui font config - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 - */ - /** - * Get font details according to the font name. - * - * @returns { UIFontConfig } Returns the ui font config - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 - */ - export function getUIFontConfig(): UIFontConfig; -} - -export default font; \ No newline at end of file diff --git a/api/@ohos.font.d.ts b/api/@ohos.font.d.ts index 3bddff9027228945f0b911560d625daecb14133c..4a8422fd69866d2cda2a8c382a37841b5c387f0c 100644 --- a/api/@ohos.font.d.ts +++ b/api/@ohos.font.d.ts @@ -17,9 +17,6 @@ * @file * @kit ArkUI */ -/*** if arkts 1.2 */ -import { Resource } from './global/resource' -/*** endif */ /** * @namespace font @@ -37,8 +34,7 @@ import { Resource } from './global/resource' * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ declare namespace font { /** @@ -57,8 +53,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface FontOptions { @@ -91,8 +86,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ familyName: string | Resource; @@ -125,8 +119,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ familySrc: string | Resource; } @@ -147,8 +140,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface FontInfo { @@ -174,8 +166,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ path: string; @@ -201,8 +192,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ postScriptName: string; @@ -228,8 +218,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fullName: string; @@ -255,8 +244,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ family: string; @@ -282,8 +270,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ subfamily: string; @@ -309,8 +296,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ weight: number; @@ -336,8 +322,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width: number; @@ -363,8 +348,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ italic: boolean; @@ -390,8 +374,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ monoSpace: boolean; @@ -417,8 +400,7 @@ declare namespace font { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ symbolic: boolean; } @@ -432,8 +414,7 @@ declare namespace font { * @typedef UIFontConfig * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface UIFontConfig { /** @@ -447,8 +428,7 @@ declare namespace font { * @type { Array } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontDir: Array; @@ -463,8 +443,7 @@ declare namespace font { * @type { Array } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ generic: Array; @@ -479,8 +458,7 @@ declare namespace font { * @type { Array } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fallbackGroups: Array; } @@ -494,8 +472,7 @@ declare namespace font { * @typedef UIFontGenericInfo * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface UIFontGenericInfo { /** @@ -509,8 +486,7 @@ declare namespace font { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ family: string; @@ -525,8 +501,7 @@ declare namespace font { * @type { Array } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ alias: Array; @@ -541,8 +516,7 @@ declare namespace font { * @type { Array } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ adjust: Array; } @@ -556,8 +530,7 @@ declare namespace font { * @typedef UIFontAliasInfo * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface UIFontAliasInfo { /** @@ -571,8 +544,7 @@ declare namespace font { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ name: string; @@ -589,8 +561,7 @@ declare namespace font { * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ weight: number; } @@ -604,8 +575,7 @@ declare namespace font { * @typedef UIFontAdjustInfo * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface UIFontAdjustInfo { /** @@ -619,8 +589,7 @@ declare namespace font { * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ weight: number; /** @@ -634,8 +603,7 @@ declare namespace font { * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ to: number; } @@ -649,8 +617,7 @@ declare namespace font { * @typedef UIFontFallbackGroupInfo * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface UIFontFallbackGroupInfo { /** @@ -666,8 +633,7 @@ declare namespace font { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fontSetName: string; @@ -682,8 +648,7 @@ declare namespace font { * @type { Array } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ fallback: Array; } @@ -697,8 +662,7 @@ declare namespace font { * @typedef UIFontFallbackInfo * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface UIFontFallbackInfo { /** @@ -712,8 +676,7 @@ declare namespace font { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ language: string; @@ -728,8 +691,7 @@ declare namespace font { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ family: string; } @@ -834,8 +796,7 @@ declare namespace font { * @returns { UIFontConfig } Returns the ui font config * @syscap SystemCapability.ArkUI.ArkUI.Full * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function getUIFontConfig(): UIFontConfig; } diff --git a/api/@ohos.font.static.d.ets b/api/@ohos.font.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..45c3c8010b099268c22a13b439282d2468f4fee4 --- /dev/null +++ b/api/@ohos.font.static.d.ets @@ -0,0 +1,291 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ +import { Resource } from './global/resource'; + +/** + * @namespace font + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace font { + /** + * @typedef FontOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface FontOptions { + /** + * The font name to register. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + familyName: string | Resource; + + /** + * The path of the font file. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + familySrc: string | Resource; + } + /** + * @typedef FontInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface FontInfo { + /** + * The path of the font file. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + path: string; + /** + * The name of postscript. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + postScriptName: string; + /** + * The font name. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fullName: string; + /** + * A set of fonts with a common design. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + family: string; + /** + * A subset of the font family. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + subfamily: string; + /** + * The weight of the font. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + weight: number; + /** + * The width of the font style. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + width: number; + /** + * Whether it is italic. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + italic: boolean; + /** + * Whether it is compact. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + monoSpace: boolean; + /** + * Whether symbol fonts are supported. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolic: boolean; + } + /** + * @typedef UIFontConfig + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface UIFontConfig { + /** + * The paths of system font files. + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontDir: Array; + /** + * The generic font info. + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + generic: Array; + /** + * The fallback font info. + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fallbackGroups: Array; + } + /** + * @typedef UIFontGenericInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface UIFontGenericInfo { + /** + * Name of the font set. + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + family: string; + /** + * Alias info of the font set. + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + alias: Array; + /** + * Adjust info of the font set. + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + adjust: Array; + } + /** + * @typedef UIFontAliasInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface UIFontAliasInfo { + /** + * Font set name. + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + name: string; + /** + * Weight the font set contains only fonts with, if weight = 0, + * this font set can contain fonts with any weight. + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + weight: number; + } + /** + * @typedef UIFontAdjustInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface UIFontAdjustInfo { + /** + * Original weight of the font + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + weight: number; + /** + * Font weight displayed in the app + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + to: number; + } + /** + * @typedef UIFontFallbackGroupInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface UIFontFallbackGroupInfo { + /** + * Indicates which font set uses following list for fallback font + * if the font set name is "", it means that the following list can be fallback font for all font sets. + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fontSetName: string; + /** + * Fallback font list related. + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + fallback: Array; + } + /** + * @typedef UIFontFallbackInfo + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + interface UIFontFallbackInfo { + /** + * Language that font set support. + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + language: string; + /** + * Font name related. + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + family: string; + } + /** + * Get font details according to the font name. + * + * @returns { UIFontConfig } Returns the ui font config + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + function getUIFontConfig(): UIFontConfig; +} +export default font; diff --git a/api/@ohos.fontManager.d.ts b/api/@ohos.fontManager.d.ts index b661f598b4f08afe8209269441a837a1cc5edb77..8f010e87fffd6b004eaead77fbc0855e1100ad50 100644 --- a/api/@ohos.fontManager.d.ts +++ b/api/@ohos.fontManager.d.ts @@ -33,7 +33,7 @@ declare namespace fontManager { * * @permission ohos.permission.UPDATE_FONT * @param { string } path - path indicates the font path. - * @returns { Promise } - int indicates the font installation result. + * @returns { Promise } - Number indicates the font installation result. * 0 - Install successful. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 202 - Non-system application. @@ -55,7 +55,7 @@ declare namespace fontManager { * * @permission ohos.permission.UPDATE_FONT * @param { string } fullName - fullName indicates the font name. - * @returns { Promise } - int indicates the font uninstallation result. + * @returns { Promise } - number indicates the font uninstallation result. * 0 - Uninstall successful. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 202 - Non-system application. diff --git a/api/@ohos.geoLocationManager.d.ts b/api/@ohos.geoLocationManager.d.ts index 74511e841d3fd3e8d4d97e0e90c6bc626bfec255..6e00ad602d8f547d7c488d804de7dd9475b3e73e 100644 --- a/api/@ohos.geoLocationManager.d.ts +++ b/api/@ohos.geoLocationManager.d.ts @@ -1439,62 +1439,62 @@ declare namespace geoLocationManager { /** * Number of satellites. * - * @type { number } + * @type { int } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - satellitesNumber: number; + satellitesNumber: int; /** * Satellite ID array. * - * @type { Array } + * @type { Array } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - satelliteIds: Array; + satelliteIds: Array; /** * Carrier to noise density array. * - * @type { Array } + * @type { Array } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - carrierToNoiseDensitys: Array; + carrierToNoiseDensitys: Array; /** * Satellite altitude array. * - * @type { Array } + * @type { Array } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - altitudes: Array; + altitudes: Array; /** * Satellite azimuth array. * - * @type { Array } + * @type { Array } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - azimuths: Array; + azimuths: Array; /** * Satellite carrier frequency array. * - * @type { Array } + * @type { Array } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - carrierFrequencies: Array; + carrierFrequencies: Array; /** * Satellite constellation type array. @@ -1509,12 +1509,12 @@ declare namespace geoLocationManager { /** * Satellite additional information array. * - * @type { ?Array } + * @type { ?Array } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - satelliteAdditionalInfo?: Array; + satelliteAdditionalInfo?: Array; } /** @@ -1529,12 +1529,12 @@ declare namespace geoLocationManager { /** * GNSS cache location report period. * - * @type { number } + * @type { int } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - reportingPeriodSec: number; + reportingPeriodSec: int; /** * Indicates whether to wake up the listener when the GNSS cache location queue is full. @@ -1705,32 +1705,32 @@ declare namespace geoLocationManager { /** * Latitude for reverse geocoding query. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - latitude: number; + latitude: double; /** * Longitude for reverse geocoding query. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - longitude: number; + longitude: double; /** * Indicates the maximum number of addresses returned by reverse geocoding query. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - maxItems?: number; + maxItems?: int; } /** @@ -1775,52 +1775,52 @@ declare namespace geoLocationManager { /** * Indicates the maximum number of geocode query results. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - maxItems?: number; + maxItems?: int; /** * Indicates the minimum latitude for geocoding query results. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - minLatitude?: number; + minLatitude?: double; /** * Indicates the minimum longitude for geocoding query results. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - minLongitude?: number; + minLongitude?: double; /** * Indicates the maximum latitude for geocoding query results. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - maxLatitude?: number; + maxLatitude?: double; /** * Indicates the maximum longitude for geocoding query results. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - maxLongitude?: number; + maxLongitude?: double; } /** @@ -1837,24 +1837,24 @@ declare namespace geoLocationManager { * A positive value indicates north latitude, * and a negative value indicates south latitude. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - latitude?: number; + latitude?: double; /** * Indicates longitude information. * A positive value indicates east longitude , * and a negative value indicates west longitude. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - longitude?: number; + longitude?: double; /** * Indicates language used for the location description. @@ -2010,12 +2010,12 @@ declare namespace geoLocationManager { /** * Indicates the amount of additional descriptive information. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Geocoder * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ - descriptionsSize?: number; + descriptionsSize?: int; /** * Indicates whether it is an mock GeoAddress @@ -2085,56 +2085,56 @@ declare namespace geoLocationManager { /** * Location report interval. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Location report interval. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - timeInterval?: number; + timeInterval?: int; /** * Location report distance interval. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Location report distance interval. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - distanceInterval?: number; + distanceInterval?: double; /** * Accuracy requirements for reporting locations. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Accuracy requirements for reporting locations. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - maxAccuracy?: number; + maxAccuracy?: double; } /** @@ -2193,38 +2193,38 @@ declare namespace geoLocationManager { /** * Accuracy requirements for reporting locations. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Accuracy requirements for reporting locations. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - maxAccuracy?: number; + maxAccuracy?: double; /** * Timeout interval of a single location request. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Timeout interval of a single location request. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - timeoutMs?: number; + timeoutMs?: int; } /** @@ -2267,13 +2267,13 @@ declare namespace geoLocationManager { /** * Location report interval, in seconds. * - * @type { number } + * @type { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - interval: number; + interval: int; /** * Location scenario. You can select a user activity scenario or power consumption scenario. @@ -2334,13 +2334,13 @@ declare namespace geoLocationManager { /** * Timeout of a single location request, in milliseconds. * - * @type { number } + * @type { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - locatingTimeoutMs: number; + locatingTimeoutMs: int; /** * Indicates whether to obtain POI information near the current location. @@ -2375,7 +2375,7 @@ declare namespace geoLocationManager { * A positive value indicates north latitude, * and a negative value indicates south latitude. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ @@ -2384,20 +2384,20 @@ declare namespace geoLocationManager { * A positive value indicates north latitude, * and a negative value indicates south latitude. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - latitude: number; + latitude: double; /** * Indicates Longitude information. * A positive value indicates east longitude , * and a negative value indicates west longitude. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ @@ -2406,121 +2406,121 @@ declare namespace geoLocationManager { * A positive value indicates east longitude , * and a negative value indicates west longitude. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - longitude: number; + longitude: double; /** * Indicates location altitude, in meters. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Indicates location altitude, in meters. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - altitude: number; + altitude: double; /** * Indicates location accuracy, in meters. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Indicates location accuracy, in meters. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - accuracy: number; + accuracy: double; /** * Indicates speed, in m/s. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Indicates speed, in m/s. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - speed: number; + speed: double; /** * Indicates location timestamp in the UTC format. * - * @type { number } + * @type { long } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Indicates location timestamp in the UTC format. * - * @type { number } + * @type { long } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - timeStamp: number; + timeStamp: long; /** * Indicates direction information. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Indicates direction information. * - * @type { number } + * @type { double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - direction: number; + direction: double; /** * Indicates location timestamp since boot. * - * @type { number } + * @type { long } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Indicates location timestamp since boot. * - * @type { number } + * @type { long } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - timeSinceBoot: number; + timeSinceBoot: long; /** * Indicates additional information. @@ -2554,20 +2554,20 @@ declare namespace geoLocationManager { /** * Indicates the amount of additional descriptive information. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Indicates the amount of additional descriptive information. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - additionSize?: number; + additionSize?: int; /** * Indicates whether it is an mock location. @@ -2583,46 +2583,46 @@ declare namespace geoLocationManager { /** * Indicates vertical position accuracy in meters. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - altitudeAccuracy?: number; + altitudeAccuracy?: double; /** * Indicates speed accuracy in meter per seconds. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - speedAccuracy?: number; + speedAccuracy?: double; /** * Indicates direction accuracy in degrees. * - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - directionAccuracy?: number; + directionAccuracy?: double; /** * Time uncertainty Of timeSinceBoot in nanosecond. * - * @type { ?number } + * @type { ?long } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - uncertaintyOfTimeSinceBoot?: number; + uncertaintyOfTimeSinceBoot?: long; /** * Indicates the source of the location. @@ -2681,25 +2681,25 @@ declare namespace geoLocationManager { * Indicates the interval between scans. The unit is millisecond. * This parameter needs to be set only when scanning information is continuously monitored. * - * @type {?number} + * @type {?int} * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - scanInterval?: number; + scanInterval?: int; /** * Indicates the timeout period of a single scan. The unit is millisecond. The default value is 10000. * This parameter needs to be set only when getLocatingRequiredData is used. * - * @type {?number} + * @type {?int} * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - scanTimeout?: number; + scanTimeout?: int; } /** @@ -2768,35 +2768,35 @@ declare namespace geoLocationManager { /** * Received signal strength indicator (RSSI). * - * @type {number} + * @type {int} * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - rssi: number; + rssi: int; /** * Frequency * - * @type {number} + * @type {int} * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - frequency: number; + frequency: int; /** * Time stamp. * - * @type {number} + * @type {long} * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - timestamp: number; + timestamp: long; } /** @@ -2834,24 +2834,24 @@ declare namespace geoLocationManager { /** * RSSI of the remote device. * - * @type {number} + * @type {int} * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - rssi: number; + rssi: int; /** * Time stamp. * - * @type {number} + * @type {long} * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - timestamp: number; + timestamp: long; } /** @@ -2876,12 +2876,12 @@ declare namespace geoLocationManager { /** * RSSI of the scanned device * - * @type { number } + * @type { int } * @syscap SystemCapability.Location.Location.Core * @since arkts {'1.1':'16','1.2':'20'} * @arkts 1.1&1.2 */ - rssi: number; + rssi: int; /** * The raw data of broadcast packet @@ -3058,7 +3058,7 @@ declare namespace geoLocationManager { /** * Enum for the source of the location. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} @@ -3109,7 +3109,7 @@ declare namespace geoLocationManager { /** * Enum for coordinate system type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Geofence * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 @@ -3137,7 +3137,7 @@ declare namespace geoLocationManager { /** * Enum for location icon status. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'12','1.2':'20'} @@ -3178,7 +3178,7 @@ declare namespace geoLocationManager { /** * Enum for location error code. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} @@ -3239,7 +3239,7 @@ declare namespace geoLocationManager { /** * Enum for geofence transition status. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Geofence * @since 12 */ @@ -3272,7 +3272,7 @@ declare namespace geoLocationManager { /** * Enum for satellite constellation category. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 @@ -3354,7 +3354,7 @@ declare namespace geoLocationManager { /** * Enum for satellite additional information. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Gnss * @since arkts {'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 @@ -3409,7 +3409,7 @@ declare namespace geoLocationManager { /** * Enum for user activity scenario. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} @@ -3460,7 +3460,7 @@ declare namespace geoLocationManager { /** * Enum for locating priority. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} @@ -3491,14 +3491,14 @@ declare namespace geoLocationManager { /** * Enum for location priority. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Enum for location priority. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} @@ -3573,14 +3573,14 @@ declare namespace geoLocationManager { /** * Enum for location scenario. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @since 9 */ /** * Enum for location scenario. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'11','1.2':'20'} @@ -3687,7 +3687,7 @@ declare namespace geoLocationManager { /** * Enum for power consumption scenario. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} @@ -3728,7 +3728,7 @@ declare namespace geoLocationManager { /** * Enum for location privacy type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'9','1.2':'20'} @@ -3769,7 +3769,7 @@ declare namespace geoLocationManager { /** * Enum for sports type * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @atomicservice * @since arkts {'1.1':'18','1.2':'20'} @@ -3867,7 +3867,7 @@ declare namespace geoLocationManager { /** * Enum for country code type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @since arkts {'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 @@ -3913,7 +3913,7 @@ declare namespace geoLocationManager { /** * Enum for locating required data type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Location.Location.Core * @systemapi * @since arkts {'1.1':'10','1.2':'20'} diff --git a/api/@ohos.graphics.common2D.d.ts b/api/@ohos.graphics.common2D.d.ts index 3795b8afdeb1c71eda0df0636182a5f642130fda..9e9838befe546e2d2cfbdf252af2164abade7d88 100644 --- a/api/@ohos.graphics.common2D.d.ts +++ b/api/@ohos.graphics.common2D.d.ts @@ -36,36 +36,64 @@ declare namespace common2D { interface Color { /** * Alpha component of the color. The value is an integer ranging from 0 to 255. - * @type { number } + * @type { int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Alpha component of the color. The value is an integer ranging from 0 to 255. + * @type { int } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - alpha: number; + alpha: int; /** * Red component of the color. The value is an integer ranging from 0 to 255. - * @type { number } + * @type { int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Red component of the color. The value is an integer ranging from 0 to 255. + * @type { int } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - red: number; + red: int; + /** + * Green component of the color. The value is an integer ranging from 0 to 255. + * @type { int } + * @syscap SystemCapability.Graphics.Drawing + * @since 11 + */ /** * Green component of the color. The value is an integer ranging from 0 to 255. - * @type { number } + * @type { int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - green: number; + green: int; + /** + * Blue component of the color. The value is an integer ranging from 0 to 255. + * @type { int } + * @syscap SystemCapability.Graphics.Drawing + * @since 11 + */ /** * Blue component of the color. The value is an integer ranging from 0 to 255. - * @type { number } + * @type { int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - blue: number; + blue: int; } /** @@ -78,36 +106,64 @@ declare namespace common2D { interface Rect { /** * X coordinate of the upper left corner of the rectangle. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * X coordinate of the upper left corner of the rectangle. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - left: number; + left: double; + /** + * Y coordinate of the upper left corner of the rectangle. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @since 11 + */ /** * Y coordinate of the upper left corner of the rectangle. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - top: number; + top: double; /** * X coordinate of the lower right corner of the rectangle. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * X coordinate of the lower right corner of the rectangle. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - right: number; + right: double; /** * Y coordinate of the lower right corner of the rectangle. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Y coordinate of the lower right corner of the rectangle. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - bottom: number; + bottom: double; } /** @@ -120,21 +176,35 @@ declare namespace common2D { interface Point { /** * Horizontal coordinate. The value is a floating point number. - * @type { number } + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @since 12 + */ + /** + * Horizontal coordinate. The value is a floating point number. + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'12', '1.2':'20'} + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - x: number; + x: double; /** * Vertical coordinate. The value is a floating point number. - * @type { number } + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @since 12 + */ + /** + * Vertical coordinate. The value is a floating point number. + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'12', '1.2':'20'} + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - y: number; + y: double; } /** @@ -148,11 +218,18 @@ declare namespace common2D { interface Point3d extends Point { /** * Z-axis coordinate. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - z: number; + /** + * Z-axis coordinate. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + z: double; } /** @@ -165,36 +242,36 @@ declare namespace common2D { interface Color4f { /** * Alpha component of color, represented as a floating point number between 0 and 1. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - alpha: number; + alpha: double; /** * Red component of color, represented as a floating point number between 0 and 1. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - red: number; + red: double; /** * Green component of color, represented as a floating point number between 0 and 1. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - green: number; + green: double; /** * Blue component of color, represented as a floating point number between 0 and 1. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - blue: number; + blue: double; } } diff --git a/api/@ohos.graphics.drawing.d.ts b/api/@ohos.graphics.drawing.d.ts index 3f52a32d8040d7b369180345290040a404fcdc87..00cfbe02520788b51f8d3e305d8e5bf51ee8cdd5 100644 --- a/api/@ohos.graphics.drawing.d.ts +++ b/api/@ohos.graphics.drawing.d.ts @@ -51,7 +51,7 @@ declare namespace drawing { * rc: used when the other three color channels are manipulated. * The table below shows the effect of each blend mode, where the yellow rectangle is the source and the blue circle is the destination. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 @@ -265,7 +265,7 @@ declare namespace drawing { /** * Enumerates the directions of a closed contour. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -287,7 +287,7 @@ declare namespace drawing { /** * Enumerates the fill types of a path. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -330,7 +330,7 @@ declare namespace drawing { /** * Enumerates the dimensions of matrix information in path measurement. * It is often used in animation scenarios where objects move along a path. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -374,30 +374,63 @@ declare namespace drawing { constructor(roundRect: RoundRect); /** - * A constructor used to create a RoundRect object. A rounded rectangle is created when both xRadii and yRadii are greater than 0. + * A constructor used to create a RoundRect object. + * A rounded rectangle is created when both xRadii and yRadii are greater than 0. * Otherwise, only a rectangle is created. * @param { common2D.Rect } rect - Rectangle that encloses the rounded rectangle to create. - * @param { number } xRadii - Radius of the rounded corner on the X axis. The value is a floating point number. A negative number is invalid. - * @param { number } yRadii - Radius of the rounded corner on the Y axis. The value is a floating point number. A negative number is invalid. + * @param { double } xRadii - Radius of the rounded corner on the X axis. + * The value is a floating point number. A negative number is invalid. + * @param { double } yRadii - Radius of the rounded corner on the Y axis. + * The value is a floating point number. A negative number is invalid. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'12', '1.2':'20'} + * @since 12 + */ + /** + * A constructor used to create a RoundRect object. + * A rounded rectangle is created when both xRadii and yRadii are greater than 0. + * Otherwise, only a rectangle is created. + * @param { common2D.Rect } rect - Rectangle that encloses the rounded rectangle to create. + * @param { double } xRadii - Radius of the rounded corner on the X axis. + * The value is a floating point number. A negative number is invalid. + * @param { double } yRadii - Radius of the rounded corner on the Y axis. + * The value is a floating point number. A negative number is invalid. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - constructor(rect: common2D.Rect, xRadii: number, yRadii: number); + constructor(rect: common2D.Rect, xRadii: double, yRadii: double); /** * Sets the radii of the specified rounded corner in this rounded rectangle. * @param { CornerPos } pos - Position of the rounded corner. - * @param { number } x - Radius of the rounded corner on the X axis. The value is a floating point number. A negative number is invalid. - * @param { number } y - Radius of the rounded corner on the Y axis. The value is a floating point number. A negative number is invalid. + * @param { double } x - Radius of the rounded corner on the X axis. + * The value is a floating point number. A negative number is invalid. + * @param { double } y - Radius of the rounded corner on the Y axis. + * The value is a floating point number. A negative number is invalid. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setCorner(pos: CornerPos, x: number, y: number): void; + /** + * Sets the radii of the specified rounded corner in this rounded rectangle. + * @param { CornerPos } pos - Position of the rounded corner. + * @param { double } x - Radius of the rounded corner on the X axis. + * The value is a floating point number. A negative number is invalid. + * @param { double } y - Radius of the rounded corner on the Y axis. + * The value is a floating point number. A negative number is invalid. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setCorner(pos: CornerPos, x: double, y: double): void; /** * Obtains the radii of the specified rounded corner in this rounded rectangle. @@ -413,21 +446,37 @@ declare namespace drawing { /** * Translates this rounded rectangle by an offset along the X axis and Y axis. - * @param { number } dx - Horizontal distance to translate. A positive number indicates a translation towards the positive direction of the X axis, - * and a negative number indicates a translation towards the negative direction of the X axis. The value is a floating point number. - * @param { number } dy - Vertical distance to translate. A positive number indicates a translation towards the positive direction of the Y axis, - * and a negative number indicates a translation towards the negative direction of the Y axis. The value is a floating point number. + * @param { double } dx - Horizontal distance to translate. A positive number indicates a translation towards + * the positive direction of the X axis, and a negative number indicates a translation towards the negative + * direction of the X axis. The value is a floating point number. + * @param { double } dy - Vertical distance to translate. A positive number indicates a translation towards + * the positive direction of the Y axis, and a negative number indicates a translation towards the negative + * direction of the Y axis. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - offset(dx: number, dy: number): void; + /** + * Translates this rounded rectangle by an offset along the X axis and Y axis. + * @param { double } dx - Horizontal distance to translate. A positive number indicates a translation towards + * the positive direction of the X axis, and a negative number indicates a translation towards the negative + * direction of the X axis. The value is a floating point number. + * @param { double } dy - Vertical distance to translate. A positive number indicates a translation towards + * the positive direction of the Y axis, and a negative number indicates a translation towards the negative + * direction of the Y axis. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + offset(dx: double, dy: double): void; } /** * Enumerates the path operation types. It is often used in path combination and clipping scenarios. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 @@ -476,7 +525,7 @@ declare namespace drawing { /** * Enumerates the path operation types contained in an iterator. It is used to read path operation instructions. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 18 */ @@ -551,14 +600,27 @@ declare namespace drawing { /** * Retrieves the next operation in this path and moves the iterator to that operation. * @param { Array } points - Indicates the point array. - * @param { number } offset - Indicates the offset into the array where entries should be placed. The default value is 0. + * @param { int } [offset] - Indicates the offset into the array where entries should be placed. + * The default value is 0. * @returns { PathIteratorVerb } Returns the next verb in this iterator's path. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - next(points: Array, offset?: number): PathIteratorVerb; + /** + * Retrieves the next operation in this path and moves the iterator to that operation. + * @param { Array } points - Indicates the point array. + * @param { int } [offset] - Indicates the offset into the array where entries should be placed. + * The default value is 0. + * @returns { PathIteratorVerb } Returns the next verb in this iterator's path. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + next(points: Array, offset?: int): PathIteratorVerb; /** * Retrieves the next operation in this path, without moving the iterator. @@ -613,174 +675,414 @@ declare namespace drawing { /** * Sets the start point of this path. - * @param { number } x - X coordinate of the start point. The value is a floating point number. - * @param { number } y - Y coordinate of the start point. The value is a floating point number. + * @param { double } x - X coordinate of the start point. The value is a floating point number. + * @param { double } y - Y coordinate of the start point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - moveTo(x: number, y: number): void; + /** + * Sets the start point of this path. + * @param { double } x - X coordinate of the start point. The value is a floating point number. + * @param { double } y - Y coordinate of the start point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + moveTo(x: double, y: double): void; /** - * Draws a line segment from the last point of this path to the target point. If the path is empty, the start point (0, 0) is used. - * @param { number } x - X coordinate of the target point. The value is a floating point number. - * @param { number } y - Y coordinate of the target point. The value is a floating point number. + * Draws a line segment from the last point of this path to the target point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } x - X coordinate of the target point. The value is a floating point number. + * @param { double } y - Y coordinate of the target point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - lineTo(x: number, y: number): void; + /** + * Draws a line segment from the last point of this path to the target point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } x - X coordinate of the target point. The value is a floating point number. + * @param { double } y - Y coordinate of the target point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + lineTo(x: double, y: double): void; /** * Draws an arc to this path using angle arc mode. This mode first defines a rectangle and takes its inscribed ellipse. * Then, it specifies a start angle and a sweep angle. The arc is the portion of the ellipse's circumference defined by the start angle * and the sweep angle. By default, a line segment from the last point of the path to the start point of the arc is also added. - * @param { number } x1 - X coordinate of the upper left corner of the rectangle. The value is a floating point number. - * @param { number } y1 - Y coordinate of the upper left corner of the rectangle. The value is a floating point number. - * @param { number } x2 - X coordinate of the lower right corner of the rectangle. The value is a floating point number. - * @param { number } y2 - Y coordinate of the lower right corner of the rectangle. The value is a floating point number. - * @param { number } startDeg - Start angle. The start direction (0°) of the angle is the positive direction of the X axis. - * @param { number } sweepDeg - Angle to sweep, in degrees. A positive number indicates a clockwise sweep, - * and a negative value indicates a counterclockwise swipe. The actual swipe degree is the modulo operation result of the input parameter by 360. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + * @param { double } x1 - X coordinate of the upper left corner of the rectangle. + * The value is a floating point number. + * @param { double } y1 - Y coordinate of the upper left corner of the rectangle. + * The value is a floating point number. + * @param { double } x2 - X coordinate of the lower right corner of the rectangle. + * The value is a floating point number. + * @param { double } y2 - Y coordinate of the lower right corner of the rectangle. + * The value is a floating point number. + * @param { double } startDeg - Start angle. The start direction (0°) of the angle is + * the positive direction of the X axis. + * @param { double } sweepDeg - Angle to sweep, in degrees. A positive number indicates a clockwise sweep, + * and a negative value indicates a counterclockwise swipe. + * The actual swipe degree is the modulo operation result of the input parameter by 360. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Draws an arc to this path using angle arc mode. + * This mode first defines a rectangle and takes its inscribed ellipse. + * Then, it specifies a start angle and a sweep angle. + * The arc is the portion of the ellipse's circumference defined by the start angle and the sweep angle. By default, + * a line segment from the last point of the path to the start point of the arc is also added. + * @param { double } x1 - X coordinate of the upper left corner of the rectangle. + * The value is a floating point number. + * @param { double } y1 - Y coordinate of the upper left corner of the rectangle. + * The value is a floating point number. + * @param { double } x2 - X coordinate of the lower right corner of the rectangle. + * The value is a floating point number. + * @param { double } y2 - Y coordinate of the lower right corner of the rectangle. + * The value is a floating point number. + * @param { double } startDeg - Start angle. The start direction (0°) of the angle is + * the positive direction of the X axis. + * @param { double } sweepDeg - Angle to sweep, in degrees. A positive number indicates a clockwise sweep, + * and a negative value indicates a counterclockwise swipe. + * The actual swipe degree is the modulo operation result of the input parameter by 360. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - arcTo(x1: number, y1: number, x2: number, y2: number, startDeg: number, sweepDeg: number): void; + arcTo(x1: double, y1: double, x2: double, y2: double, startDeg: double, sweepDeg: double): void; /** - * Draws a quadratic Bezier curve from the last point of this path to the target point. If the path is empty, the start point (0, 0) is used. - * @param { number } ctrlX - X coordinate of the control point. The value is a floating point number. - * @param { number } ctrlY - Y coordinate of the control point. The value is a floating point number. - * @param { number } endX - X coordinate of the target point. The value is a floating point number. - * @param { number } endY - Y coordinate of the target point. The value is a floating point number. + * Draws a quadratic Bezier curve from the last point of this path to the target point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX - X coordinate of the control point. The value is a floating point number. + * @param { double } ctrlY - Y coordinate of the control point. The value is a floating point number. + * @param { double } endX - X coordinate of the target point. The value is a floating point number. + * @param { double } endY - Y coordinate of the target point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - quadTo(ctrlX: number, ctrlY: number, endX: number, endY: number): void; + /** + * Draws a quadratic Bezier curve from the last point of this path to the target point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX - X coordinate of the control point. The value is a floating point number. + * @param { double } ctrlY - Y coordinate of the control point. The value is a floating point number. + * @param { double } endX - X coordinate of the target point. The value is a floating point number. + * @param { double } endY - Y coordinate of the target point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + quadTo(ctrlX: double, ctrlY: double, endX: double, endY: double): void; /** - * Draws a conic curve from the last point of this path to the target point. If the path is empty, the start point (0, 0) is used. - * @param { number } ctrlX - X coordinate of the control point. The value is a floating point number. - * @param { number } ctrlY - Y coordinate of the control point. The value is a floating point number. - * @param { number } endX - X coordinate of the target point. The value is a floating point number. - * @param { number } endY - Y coordinate of the target point. The value is a floating point number. - * @param { number } weight - Weight of the curve, which determines its shape. The larger the value, - * the closer of the curve to the control point. If the value is less than or equal to 0, - * this API has the same effect as lineTo. If the value is 1, it has the same effect as quadTo. The value is a floating point number. + * Draws a conic curve from the last point of this path to the target point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX - X coordinate of the control point. The value is a floating point number. + * @param { double } ctrlY - Y coordinate of the control point. The value is a floating point number. + * @param { double } endX - X coordinate of the target point. The value is a floating point number. + * @param { double } endY - Y coordinate of the target point. The value is a floating point number. + * @param { double } weight - Weight of the curve, which determines its shape. The larger the value, + * the closer of the curve to the control point. If the value is less than or equal to 0, + * this API has the same effect as lineTo. If the value is 1, it has the same effect as quadTo. + * The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - conicTo(ctrlX: number, ctrlY: number, endX: number, endY: number, weight: number): void; + /** + * Draws a conic curve from the last point of this path to the target point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX - X coordinate of the control point. The value is a floating point number. + * @param { double } ctrlY - Y coordinate of the control point. The value is a floating point number. + * @param { double } endX - X coordinate of the target point. The value is a floating point number. + * @param { double } endY - Y coordinate of the target point. The value is a floating point number. + * @param { double } weight - Weight of the curve, which determines its shape. The larger the value, + * the closer of the curve to the control point. If the value is less than or equal to 0, + * this API has the same effect as lineTo. If the value is 1, it has the same effect as quadTo. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + conicTo(ctrlX: double, ctrlY: double, endX: double, endY: double, weight: double): void; /** - * Draws a cubic Bezier curve from the last point of this path to the target point. If the path is empty, the start point (0, 0) is used. - * @param { number } ctrlX1 - X coordinate of the first control point. The value is a floating point number. - * @param { number } ctrlY1 - Y coordinate of the first control point. The value is a floating point number. - * @param { number } ctrlX2 - X coordinate of the second control point. The value is a floating point number. - * @param { number } ctrlY2 - Y coordinate of the second control point. The value is a floating point number. - * @param { number } endX - X coordinate of the target point. The value is a floating point number. - * @param { number } endY - Y coordinate of the target point. The value is a floating point number. + * Draws a cubic Bezier curve from the last point of this path to the target point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX1 - X coordinate of the first control point. The value is a floating point number. + * @param { double } ctrlY1 - Y coordinate of the first control point. The value is a floating point number. + * @param { double } ctrlX2 - X coordinate of the second control point. The value is a floating point number. + * @param { double } ctrlY2 - Y coordinate of the second control point. The value is a floating point number. + * @param { double } endX - X coordinate of the target point. The value is a floating point number. + * @param { double } endY - Y coordinate of the target point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - cubicTo(ctrlX1: number, ctrlY1: number, ctrlX2: number, ctrlY2: number, endX: number, endY: number): void; - /** - * Sets the start position relative to the last point of this path. If the path is empty, the start point (0, 0) is used. - * @param { number } dx - X offset of the start point relative to the last point. A positive number indicates a rightward shift from the last point, - * and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } dy - Y offset of the start point relative to the last point. A positive number indicates an upward shift from the last point, - * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * Draws a cubic Bezier curve from the last point of this path to the target point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX1 - X coordinate of the first control point. The value is a floating point number. + * @param { double } ctrlY1 - Y coordinate of the first control point. The value is a floating point number. + * @param { double } ctrlX2 - X coordinate of the second control point. The value is a floating point number. + * @param { double } ctrlY2 - Y coordinate of the second control point. The value is a floating point number. + * @param { double } endX - X coordinate of the target point. The value is a floating point number. + * @param { double } endY - Y coordinate of the target point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + cubicTo(ctrlX1: double, ctrlY1: double, ctrlX2: double, ctrlY2: double, endX: double, endY: double): void; + + /** + * Sets the start position relative to the last point of this path. + * If the path is empty, the start point (0, 0) is used. + * @param { double } dx - X offset of the start point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } dy - Y offset of the start point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - rMoveTo(dx: number, dy: number): void; + /** + * Sets the start position relative to the last point of this path. + * If the path is empty, the start point (0, 0) is used. + * @param { double } dx - X offset of the start point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } dy - Y offset of the start point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + rMoveTo(dx: double, dy: double): void; /** * Draws a line segment from the last point of this path to a point relative to the last point. If the path is empty, the start point (0, 0) is used. - * @param { number } dx - X offset of the target point relative to the last point. A positive number indicates a rightward shift from the last point, - * and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } dy - Y offset of the target point relative to the last point. A positive number indicates an upward shift from the last point, - * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @param { double } dx - X offset of the target point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } dy - Y offset of the target point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - rLineTo(dx: number, dy: number): void; + /** + * Draws a line segment from the last point of this path to a point relative to the last point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } dx - X offset of the target point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } dy - Y offset of the target point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + rLineTo(dx: double, dy: double): void; /** * Draws a quadratic Bezier curve from the last point of this path to a point relative to the last point. * If the path is empty, the start point (0, 0) is used. - * @param { number } dx1 - X offset of the control point relative to the last point. A positive number indicates a rightward shift from the last point, - * and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } dy1 - Y offset of the control point relative to the last point. A positive number indicates an upward shift from the last point, - * and a negative number indicates a downward shift from the last point. The value is a floating point number. - * @param { number } dx2 - X offset of the target point relative to the last point. A positive number indicates a rightward shift from the last point, - * and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } dy2 - Y offset of the target point relative to the last point. A positive number indicates an upward shift from the last point, - * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @param { double } dx1 - X offset of the control point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } dy1 - Y offset of the control point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @param { double } dx2 - X offset of the target point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } dy2 - Y offset of the target point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - rQuadTo(dx1: number, dy1: number, dx2: number, dy2: number): void; - /** - * Draws a conic curve from the last point of this path to a point relative to the last point. If the path is empty, the start point (0, 0) is used. - * @param { number } ctrlX - X offset of the control point relative to the last point. A positive number indicates a rightward shift from the last point, - * and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } ctrlY - Y offset of the control point relative to the last point. A positive number indicates an upward shift from the last point, - * and a negative number indicates a downward shift from the last point. The value is a floating point number. - * @param { number } endX - X offset of the target point relative to the last point. A positive number indicates a rightward shift from the last point, - * and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } endY - Y offset of the target point relative to the last point. A positive number indicates an upward shift from the last point, - * and a negative number indicates a downward shift from the last point. The value is a floating point number. - * @param { number } weight - Weight of the curve, which determines its shape. The larger the value, the closer of the curve to the control point. - * If the value is less than or equal to 0, this API is equivalent to rLineTo, that is, adding a line segment from the last point of the path - * to the target point. If the value is 1, this API is equivalent to rQuadTo. The value is a floating point number. + * Draws a quadratic Bezier curve from the last point of this path to a point relative to the last point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } dx1 - X offset of the control point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } dy1 - Y offset of the control point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @param { double } dx2 - X offset of the target point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } dy2 - Y offset of the target point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @crossplatform + * @since 20 + */ + rQuadTo(dx1: double, dy1: double, dx2: double, dy2: double): void; + + /** + * Draws a conic curve from the last point of this path to a point relative to the last point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX - X offset of the control point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } ctrlY - Y offset of the control point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @param { double } endX - X offset of the target point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } endY - Y offset of the target point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @param { double } weight - Weight of the curve, which determines its shape. + * The larger the value, the closer of the curve to the control point. + * If the value is less than or equal to 0, this API is equivalent to rLineTo, that is, + * adding a line segment from the last point of the path to the target point. + * If the value is 1, this API is equivalent to rQuadTo. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @since 12 + */ + /** + * Draws a conic curve from the last point of this path to a point relative to the last point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX - X offset of the control point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } ctrlY - Y offset of the control point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @param { double } endX - X offset of the target point relative to the last point. + * A positive number indicates a rightward shift from the last point, + * and a negative number indicates a leftward shift from the last point. The value is a floating point number. + * @param { double } endY - Y offset of the target point relative to the last point. + * A positive number indicates an upward shift from the last point, + * and a negative number indicates a downward shift from the last point. The value is a floating point number. + * @param { double } weight - Weight of the curve, which determines its shape. + * The larger the value, the closer of the curve to the control point. + * If the value is less than or equal to 0, this API is equivalent to rLineTo, that is, + * adding a line segment from the last point of the path to the target point. + * If the value is 1, this API is equivalent to rQuadTo. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 */ - rConicTo(ctrlX: number, ctrlY: number, endX: number, endY: number, weight: number): void; + rConicTo(ctrlX: double, ctrlY: double, endX: double, endY: double, weight: double): void; /** * Draws a cubic Bezier curve from the last point of this path to a point relative to the last point. * If the path is empty, the start point (0, 0) is used. - * @param { number } ctrlX1 - X offset of the first control point relative to the last point. A positive number indicates a rightward shift - * from the last point, and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } ctrlY1 - Y offset of the first control point relative to the last point. A positive number indicates an upward shift - * from the last point, and a negative number indicates a downward shift from the last point. The value is a floating point number. - * @param { number } ctrlX2 - X offset of the second control point relative to the last point. A positive number indicates a rightward shift - * from the last point, and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } ctrlY2 - Y offset of the second control point relative to the last point. A positive number indicates an upward shift - * from the last point, and a negative number indicates a downward shift from the last point. The value is a floating point number. - * @param { number } endX - X offset of the target point relative to the last point. A positive number indicates a rightward shift - * from the last point, and a negative number indicates a leftward shift from the last point. The value is a floating point number. - * @param { number } endY - Y offset of the target point relative to the last point. A positive number indicates an upward shift - * from the last point, and a negative number indicates a downward shift from the last point. The value is a floating point number. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + * @param { double } ctrlX1 - X offset of the first control point relative to the last point. + * A positive number indicates a rightward shift + * from the last point, and a negative number indicates a leftward shift from the last point. + * The value is a floating point number. + * @param { double } ctrlY1 - Y offset of the first control point relative to the last point. + * A positive number indicates an upward shift + * from the last point, and a negative number indicates a downward shift from the last point. + * The value is a floating point number. + * @param { double } ctrlX2 - X offset of the second control point relative to the last point. + * A positive number indicates a rightward shift + * from the last point, and a negative number indicates a leftward shift from the last point. + * The value is a floating point number. + * @param { double } ctrlY2 - Y offset of the second control point relative to the last point. + * A positive number indicates an upward shift + * from the last point, and a negative number indicates a downward shift from the last point. + * The value is a floating point number. + * @param { double } endX - X offset of the target point relative to the last point. + * A positive number indicates a rightward shift + * from the last point, and a negative number indicates a leftward shift from the last point. + * The value is a floating point number. + * @param { double } endY - Y offset of the target point relative to the last point. + * A positive number indicates an upward shift + * from the last point, and a negative number indicates a downward shift from the last point. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - rCubicTo(ctrlX1: number, ctrlY1: number, ctrlX2: number, ctrlY2: number, endX: number, endY: number): void; + /** + * Draws a cubic Bezier curve from the last point of this path to a point relative to the last point. + * If the path is empty, the start point (0, 0) is used. + * @param { double } ctrlX1 - X offset of the first control point relative to the last point. + * A positive number indicates a rightward shift + * from the last point, and a negative number indicates a leftward shift from the last point. + * The value is a floating point number. + * @param { double } ctrlY1 - Y offset of the first control point relative to the last point. + * A positive number indicates an upward shift + * from the last point, and a negative number indicates a downward shift from the last point. + * The value is a floating point number. + * @param { double } ctrlX2 - X offset of the second control point relative to the last point. + * A positive number indicates a rightward shift + * from the last point, and a negative number indicates a leftward shift from the last point. + * The value is a floating point number. + * @param { double } ctrlY2 - Y offset of the second control point relative to the last point. + * A positive number indicates an upward shift + * from the last point, and a negative number indicates a downward shift from the last point. + * The value is a floating point number. + * @param { double } endX - X offset of the target point relative to the last point. + * A positive number indicates a rightward shift + * from the last point, and a negative number indicates a leftward shift from the last point. + * The value is a floating point number. + * @param { double } endY - Y offset of the target point relative to the last point. + * A positive number indicates an upward shift + * from the last point, and a negative number indicates a downward shift from the last point. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + rCubicTo(ctrlX1: double, ctrlY1: double, ctrlX2: double, ctrlY2: double, endX: double, endY: double): void; /** * Adds a polygon to this path. @@ -817,22 +1119,46 @@ declare namespace drawing { * * In other cases, this API adds an arc by applying the result of sweepAngle modulo 360 to the path. * @param { common2D.Rect } rect - Rectangular boundary that encapsulates the oval including the arc. - * @param { number } startAngle - Start angle of the arc, in degrees. The value 0 indicates the positive direction of the X axis. - * The value is a floating point number. - * @param { number } sweepAngle - Angle to sweep, in degrees. A positive number indicates a clockwise sweep, - * and a negative number indicates a counterclockwise sweep. The value is a floating point number. + * @param { double } startAngle - Start angle of the arc, in degrees. + * The value 0 indicates the positive direction of the X axis. + * The value is a floating point number. + * @param { double } sweepAngle - Angle to sweep, in degrees. + * A positive number indicates a clockwise sweep, + * and a negative number indicates a counterclockwise sweep. + * The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - addArc(rect: common2D.Rect, startAngle: number, sweepAngle: number): void; + /** + * Adds an arc to this path. + * + * When startAngle and sweepAngle meet the following conditions, an oval instead of an arc is added: + * + * The result of startAngle modulo 90 is close to 0. + * The value of sweepAngle is not in the range of (-360, 360). + * + * In other cases, this API adds an arc by applying the result of sweepAngle modulo 360 to the path. + * @param { common2D.Rect } rect - Rectangular boundary that encapsulates the oval including the arc. + * @param { double } startAngle - Start angle of the arc, in degrees. + * The value 0 indicates the positive direction of the X axis. + * The value is a floating point number. + * @param { double } sweepAngle - Angle to sweep, in degrees. A positive number indicates a clockwise sweep, + * and a negative number indicates a counterclockwise sweep. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + addArc(rect: common2D.Rect, startAngle: double, sweepAngle: double): void; /** * Adds a circle to this path in the specified direction. The start point of the circle is (x + radius, y). - * @param { number } x - X coordinate of the center of the circle. The value is a floating point number. - * @param { number } y - Y coordinate of the center of the circle. The value is a floating point number. - * @param { number } radius - Radius of the circle. The value is a floating point number. + * @param { double } x - X coordinate of the center of the circle. The value is a floating point number. + * @param { double } y - Y coordinate of the center of the circle. The value is a floating point number. + * @param { double } radius - Radius of the circle. The value is a floating point number. * If the value is less than or equal to 0, there is no effect. * @param { PathDirection } pathDirection - Direction of the path. The default direction is clockwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -840,12 +1166,25 @@ declare namespace drawing { * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - addCircle(x: number, y: number, radius: number, pathDirection?: PathDirection): void; + /** + * Adds a circle to this path in the specified direction. The start point of the circle is (x + radius, y). + * @param { double } x - X coordinate of the center of the circle. The value is a floating point number. + * @param { double } y - Y coordinate of the center of the circle. The value is a floating point number. + * @param { double } radius - Radius of the circle. The value is a floating point number. + * If the value is less than or equal to 0, there is no effect. + * @param { PathDirection } pathDirection - Direction of the path. The default direction is clockwise. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + addCircle(x: double, y: double, radius: double, pathDirection?: PathDirection): void; /** * Adds the inscribed ellipse of a rectangle to this path in the specified direction. * @param { common2D.Rect } rect - Rectangular boundary of the oval. - * @param { number } start - Start point of the oval, where 0, 1, 2, and 3 correspond to the upper, right, lower, and left points, respectively. + * @param { int } start - Start point of the oval, where 0, 1, 2, and 3 correspond to the upper, right, lower, and left points, respectively. * The value is an integer greater than or equal to 0. If the value is greater than or equal to 4, the remainder of 4 is used. * @param { PathDirection } pathDirection - Direction of the path. The default direction is clockwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -853,7 +1192,21 @@ declare namespace drawing { * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - addOval(rect: common2D.Rect, start: number, pathDirection?: PathDirection): void; + /** + * Adds the inscribed ellipse of a rectangle to this path in the specified direction. + * @param { common2D.Rect } rect - Rectangular boundary of the oval. + * @param { int } start - Start point of the oval, where 0, 1, 2, and 3 correspond to the upper, + * right, lower, and left points, respectively. + * The value is an integer greater than or equal to 0. If the value is greater than or equal to 4, + * the remainder of 4 is used. + * @param { PathDirection } pathDirection - Direction of the path. The default direction is clockwise. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + addOval(rect: common2D.Rect, start: int, pathDirection?: PathDirection): void; /** * Adds a rectangle to this path in the specified direction. The start point is the upper left corner of the rectangle. @@ -903,25 +1256,38 @@ declare namespace drawing { /** * Checks whether a coordinate point is included in this path. For details, see PathFillType. - * @param { number } x - X coordinate. The value is a floating point number. - * @param { number } y - Y coordinate. The value is a floating point number. - * @returns { boolean } Check result. The value true means that the coordinate point is included in the path, and false means the opposite. + * @param { double } x - X coordinate. The value is a floating point number. + * @param { double } y - Y coordinate. The value is a floating point number. + * @returns { boolean } Check result. + * The value true means that the coordinate point is included in the path, and false means the opposite. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - contains(x: number, y: number): boolean; + /** + * Checks whether a coordinate point is included in this path. For details, see PathFillType. + * @param { double } x - X coordinate. The value is a floating point number. + * @param { double } y - Y coordinate. The value is a floating point number. + * @returns { boolean } Check result. + * The value true means that the coordinate point is included in the path, and false means the opposite. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + contains(x: double, y: double): boolean; /** * Changes the last point of the path to specific value. - * @param { number } x - Indicates the new x-axis value for the last point. - * @param { number } y - Indicates the new y-axis value for the last point. + * @param { double } x - Indicates the new x-axis value for the last point. + * @param { double } y - Indicates the new y-axis value for the last point. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - setLastPoint(x: number, y: number): void; + setLastPoint(x: double, y: double): void; /** * Sets the fill type of this path. The fill type determines how "inside" of the path is drawn. @@ -960,18 +1326,40 @@ declare namespace drawing { close(): void; /** - * Offsets this path by specified distances along the X axis and Y axis and stores the resulting path in the Path object returned. - * @param { number } dx - X offset. A positive number indicates an offset towards the positive direction of the X axis, - * and a negative number indicates an offset towards the negative direction of the X axis. The value is a floating point number. - * @param { number } dy - Y offset. A positive number indicates an offset towards the positive direction of the Y axis, - * and a negative number indicates an offset towards the negative direction of the Y axis. The value is a floating point number. + * Offsets this path by specified distances along the X axis and Y axis and + * stores the resulting path in the Path object returned. + * @param { double } dx - X offset. A positive number indicates an offset + * towards the positive direction of the X axis, and a negative number + * indicates an offset towards the negative direction of the X axis. The value is a floating point number. + * @param { double } dy - Y offset. A positive number indicates an offset + * towards the positive direction of the Y axis, and a negative number + * indicates an offset towards the negative direction of the Y axis. + * The value is a floating point number. * @returns { Path } New path generated. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - offset(dx: number, dy: number): Path; + /** + * Offsets this path by specified distances along the X axis and Y axis and + * stores the resulting path in the Path object returned. + * @param { double } dx - X offset. A positive number indicates an offset + * towards the positive direction of the X axis, and a negative number + * indicates an offset towards the negative direction of the X axis. + * The value is a floating point number. + * @param { double } dy - Y offset. A positive number indicates an offset + * towards the positive direction of the Y axis, and a negative number + * indicates an offset towards the negative direction of the Y axis. + * The value is a floating point number. + * @returns { Path } New path generated. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + offset(dx: double, dy: double): Path; /** * Resets the path data. @@ -1012,49 +1400,112 @@ declare namespace drawing { * @param { boolean } forceClosed - Whether the path is measured as a closed path. * The value true means that the path is considered closed during measurement, * and false means that the path is measured based on the actual closed status. - * @returns { number } Return path length. + * @returns { double } Return path length. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getLength(forceClosed: boolean): number; + /** + * Obtains the path length. + * @param { boolean } forceClosed - Whether the path is measured as a closed path. + * The value true means that the path is considered closed during measurement, + * and false means that the path is measured based on the actual closed status. + * @returns { double } Return path length. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getLength(forceClosed: boolean): double; /** * Obtains the coordinates and tangent at a distance from the start point of this path. * * @param { boolean } forceClosed - Whether the path is measured as a closed path. - * The value true means that the path is considered closed during measurement, - * and false means that the path is measured based on the actual closed status. - * @param { number } distance - Distance from the start point. If a negative number is passed in, the value 0 is used. - * If a value greater than the path length is passed in, the path length is used. The value is a floating point number. + * The value true means that the path is considered closed during measurement, + * and false means that the path is measured based on the actual closed status. + * @param { double } distance - Distance from the start point. + * If a negative number is passed in, the value 0 is used. + * If a value greater than the path length is passed in, the path length is used. + * The value is a floating point number. + * @param { common2D.Point } position - Coordinates obtained. + * @param { common2D.Point } tangent - Tangent obtained, where tangent.x and tangent.y represent + * the cosine and sine of the tangent of the point, respectively. + * @returns { boolean } - Check result. The value true means that they are obtained, + * and false means the opposite. The values of position and tangent are not changed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @since 12 + */ + /** + * Obtains the coordinates and tangent at a distance from the start point of this path. + * + * @param { boolean } forceClosed - Whether the path is measured as a closed path. + * The value true means that the path is considered closed during measurement, + * and false means that the path is measured based on the actual closed status. + * @param { double } distance - Distance from the start point. If a negative number is passed in, + * the value 0 is used. If a value greater than the path length is passed in, the path length is used. + * The value is a floating point number. * @param { common2D.Point } position - Coordinates obtained. * @param { common2D.Point } tangent - Tangent obtained, where tangent.x and tangent.y represent the cosine - * and sine of the tangent of the point, respectively. + * and sine of the tangent of the point, respectively. * @returns { boolean } - Check result. The value true means that they are obtained, and false means the opposite. - * The values of position and tangent are not changed. + * The values of position and tangent are not changed. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @crossplatform + * @since 20 */ - getPositionAndTangent(forceClosed: boolean, distance: number, position: common2D.Point, tangent: common2D.Point): boolean; + getPositionAndTangent(forceClosed: boolean, distance: double, position: common2D.Point, tangent: common2D.Point): boolean; /** * Extracts a segment of this path and appends it to a destination path. * - * @param { boolean } forceClosed - Whether the path is measured as a closed path. The value true means that the path is considered closed - * during measurement, and false means that the path is measured based on the actual closed status. - * @param { number } start - Distance from the start point of the path to the start point of the segment. If it is less than 0, it defaults to 0. - * If it is greater than or equal to stop, the extraction fails. The value is a floating point number. - * @param { number } stop - Distance from the start point of the path to the end point of the segment. If it is less than or equal to start, - * the extraction fails. If it is greater than the path length, it defaults to the path length. The value is a floating point number. - * @param { boolean } startWithMoveTo - Whether to execute moveto in the destination path to move to its start point. - * The value true means to move to the start point, and false means the opposite. - * @param { Path } dst - Destination path. If the extraction succeeds, the segment is appended to the path. If the extraction fails, nothing changes. - * @returns { boolean } - Extraction result. The value **true** means that the extraction is successful, and **false** means the opposite. + * @param { boolean } forceClosed - Whether the path is measured as a closed path. + * The value true means that the path is considered closed + * during measurement, and false means that the path is measured based on the actual closed status. + * @param { double } start - Distance from the start point of the path to the start point + * of the segment. If it is less than 0, it defaults to 0. + * If it is greater than or equal to stop, the extraction fails. + * The value is a floating point number. + * @param { double } stop - Distance from the start point of the path to the end point + * of the segment. If it is less than or equal to start, the extraction fails. + * If it is greater than the path length, it defaults to the path length. + * The value is a floating point number. + * @param { boolean } startWithMoveTo - Whether to execute moveto in the destination path + * to move to its start point. The value true means to move to the start point, and false means the opposite. + * @param { Path } dst - Destination path. If the extraction succeeds, + * the segment is appended to the path. If the extraction fails, nothing changes. + * @returns { boolean } - Extraction result. The value **true** means that the extraction + * is successful, and **false** means the opposite. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - getSegment(forceClosed: boolean, start: number, stop: number, startWithMoveTo: boolean, dst: Path): boolean; + /** + * Extracts a segment of this path and appends it to a destination path. + * + * @param { boolean } forceClosed - Whether the path is measured as a closed path. + * The value true means that the path is considered closed + * during measurement, and false means that the path is measured based on the actual closed status. + * @param { double } start - Distance from the start point of the path to the start point + * of the segment. If it is less than 0, it defaults to 0. + * If it is greater than or equal to stop, the extraction fails. The value is a floating point number. + * @param { double } stop - Distance from the start point of the path to the end point of the segment. + * If it is less than or equal to start, + * the extraction fails. If it is greater than the path length, it defaults to the path length. + * The value is a floating point number. + * @param { boolean } startWithMoveTo - Whether to execute moveto in + * the destination path to move to its start point. + * The value true means to move to the start point, and false means the opposite. + * @param { Path } dst - Destination path. If the extraction succeeds, + * the segment is appended to the path. If the extraction fails, nothing changes. + * @returns { boolean } - Extraction result. + * The value **true** means that the extraction is successful, and **false** means the opposite. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getSegment(forceClosed: boolean, start: double, stop: double, startWithMoveTo: boolean, dst: Path): boolean; /** * Checks whether a path is closed. @@ -1066,21 +1517,45 @@ declare namespace drawing { isClosed(): boolean; /** - * Obtains a transformation matrix at a specific position along the path, which represents the coordinates and orientation of that point. + * Obtains a transformation matrix at a specific position along the path, + * which represents the coordinates and orientation of that point. * - * @param { boolean } forceClosed - Whether the path is measured as a closed path. The value true means that the path is considered closed - * during measurement, and false means that the path is measured based on the actual closed status. - * @param { number } distance - Distance from the start point. If a negative number is passed in, the value 0 is used. - * If a value greater than the path length is passed in, the path length is used. The value is a floating point number. + * @param { boolean } forceClosed - Whether the path is measured as a closed path. + * The value true means that the path is considered closed + * during measurement, and false means that the path is measured based on the actual closed status. + * @param { double } distance - Distance from the start point. + * If a negative number is passed in, the value 0 is used. + * If a value greater than the path length is passed in, the path length is used. + * The value is a floating point number. * @param { Matrix } matrix - Matrix object used to store the matrix obtained. * @param { PathMeasureMatrixFlags } flags - Type of the matrix information obtained. * @returns { boolean } - Result indicating whether the transformation matrix is obtained. - * The value true means that the operation is successful, and false means the opposite. + * The value true means that the operation is successful, and false means the opposite. * @throws { BusinessError } 401 - Parameter error. Possible causes: Mandatory parameters are left unspecified. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getMatrix(forceClosed: boolean, distance: number, matrix: Matrix, flags: PathMeasureMatrixFlags): boolean; + /** + * Obtains a transformation matrix at a specific position along the path, + * which represents the coordinates and orientation of that point. + * + * @param { boolean } forceClosed - Whether the path is measured as a closed path. + * The value true means that the path is considered closed + * during measurement, and false means that the path is measured based on the actual closed status. + * @param { double } distance - Distance from the start point. + * If a negative number is passed in, the value 0 is used. + * If a value greater than the path length is passed in, the path length is used. + * The value is a floating point number. + * @param { Matrix } matrix - Matrix object used to store the matrix obtained. + * @param { PathMeasureMatrixFlags } flags - Type of the matrix information obtained. + * @returns { boolean } - Result indicating whether the transformation matrix is obtained. + * The value true means that the operation is successful, and false means the opposite. + * @throws { BusinessError } 401 - Parameter error. Possible causes: Mandatory parameters are left unspecified. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getMatrix(forceClosed: boolean, distance: double, matrix: Matrix, flags: PathMeasureMatrixFlags): boolean; /** * Parses the path represented by an SVG string. @@ -1105,8 +1580,8 @@ declare namespace drawing { /** * Approximates the path with a series of line segments. * - * @param { number } acceptableError - Indicates the acceptable error for a line on the path. Should be no less than 0. - * @returns { Array } - Returns with the array containing point components. + * @param { double } acceptableError - Indicates the acceptable error for a line on the path. Should be no less than 0. + * @returns { Array } - Returns with the array containing point components. *
There are three components for each point: *
1. Fraction along the length of the path that the point resides [0.0, 1.0]. *
2. The x coordinate of the point. @@ -1116,13 +1591,13 @@ declare namespace drawing { * @crossplatform * @since 20 */ - approximate(acceptableError: number): Array; + approximate(acceptableError: double): Array; /** * Performs interpolation between the current path and another path based on a given weight, and stores the result in the target path object. * * @param { Path } other - Indicates the other path to be interpolated with the current path. - * @param { number } weight - Indicates the interpolation weight, which must be in the range [0, 1]. + * @param { double } weight - Indicates the interpolation weight, which must be in the range [0, 1]. * @param { Path } interpolatedPath - Indicates the target path object where the interpolation result will be stored. * @returns { boolean } - Returns true if the interpolation operation was successful; returns false otherwise. *
Possible reasons for failure include: @@ -1133,7 +1608,7 @@ declare namespace drawing { * @crossplatform * @since 20 */ - interpolate(other: Path, weight: number, interpolatedPath: Path): boolean; + interpolate(other: Path, weight: double, interpolatedPath: Path): boolean; /** * Checks whether the current path is compatible with another path (other) for interpolation, which means @@ -1151,7 +1626,7 @@ declare namespace drawing { /** * Enumerates the modes for drawing multiple points in an array. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -1180,7 +1655,7 @@ declare namespace drawing { /** * Enumerates the filter modes. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 @@ -1205,7 +1680,7 @@ declare namespace drawing { /** * Enumerates the shadow drawing behaviors. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -1289,24 +1764,55 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Draws a rectangle. By default, black is used for filling. + * @param { common2D.Rect } rect - Rectangle to draw. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ drawRect(rect: common2D.Rect): void; /** - * Draws a rectangle. By default, black is used for filling. This API provides better performance than drawRect and is recommended. - * @param { number } left - X coordinate of the upper left corner of the rectangle. The value is a floating point number. - * @param { number } top - Y coordinate of the upper left corner of the rectangle. The value is a floating point number. - * @param { number } right - X coordinate of the lower right corner of the rectangle. The value is a floating point number. - * @param { number } bottom - Y coordinate of the lower right corner of the rectangle. The value is a floating point number. + * Draws a rectangle. By default, black is used for filling. + * This API provides better performance than drawRect and is recommended. + * @param { double } left - X coordinate of the upper left corner of the rectangle. + * The value is a floating point number. + * @param { double } top - Y coordinate of the upper left corner of the rectangle. + * The value is a floating point number. + * @param { double } right - X coordinate of the lower right corner of the rectangle. + * The value is a floating point number. + * @param { double } bottom - Y coordinate of the lower right corner of the rectangle. + * The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'12', '1.2':'20'} + * @since 12 + */ + /** + * Draws a rectangle. By default, black is used for filling. + * This API provides better performance than drawRect and is recommended. + * @param { double } left - X coordinate of the upper left corner of the rectangle. + * The value is a floating point number. + * @param { double } top - Y coordinate of the upper left corner of the rectangle. + * The value is a floating point number. + * @param { double } right - X coordinate of the lower right corner of the rectangle. + * The value is a floating point number. + * @param { double } bottom - Y coordinate of the lower right corner of the rectangle. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - drawRect(left: number, top: number, right: number, bottom: number): void; + drawRect(left: double, top: double, right: double, bottom: double): void; /** * Draws a rounded rectangle. @@ -1343,55 +1849,105 @@ declare namespace drawing { /** * Draws a spot shadow and uses a given path to outline the ambient shadow. * @param { Path } path - Path object, which is used to outline the shadow. - * @param { common2D.Point3d } planeParams - 3D vector, which is used to determine the z-axis offset of an occluder relative to the canvas, - * based on its x and y coordinates. + * @param { common2D.Point3d } planeParams - 3D vector, + * which is used to determine the z-axis offset of an occluder relative to the canvas, + * based on its x and y coordinates. * @param { common2D.Point3d } devLightPos - Position of the light relative to the canvas. - * @param { number } lightRadius - Radius of the light. The value is a floating point number. + * @param { double } lightRadius - Radius of the light. The value is a floating point number. * @param { common2D.Color } ambientColor - Color of the ambient shadow. * @param { common2D.Color } spotColor - Color of the spot shadow. * @param { ShadowFlag } flag - Shadow flag. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - drawShadow(path: Path, planeParams: common2D.Point3d, devLightPos: common2D.Point3d, lightRadius: number, - ambientColor: common2D.Color, spotColor: common2D.Color, flag: ShadowFlag) : void; - /** * Draws a spot shadow and uses a given path to outline the ambient shadow. * @param { Path } path - Path object, which is used to outline the shadow. - * @param { common2D.Point3d } planeParams - 3D vector, which is used to calculate the offset in the Z axis. + * @param { common2D.Point3d } planeParams - 3D vector, + * which is used to determine the z-axis offset of an occluder relative to the canvas, + * based on its x and y coordinates. * @param { common2D.Point3d } devLightPos - Position of the light relative to the canvas. - * @param { number } lightRadius - Radius of the light. The value is a floating point number. - * @param { common2D.Color | number } ambientColor - Ambient shadow color, represented by a 32-bit unsigned integer in hexadecimal ARGB format. - * @param { common2D.Color | number } spotColor - Spot shadow color, represented by a 32-bit unsigned integer in hexadecimal ARGB format. - * @param { ShadowFlag } flag - Indicates the flag to control opaque occluder, shadow, and light position. + * @param { double } lightRadius - Radius of the light. The value is a floating point number. + * @param { common2D.Color } ambientColor - Color of the ambient shadow. + * @param { common2D.Color } spotColor - Color of the spot shadow. + * @param { ShadowFlag } flag - Shadow flag. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawShadow(path: Path, planeParams: common2D.Point3d, devLightPos: common2D.Point3d, lightRadius: double, + ambientColor: common2D.Color, spotColor: common2D.Color, flag: ShadowFlag) : void; + + /** + * Draws a spot shadow and uses a given path to outline the ambient shadow. + * @param { Path } path - Path object, which is used to outline the shadow. + * @param { common2D.Point3d } planeParams - 3D vector, which is used to calculate the offset in the Z axis. + * @param { common2D.Point3d } devLightPos - Position of the light relative to the canvas. + * @param { double } lightRadius - Radius of the light. The value is a floating point number. + * @param { common2D.Color | int } ambientColor - Ambient shadow color, + * represented by a 32-bit unsigned integer in hexadecimal ARGB format. + * @param { common2D.Color | int } spotColor - Spot shadow color, + * represented by a 32-bit unsigned integer in hexadecimal ARGB format. + * @param { ShadowFlag } flag - Indicates the flag to control opaque occluder, shadow, and light position. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - drawShadow(path: Path, planeParams: common2D.Point3d, devLightPos: common2D.Point3d, lightRadius: number, - ambientColor: common2D.Color | number, spotColor: common2D.Color | number, flag: ShadowFlag) : void; + /** + * Draws a spot shadow and uses a given path to outline the ambient shadow. + * @param { Path } path - Path object, which is used to outline the shadow. + * @param { common2D.Point3d } planeParams - 3D vector, which is used to calculate the offset in the Z axis. + * @param { common2D.Point3d } devLightPos - Position of the light relative to the canvas. + * @param { double } lightRadius - Radius of the light. The value is a floating point number. + * @param { common2D.Color | int } ambientColor - Ambient shadow color, + * represented by a 32-bit unsigned integer in hexadecimal ARGB format. + * @param { common2D.Color | int } spotColor - Spot shadow color, + * represented by a 32-bit unsigned integer in hexadecimal ARGB format. + * @param { ShadowFlag } flag - Indicates the flag to control opaque occluder, shadow, and light position. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawShadow(path: Path, planeParams: common2D.Point3d, devLightPos: common2D.Point3d, lightRadius: double, + ambientColor: common2D.Color | int, spotColor: common2D.Color | int, flag: ShadowFlag) : void; /** - * Draws a circle. If the radius is less than or equal to zero, nothing is drawn. By default, black is used for filling. - * @param { number } x - X coordinate of the center of the circle. The value is a floating point number. - * @param { number } y - Y coordinate of the center of the circle. The value is a floating point number. - * @param { number } radius - Radius of the circle. The value is a floating point number greater than 0. + * Draws a circle. If the radius is less than or equal to zero, nothing is drawn. + * By default, black is used for filling. + * @param { double } x - X coordinate of the center of the circle. The value is a floating point number. + * @param { double } y - Y coordinate of the center of the circle. The value is a floating point number. + * @param { double } radius - Radius of the circle. The value is a floating point number greater than 0. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - drawCircle(x: number, y: number, radius: number): void; + /** + * Draws a circle. If the radius is less than or equal to zero, nothing is drawn. + * By default, black is used for filling. + * @param { double } x - X coordinate of the center of the circle. The value is a floating point number. + * @param { double } y - Y coordinate of the center of the circle. The value is a floating point number. + * @param { double } radius - Radius of the circle. The value is a floating point number greater than 0. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawCircle(x: double, y: double, radius: double): void; /** * Draw a pixelmap, with the upper left corner at (left, top). * @param { image.PixelMap } pixelmap - PixelMap. - * @param { number } left - Left side of image. - * @param { number } top - Top side of image. + * @param { double } left - Left side of image. + * @param { double } top - Top side of image. * @throws { BusinessError } 401 - Parameter error. * @syscap SystemCapability.Graphics.Drawing * @since 11 @@ -1399,15 +1955,32 @@ declare namespace drawing { /** * Draws an image. The coordinates of the upper left corner of the image are (left, top). * @param { image.PixelMap } pixelmap - PixelMap. - * @param { number } left - X coordinate of the upper left corner of the image. The value is a floating point number. - * @param { number } top - Y coordinate of the upper left corner of the image. The value is a floating point number. - * @param { SamplingOptions } samplingOptions - Sampling options. By default, the SamplingOptions object created using the no-argument constructor is used. + * @param { double } left - X coordinate of the upper left corner of the image. + * The value is a floating point number. + * @param { double } top - Y coordinate of the upper left corner of the image. The value is a floating point number. + * @param { SamplingOptions } samplingOptions - Sampling options. By default, + * the SamplingOptions object created using the no-argument constructor is used. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - drawImage(pixelmap: image.PixelMap, left: number, top: number, samplingOptions?: SamplingOptions): void; + /** + * Draws an image. The coordinates of the upper left corner of the image are (left, top). + * @param { image.PixelMap } pixelmap - PixelMap. + * @param { double } left - X coordinate of the upper left corner of the image. + * The value is a floating point number. + * @param { double } top - Y coordinate of the upper left corner of the image. + * The value is a floating point number. + * @param { SamplingOptions } samplingOptions - Sampling options. By default, + * the SamplingOptions object created using the no-argument constructor is used. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawImage(pixelmap: image.PixelMap, left: double, top: double, samplingOptions?: SamplingOptions): void; /** * Splits an image into multiple sections based on the lattice object's configuration and @@ -1478,7 +2051,7 @@ declare namespace drawing { /** * Fills the drawable area of the canvas with the specified color and blend mode. * @param { common2D.Color } color - Color in ARGB format. The value of each color channel is an integer ranging from 0 to 255. - * @param { BlendMode } blendMode - Blend mode. The default mode is SRC_OVER. + * @param { BlendMode } [blendMode] - Blend mode. The default mode is SRC_OVER. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing @@ -1487,33 +2060,62 @@ declare namespace drawing { drawColor(color: common2D.Color, blendMode?: BlendMode): void; /** - * Fills the drawable area of the canvas with the specified color and blend mode. This API provides better performance and is recommended. - * @param { number } alpha - Alpha channel value of the color in ARGB format. - * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. - * @param { number } red - Red channel value of the color in ARGB format. - * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. - * @param { number } green - Green channel value of the color in ARGB format. - * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. - * @param { number } blue - Blue channel value of the color in ARGB format. - * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. - * @param { BlendMode } blendMode - Blend mode. The default mode is SRC_OVER. + * Fills the drawable area of the canvas with the specified color and blend mode. + * This API provides better performance and is recommended. + * @param { int } alpha - Alpha channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. + * @param { int } red - Red channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. + * @param { int } green - Green channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. + * @param { int } blue - Blue channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. + * @param { BlendMode } [blendMode] - Blend mode. The default mode is SRC_OVER. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - drawColor(alpha: number, red: number, green: number, blue: number, blendMode?: BlendMode): void; + /** + * Fills the drawable area of the canvas with the specified color and blend mode. + * This API provides better performance and is recommended. + * @param { int } alpha - Alpha channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. + * @param { int } red - Red channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. + * @param { int } green - Green channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. + * @param { int } blue - Blue channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. Any passed-in floating point number is rounded down. + * @param { BlendMode } [blendMode] - Blend mode. The default mode is SRC_OVER. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawColor(alpha: int, red: int, green: int, blue: int, blendMode?: BlendMode): void; /** * Fills the drawable area of the canvas with the specified color and blend mode. - * @param { number } color - Color in hexadecimal ARGB format. - * @param { BlendMode } blendMode - Blend mode. The default mode is SRC_OVER. + * @param { int } color - Color in hexadecimal ARGB format. + * @param { BlendMode } [blendMode] - Blend mode. The default mode is SRC_OVER. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - drawColor(color: number, blendMode?: BlendMode): void; + /** + * Fills the drawable area of the canvas with the specified color and blend mode. + * @param { int } color - Color in hexadecimal ARGB format. + * @param { BlendMode } [blendMode] - Blend mode. The default mode is SRC_OVER. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawColor(color: int, blendMode?: BlendMode): void; /** * Draws an oval on the canvas, where the shape and position of the oval are defined by its bounding rectangle. @@ -1529,30 +2131,48 @@ declare namespace drawing { * Draws an arc on the canvas, with the start angle and sweep angle specified. * If the absolute value of the sweep angle exceeds 360 degrees, an ellipse is drawn. * @param { common2D.Rect } arc - Rectangular boundary that encapsulates the oval including the arc. - * @param { number } startAngle - Start angle, in degrees. The value is a floating point number. - * When the degree is 0, the start point is located at the right end of the oval. - * A positive number indicates that the start point is placed clockwise, - * and a negative number indicates that the start point is placed counterclockwise. - * @param { number } sweepAngle - Angle to sweep, in degrees. The value is a floating point number. - * A positive number indicates a clockwise sweep, and a negative value indicates a counterclockwise swipe. - * The valid range is from -360 degrees to 360 degrees. If the absolute value of the sweep angle exceeds 360 degrees, - * an ellipse is drawn. + * @param { double } startAngle - Start angle, in degrees. The value is a floating point number. + * When the degree is 0, the start point is located at the right end of the oval. + * A positive number indicates that the start point is placed clockwise, + * and a negative number indicates that the start point is placed counterclockwise. + * @param { double } sweepAngle - Angle to sweep, in degrees. The value is a floating point number. + * A positive number indicates a clockwise sweep, and a negative value indicates + * a counterclockwise swipe. The valid range is from -360 degrees to 360 degrees. + * If the absolute value of the sweep angle exceeds 360 degrees, an ellipse is drawn. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - drawArc(arc: common2D.Rect, startAngle: number, sweepAngle: number): void; + /** + * Draws an arc on the canvas, with the start angle and sweep angle specified. + * If the absolute value of the sweep angle exceeds 360 degrees, an ellipse is drawn. + * @param { common2D.Rect } arc - Rectangular boundary that encapsulates the oval including the arc. + * @param { double } startAngle - Start angle, in degrees. The value is a floating point number. + * When the degree is 0, the start point is located at the right end of the oval. + * A positive number indicates that the start point is placed clockwise, + * and a negative number indicates that the start point is placed counterclockwise. + * @param { double } sweepAngle - Angle to sweep, in degrees. The value is a floating point number. + * A positive number indicates a clockwise sweep, and a negative value indicates + * a counterclockwise swipe. The valid range is from -360 degrees to 360 degrees. + * If the absolute value of the sweep angle exceeds 360 degrees, an ellipse is drawn. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawArc(arc: common2D.Rect, startAngle: double, sweepAngle: double): void; /** * Draws an arc on the canvas. It enables you to define the start angle, sweep angle, * and whether the arc's endpoints should connect to its center. * @param { common2D.Rect } arc - Rectangular boundary that encapsulates the oval including the arc. - * @param { number } startAngle - Start angle, in degrees. The value is a floating point number. + * @param { double } startAngle - Start angle, in degrees. The value is a floating point number. * When the degree is 0, the start point is located at the right end of the oval. * A positive number indicates that the start point is placed clockwise, * and a negative number indicates that the start point is placed counterclockwise. - * @param { number } sweepAngle - Angle to sweep, in degrees. The value is a floating point number. + * @param { double } sweepAngle - Angle to sweep, in degrees. The value is a floating point number. * A positive number indicates a clockwise sweep, and a negative value indicates a counterclockwise swipe. * The swipe angle can exceed 360 degrees, and a complete ellipse is drawn. * @param { boolean } useCenter - Whether the start point and end point of the arc are connected to its center. @@ -1560,18 +2180,45 @@ declare namespace drawing { * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - drawArcWithCenter(arc: common2D.Rect, startAngle: number, sweepAngle: number, useCenter: boolean): void; + /** + * Draws an arc on the canvas. It enables you to define the start angle, sweep angle, + * and whether the arc's endpoints should connect to its center. + * @param { common2D.Rect } arc - Rectangular boundary that encapsulates the oval including the arc. + * @param { double } startAngle - Start angle, in degrees. The value is a floating point number. + * When the degree is 0, the start point is located at the right end of the oval. + * A positive number indicates that the start point is placed clockwise, + * and a negative number indicates that the start point is placed counterclockwise. + * @param { double } sweepAngle - Angle to sweep, in degrees. The value is a floating point number. + * A positive number indicates a clockwise sweep, and a negative value indicates a counterclockwise swipe. + * The swipe angle can exceed 360 degrees, and a complete ellipse is drawn. + * @param { boolean } useCenter - Whether the start point and end point of the arc are connected to its center. + * The value true means that they are connected to the center; the value false means the opposite. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawArcWithCenter(arc: common2D.Rect, startAngle: double, sweepAngle: double, useCenter: boolean): void; /** * Draws a point. - * @param { number } x - X coordinate of the point. The value is a floating point number. - * @param { number } y - Y coordinate of the point. The value is a floating point number. + * @param { double } x - X coordinate of the point. The value is a floating point number. + * @param { double } y - Y coordinate of the point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - drawPoint(x: number, y: number): void; + /** + * Draws a point. + * @param { double } x - X coordinate of the point. The value is a floating point number. + * @param { double } y - Y coordinate of the point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawPoint(x: double, y: double): void; /** * Draws a group of points, line segments, or polygons on the canvas, with the specified drawing mode. An array is used to hold these points. @@ -1595,68 +2242,129 @@ declare namespace drawing { drawPath(path: Path): void; /** - * Draws a line segment from the start point to the end point. If the coordinates of the start point are the same as those of the end point, - * nothing is drawn. - * @param { number } x0 - X coordinate of the start point of the line segment. The value is a floating point number. - * @param { number } y0 - Y coordinate of the start point of the line segment. The value is a floating point number. - * @param { number } x1 - X coordinate of the end point of the line segment. The value is a floating point number. - * @param { number } y1 - Y coordinate of the end point of the line segment. The value is a floating point number. + * Draws a line segment from the start point to the end point. + * If the coordinates of the start point are the same as those of the end point, nothing is drawn. + * @param { double } x0 - X coordinate of the start point of the line segment. The value is a floating point number. + * @param { double } y0 - Y coordinate of the start point of the line segment. The value is a floating point number. + * @param { double } x1 - X coordinate of the end point of the line segment. The value is a floating point number. + * @param { double } y1 - Y coordinate of the end point of the line segment. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - drawLine(x0: number, y0: number, x1: number, y1: number): void; + /** + * Draws a line segment from the start point to the end point. + * If the coordinates of the start point are the same as those of the end point, + * nothing is drawn. + * @param { double } x0 - X coordinate of the start point of the line segment. The value is a floating point number. + * @param { double } y0 - Y coordinate of the start point of the line segment. The value is a floating point number. + * @param { double } x1 - X coordinate of the end point of the line segment. The value is a floating point number. + * @param { double } y1 - Y coordinate of the end point of the line segment. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawLine(x0: double, y0: double, x1: double, y1: double): void; /** * Draws a single character. If the typeface of the current font does not support the character to draw, * the system typeface is used to draw the character. * @param { string } text - Single character to draw. The length of the string must be 1. * @param { Font } font - Font object. - * @param { number } x - X coordinate of the left point (red point in the figure below) of the character baseline (blue line in the figure below). - * The value is a floating point number. - * @param { number } y - Y coordinate of the left point (red point in the figure below) of the character baseline (blue line in the figure below). - * The value is a floating point number. + * @param { double } x - X coordinate of the left point (red point in the figure below) of + * the character baseline (blue line in the figure below). The value is a floating point number. + * @param { double } y - Y coordinate of the left point (red point in the figure below) of + * the character baseline (blue line in the figure below). The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - drawSingleCharacter(text: string, font: Font, x: number, y: number): void; + /** + * Draws a single character. If the typeface of the current font does not support the character to draw, + * the system typeface is used to draw the character. + * @param { string } text - Single character to draw. The length of the string must be 1. + * @param { Font } font - Font object. + * @param { double } x - X coordinate of the left point (red point in the figure below) of + * the character baseline (blue line in the figure below). The value is a floating point number. + * @param { double } y - Y coordinate of the left point (red point in the figure below) of + * the character baseline (blue line in the figure below). The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawSingleCharacter(text: string, font: Font, x: double, y: double): void; /** - * Draws a text blob. If the typeface used to construct blob does not support a character, that character will not be drawn. + * Draws a text blob. If the typeface used to construct blob does not support a character, + * that character will not be drawn. * @param { TextBlob } blob - TextBlob to draw. - * @param { number } x - X coordinate of the left point (red point in the figure below) of the text baseline (blue line in the figure below). - * The value is a floating point number. - * @param { number } y - Y coordinate of the left point (red point in the figure below) of the text baseline (blue line in the figure below). - * The value is a floating point number. + * @param { double } x - X coordinate of the left point (red point in the figure below) of the text + * baseline (blue line in the figure below). The value is a floating point number. + * @param { double } y - Y coordinate of the left point (red point in the figure below) of the text + * baseline (blue line in the figure below). The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - drawTextBlob(blob: TextBlob, x: number, y: number): void; + /** + * Draws a text blob. If the typeface used to construct blob does not support a character, + * that character will not be drawn. + * @param { TextBlob } blob - TextBlob to draw. + * @param { double } x - X coordinate of the left point (red point in the figure below) of the text + * baseline (blue line in the figure below). The value is a floating point number. + * @param { double } y - Y coordinate of the left point (red point in the figure below) of the text + * baseline (blue line in the figure below). The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + drawTextBlob(blob: TextBlob, x: double, y: double): void; /** * Draws a PixelMap based on a mesh, where mesh vertices are evenly distributed across the PixelMap. - * @param { image.PixelMap } pixelmap - PixelMap to draw. - * @param { number } meshWidth - Number of columns in the mesh. The value is an integer greater than 0. - * @param { number } meshHeight - Number of rows in the mesh. The value is an integer greater than 0. - * @param { Array } vertices - Array of vertices, which specify the position to draw. - * The value is a floating-point array and the size must be ((meshWidth+1) * (meshHeight+1) + vertOffset) * 2. - * @param { number } vertOffset - Number of vert elements to skip before drawing. The value is an integer greater than or equal to 0. - * @param { Array } colors - Array of colors, which specify the color at each vertex. - * The value is an integer array and can be null. The size must be (meshWidth+1) * (meshHeight+1) + colorOffset. - * @param { number } colorOffset - Number of color elements to skip before drawing. The value is an integer greater than or equal to 0. + * @param { image.PixelMap } pixelmap - The pixelmap to draw using the mesh. + * @param { int } meshWidth - The number of columns in the mesh. + * @param { int } meshHeight - The number of rows in the mesh. + * @param { Array } vertices - Array of vertices, specifying where the mesh should be drawn. + * @param { int } vertOffset - Number of vert elements to skip before drawing. + * @param { Array } colors - Array of colors, specifying a color at each vertex. + * @param { int } colorOffset - Number of color elements to skip before drawing. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'12', '1.2':'20'} + * @since 12 + */ + /** + * Draws a PixelMap based on a mesh, where mesh vertices are evenly distributed across the PixelMap. + * @param { image.PixelMap } pixelmap - PixelMap to draw. + * @param { int } meshWidth - Number of columns in the mesh. The value is an integer greater than 0. + * @param { int } meshHeight - Number of rows in the mesh. The value is an integer greater than 0. + * @param { Array } vertices - Array of vertices, which specify the position to draw. + * The value is a floating-point array and the size must be ((meshWidth+1) * (meshHeight+1) + vertOffset) * 2. + * @param { int } vertOffset - Number of vert elements to skip before drawing. + * The value is an integer greater than or equal to 0. + * @param { Array } colors - Array of colors, which specify the color at each vertex. + * The value is an integer array and can be null. The size must be (meshWidth+1) * (meshHeight+1) + colorOffset. + * @param { int } colorOffset - Number of color elements to skip before drawing. + * The value is an integer greater than or equal to 0. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - drawPixelMapMesh(pixelmap: image.PixelMap, meshWidth: number, meshHeight: number, - vertices: Array, vertOffset: number, colors: Array, colorOffset: number): void; + drawPixelMapMesh(pixelmap: image.PixelMap, meshWidth: int, meshHeight: int, + vertices: Array, vertOffset: int, colors: Array, colorOffset: int): void; /** * Draws a region. @@ -1705,27 +2413,48 @@ declare namespace drawing { detachBrush(): void; /** - * Saves the canvas states (canvas matrix and drawable area) to the top of the stack. This API must be used in pair with restore. - * @returns { number } Number of canvas statuses. The value is a positive integer. + * Saves the canvas states (canvas matrix and drawable area) to the top of the stack. + * This API must be used in pair with restore. + * @returns { int } Number of canvas statuses. The value is a positive integer. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - save(): number; + /** + * Saves the canvas states (canvas matrix and drawable area) to the top of the stack. + * This API must be used in pair with restore. + * @returns { int } Number of canvas statuses. The value is a positive integer. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + save(): int; + /** + * Saves the matrix and clip, and allocates a bitmap for subsequent drawing. + * Calling restore doscards changes to matrix and clip, and draws the bitmap. + * @param { common2D.Rect | null} rect - Optional layer size. The default value is null. + * @param { Brush | null} brush - Optional brush effect effect used to draw the layer. The default value is null. + * @returns { long } Return the number of saved states before this call. + * @throws { BusinessError } 401 - Parameter error. Possible causes: Mandatory parameters are left unspecified. + * @syscap SystemCapability.Graphics.Drawing + * @since 12 + */ /** * Saves the matrix and cropping region of the canvas, and allocates a PixelMap for subsequent drawing. * If you call restore, changes made to the matrix and clipping region are discarded, and the PixelMap is drawn. * @param { common2D.Rect | null} rect - Rect object, which is used to limit the size of the graphics layer. - * The default value is the current canvas size. - * @param { Brush | null} brush - Brush object. The alpha value, filter effect, and blend mode of the brush are applied when the PixelMap is drawn. - * If null is passed in, no effect is applied. - * @returns { number } Number of canvas statuses that have been saved. The value is a positive integer. + * The default value is the current canvas size. + * @param { Brush | null} brush - Brush object. The alpha value, filter effect, + * and blend mode of the brush are applied when the PixelMap is drawn. + * If null is passed in, no effect is applied. + * @returns { long } Number of canvas statuses that have been saved. The value is a positive integer. * @throws { BusinessError } 401 - Parameter error. Possible causes: Mandatory parameters are left unspecified. * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'12', '1.2':'20'} + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - saveLayer(rect?: common2D.Rect | null, brush?: Brush | null): number; + saveLayer(rect?: common2D.Rect | null, brush?: Brush | null): long; /** * Clears the canvas with a given color. This API has the same effect as drawColor. @@ -1739,11 +2468,18 @@ declare namespace drawing { /** * Clears the canvas with a given color. - * @param { common2D.Color | number } color - Color, represented by an unsigned integer in hexadecimal ARGB format. + * @param { common2D.Color | int } color - Color, represented by an unsigned integer in hexadecimal ARGB format. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - clear(color: common2D.Color | number): void; + /** + * Clears the canvas with a given color. + * @param { common2D.Color | int } color - Color, represented by an unsigned integer in hexadecimal ARGB format. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + clear(color: common2D.Color | int): void; /** * Restores the canvas state (canvas matrix and clipping area) saved on the top of the stack. @@ -1755,39 +2491,71 @@ declare namespace drawing { /** * Restores the canvas state (canvas matrix and clipping area) to a specified number. - * @param { number } count - Depth of the canvas statuses to restore. The value is an integer. - * If the value is less than or equal to 1, the canvas is restored to the initial state. - * If the value is greater than the number of canvas statuses that have been saved, no operation is performed. + * @param { int } count - Depth of the canvas statuses to restore. The value is an integer. + * If the value is less than or equal to 1, the canvas is restored to the initial state. + * If the value is greater than the number of canvas statuses that have been saved, no operation is performed. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - restoreToCount(count: number): void; + /** + * Restores the canvas state (canvas matrix and clipping area) to a specified number. + * @param { int } count - Depth of the canvas statuses to restore. The value is an integer. + * If the value is less than or equal to 1, the canvas is restored to the initial state. + * If the value is greater than the number of canvas statuses that have been saved, no operation is performed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + restoreToCount(count: int): void; /** * Obtains the number of canvas states (canvas matrix and clipping area) saved in the stack. - * @returns { number } Number of canvas statuses that have been saved. The value is a positive integer. + * @returns { int } Number of canvas statuses that have been saved. The value is a positive integer. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getSaveCount(): number; + /** + * Obtains the number of canvas states (canvas matrix and clipping area) saved in the stack. + * @returns { int } Number of canvas statuses that have been saved. The value is a positive integer. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getSaveCount(): int; /** * Obtains the canvas width. - * @returns { number } Canvas width. The value is a floating point number. + * @returns { int } Canvas width. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getWidth(): number; + /** + * Obtains the canvas width. + * @returns { int } Canvas width. The value is a floating point number. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getWidth(): int; /** * Obtains the canvas height. - * @returns { number } Canvas height. The value is a floating point number. + * @returns { int } Canvas height. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getHeight(): number; + /** + * Obtains the canvas height. + * @returns { int } Canvas height. The value is a floating point number. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getHeight(): int; /** * Obtains the bounds of the cropping region of the canvas. @@ -1806,59 +2574,110 @@ declare namespace drawing { getTotalMatrix(): Matrix; /** - * Applies a scaling matrix on top of the current canvas matrix (identity matrix by default). - * Subsequent drawing and clipping operations will automatically have a scaling effect applied to the shapes and positions. - * @param { number } sx - Scale ratio on the X axis. The value is a floating point number. - * @param { number } sy - Scale ratio on the Y axis. The value is a floating point number. + * Scales the canvas. + * @param { double } sx - Scale ratio on the X axis. The value is a floating point number. + * @param { double } sy - Scale ratio on the Y axis. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - scale(sx: number, sy: number): void; + /** + * Applies a scaling matrix on top of the current canvas matrix (identity matrix by default). + * Subsequent drawing and clipping operations will automatically have a scaling effect applied to + * the shapes and positions. + * @param { double } sx - Scale ratio on the X axis. The value is a floating point number. + * @param { double } sy - Scale ratio on the Y axis. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + scale(sx: double, sy: double): void; /** - * Applies a skewing matrix on top of the current canvas matrix (identity matrix by default). - * Subsequent drawing and clipping operations will automatically have a skewing effect applied to the shapes and positions. - * @param { number } sx - Amount of tilt on the X axis. The value is a floating point number. - * A positive number tilts the drawing rightwards along the positive direction of the Y axis, - * and a negative number tilts the drawing leftwards along the positive direction of the Y axis. - * @param { number } sy - Amount of tilt on the Y axis. The value is a floating point number. - * A positive number tilts the drawing downwards along the positive direction of the X axis, - * and a negative number tilts the drawing upwards along the positive direction of the X axis. + * Skews the canvas in both the horizontal and vertical directions. + * @param { double } sx - Amount of tilt on the X axis. The value is a floating point number. + * A positive number tilts the drawing rightwards along the positive direction of the Y axis, + * and a negative number tilts the drawing leftwards along the positive direction of the Y axis. + * @param { double } sy - Amount of tilt on the Y axis. The value is a floating point number. + * A positive number tilts the drawing downwards along the positive direction of the X axis, + * and a negative number tilts the drawing upwards along the positive direction of the X axis. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - skew(sx: number, sy: number) : void; + /** + * Applies a skewing matrix on top of the current canvas matrix (identity matrix by default). + * Subsequent drawing and clipping operations will automatically have a skewing effect applied to + * the shapes and positions. + * @param { double } sx - Amount of tilt on the X axis. The value is a floating point number. + * A positive number tilts the drawing rightwards along the positive direction of the Y axis, + * and a negative number tilts the drawing leftwards along the positive direction of the Y axis. + * @param { double } sy - Amount of tilt on the Y axis. The value is a floating point number. + * A positive number tilts the drawing downwards along the positive direction of the X axis, + * and a negative number tilts the drawing upwards along the positive direction of the X axis. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + skew(sx: double, sy: double) : void; + /** + * Rotates by degrees, positive degrees rotates clockwise. + * @param { double } degrees - Indicates the amount to rotate, in degrees. + * @param { double } sx - Indicates the x-axis valie of the point to rotate about. + * @param { double } sy - Indicates the y-axis valie of the point to rotate about. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @since 12 + */ /** * Applies a rotation matrix on top of the current canvas matrix (identity matrix by default). - * Subsequent drawing and clipping operations will automatically have a rotation effect applied to their shapes and positions. - * @param { number } degrees - Angle to rotate, in degrees. The value is a floating point number. - * A positive value indicates a clockwise rotation, and a negative value indicates a counterclockwise rotation. - * @param { number } sx - X coordinate of the rotation center. The value is a floating point number. - * @param { number } sy - Y coordinate of the rotation center. The value is a floating point number. + * Subsequent drawing and clipping operations will automatically have a rotation effect applied to + * their shapes and positions. + * @param { double } degrees - Angle to rotate, in degrees. The value is a floating point number. + * A positive value indicates a clockwise rotation, and a negative value indicates a counterclockwise rotation. + * @param { double } sx - X coordinate of the rotation center. The value is a floating point number. + * @param { double } sy - Y coordinate of the rotation center. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'12', '1.2':'20'} + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - rotate(degrees: number, sx: number, sy: number) : void; + rotate(degrees: double, sx: double, sy: double) : void; /** * Applies a translation matrix on top of the current canvas matrix (identity matrix by default). - * Subsequent drawing and clipping operations will automatically have a translation effect applied to the shapes and positions. - * @param { number } dx - Distance to translate on the X axis. The value is a floating point number. - * @param { number } dy - Distance to translate on the Y axis. The value is a floating point number. + * Subsequent drawing and clipping operations will automatically have a translation effect applied + * to the shapes and positions. + * @param { double } dx - Distance to translate on the X axis. The value is a floating point number. + * @param { double } dy - Distance to translate on the Y axis. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - translate(dx: number, dy: number): void; + /** + * Applies a translation matrix on top of the current canvas matrix (identity matrix by default). + * Subsequent drawing and clipping operations will automatically have a translation effect applied + * to the shapes and positions. + * @param { double } dx - Distance to translate on the X axis. The value is a floating point number. + * @param { double } dy - Distance to translate on the Y axis. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + translate(dx: double, dy: double): void; /** * Clips the drawable area of the canvas using a custom path. @@ -1930,13 +2749,24 @@ declare namespace drawing { isClipEmpty(): boolean; /** - * Sets a matrix for the canvas. Subsequent drawing and clipping operations will be affected by this matrix in terms of shape and position. + * Sets a matrix for the canvas. + * Subsequent drawing and clipping operations will be affected by this matrix in terms of shape and position. * @param { Matrix } matrix - Declares functions related to the matrix object in the drawing module. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ + /** + * Sets a matrix for the canvas. + * Subsequent drawing and clipping operations will be affected by this matrix in terms of shape and position. + * @param { Matrix } matrix - Declares functions related to the matrix object in the drawing module. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ setMatrix(matrix: Matrix): void; /** @@ -1968,7 +2798,7 @@ declare namespace drawing { /** * Enumerates the canvas clipping modes. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 @@ -1999,31 +2829,52 @@ declare namespace drawing { interface TextBlobRunBuffer { /** * Index of the glyph. The value is an integer. If a floating point number is passed in, the value is rounded down. - * @type { number } + * @type { int } * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - glyph: number; + /** + * Index of the glyph. The value is an integer. If a floating point number is passed in, the value is rounded down. + * @type { int } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + glyph: int; /** * X coordinate of the start point of the text blob. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - positionX: number; + /** + * X coordinate of the start point of the text blob. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + positionX: double; /** * Y coordinate of the start point of the text blob. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - positionY: number; + /** + * Y coordinate of the start point of the text blob. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + positionY: double; } /** * Enumerates the text encoding types. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 11 */ @@ -2079,20 +2930,38 @@ declare namespace drawing { /** * Creates a TextBlob object from the text. - * The coordinates of each font in the TextBlob object are determined by the coordinate information in the points array. + * The coordinates of each font in the TextBlob object are determined by + * the coordinate information in the points array. * @param { string } text - Content to be used for drawing the text blob. - * @param { number } len - Number of fonts. The value is an integer and is obtained from countText. + * @param { int } len - Number of fonts. The value is an integer and is obtained from countText. * @param { common2D.Point[] } points - Array of points, which are used to specify the coordinates of each font. - * The array length must be the same as the value of len. + * The array length must be the same as the value of len. * @param { Font } font - Specify text size, font, text scale, etc. * @returns { TextBlob } TextBlob object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static makeFromPosText(text: string, len: number, points: common2D.Point[], font: Font): TextBlob; + /** + * Creates a TextBlob object from the text. + * The coordinates of each font in the TextBlob object are determined by + * the coordinate information in the points array. + * @param { string } text - Content to be used for drawing the text blob. + * @param { int } len - Number of fonts. The value is an integer and is obtained from countText. + * @param { common2D.Point[] } points - Array of points, which are used to specify the coordinates of each font. + * The array length must be the same as the value of len. + * @param { Font } font - Specify text size, font, text scale, etc. + * @returns { TextBlob } TextBlob object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static makeFromPosText(text: string, len: int, points: common2D.Point[], font: Font): TextBlob; /** * Creates a Textblob object based on the RunBuffer information. @@ -2118,11 +2987,18 @@ declare namespace drawing { /** * Obtains the unique, non-zero identifier of this TextBlob object. - * @returns { number } Unique, non-zero identifier of this TextBlob object. + * @returns { long } Unique, non-zero identifier of this TextBlob object. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - uniqueID(): number; + /** + * Obtains the unique, non-zero identifier of this TextBlob object. + * @returns { long } Unique, non-zero identifier of this TextBlob object. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + uniqueID(): long; } /** @@ -2142,13 +3018,13 @@ declare namespace drawing { /** * Adds variation axis for the TypefaceArguments. * @param { string } axis - Indicates the axis tag, which must contain four ASCII characters. - * @param { number } value - Indicates the value of the axis field. + * @param { double } value - Indicates the value of the axis field. * @throws { BusinessError } 25900001 - Parameter error. Possible causes: Incorrect parameter range. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - addVariation(axis: string, value: number); + addVariation(axis: string, value: double); } /** @@ -2230,7 +3106,7 @@ declare namespace drawing { /** * Enumerates the font edging types. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -2260,7 +3136,7 @@ declare namespace drawing { /** * Enumerates the font hinting types. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -2337,23 +3213,40 @@ declare namespace drawing { /** * Sets the font size. - * @param { number } textSize - Font size. The value is a floating point number. + * @param { double } textSize - Font size. The value is a floating point number. * If a negative number is passed in, the size is set to 0. If the size is 0, the text drawn will not be displayed. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Sets the font size. + * @param { double } textSize - Font size. The value is a floating point number. + * If a negative number is passed in, the size is set to 0. If the size is 0, the text drawn will not be displayed. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - setSize(textSize: number): void; + setSize(textSize: double): void; /** * Obtains the font size. - * @returns { number } Font size. The value is a floating point number. + * @returns { double } Font size. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - getSize(): number; + /** + * Obtains the font size. + * @returns { double } Font size. The value is a floating point number. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getSize(): double; /** * Sets the typeface style (including attributes such as font name, weight, and italic) for the font. @@ -2385,48 +3278,93 @@ declare namespace drawing { /** * Measures the width of a single character. - * If the typeface of the current font does not support the character to measure, the system typeface is used to measure the character width. + * If the typeface of the current font does not support the character to measure, + * the system typeface is used to measure the character width. * @param { string } text - Single character to measure. The length of the string must be 1. - * @returns { number } Width of the character. The value is a floating point number. + * @returns { double } Width of the character. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - measureSingleCharacter(text: string): number; + /** + * Measures the width of a single character. + * If the typeface of the current font does not support the character to measure, + * the system typeface is used to measure the character width. + * @param { string } text - Single character to measure. The length of the string must be 1. + * @returns { double } Width of the character. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + measureSingleCharacter(text: string): double; /** * Measures the text width. * @param { string } text - Text Symbol Content. * @param { TextEncoding } encoding - Encoding format. - * @returns { number } Width of the text. The value is a floating point number. + * @returns { double } Width of the text. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - measureText(text: string, encoding: TextEncoding): number; + /** + * Measures the text width. + * @param { string } text - Text Symbol Content. + * @param { TextEncoding } encoding - Encoding format. + * @returns { double } Width of the text. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + measureText(text: string, encoding: TextEncoding): double; /** * Sets a horizontal scale factor for this font. - * @param { number } scaleX - Horizontal scale factor. The value is a floating point number. + * @param { double } scaleX - Horizontal scale factor. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setScaleX(scaleX: number): void; + /** + * Sets a horizontal scale factor for this font. + * @param { double } scaleX - Horizontal scale factor. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setScaleX(scaleX: double): void; /** * Sets a horizontal skew factor for this font. - * @param { number } skewX - Horizontal skew factor. - * A positive number means a skew to the left, and a negative number means a skew to the right. The value is a floating point number. + * @param { double } skewX - Horizontal skew factor. + * A positive number means a skew to the left, and a negative number means a skew to the right. + * The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setSkewX(skewX: number): void; + /** + * Sets a horizontal skew factor for this font. + * @param { double } skewX - Horizontal skew factor. + * A positive number means a skew to the left, and a negative number means a skew to the right. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setSkewX(skewX: double): void; /** * Sets a font edging effect. @@ -2451,13 +3389,23 @@ declare namespace drawing { /** * Obtains the number of glyphs represented by text. * @param { string } text - Indicates the character storage encoded with text encoding. - * @returns { number } Returns the count of text. + * @returns { int } Returns the count of text. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - countText(text: string): number; + /** + * Obtains the number of glyphs represented by text. + * @param { string } text - Indicates the character storage encoded with text encoding. + * @returns { int } Returns the count of text. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + countText(text: string): int; /** * Sets whether to request that baselines be snapped to pixels when the current canvas matrix is axis aligned. @@ -2519,27 +3467,51 @@ declare namespace drawing { /** * Obtains the width of each glyph in an array. - * @param { Array } glyphs - Glyph array, which can be generated by textToGlyphs. - * @returns { Array } Glyph array, which can be generated by textToGlyphs. + * @param { Array } glyphs - Glyph array, which can be generated by textToGlyphs. + * @returns { Array } Glyph array, which can be generated by textToGlyphs. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getWidths(glyphs: Array): Array; + /** + * Obtains the width of each glyph in an array. + * @param { Array } glyphs - Glyph array, which can be generated by textToGlyphs. + * @returns { Array } Glyph array, which can be generated by textToGlyphs. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getWidths(glyphs: Array): Array; /** * Converts text into glyph indexes. * @param { string } text - Text string. - * @param { number } glyphCount - Number of glyphs represented by the text. The value must be the same as the value obtained from countText. - * The default value is the number of characters in the text string. The value is an integer. - * @returns { Array } Returns the storage for glyph indices. + * @param { int } glyphCount - Number of glyphs represented by the text. + * The value must be the same as the value obtained from countText. + * The default value is the number of characters in the text string. The value is an integer. + * @returns { Array } Returns the storage for glyph indices. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - textToGlyphs(text: string, glyphCount?: number): Array; + /** + * Converts text into glyph indexes. + * @param { string } text - Text string. + * @param { int } glyphCount - Number of glyphs represented by the text. + * The value must be the same as the value obtained from countText. + * The default value is the number of characters in the text string. The value is an integer. + * @returns { Array } Returns the storage for glyph indices. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + textToGlyphs(text: string, glyphCount?: int): Array; /** * Checks whether sub-pixel rendering is used for this font. @@ -2559,11 +3531,18 @@ declare namespace drawing { /** * Obtains the horizontal skew factor of this font. - * @returns { number } Horizontal skew factor. + * @returns { double } Horizontal skew factor. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getSkewX(): number; + /** + * Obtains the horizontal skew factor of this font. + * @returns { double } Horizontal skew factor. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getSkewX(): double; /** * Checks whether the bold effect is set for this font. @@ -2576,11 +3555,18 @@ declare namespace drawing { /** * Obtains the horizontal scale ratio of this font. - * @returns { number } Horizontal scale ratio. + * @returns { double } Horizontal scale ratio. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getScaleX(): number; + /** + * Obtains the horizontal scale ratio of this font. + * @returns { double } Horizontal scale ratio. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getScaleX(): double; /** * Obtains the font hinting effect. @@ -2600,40 +3586,76 @@ declare namespace drawing { /** * Obtains the outline path of a glyph. - * @param { number } index - Index of the glyph. + * @param { int } index - Index of the glyph. * @returns { Path } Outline path of the glyph. * Note: Path use y-axis-goes-down system, y axis is inverted to the y-axis-goes-up system. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - createPathForGlyph(index: number): Path; + /** + * Obtains the outline path of a glyph. + * @param { int } index - Index of the glyph. + * @returns { Path } Outline path of the glyph. + * Note: Path use y-axis-goes-down system, y axis is inverted to the y-axis-goes-up system. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + createPathForGlyph(index: int): Path; /** * Obtains the rectangular bounding box of each glyph in an array. - * @param { Array } glyphs - Glyph array, which can be generated by textToGlyphs. + * @param { Array } glyphs - Glyph array, which can be generated by textToGlyphs. * @returns { Array } Array that holds the rectangular bounding boxes. - * Note: 1. Rect use y-axis-goes-down system, y axis is inverted to the y-axis-goes-up system. - *
2. Rect use two points(left-bottom & right-top) to describe the bound. - *
3. The bound rect will be snap to integral boundaries. + * Note: 1. Rect use y-axis-goes-down system, y axis is inverted to the y-axis-goes-up system. + *
2. Rect use two points(left-bottom & right-top) to describe the bound. + *
3. The bound rect will be snap to integral boundaries. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - getBounds(glyphs: Array): Array; + /** + * Obtains the rectangular bounding box of each glyph in an array. + * @param { Array } glyphs - Glyph array, which can be generated by textToGlyphs. + * @returns { Array } Array that holds the rectangular bounding boxes. + * Note: 1. Rect use y-axis-goes-down system, y axis is inverted to the y-axis-goes-up system. + *
2. Rect use two points(left-bottom & right-top) to describe the bound. + *
3. The bound rect will be snap to integral boundaries. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getBounds(glyphs: Array): Array; /** * Obtains the outline path of a text. * @param { string } text - UTF-8 text-encoded characters. - * @param { number } byteLength - Length of the outline path, - * which is obtained based on the minimum value between the passed value of byteLength and the actual text byte size. - * @param { number } x - X coordinate of the text in the drawing area, with the origin as the start point. - * @param { number } y - Y coordinate of the text in the drawing area, with the origin as the start point. + * @param { int } byteLength - Length of the outline path, + * which is obtained based on the minimum value between the passed value of byteLength and + * the actual text byte size. + * @param { double } x - X coordinate of the text in the drawing area, with the origin as the start point. + * @param { double } y - Y coordinate of the text in the drawing area, with the origin as the start point. * @returns { Path } Outline path of the text. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - getTextPath(text: string, byteLength: number, x: number, y: number): Path; + /** + * Obtains the outline path of a text. + * @param { string } text - UTF-8 text-encoded characters. + * @param { int } byteLength - Length of the outline path, + * which is obtained based on the minimum value between the passed value of byteLength and + * the actual text byte size. + * @param { double } x - X coordinate of the text in the drawing area, with the origin as the start point. + * @param { double } y - Y coordinate of the text in the drawing area, with the origin as the start point. + * @returns { Path } Outline path of the text. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getTextPath(text: string, byteLength: int, x: double, y: double): Path; /** * Sets whether to follow the theme font. When followed is set to true, @@ -2658,7 +3680,7 @@ declare namespace drawing { /** * Enumerates the font measurement flags, which is used to specify whether a field in the font measurement information is valid. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -2717,126 +3739,234 @@ declare namespace drawing { /** * Maximum distance from the baseline to the highest coordinate of the text. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Maximum distance from the baseline to the highest coordinate of the text. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - top: number; + top: double; /** * Distance from the baseline to the highest coordinate of the text. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Distance from the baseline to the highest coordinate of the text. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - ascent: number; + ascent: double; /** * Distance from the baseline to the lowest coordinate of the text. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Distance from the baseline to the lowest coordinate of the text. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - descent: number; + descent: double; /** * Maximum distance from the baseline to the lowest coordinate of the text. The value is a floating point number. - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Maximum distance from the baseline to the lowest coordinate of the text. The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - bottom: number; + bottom: double; /** * Interline spacing, that is, the distance from the descent of one line of text to the ascent of the next line. * The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Interline spacing, that is, the distance from the descent of one line of text to the ascent of the next line. + * The value is a floating point number. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - leading: number; + leading: double; /** * Average character width. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - avgCharWidth?: number; + /** + * Average character width. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + avgCharWidth?: double; /** * Maximum character width. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - maxCharWidth?: number; + /** + * Maximum character width. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + maxCharWidth?: double; /** * Horizontal distance from the leftmost edge of any glyph bounding box to the origin. * This value is usually less than 0, indicating the minimum horizontal coordinate across all glyph bounding boxes. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - xMin?: number; + /** + * Horizontal distance from the leftmost edge of any glyph bounding box to the origin. + * This value is usually less than 0, indicating the minimum horizontal coordinate across all glyph bounding boxes. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + xMin?: double; /** * Horizontal distance from the rightmost edge of any glyph bounding box to the origin. * The value is a positive number, indicating the maximum horizontal coordinate across all glyph bounding boxes. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - xMax?: number; + /** + * Horizontal distance from the rightmost edge of any glyph bounding box to the origin. + * The value is a positive number, indicating the maximum horizontal coordinate across all glyph bounding boxes. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + xMax?: double; /** * Height of the lowercase letter x. The value is usually a negative value. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - xHeight?: number; + /** + * Height of the lowercase letter x. The value is usually a negative value. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + xHeight?: double; /** * Height of a capital letter. The value is usually a negative value. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - capHeight?: number; + /** + * Height of a capital letter. The value is usually a negative value. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + capHeight?: double; /** * Thickness of the underline. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - underlineThickness?: number; + /** + * Thickness of the underline. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + underlineThickness?: double; /** * Vertical distance from the baseline to the top of the underline. The value is usually a positive number. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - underlinePosition?: number; + /** + * Vertical distance from the baseline to the top of the underline. The value is usually a positive number. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + underlinePosition?: double; /** * Thickness of the strikethrough. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - strikethroughThickness?: number; + /** + * Thickness of the strikethrough. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + strikethroughThickness?: double; /** * Vertical distance from the baseline to the bottom of the strikethrough. The value is usually a negative value. - * @type { ?number } + * @type { ?double } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - strikethroughPosition?: number; + /** + * Vertical distance from the baseline to the bottom of the strikethrough. The value is usually a negative value. + * @type { ?double } + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + strikethroughPosition?: double; } /** @@ -2851,26 +3981,52 @@ declare namespace drawing { * and they are drawn at their original size if the target is large enough. * If the target is too small to hold the fixed lattices, all the fixed lattices are scaled down to fit the target, * and the lattices that are not on even columns and even rows are scaled to accommodate the remaining space. - * @param { Array } xDivs - Array of X coordinates used to divide the image. The value is an integer. - * @param { Array } yDivs - Array of Y coordinates used to divide the image. The value is an integer. - * @param { number } fXCount - Size of the array that holds the X coordinates. The value range is [0, 5]. - * @param { number } fYCount - Size of the array that holds the Y coordinates. The value range is [0, 5]. - * @param { common2D.Rect | null } fBounds - Source bounds to draw. The rectangle parameter must be an integer. - * The default value is the rectangle size of the original image. If the rectangle parameter is a decimal, - * the decimal part is discarded and converted into an integer. - * @param { Array | null } fRectTypes - Array that holds the rectangle types. The default value is null. - * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). - * @param { Array | null } fColors - Array that holds the colors used to fill the lattices. The default value is null. - * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). + * @param { Array } xDivs - Array of X coordinates used to divide the image. The value is an integer. + * @param { Array } yDivs - Array of Y coordinates used to divide the image. The value is an integer. + * @param { int } fXCount - Size of the array that holds the X coordinates. The value range is [0, 5]. + * @param { int } fYCount - Size of the array that holds the Y coordinates. The value range is [0, 5]. + * @param { common2D.Rect | null } [fBounds] - Source bounds to draw. The rectangle parameter must be an integer. + * The default value is the rectangle size of the original image. If the rectangle parameter is a decimal, + * the decimal part is discarded and converted into an integer. + * @param { Array | null } [fRectTypes] - Array that holds the rectangle types. The default value is null. + * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). + * @param { Array | null } [fColors] - Array that holds the colors used to fill the lattices. + * The default value is null. + * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). + * @returns { Lattice } Lattice object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @since 12 + */ + /** + * Divides the image into lattices. The lattices on both even columns and even rows are fixed, + * and they are drawn at their original size if the target is large enough. + * If the target is too small to hold the fixed lattices, all the fixed lattices are scaled down to fit the target, + * and the lattices that are not on even columns and even rows are scaled to accommodate the remaining space. + * @param { Array } xDivs - Array of X coordinates used to divide the image. The value is an integer. + * @param { Array } yDivs - Array of Y coordinates used to divide the image. The value is an integer. + * @param { int } fXCount - Size of the array that holds the X coordinates. The value range is [0, 5]. + * @param { int } fYCount - Size of the array that holds the Y coordinates. The value range is [0, 5]. + * @param { common2D.Rect | null } [fBounds] - Source bounds to draw. The rectangle parameter must be an integer. + * The default value is the rectangle size of the original image. If the rectangle parameter is a decimal, + * the decimal part is discarded and converted into an integer. + * @param { Array | null } [fRectTypes] - Array that holds the rectangle types. The default value is null. + * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). + * @param { Array | null } [fColors] - Array that holds the colors used to fill the lattices. + * The default value is null. + * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). * @returns { Lattice } Lattice object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'12', '1.2':'20'} + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - static createImageLattice(xDivs: Array, yDivs: Array, fXCount: number, fYCount: number, + static createImageLattice(xDivs: Array, yDivs: Array, fXCount: int, fYCount: int, fBounds?: common2D.Rect | null, fRectTypes?: Array | null, fColors?: Array | null): Lattice; /** @@ -2878,32 +4034,59 @@ declare namespace drawing { * and they are drawn at their original size if the target is large enough. * If the target is too small to hold the fixed lattices, all the fixed lattices are scaled down to fit the target, * and the lattices that are not on even columns and even rows are scaled to accommodate the remaining space. - * @param { Array } xDivs - Array of X coordinates used to divide the image. The value is an integer. - * @param { Array } yDivs - Array of Y coordinates used to divide the image. The value is an integer. - * @param { number } fXCount - Size of the array that holds the X coordinates. The value range is [0, 5]. - * @param { number } fYCount - Size of the array that holds the Y coordinates. The value range is [0, 5]. - * @param { common2D.Rect | null } fBounds - Source bounds to draw. The rectangle parameter must be an integer. - * The default value is the rectangle size of the original image. If the rectangle parameter is a decimal, - * the decimal part is discarded and converted into an integer. - * @param { Array | null } fRectTypes - Array that holds the rectangle types. The default value is null. - * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). - * @param { Array | null } fColors - Array that holds the colors used to fill the lattices. - * Each color is represented by a 32-bit unsigned integer in hexadecimal ARGB format. - * The default value is null. If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). + * @param { Array } xDivs - Array of X coordinates used to divide the image. The value is an integer. + * @param { Array } yDivs - Array of Y coordinates used to divide the image. The value is an integer. + * @param { int } fXCount - Size of the array that holds the X coordinates. The value range is [0, 5]. + * @param { int } fYCount - Size of the array that holds the Y coordinates. The value range is [0, 5]. + * @param { common2D.Rect | null } [fBounds] - Source bounds to draw. The rectangle parameter must be an integer. + * The default value is the rectangle size of the original image. If the rectangle parameter is a decimal, + * the decimal part is discarded and converted into an integer. + * @param { Array | null } [fRectTypes] - Array that holds the rectangle types. The default value is null. + * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). + * @param { Array | null } [fColors] - Array that holds the colors used to fill the lattices. + * Each color is represented by a 32-bit unsigned integer in hexadecimal ARGB format. + * The default value is null. + * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). * @returns { Lattice } Lattice object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - static createImageLattice(xDivs: Array, yDivs: Array, fXCount: number, fYCount: number, - fBounds?: common2D.Rect | null, fRectTypes?: Array | null, fColors?: Array | null): Lattice; + /** + * Divides the image into lattices. The lattices on both even columns and even rows are fixed, + * and they are drawn at their original size if the target is large enough. + * If the target is too small to hold the fixed lattices, all the fixed lattices are scaled down to fit the target, + * and the lattices that are not on even columns and even rows are scaled to accommodate the remaining space. + * @param { Array } xDivs - Array of X coordinates used to divide the image. The value is an integer. + * @param { Array } yDivs - Array of Y coordinates used to divide the image. The value is an integer. + * @param { int } fXCount - Size of the array that holds the X coordinates. The value range is [0, 5]. + * @param { int } fYCount - Size of the array that holds the Y coordinates. The value range is [0, 5]. + * @param { common2D.Rect | null } [fBounds] - Source bounds to draw. The rectangle parameter must be an integer. + * The default value is the rectangle size of the original image. If the rectangle parameter is a decimal, + * the decimal part is discarded and converted into an integer. + * @param { Array | null } [fRectTypes] - Array that holds the rectangle types. The default value is null. + * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). + * @param { Array | null } [fColors] - Array that holds the colors used to fill the lattices. + * Each color is represented by a 32-bit unsigned integer in hexadecimal ARGB format. + * The default value is null. + * If this parameter is specified, the array size must be (fXCount + 1) * (fYCount + 1). + * @returns { Lattice } Lattice object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createImageLattice(xDivs: Array, yDivs: Array, fXCount: int, fYCount: int, + fBounds?: common2D.Rect | null, fRectTypes?: Array | null, fColors?: Array | null): Lattice; } /** * Enumerates the types of rectangles used to fill the lattices. This enum is used only in Lattice. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 @@ -2943,20 +4126,34 @@ declare namespace drawing { /** * Creates a mask filter with a blur effect. * @param { BlurType } blurType - Blur type. - * @param { number } sigma - Standard deviation of the Gaussian blur to apply. The value must be a floating point number greater than 0. + * @param { double } sigma - Standard deviation of the Gaussian blur to apply. + * The value must be a floating point number greater than 0. * @returns { MaskFilter } MaskFilter object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createBlurMaskFilter(blurType: BlurType, sigma: number): MaskFilter; + /** + * Creates a mask filter with a blur effect. + * @param { BlurType } blurType - Blur type. + * @param { double } sigma - Standard deviation of the Gaussian blur to apply. + * The value must be a floating point number greater than 0. + * @returns { MaskFilter } MaskFilter object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createBlurMaskFilter(blurType: BlurType, sigma: double): MaskFilter; } /** * Enumerates the styles of the dashed path effect. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 18 */ @@ -2989,44 +4186,88 @@ declare namespace drawing { class PathEffect { /** * Creates a PathEffect object that converts a path into a dotted line. - * @param { Array } intervals - Array of ON and OFF lengths of dotted lines. + * @param { Array } intervals - Array of ON and OFF lengths of dotted lines. * The number of arrays must be an even number and be greater than or equal to 2. - * @param { number } phase - Offset used during drawing. The value is a floating point number. + * @param { double } phase - Offset used during drawing. The value is a floating point number. * @returns { PathEffect } PathEffect object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createDashPathEffect(intervals: Array, phase: number): PathEffect; + /** + * Creates a PathEffect object that converts a path into a dotted line. + * @param { Array } intervals - Array of ON and OFF lengths of dotted lines. + * The number of arrays must be an even number and be greater than or equal to 2. + * @param { double } phase - Offset used during drawing. The value is a floating point number. + * @returns { PathEffect } PathEffect object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createDashPathEffect(intervals: Array, phase: double): PathEffect; /** - * Creates a path effect that transforms the sharp angle between line segments into a rounded corner with the specified radius. - * @param { number } radius - Radius of the rounded corner. The value must be greater than 0. The value is a floating point number. + * Creates a path effect that transforms the sharp angle between line segments + * into a rounded corner with the specified radius. + * @param { double } radius - Radius of the rounded corner. + * The value must be greater than 0. The value is a floating point number. * @returns { PathEffect } PathEffect object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createCornerPathEffect(radius: number): PathEffect; + /** + * Creates a path effect that transforms the sharp angle between line segments + * into a rounded corner with the specified radius. + * @param { double } radius - Radius of the rounded corner. + * The value must be greater than 0. The value is a floating point number. + * @returns { PathEffect } PathEffect object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createCornerPathEffect(radius: double): PathEffect; /** * Creates an effect that segments the path and scatters the segments in an irregular pattern along the path. - * @param { number } segLength - Distance along the path at which each segment is fragmented. The value is a floating point number. - * If a negative number or the value 0 is passed in, no effect is created. - * @param { number } dev - Maximum amount by which the end points of the segments can be randomly displaced during rendering. - * The value is a floating-point number. - * @param { number } seedAssist - Optional parameter to assist in generating a pseudo-random seed for the effect. - * The default value is 0, and the value is a 32-bit unsigned integer. + * @param { double } segLength - Distance along the path at which each segment is fragmented. + * The value is a floating point number. + * If a negative number or the value 0 is passed in, no effect is created. + * @param { double } dev - Maximum amount by which the end points of the segments can be + * randomly displaced during rendering. The value is a floating-point number. + * @param { int } [seedAssist] - Optional parameter to assist in generating a pseudo-random seed for the effect. + * The default value is 0, and the value is a 32-bit unsigned integer. * @returns { PathEffect } PathEffect object. * @static * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - static createDiscretePathEffect(segLength: number, dev: number, seedAssist?: number): PathEffect; + /** + * Creates an effect that segments the path and scatters the segments in an irregular pattern along the path. + * @param { double } segLength - Distance along the path at which each segment is fragmented. + * The value is a floating point number. + * If a negative number or the value 0 is passed in, no effect is created. + * @param { double } dev - Maximum amount by which the end points of the segments can be + * randomly displaced during rendering. The value is a floating-point number. + * @param { int } [seedAssist] - Optional parameter to assist in generating a pseudo-random seed for the effect. + * The default value is 0, and the value is a 32-bit unsigned integer. + * @returns { PathEffect } PathEffect object. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createDiscretePathEffect(segLength: double, dev: double, seedAssist?: int): PathEffect; /** * Creates a path effect by sequentially applying the inner effect and then the outer effect. @@ -3039,22 +4280,40 @@ declare namespace drawing { */ static createComposePathEffect(outer: PathEffect, inner: PathEffect): PathEffect; - /** + /** * Creates a dashed path effect based on the shape described by a path. * @param { Path } path - Path that defines the shape to be used for filling each dash in the pattern. - * @param { number } advance - Distance between two consecutive dashes. The value is a floating point number greater than 0. - * Otherwise, an error code is thrown. - * @param { number } phase - Starting offset of the dash pattern. The value is a floating point number. - * The actual offset used is the absolute value of this value modulo the value of advance. + * @param { double } advance - Distance between two consecutive dashes. + * The value is a floating point number greater than 0. + * Otherwise, an error code is thrown. + * @param { double } phase - Starting offset of the dash pattern. The value is a floating point number. + * The actual offset used is the absolute value of this value modulo the value of advance. * @param { PathDashStyle } style - Style of the dashed path effect. * @returns { PathEffect } PathEffect object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - static createPathDashEffect(path: Path, advance: number, phase: number, style: PathDashStyle): PathEffect; + /** + * Creates a dashed path effect based on the shape described by a path. + * @param { Path } path - Path that defines the shape to be used for filling each dash in the pattern. + * @param { double } advance - Distance between two consecutive dashes. + * The value is a floating point number greater than 0. + * Otherwise, an error code is thrown. + * @param { double } phase - Starting offset of the dash pattern. The value is a floating point number. + * The actual offset used is the absolute value of this value modulo the value of advance. + * @param { PathDashStyle } style - Style of the dashed path effect. + * @returns { PathEffect } PathEffect object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createPathDashEffect(path: Path, advance: double, phase: double, style: PathDashStyle): PathEffect; /** * Creates an overlay path effect based on two distinct path effects. @@ -3079,114 +4338,250 @@ declare namespace drawing { class ShaderEffect { /** * Creates a ShaderEffect object with a single color. - * @param { number } color - Color in the ARGB format. The value is a 32-bit unsigned integer. + * @param { int } color - Color in the ARGB format. The value is a 32-bit unsigned integer. * @returns { ShaderEffect } Returns the shader with single color ShaderEffect object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. + * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createColorShader(color: number): ShaderEffect; + /** + * Creates a ShaderEffect object with a single color. + * @param { int } color - Color in the ARGB format. The value is a 32-bit unsigned integer. + * @returns { ShaderEffect } Returns the shader with single color ShaderEffect object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createColorShader(color: int): ShaderEffect; /** * Creates a ShaderEffect object that generates a linear gradient between two points. * @param { common2D.Point } startPt - Start point. * @param { common2D.Point } endPt - End point. - * @param { Array } colors - Array of colors to distribute between the two points. - * The values in the array are 32-bit (ARGB) unsigned integers. + * @param { Array } colors - Array of colors to distribute between the two points. + * The values in the array are 32-bit (ARGB) unsigned integers. * @param { TileMode } mode - Tile mode of the shader effect. - * @param { Array | null } pos - Relative position of each color in the color array. - * The array length must be the same as that of colors. The first element in the array must be 0.0, - * the last element must be 1.0, and the middle elements must be between 0.0 and 1.0 and increase by index. - * The default value is null, indicating that colors are evenly distributed between the two points. + * @param { Array | null } pos - Relative position of each color in the color array. + * The array length must be the same as that of colors. The first element in the array must be 0.0, + * the last element must be 1.0, and the middle elements must be between 0.0 and 1.0 and increase by index. + * The default value is null, indicating that colors are evenly distributed between the two points. * @param { Matrix | null } matrix - Matrix object used to perform matrix transformation on the shader effect. - * The default value is null, indicating the identity matrix. + * The default value is null, indicating the identity matrix. * @returns { ShaderEffect } Returns a linear gradient ShaderEffect object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createLinearGradient(startPt: common2D.Point, endPt: common2D.Point, colors: Array, - mode: TileMode, pos?: Array | null, matrix?: Matrix | null): ShaderEffect; + /** + * Creates a ShaderEffect object that generates a linear gradient between two points. + * @param { common2D.Point } startPt - Start point. + * @param { common2D.Point } endPt - End point. + * @param { Array } colors - Array of colors to distribute between the two points. + * The values in the array are 32-bit (ARGB) unsigned integers. + * @param { TileMode } mode - Tile mode of the shader effect. + * @param { Array | null } pos - Relative position of each color in the color array. + * The array length must be the same as that of colors. The first element in the array must be 0.0, + * the last element must be 1.0, and the middle elements must be between 0.0 and 1.0 and increase by index. + * The default value is null, indicating that colors are evenly distributed between the two points. + * @param { Matrix | null } matrix - Matrix object used to perform matrix transformation on the shader effect. + * The default value is null, indicating the identity matrix. + * @returns { ShaderEffect } Returns a linear gradient ShaderEffect object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createLinearGradient(startPt: common2D.Point, endPt: common2D.Point, colors: Array, + mode: TileMode, pos?: Array | null, matrix?: Matrix | null): ShaderEffect; /** * Creates a ShaderEffect object that generates a radial gradient based on the center and radius of a circle. * A radial gradient refers to the color transition that spreads out gradually from the center of a circle. * @param { common2D.Point } centerPt - Center of the circle. - * @param { number } radius - Radius of the gradient. A negative number is invalid. The value is a floating point number. - * @param { Array } colors - Array of colors to distribute between the center and ending shape of the circle. - * The values in the array are 32-bit (ARGB) unsigned integers. + * @param { double } radius - Radius of the gradient. A negative number is invalid. + * The value is a floating point number. + * @param { Array } colors - Array of colors to distribute between the center + * and ending shape of the circle. + * The values in the array are 32-bit (ARGB) unsigned integers. * @param { TileMode } mode - Tile mode of the shader effect. - * @param { Array | null } pos - Relative position of each color in the color array. - * The array length must be the same as that of colors. The first element in the array must be 0.0, the last element must be 1.0, - * and the middle elements must be between 0.0 and 1.0 and increase by index. - * The default value is null, indicating that colors are evenly distributed between the center and ending shape of the circle. + * @param { Array | null } pos - Relative position of each color in the color array. + * The array length must be the same as that of colors. The first element in the array must be 0.0, + * the last element must be 1.0, + * and the middle elements must be between 0.0 and 1.0 and increase by index. + * The default value is null, indicating that colors are evenly distributed between + * the center and ending shape of the circle. * @param { Matrix | null } matrix - Matrix object used to perform matrix transformation on the shader effect. - * The default value is null, indicating the identity matrix. + * The default value is null, indicating the identity matrix. * @returns { ShaderEffect } Returns a radial gradient ShaderEffect object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createRadialGradient(centerPt: common2D.Point, radius: number, colors: Array, - mode: TileMode, pos?: Array | null, matrix?: Matrix | null): ShaderEffect; + /** + * Creates a ShaderEffect object that generates a radial gradient based on the center and radius of a circle. + * A radial gradient refers to the color transition that spreads out gradually from the center of a circle. + * @param { common2D.Point } centerPt - Center of the circle. + * @param { double } radius - Radius of the gradient. A negative number is invalid. + * The value is a floating point number. + * @param { Array } colors - Array of colors to distribute between the center + * and ending shape of the circle. + * The values in the array are 32-bit (ARGB) unsigned integers. + * @param { TileMode } mode - Tile mode of the shader effect. + * @param { Array | null } pos - Relative position of each color in the color array. + * The array length must be the same as that of colors. The first element in the array must be 0.0, + * the last element must be 1.0, + * and the middle elements must be between 0.0 and 1.0 and increase by index. + * The default value is null, indicating that colors are evenly distributed between + * the center and ending shape of the circle. + * @param { Matrix | null } matrix - Matrix object used to perform matrix transformation on the shader effect. + * The default value is null, indicating the identity matrix. + * @returns { ShaderEffect } Returns a radial gradient ShaderEffect object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createRadialGradient(centerPt: common2D.Point, radius: double, colors: Array, + mode: TileMode, pos?: Array | null, matrix?: Matrix | null): ShaderEffect; /** * Creates a ShaderEffect object that generates a color sweep gradient around a given center point, * either in a clockwise or counterclockwise direction. * @param { common2D.Point } centerPt - Center of the circle. - * @param { Array } colors - Array of colors to distribute between the start angle and end angle. - * The values in the array are 32-bit (ARGB) unsigned integers. + * @param { Array } colors - Array of colors to distribute between the start angle and end angle. + * The values in the array are 32-bit (ARGB) unsigned integers. * @param { TileMode } mode - Tile mode of the shader effect. - * @param { number } startAngle - Start angle of the sweep gradient, in degrees. - * The value 0 indicates the positive direction of the X axis. A positive number indicates an offset towards the positive direction, - * and a negative number indicates an offset towards the negative direction. The value is a floating point number. - * @param { number } endAngle - End angle of the sweep gradient, in degrees. - * The value 0 indicates the positive direction of the X axis. A positive number indicates an offset towards the positive direction, - * and a negative number indicates an offset towards the negative direction. A value less than the start angle is invalid. - * The value is a floating point number. - * @param { Array | null } pos - Relative position of each color in the color array. The array length must be the same as that of colors. - * The first element in the array must be 0.0, the last element must be 1.0, and the middle elements must be between 0.0 and 1.0 and increase by index. - * The default value is null, indicating that the colors are evenly distributed between the start angle and end angle. + * @param { double } startAngle - Start angle of the sweep gradient, in degrees. + * The value 0 indicates the positive direction of the X axis. + * A positive number indicates an offset towards the positive direction, + * and a negative number indicates an offset towards the negative direction. + * The value is a floating point number. + * @param { double } endAngle - End angle of the sweep gradient, in degrees. + * The value 0 indicates the positive direction of the X axis. + * A positive number indicates an offset towards the positive direction, + * and a negative number indicates an offset towards the negative direction. + * A value less than the start angle is invalid. + * The value is a floating point number. + * @param { Array | null } pos - Relative position of each color in the color array. + * The array length must be the same as that of colors. + * The first element in the array must be 0.0, the last element must be 1.0, + * and the middle elements must be between 0.0 and 1.0 and increase by index. + * The default value is null, indicating that the colors are evenly distributed between + * the start angle and end angle. * @param { Matrix | null } matrix - Matrix object used to perform matrix transformation on the shader effect. - * The default value is null, indicating the identity matrix. + * The default value is null, indicating the identity matrix. * @returns { ShaderEffect } Returns a sweep gradient ShaderEffect object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createSweepGradient(centerPt: common2D.Point, colors: Array, - mode: TileMode, startAngle: number, endAngle: number, pos?: Array | null, + /** + * Creates a ShaderEffect object that generates a color sweep gradient around a given center point, + * either in a clockwise or counterclockwise direction. + * @param { common2D.Point } centerPt - Center of the circle. + * @param { Array } colors - Array of colors to distribute between the start angle and end angle. + * The values in the array are 32-bit (ARGB) unsigned integers. + * @param { TileMode } mode - Tile mode of the shader effect. + * @param { double } startAngle - Start angle of the sweep gradient, in degrees. + * The value 0 indicates the positive direction of the X axis. + * A positive number indicates an offset towards the positive direction, + * and a negative number indicates an offset towards the negative direction. + * The value is a floating point number. + * @param { double } endAngle - End angle of the sweep gradient, in degrees. + * The value 0 indicates the positive direction of the X axis. + * A positive number indicates an offset towards the positive direction, + * and a negative number indicates an offset towards the negative direction. + * A value less than the start angle is invalid. + * The value is a floating point number. + * @param { Array | null } pos - Relative position of each color in the color array. + * The array length must be the same as that of colors. + * The first element in the array must be 0.0, the last element must be 1.0, + * and the middle elements must be between 0.0 and 1.0 and increase by index. + * The default value is null, indicating that the colors are evenly distributed between + * the start angle and end angle. + * @param { Matrix | null } matrix - Matrix object used to perform matrix transformation on the shader effect. + * The default value is null, indicating the identity matrix. + * @returns { ShaderEffect } Returns a sweep gradient ShaderEffect object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createSweepGradient(centerPt: common2D.Point, colors: Array, + mode: TileMode, startAngle: double, endAngle: double, pos?: Array | null, matrix?: Matrix | null): ShaderEffect; /** * Creates a ShaderEffect object that generates a conical gradient between two given circles. * @param { common2D.Point } startPt - Center of the start circle of the gradient. - * @param { number } startRadius - Radius of the start circle of the gradient. A negative number is invalid. - * The value is a floating point number. + * @param { double } startRadius - Radius of the start circle of the gradient. A negative number is invalid. + * The value is a floating point number. * @param { common2D.Point } endPt - Center of the end circle of the gradient. - * @param { number } endRadius - Radius of the end circle of the gradient. A negative value is invalid. - * The value is a floating point number. - * @param { Array } colors - Array of colors to distribute between the start circle and end circle. - * The values in the array are 32-bit (ARGB) unsigned integers. + * @param { double } endRadius - Radius of the end circle of the gradient. A negative value is invalid. + * The value is a floating point number. + * @param { Array } colors - Array of colors to distribute between the start circle and end circle. + * The values in the array are 32-bit (ARGB) unsigned integers. * @param { TileMode } mode - Tile mode of the shader effect. - * @param { Array | null } pos - Relative position of each color in the color array. The array length must be the same as that of colors. - * The first element in the array must be 0.0, the last element must be 1.0, and the middle elements must be between 0.0 and 1.0 and increase by index. - * The default value is null, indicating that colors are evenly distributed between the two circles. + * @param { Array | null } pos - Relative position of each color in the color array. + * The array length must be the same as that of colors. + * The first element in the array must be 0.0, the last element must be 1.0, + * and the middle elements must be between 0.0 and 1.0 and increase by index. + * The default value is null, indicating that colors are evenly distributed between the two circles. * @param { Matrix | null } matrix - Matrix object used to perform matrix transformation on the shader effect. - * The default value is null, indicating the identity matrix. + * The default value is null, indicating the identity matrix. * @returns { ShaderEffect } Returns a conical gradient ShaderEffect object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createConicalGradient(startPt: common2D.Point, startRadius: number, endPt: common2D.Point, - endRadius: number, colors: Array, mode: TileMode, - pos?: Array | null, matrix?: Matrix | null): ShaderEffect; + /** + * Creates a ShaderEffect object that generates a conical gradient between two given circles. + * @param { common2D.Point } startPt - Center of the start circle of the gradient. + * @param { double } startRadius - Radius of the start circle of the gradient. A negative number is invalid. + * The value is a floating point number. + * @param { common2D.Point } endPt - Center of the end circle of the gradient. + * @param { double } endRadius - Radius of the end circle of the gradient. A negative value is invalid. + * The value is a floating point number. + * @param { Array } colors - Array of colors to distribute between the start circle and end circle. + * The values in the array are 32-bit (ARGB) unsigned integers. + * @param { TileMode } mode - Tile mode of the shader effect. + * @param { Array | null } pos - Relative position of each color in the color array. + * The array length must be the same as that of colors. + * The first element in the array must be 0.0, the last element must be 1.0, + * and the middle elements must be between 0.0 and 1.0 and increase by index. + * The default value is null, indicating that colors are evenly distributed between the two circles. + * @param { Matrix | null } matrix - Matrix object used to perform matrix transformation on the shader effect. + * The default value is null, indicating the identity matrix. + * @returns { ShaderEffect } Returns a conical gradient ShaderEffect object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createConicalGradient(startPt: common2D.Point, startRadius: double, endPt: common2D.Point, + endRadius: double, colors: Array, mode: TileMode, + pos?: Array | null, matrix?: Matrix | null): ShaderEffect; /** * Creates an ShaderEffect object that generates a shader with single image. @@ -3223,7 +4618,7 @@ declare namespace drawing { /** * Enumerates the tile modes of the shader effect. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -3266,34 +4661,70 @@ declare namespace drawing { /** * Creates a ShadowLayer object. * - * @param { number } blurRadius - Radius of the shadow layer. The value must be a floating point number greater than 0. - * @param { number } x - Offset on the X axis. The value is a floating point number. - * @param { number } y - Offset on the Y axis. The value is a floating point number. - * @param { common2D.Color } color - Color in ARGB format. The value of each color channel is an integer ranging from 0 to 255. + * @param { double } blurRadius - Radius of the shadow layer. + * The value must be a floating point number greater than 0. + * @param { double } x - Offset on the X axis. The value is a floating point number. + * @param { double } y - Offset on the Y axis. The value is a floating point number. + * @param { common2D.Color } color - Color in ARGB format. + * The value of each color channel is an integer ranging from 0 to 255. * @returns { ShadowLayer } ShadowLayer object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static create(blurRadius: number, x: number, y: number, color: common2D.Color): ShadowLayer; + /** + * Creates a ShadowLayer object. + * + * @param { double } blurRadius - Radius of the shadow layer. + * The value must be a floating point number greater than 0. + * @param { double } x - Offset on the X axis. The value is a floating point number. + * @param { double } y - Offset on the Y axis. The value is a floating point number. + * @param { common2D.Color } color - Color in ARGB format. + * The value of each color channel is an integer ranging from 0 to 255. + * @returns { ShadowLayer } ShadowLayer object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static create(blurRadius: double, x: double, y: double, color: common2D.Color): ShadowLayer; /** * Creates a ShadowLayer object. * - * @param { number } blurRadius - Radius of the shadow layer. The value must be a floating point number greater than 0. - * @param { number } x - Offset on the X axis. The value is a floating point number. - * @param { number } y - Offset on the Y axis. The value is a floating point number. - * @param { common2D.Color | number } color - Color, represented by an unsigned integer in hexadecimal ARGB format. + * @param { double } blurRadius - Radius of the shadow layer. + * The value must be a floating point number greater than 0. + * @param { double } x - Offset on the X axis. The value is a floating point number. + * @param { double } y - Offset on the Y axis. The value is a floating point number. + * @param { common2D.Color | int } color - Color, represented by an unsigned integer in hexadecimal ARGB format. * @returns { ShadowLayer } ShadowLayer object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - static create(blurRadius: number, x: number, y: number, color: common2D.Color | number): ShadowLayer; + /** + * Creates a ShadowLayer object. + * + * @param { double } blurRadius - Radius of the shadow layer. + * The value must be a floating point number greater than 0. + * @param { double } x - Offset on the X axis. The value is a floating point number. + * @param { double } y - Offset on the Y axis. The value is a floating point number. + * @param { common2D.Color | int } color - Color, represented by an unsigned integer in hexadecimal ARGB format. + * @returns { ShadowLayer } ShadowLayer object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static create(blurRadius: double, x: double, y: double, color: common2D.Color | int): ShadowLayer; } /** @@ -3313,24 +4744,48 @@ declare namespace drawing { *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'11', '1.2':'20'} + * @since 11 + */ + /** + * Creates a ColorFilter object with a given color and blend mode. + * @param { common2D.Color } color - Color in ARGB format. The value of each color channel is an integer ranging from 0 to 255. + * @param { BlendMode } mode - Blend mode. + * @returns { ColorFilter } Colorfilter object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ static createBlendModeColorFilter(color: common2D.Color, mode: BlendMode): ColorFilter; /** * Creates a ColorFilter object with a given color and blend mode. - * @param { common2D.Color | number } color - Color, represented by an unsigned integer in hexadecimal ARGB format. + * @param { common2D.Color | int } color - Color, represented by an unsigned integer in hexadecimal ARGB format. * @param { BlendMode } mode - Blend mode. * @returns { ColorFilter } Colorfilter object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing - * @since arkts {'1.1':'18', '1.2':'20'} + * @since 18 + */ + /** + * Creates a ColorFilter object with a given color and blend mode. + * @param { common2D.Color | int } color - Color, represented by an unsigned integer in hexadecimal ARGB format. + * @param { BlendMode } mode - Blend mode. + * @returns { ColorFilter } Colorfilter object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 * @arkts 1.1&1.2 */ - static createBlendModeColorFilter(color: common2D.Color | number, mode: BlendMode): ColorFilter; + static createBlendModeColorFilter(color: common2D.Color | int, mode: BlendMode): ColorFilter; /** * Creates a ColorFilter object by combining another two color filters. @@ -3373,27 +4828,38 @@ declare namespace drawing { static createLumaColorFilter(): ColorFilter; /** * Creates a color filter object with a 4*5 color matrix. - * @param { Array } matrix - An array of 20 numbers, indicating the 4*5 matrix. + * @param { Array } matrix - An array of 20 numbers, indicating the 4*5 matrix. * @returns { ColorFilter } Colorfilter object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createMatrixColorFilter(matrix: Array): ColorFilter; + /** + * Creates a color filter object with a 4*5 color matrix. + * @param { Array } matrix - An array of 20 numbers, indicating the 4*5 matrix. + * @returns { ColorFilter } Colorfilter object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createMatrixColorFilter(matrix: Array): ColorFilter; /** * Makes a color filter with the given mutColor and addColor. - * @param { common2D.Color | number } mutColor - The range of color channels must be [0, 255], used to multiply source color. - * @param { common2D.Color | number } addColor - The range of color channels must be [0, 255], used to add to source color. + * @param { common2D.Color | int } mutColor - The range of color channels must be [0, 255], used to multiply source color. + * @param { common2D.Color | int } addColor - The range of color channels must be [0, 255], used to add to source color. * @returns { ColorFilter } Colorfilter object. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static createLightingColorFilter(mutColor: common2D.Color | number, addColor: common2D.Color | number): ColorFilter; + static createLightingColorFilter(mutColor: common2D.Color | int, addColor: common2D.Color | int): ColorFilter; } @@ -3406,19 +4872,38 @@ declare namespace drawing { class ImageFilter { /** * Creates an image filter with a given blur effect. - * @param { number } sigmaX - Standard deviation of the Gaussian blur along the X axis. The value must be a floating point number greater than 0. - * @param { number } sigmaY - Standard deviation of the Gaussian blur along the Y axis. The value must be a floating point number greater than 0. + * @param { double } sigmaX - Standard deviation of the Gaussian blur along the X axis. + * The value must be a floating point number greater than 0. + * @param { double } sigmaY - Standard deviation of the Gaussian blur along the Y axis. + * The value must be a floating point number greater than 0. * @param { TileMode } tileMode - Tile mode to apply to the edges. * @param { ImageFilter | null } imageFilter - Filter to which the image filter will be applied. - * The default value is null, indicating that the image filter is directly applied to the original image. + * The default value is null, indicating that the image filter is directly applied to the original image. * @returns { ImageFilter } ImageFilter object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - static createBlurImageFilter(sigmaX: number, sigmaY: number, + /** + * Creates an image filter with a given blur effect. + * @param { double } sigmaX - Standard deviation of the Gaussian blur along the X axis. + * The value must be a floating point number greater than 0. + * @param { double } sigmaY - Standard deviation of the Gaussian blur along the Y axis. + * The value must be a floating point number greater than 0. + * @param { TileMode } tileMode - Tile mode to apply to the edges. + * @param { ImageFilter | null } imageFilter - Filter to which the image filter will be applied. + * The default value is null, indicating that the image filter is directly applied to the original image. + * @returns { ImageFilter } ImageFilter object. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + static createBlurImageFilter(sigmaX: double, sigmaY: double, tileMode: TileMode, imageFilter?: ImageFilter | null): ImageFilter; /** * Creates an image filter object with a given color filter effect. @@ -3436,9 +4921,9 @@ declare namespace drawing { /** * Makes an ImageFilter object that instance with the provided x and y offset. - * @param { number } dx - Indicates the offset in the X direction. - * @param { number } dy - Indicates the offset in the Y direction. - * @param { ImageFilter | null } input - Indicates the input image filter used to generate offset effects, or uses + * @param { double } dx - Indicates the offset in the X direction. + * @param { double } dy - Indicates the offset in the Y direction. + * @param { ImageFilter | null } [input] - Indicates the input image filter used to generate offset effects, or uses * the source bitmap if this is null. * @returns { ImageFilter } ImageFilter object. * @static @@ -3446,7 +4931,7 @@ declare namespace drawing { * @crossplatform * @since 20 */ - static createOffsetImageFilter(dx: number, dy: number, input?: ImageFilter | null): ImageFilter; + static createOffsetImageFilter(dx: double, dy: double, input?: ImageFilter | null): ImageFilter; /** * Makes an ImageFilter object that applies the bitmap to the input. @@ -3503,7 +4988,7 @@ declare namespace drawing { } /** * Enumerates the join styles of a pen. The join style defines the shape of the joints of a polyline segment drawn by the pen. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -3533,7 +5018,7 @@ declare namespace drawing { /** * Enumerates the cap styles of a pen. The cap style defines the style of both ends of a line segment drawn by the pen. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -3562,7 +5047,7 @@ declare namespace drawing { /** * Enumerates the blur types of a mask filter. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -3626,22 +5111,43 @@ declare namespace drawing { * Sets the maximum ratio allowed between the sharp corner length of a polyline and its line width. * When drawing a polyline with the pen, if JoinStyle is set to MITER_JOIN and this maximum ratio is exceeded, * the corner will be displayed as beveled instead of mitered. - * @param { number } miter - Maximum ratio of the sharp corner length of the polyline to the line width. - * A negative number is processed as 4.0 during drawing. Non-negative numbers take effect normally. The value is a floating point number. + * @param { double } miter - Maximum ratio of the sharp corner length of the polyline to the line width. + * A negative number is processed as 4.0 during drawing. Non-negative numbers take effect normally. + * The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setMiterLimit(miter: number): void; + /** + * Sets the maximum ratio allowed between the sharp corner length of a polyline and its line width. + * When drawing a polyline with the pen, if JoinStyle is set to MITER_JOIN and this maximum ratio is exceeded, + * the corner will be displayed as beveled instead of mitered. + * @param { double } miter - Maximum ratio of the sharp corner length of the polyline to the line width. + * A negative number is processed as 4.0 during drawing. Non-negative numbers take effect normally. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setMiterLimit(miter: double): void; /** * Obtains the maximum ratio allowed between the sharp corner length of a polyline and its line width. - * @returns { number } Returns the miter limit. + * @returns { double } Returns the miter limit. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getMiterLimit(): number; + /** + * Obtains the maximum ratio allowed between the sharp corner length of a polyline and its line width. + * @returns { double } Returns the miter limit. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getMiterLimit(): double; /** * Sets the shader effect for this pen. @@ -3654,39 +5160,81 @@ declare namespace drawing { setShaderEffect(shaderEffect: ShaderEffect): void; /** - * Sets a color for this pen. - * @param { common2D.Color } color - Color in ARGB format. The value of each color channel is an integer ranging from 0 to 255. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. - * @syscap SystemCapability.Graphics.Drawing - * @since 11 - */ + * Sets a color for this pen. + * @param { common2D.Color } color - Color in ARGB format. + * The value of each color channel is an integer ranging from 0 to 255. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @since 11 + */ + /** + * Sets a color for this pen. + * @param { common2D.Color } color - Color in ARGB format. + * The value of each color channel is an integer ranging from 0 to 255. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ setColor(color: common2D.Color): void; /** - * Sets a color for this pen. This API provides better performance than setColor and is recommended. - * @param { number } alpha - Alpha channel value of the color in ARGB format. The value is an integer ranging from 0 to 255 - * Any passed-in floating point number is rounded down. - * @param { number } red - Red channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. - * Any passed-in floating point number is rounded down. - * @param { number } green - Green channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. - * Any passed-in floating point number is rounded down. - * @param { number } blue - Blue channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. - * Any passed-in floating point number is rounded down. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. - * @syscap SystemCapability.Graphics.Drawing - * @since 12 - */ - setColor(alpha: number, red: number, green: number, blue: number): void; - + * Sets a color for this pen. This API provides better performance than setColor and is recommended. + * @param { int } alpha - Alpha channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255 + * Any passed-in floating point number is rounded down. + * @param { int } red - Red channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @param { int } green - Green channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @param { int } blue - Blue channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @since 12 + */ + /** + * Sets a color for this pen. This API provides better performance than setColor and is recommended. + * @param { int } alpha - Alpha channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255 + * Any passed-in floating point number is rounded down. + * @param { int } red - Red channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @param { int } green - Green channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @param { int } blue - Blue channel value of the color in ARGB format. + * The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setColor(alpha: int, red: int, green: int, blue: int): void; + + /** + * Sets a color for this pen. + * @param { int } color - Color in hexadecimal ARGB format. + * @syscap SystemCapability.Graphics.Drawing + * @since 18 + */ /** - * Sets a color for this pen. - * @param { number } color - Color in hexadecimal ARGB format. - * @syscap SystemCapability.Graphics.Drawing - * @since 18 - */ - setColor(color: number): void; + * Sets a color for this pen. + * @param { int } color - Color in hexadecimal ARGB format. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setColor(color: int): void; /** * Set the color by four floating point values, unpremultiplied. The color values are interpreted as being in @@ -3719,32 +5267,58 @@ declare namespace drawing { /** * Obtains the color of this pen. - * @returns { number } Returns a 32-bit (ARGB) variable that describes the color of hexadecimal format. + * @returns { int } Returns a 32-bit (ARGB) variable that describes the color of hexadecimal format. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - getHexColor(): number; + /** + * Obtains the color of this pen. + * @returns { int } Returns a 32-bit (ARGB) variable that describes the color of hexadecimal format. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getHexColor(): int; /** - * Sets the stroke width for this pen. The value 0 is treated as an unusually thin width. During drawing, - * the width of 0 is always drawn as 1 pixel wide, regardless of any scaling applied to the canvas. - * Negative values are also regarded as the value 0 during the drawing process. - * - * @param { number } width - Stroke width. The value is a floating point number. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. - * @syscap SystemCapability.Graphics.Drawing - * @since 11 - */ - setStrokeWidth(width: number): void; + * Sets the stroke width for this pen. The value 0 is treated as an unusually thin width. During drawing, + * the width of 0 is always drawn as 1 pixel wide, regardless of any scaling applied to the canvas. + * Negative values are also regarded as the value 0 during the drawing process. + * + * @param { double } width - Stroke width. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @since 11 + */ + /** + * Sets the stroke width for this pen. The value 0 is treated as an unusually thin width. During drawing, + * the width of 0 is always drawn as 1 pixel wide, regardless of any scaling applied to the canvas. + * Negative values are also regarded as the value 0 during the drawing process. + * + * @param { double } width - Stroke width. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setStrokeWidth(width: double): void; /** * Obtains the stroke width of this pen. The width describes the thickness of the outline of a shape. - * @returns { number } Stroke width for the pen, in px. + * @returns { double } Stroke width for the pen, in px. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getWidth(): number; + /** + * Obtains the stroke width of this pen. The width describes the thickness of the outline of a shape. + * @returns { double } Stroke width for the pen, in px. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getWidth(): double; /** * Enables anti-aliasing for this pen. Anti-aliasing makes the edges of the content smoother. @@ -3769,21 +5343,40 @@ declare namespace drawing { /** * Sets an alpha value for this pen. * - * @param { number } alpha - Alpha value. The value is an integer in the range [0, 255]. If a floating point number is passed in, the value is rounded down. + * @param { int } alpha - Alpha value. The value is an integer in the range [0, 255]. + * If a floating point number is passed in, the value is rounded down. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - setAlpha(alpha: number): void; + /** + * Sets an alpha value for this pen. + * + * @param { int } alpha - Alpha value. The value is an integer in the range [0, 255]. + * If a floating point number is passed in, the value is rounded down. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setAlpha(alpha: int): void; /** * Obtains the alpha value of this pen. - * @returns { number } Returns a 8-bit variable that describes the alpha. + * @returns { int } Returns a 8-bit variable that describes the alpha. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getAlpha(): number; + /** + * Obtains the alpha value of this pen. + * @returns { int } Returns a 8-bit variable that describes the alpha. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getAlpha(): int; /** * Sets a color filter for this pen. @@ -3956,40 +5549,76 @@ declare namespace drawing { /** * Sets a color for this brush. - * @param { common2D.Color } color - Color in ARGB format. The value of each color channel is an integer ranging from 0 to 255. + * @param { common2D.Color } color - Color in ARGB format. + * The value of each color channel is an integer ranging from 0 to 255. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ + /** + * Sets a color for this brush. + * @param { common2D.Color } color - Color in ARGB format. + * The value of each color channel is an integer ranging from 0 to 255. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ setColor(color: common2D.Color): void; /** * Sets a color for this brush. This API provides better performance than setColor and is recommended. - * @param { number } alpha - Alpha channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. + * @param { int } alpha - Alpha channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. * Any passed-in floating point number is rounded down. - * @param { number } red - Red channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. + * @param { int } red - Red channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. * Any passed-in floating point number is rounded down. - * @param { number } green - Green channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. + * @param { int } green - Green channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. * Any passed-in floating point number is rounded down. - * @param { number } blue - Blue channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. + * @param { int } blue - Blue channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. * Any passed-in floating point number is rounded down. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setColor(alpha: number, red: number, green: number, blue: number): void; + /** + * Sets a color for this brush. This API provides better performance than setColor and is recommended. + * @param { int } alpha - Alpha channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @param { int } red - Red channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @param { int } green - Green channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @param { int } blue - Blue channel value of the color in ARGB format. The value is an integer ranging from 0 to 255. + * Any passed-in floating point number is rounded down. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setColor(alpha: int, red: int, green: int, blue: int): void; /** * Sets a color for this brush. - * @param { number } color - Color in hexadecimal ARGB format. + * @param { int } color - Color in hexadecimal ARGB format. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - setColor(color: number): void; + /** + * Sets a color for this brush. + * @param { int } color - Color in hexadecimal ARGB format. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setColor(color: int): void; /** * Sets the color by four floating point values, unpremultiplied. The color values are interpreted as being in @@ -4022,11 +5651,18 @@ declare namespace drawing { /** * Obtains the color of this brush. - * @returns { number } Returns a 32-bit (ARGB) variable that describes the color of hexadecimal format. + * @returns { int } Returns a 32-bit (ARGB) variable that describes the color of hexadecimal format. * @syscap SystemCapability.Graphics.Drawing * @since 18 */ - getHexColor(): number; + /** + * Obtains the color of this brush. + * @returns { int } Returns a 32-bit (ARGB) variable that describes the color of hexadecimal format. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getHexColor(): int; /** * Enables anti-aliasing for this brush. Anti-aliasing makes the edges of the content smoother. @@ -4049,21 +5685,39 @@ declare namespace drawing { /** * Sets an alpha value for this brush. - * @param { number } alpha - Alpha value. The value is an integer in the range [0, 255]. If a floating point number is passed in, the value is rounded down. + * @param { int } alpha - Alpha value. The value is an integer in the range [0, 255]. + * If a floating point number is passed in, the value is rounded down. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 11 */ - setAlpha(alpha: number): void; + /** + * Sets an alpha value for this brush. + * @param { int } alpha - Alpha value. The value is an integer in the range [0, 255]. + * If a floating point number is passed in, the value is rounded down. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setAlpha(alpha: int): void; /** * Obtains the alpha value of this brush. - * @returns { number } Returns a 8-bit variable that describes the alpha. + * @returns { int } Returns a 8-bit variable that describes the alpha. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getAlpha(): number; + /** + * Obtains the alpha value of this brush. + * @returns { int } Returns a 8-bit variable that describes the alpha. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getAlpha(): int; /** * Sets a color filter for this brush. @@ -4187,72 +5841,118 @@ declare namespace drawing { /** * Sets this matrix as an identity matrix and rotates it by a given degree around the rotation point (px, py). - * @param { number } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, - * and a negative number indicates a counterclockwise rotation. The value is a floating point number. - * @param { number } px - X coordinate of the rotation point. The value is a floating point number. - * @param { number } py - Y coordinate of the rotation point. The value is a floating point number. + * @param { double } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, + * and a negative number indicates a counterclockwise rotation. The value is a floating point number. + * @param { double } px - X coordinate of the rotation point. The value is a floating point number. + * @param { double } py - Y coordinate of the rotation point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setRotation(degree: number, px: number, py: number): void; + /** + * Sets this matrix as an identity matrix and rotates it by a given degree around the rotation point (px, py). + * @param { double } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, + * and a negative number indicates a counterclockwise rotation. The value is a floating point number. + * @param { double } px - X coordinate of the rotation point. The value is a floating point number. + * @param { double } py - Y coordinate of the rotation point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setRotation(degree: double, px: double, py: double): void; /** * Sets this matrix as an identity matrix and scales it with the coefficients (sx, sy) at the scale point (px, py). - * @param { number } sx - Scale coefficient along the X axis. If a negative number is passed in, - * the matrix is mirrored around y = px before being scaled. The value is a floating point number. - * @param { number } sy - Scale coefficient along the Y axis. If a negative number is passed in, - * the matrix is mirrored around x = py before being scaled. The value is a floating point number. - * @param { number } px - X coordinate of the scale point. The value is a floating point number. - * @param { number } py - Y coordinate of the scale point. The value is a floating point number. + * @param { double } sx - Scale coefficient along the X axis. If a negative number is passed in, + * the matrix is mirrored around y = px before being scaled. The value is a floating point number. + * @param { double } sy - Scale coefficient along the Y axis. If a negative number is passed in, + * the matrix is mirrored around x = py before being scaled. The value is a floating point number. + * @param { double } px - X coordinate of the scale point. The value is a floating point number. + * @param { double } py - Y coordinate of the scale point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setScale(sx: number, sy: number, px: number, py: number): void; + /** + * Sets this matrix as an identity matrix and scales it with the coefficients (sx, sy) at the scale point (px, py). + * @param { double } sx - Scale coefficient along the X axis. If a negative number is passed in, + * the matrix is mirrored around y = px before being scaled. The value is a floating point number. + * @param { double } sy - Scale coefficient along the Y axis. If a negative number is passed in, + * the matrix is mirrored around x = py before being scaled. The value is a floating point number. + * @param { double } px - X coordinate of the scale point. The value is a floating point number. + * @param { double } py - Y coordinate of the scale point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setScale(sx: double, sy: double, px: double, py: double): void; /** * Sets this matrix as an identity matrix and translates it by a given distance (dx, dy). - * @param { number } dx - Horizontal distance to translate. A positive number indicates a translation towards the positive direction of the X axis, - * and a negative number indicates a translation towards the negative direction of the X axis. The value is a floating point number. - * @param { number } dy - Vertical distance to translate. A positive number indicates a translation towards the positive direction of the Y axis, - * and a negative number indicates a translation towards the negative direction of the Y axis. The value is a floating point number. + * @param { double } dx - Horizontal distance to translate. + * A positive number indicates a translation towards the positive direction of the X axis, + * and a negative number indicates a translation towards the negative direction of the X axis. + * The value is a floating point number. + * @param { double } dy - Vertical distance to translate. + * A positive number indicates a translation towards the positive direction of the Y axis, + * and a negative number indicates a translation towards the negative direction of the Y axis. + * The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setTranslation(dx: number, dy: number): void; + /** + * Sets this matrix as an identity matrix and translates it by a given distance (dx, dy). + * @param { double } dx - Horizontal distance to translate. + * A positive number indicates a translation towards the positive direction of the X axis, + * and a negative number indicates a translation towards the negative direction of the X axis. + * The value is a floating point number. + * @param { double } dy - Vertical distance to translate. + * A positive number indicates a translation towards the positive direction of the Y axis, + * and a negative number indicates a translation towards the negative direction of the Y axis. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setTranslation(dx: double, dy: double): void; /** * Sets the skew transformation with a pivot point. - * @param { number } kx - The skew factor along the x-axis. - * @param { number } ky - The skew factor along the y-axis. - * @param { number } px - The x-coordinate of the point around which to apply the skew. - * @param { number } py - The y-coordinate of the point around which to apply the skew. + * @param { double } kx - The skew factor along the x-axis. + * @param { double } ky - The skew factor along the y-axis. + * @param { double } px - The x-coordinate of the point around which to apply the skew. + * @param { double } py - The y-coordinate of the point around which to apply the skew. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - setSkew(kx: number, ky: number, px: number, py: number): void; + setSkew(kx: double, ky: double, px: double, py: double): void; /** * Sets the sine and cosine values for a rotation transformation around a point. - * @param { number } sinValue - The sine of the angle of rotation. - * @param { number } cosValue - The cosine of the angle of rotation. - * @param { number } px - The x-coordinate of the point around which to rotate. - * @param { number } py - The y-coordinate of the point around which to rotate. + * @param { double } sinValue - The sine of the angle of rotation. + * @param { double } cosValue - The cosine of the angle of rotation. + * @param { double } px - The x-coordinate of the point around which to rotate. + * @param { double } py - The y-coordinate of the point around which to rotate. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - setSinCos(sinValue: number, cosValue: number, px: number, py: number): void; + setSinCos(sinValue: double, cosValue: double, px: double, py: double): void; /** * Sets parameters for this matrix. - * @param { Array } values - Each value in the array represents the following parameters: + * @param { Array } values - Each value in the array represents the following parameters: * values[0] - horizontal scale factor to store. * values[1] - horizontal skew factor to store. * values[2] - horizontal translation to store. @@ -4267,16 +5967,34 @@ declare namespace drawing { * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setMatrix(values: Array): void; + /** + * Sets parameters for this matrix. + * @param { Array } values - Each value in the array represents the following parameters: + * values[0] - horizontal scale factor to store. + * values[1] - horizontal skew factor to store. + * values[2] - horizontal translation to store. + * values[3] - vertical skew factor to store. + * values[4] - vertical scale factor to store. + * values[5] - vertical translation to store. + * values[6] - input x-axis values perspective factor to store. + * values[7] - input y-axis values perspective factor to store. + * values[8] - perspective scale factor to store. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setMatrix(values: Array): void; /** * Sets matrix to the copy of anther matrix object. - * @param { Array | Matrix } matrix - Indicates the Matrix object to copy. + * @param { Array | Matrix } matrix - Indicates the Matrix object to copy. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - setMatrix(matrix: Array | Matrix): void; + setMatrix(matrix: Array | Matrix): void; /** * Sets matrix to the product of matrix A and matrix B. @@ -4340,122 +6058,232 @@ declare namespace drawing { /** * Obtains the value of a given index in this matrix. The index ranges from 0 to 8. - * @param { number } index - Index. The value is an integer ranging from 0 to 8. - * @returns { number } Returns value corresponding to index.Returns 0 if out of range. + * @param { int } index - Index. The value is an integer ranging from 0 to 8. + * @returns { double } Returns value corresponding to index.Returns 0 if out of range. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. + *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getValue(index: number): number; + /** + * Obtains the value of a given index in this matrix. The index ranges from 0 to 8. + * @param { int } index - Index. The value is an integer ranging from 0 to 8. + * @returns { double } Returns value corresponding to index.Returns 0 if out of range. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types; 3. Parameter verification failed. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getValue(index: int): double; /** * Post multiplies this matrix by a matrix that is derived from an identity matrix after it has been rotated by a * given degree around the rotation point (px, py). - * @param { number } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, - * and a negative number indicates a counterclockwise rotation. The value is a floating point number. - * @param { number } px - X coordinate of the rotation point. The value is a floating point number. - * @param { number } py - Y coordinate of the rotation point. The value is a floating point number. + * @param { double } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, + * and a negative number indicates a counterclockwise rotation. The value is a floating point number. + * @param { double } px - X coordinate of the rotation point. The value is a floating point number. + * @param { double } py - Y coordinate of the rotation point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - postRotate(degree: number, px: number, py: number): void; + /** + * Post multiplies this matrix by a matrix that is derived from an identity matrix after it has been rotated by a + * given degree around the rotation point (px, py). + * @param { double } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, + * and a negative number indicates a counterclockwise rotation. The value is a floating point number. + * @param { double } px - X coordinate of the rotation point. The value is a floating point number. + * @param { double } py - Y coordinate of the rotation point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + postRotate(degree: double, px: double, py: double): void; /** * Post multiplies this matrix by a matrix that is derived from an identity matrix after it has been * scaled with the coefficient (sx, sy) at the scale point (px, py). - * @param { number } sx - Scale coefficient along the X axis. If a negative number is passed in, - * the matrix is mirrored around y = px before being scaled. The value is a floating point number. - * @param { number } sy - Scale coefficient along the Y axis. If a negative number is passed in, - * the matrix is mirrored around x = py before being scaled. The value is a floating point number. - * @param { number } px - X coordinate of the scale point. The value is a floating point number. - * @param { number } py - Y coordinate of the scale point. The value is a floating point number. + * @param { double } sx - Scale coefficient along the X axis. If a negative number is passed in, + * the matrix is mirrored around y = px before being scaled. The value is a floating point number. + * @param { double } sy - Scale coefficient along the Y axis. If a negative number is passed in, + * the matrix is mirrored around x = py before being scaled. The value is a floating point number. + * @param { double } px - X coordinate of the scale point. The value is a floating point number. + * @param { double } py - Y coordinate of the scale point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - postScale(sx: number, sy: number, px: number, py: number): void; /** - * Post multiplies this matrix by a matrix that is derived from an identity matrix after it has been translated by a given distance (dx, dy). - * @param { number } dx - Horizontal distance to translate. A positive number indicates a translation towards the positive direction of the X axis, - * and a negative number indicates a translation towards the negative direction of the X axis. The value is a floating point number. - * @param { number } dy - Vertical distance to translate. A positive number indicates a translation towards the positive direction of the Y axis, - * and a negative number indicates a translation towards the negative direction of the Y axis. The value is a floating point number. + * Post multiplies this matrix by a matrix that is derived from an identity matrix after it has been + * scaled with the coefficient (sx, sy) at the scale point (px, py). + * @param { double } sx - Scale coefficient along the X axis. If a negative number is passed in, + * the matrix is mirrored around y = px before being scaled. The value is a floating point number. + * @param { double } sy - Scale coefficient along the Y axis. If a negative number is passed in, + * the matrix is mirrored around x = py before being scaled. The value is a floating point number. + * @param { double } px - X coordinate of the scale point. The value is a floating point number. + * @param { double } py - Y coordinate of the scale point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + postScale(sx: double, sy: double, px: double, py: double): void; + /** + * Post multiplies this matrix by a matrix that is derived from an identity matrix after + * it has been translated by a given distance (dx, dy). + * @param { double } dx - Horizontal distance to translate. + * A positive number indicates a translation towards the positive direction of the X axis, + * and a negative number indicates a translation towards the negative direction of the X axis. + * The value is a floating point number. + * @param { double } dy - Vertical distance to translate. + * A positive number indicates a translation towards the positive direction of the Y axis, + * and a negative number indicates a translation towards the negative direction of the Y axis. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - postTranslate(dx: number, dy: number): void; + /** + * Post multiplies this matrix by a matrix that is derived from an identity matrix after + * it has been translated by a given distance (dx, dy). + * @param { double } dx - Horizontal distance to translate. + * A positive number indicates a translation towards the positive direction of the X axis, + * and a negative number indicates a translation towards the negative direction of the X axis. + * The value is a floating point number. + * @param { double } dy - Vertical distance to translate. + * A positive number indicates a translation towards the positive direction of the Y axis, + * and a negative number indicates a translation towards the negative direction of the Y axis. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + postTranslate(dx: double, dy: double): void; /** * Premultiplies this matrix by a matrix that is derived from an identity matrix after it has been rotated by a * given degree around the rotation point (px, py). - * @param { number } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, - * and a negative number indicates a counterclockwise rotation. The value is a floating point number. - * @param { number } px - X coordinate of the rotation point. The value is a floating point number. - * @param { number } py - Y coordinate of the rotation point. The value is a floating point number. + * @param { double } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, + * and a negative number indicates a counterclockwise rotation. The value is a floating point number. + * @param { double } px - X coordinate of the rotation point. The value is a floating point number. + * @param { double } py - Y coordinate of the rotation point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - preRotate(degree: number, px: number, py: number): void; + /** + * Premultiplies this matrix by a matrix that is derived from an identity matrix after it has been rotated by a + * given degree around the rotation point (px, py). + * @param { double } degree - Angle to rotate, in degrees. A positive number indicates a clockwise rotation, + * and a negative number indicates a counterclockwise rotation. The value is a floating point number. + * @param { double } px - X coordinate of the rotation point. The value is a floating point number. + * @param { double } py - Y coordinate of the rotation point. The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + preRotate(degree: double, px: double, py: double): void; /** * Sets matrix to matrix constructed from skewing by (kx, ky) about pivot point (px, py), multiplied by matrix. * This can be thought of as skewing relative to a pivot point after applying matrix. - * @param { number } kx - Indicates the horizontal skew factor. - * @param { number } ky - Indicates the vertical skew factor. - * @param { number } px - Indicates the pivot on x-axis. - * @param { number } py - Indicates the pivot on y-axis. + * @param { double } kx - Indicates the horizontal skew factor. + * @param { double } ky - Indicates the vertical skew factor. + * @param { double } px - Indicates the pivot on x-axis. + * @param { double } py - Indicates the pivot on y-axis. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - postSkew(kx: number, ky: number, px: number, py: number): void; + postSkew(kx: double, ky: double, px: double, py: double): void; /** * Premultiplies this matrix by a matrix that is derived from an identity matrix after it has been scaled with the * coefficient (sx, sy) at the scale point (px, py). - * @param { number } sx - Scale coefficient along the X axis. If a negative number is passed in, - * the matrix is mirrored around y = px before being scaled. The value is a floating point number. - * @param { number } sy - Scale coefficient along the Y axis. If a negative number is passed in, - * the matrix is mirrored around x = py before being scaled. The value is a floating point number. - * @param { number } px - X coordinate of the scale point. The value is a floating point number. - * @param { number } py - Y coordinate of the scale point. The value is a floating point number. + * @param { double } sx - Scale coefficient along the X axis. If a negative number is passed in, + * the matrix is mirrored around y = px before being scaled. The value is a floating point number. + * @param { double } sy - Scale coefficient along the Y axis. If a negative number is passed in, + * the matrix is mirrored around x = py before being scaled. The value is a floating point number. + * @param { double } px - X coordinate of the scale point. The value is a floating point number. + * @param { double } py - Y coordinate of the scale point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - preScale(sx: number, sy: number, px: number, py: number): void; /** - * Premultiplies this matrix by a matrix that is derived from an identity matrix after it has been translated by a given distance (dx, dy). - * @param { number } dx - Horizontal distance to translate. A positive number indicates a translation towards the positive direction of the X axis, - * and a negative number indicates a translation towards the negative direction of the X axis. The value is a floating point number. - * @param { number } dy - Vertical distance to translate. A positive number indicates a translation towards the positive direction of the Y axis, - * and a negative number indicates a translation towards the negative direction of the Y axis. The value is a floating point number. + * Premultiplies this matrix by a matrix that is derived from an identity matrix after it has been scaled with the + * coefficient (sx, sy) at the scale point (px, py). + * @param { double } sx - Scale coefficient along the X axis. If a negative number is passed in, + * the matrix is mirrored around y = px before being scaled. The value is a floating point number. + * @param { double } sy - Scale coefficient along the Y axis. If a negative number is passed in, + * the matrix is mirrored around x = py before being scaled. The value is a floating point number. + * @param { double } px - X coordinate of the scale point. The value is a floating point number. + * @param { double } py - Y coordinate of the scale point. The value is a floating point number. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + preScale(sx: double, sy: double, px: double, py: double): void; + /** + * Premultiplies this matrix by a matrix that is derived from an identity matrix after + * it has been translated by a given distance (dx, dy). + * @param { double } dx - Horizontal distance to translate. + * A positive number indicates a translation towards the positive direction of the X axis, + * and a negative number indicates a translation towards the negative direction of the X axis. + * The value is a floating point number. + * @param { double } dy - Vertical distance to translate. + * A positive number indicates a translation towards the positive direction of the Y axis, + * and a negative number indicates a translation towards the negative direction of the Y axis. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - preTranslate(dx: number, dy: number): void; + /** + * Premultiplies this matrix by a matrix that is derived from an identity matrix after + * it has been translated by a given distance (dx, dy). + * @param { double } dx - Horizontal distance to translate. + * A positive number indicates a translation towards the positive direction of the X axis, + * and a negative number indicates a translation towards the negative direction of the X axis. + * The value is a floating point number. + * @param { double } dy - Vertical distance to translate. + * A positive number indicates a translation towards the positive direction of the Y axis, + * and a negative number indicates a translation towards the negative direction of the Y axis. + * The value is a floating point number. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + preTranslate(dx: double, dy: double): void; /** * Sets matrix to matrix multiplied by matrix constructed from skewing by (kx, ky) about pivot point (px, py). * This can be thought of as scaling relative to a pivot point before applying matrix. - * @param { number } kx - Indicates the horizontal skew factor. - * @param { number } ky - Indicates the vertical skew factor. - * @param { number } px - Indicates the pivot on x-axis. - * @param { number } py - Indicates the pivot on y-axis. + * @param { double } kx - Indicates the horizontal skew factor. + * @param { double } ky - Indicates the vertical skew factor. + * @param { double } px - Indicates the pivot on x-axis. + * @param { double } py - Indicates the pivot on y-axis. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - preSkew(kx: number, ky: number, px: number, py: number): void; + preSkew(kx: double, ky: double, px: double, py: double): void; /** * Resets this matrix to an identity matrix. * @syscap SystemCapability.Graphics.Drawing @@ -4477,13 +6305,13 @@ declare namespace drawing { /** * Forms a circle by radius and maps it to a ellipse, returns the average radius of the ellipse. * The average radius is equal to the square root of the product of the major axis length and the minor axis length. - * @param { number } radius - circle size to map. - * @returns { number } Return average mapped radius. + * @param { double } radius - circle size to map. + * @returns { double } Return average mapped radius. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - mapRadius(radius: number): number; + mapRadius(radius: double): double; /** * Obtains all element values of this matrix. @@ -4491,7 +6319,14 @@ declare namespace drawing { * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - getAll(): Array; + /** + * Obtains all element values of this matrix. + * @returns { Array } nine scalar values contained by Matrix. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + getAll(): Array; /** * Sets the destination rectangle to the bounding rectangle of the shape obtained after transforming the source rectangle * with a matrix transformation. As shown in the figure below, the blue rectangle represents the source rectangle, @@ -4525,21 +6360,38 @@ declare namespace drawing { /** * Sets this matrix to a transformation matrix that maps the source point array to the destination point array. * Both the number of source points and that of destination points must be in the range [0, 4]. - * @param { Array } src - Array of source points. The array length must be the same as the value of count. - * @param { Array } dst - Array of destination points. The array length must be the same as the value of count. - * @param { number } count - Number of points in each array. The value is an integer. + * @param { Array } src - Array of source points. + * The array length must be the same as the value of count. + * @param { Array } dst - Array of destination points. + * The array length must be the same as the value of count. + * @param { int } count - Number of points in each array. The value is an integer. * @returns { boolean } Returns true if Matrix was constructed successfully * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setPolyToPoly(src: Array, dst: Array, count: number): boolean; + /** + * Sets this matrix to a transformation matrix that maps the source point array to the destination point array. + * Both the number of source points and that of destination points must be in the range [0, 4]. + * @param { Array } src - Array of source points. + * The array length must be the same as the value of count. + * @param { Array } dst - Array of destination points. + * The array length must be the same as the value of count. + * @param { int } count - Number of points in each array. The value is an integer. + * @returns { boolean } Returns true if Matrix was constructed successfully + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setPolyToPoly(src: Array, dst: Array, count: int): boolean; } /** * Enumerates the modes of scaling a source rectangle into a destination rectangle. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -4599,15 +6451,15 @@ declare namespace drawing { /** * Creates a region with a rectangle. - * @param { number } left - Indicates the left edge of the rectangle. - * @param { number } top - Indicates the top edge of the rectangle. - * @param { number } right - Indicates the right edge of the rectangle. - * @param { number } bottom - Indicates the bottom edge of the rectangle. + * @param { int } left - Indicates the left edge of the rectangle. + * @param { int } top - Indicates the top edge of the rectangle. + * @param { int } right - Indicates the right edge of the rectangle. + * @param { int } bottom - Indicates the bottom edge of the rectangle. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - constructor(left: number, top: number, right: number, bottom: number); + constructor(left: int, top: int, right: int, bottom: int); /** * Query whether this region is equal to the other region. @@ -4658,15 +6510,30 @@ declare namespace drawing { /** * Checks whether a point is contained in this region. - * @param { number } x - X coordinate of the point. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. - * @param { number } y - Y coordinate of the point. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. + * @param { int } x - X coordinate of the point. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } y - Y coordinate of the point. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. * @returns { boolean } Returns true if (x, y) is inside region; returns false otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - isPointContained(x: number, y:number): boolean; + /** + * Checks whether a point is contained in this region. + * @param { int } x - X coordinate of the point. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } y - Y coordinate of the point. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @returns { boolean } Returns true if (x, y) is inside region; returns false otherwise. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + isPointContained(x: int, y:int): boolean; /** * Checks whether another region is contained in this region. @@ -4694,28 +6561,52 @@ declare namespace drawing { /** * Offsets the region by adding dx along the x-axis and dy along the y-axis. - * @param { number } dx - Indicates the x coordinate of the point. The parameter must be an integer. - * @param { number } dy - Indicates the y coordinate of the point. The parameter must be an integer. + * @param { int } dx - Indicates the x coordinate of the point. The parameter must be an integer. + * @param { int } dy - Indicates the y coordinate of the point. The parameter must be an integer. * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - offset(dx: number, dy: number): void; + offset(dx: int, dy: int): void; /** * Checks whether a rectangle do not intersect with this region. Actually, - * this API determines whether the rectangle does not intersect with the bounding rectangle of the region, and therefore the result may not be accurate. - * @param { number } left - Left position of the rectangle. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. - * @param { number } top - Top position of the rectangle. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. - * @param { number } right - Right position of the rectangle. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. - * @param { number } bottom - Bottom position of the rectangle. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. + * this API determines whether the rectangle does not intersect with the bounding rectangle of the region, + * and therefore the result may not be accurate. + * @param { int } left - Left position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } top - Top position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } right - Right position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } bottom - Bottom position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. * @returns { boolean } Returns true if rect and region is not intersect; returns false otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - quickReject(left: number, top: number, right: number, bottom: number): boolean; + /** + * Checks whether a rectangle do not intersect with this region. Actually, + * this API determines whether the rectangle does not intersect with the bounding rectangle of the region, + * and therefore the result may not be accurate. + * @param { int } left - Left position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } top - Top position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } right - Right position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } bottom - Bottom position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @returns { boolean } Returns true if rect and region is not intersect; returns false otherwise. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + quickReject(left: int, top: int, right: int, bottom: int): boolean; /** * Determines whether region is intersect with another. @@ -4742,17 +6633,38 @@ declare namespace drawing { /** * Sets a rectangle. - * @param { number } left - Left position of the rectangle. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. - * @param { number } top - Top position of the rectangle. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. - * @param { number } right - Right position of the rectangle. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. - * @param { number } bottom - Bottom position of the rectangle. The value must be an integer. If a decimal is passed in, the decimal part is rounded off. + * @param { int } left - Left position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } top - Top position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } right - Right position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } bottom - Bottom position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. * @returns { boolean } Returns true if constructed region is not empty; returns false otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. + *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing * @since 12 */ - setRect(left: number, top: number, right: number, bottom: number): boolean; + /** + * Sets a rectangle. + * @param { int } left - Left position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } top - Top position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } right - Right position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @param { int } bottom - Bottom position of the rectangle. The value must be an integer. + * If a decimal is passed in, the decimal part is rounded off. + * @returns { boolean } Returns true if constructed region is not empty; returns false otherwise. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; + *
2. Incorrect parameter types. + * @syscap SystemCapability.Graphics.Drawing + * @crossplatform + * @since 20 + */ + setRect(left: int, top: int, right: int, bottom: int): boolean; /** * Sets the region to the specified region. @@ -4774,7 +6686,7 @@ declare namespace drawing { /** * Enumerates the operations for combining two regions. - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 @@ -4832,7 +6744,7 @@ declare namespace drawing { /** * Enumerates the corner positions of a rounded rectangle. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -4870,7 +6782,7 @@ declare namespace drawing { * Enumerates the constraints on the source rectangle. * It is used to specify whether to limit the sampling range within the source rectangle when drawing an image on a canvas. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @since 12 */ @@ -4936,17 +6848,17 @@ declare namespace drawing { /** * Makes a 2D rectangular object from boundary coordinates. - * @param { number } left - Indicates the X-coordinate of the left edge. - * @param { number } top - Indicates the Y-coordinate of the top edge. - * @param { number } right - Indicates the X-coordinate of the right edge. - * @param { number } bottom - Indicates the Y-coordinate of the bottom edge. + * @param { double } left - Indicates the X-coordinate of the left edge. + * @param { double } top - Indicates the Y-coordinate of the top edge. + * @param { double } right - Indicates the X-coordinate of the right edge. + * @param { double } bottom - Indicates the Y-coordinate of the bottom edge. * @returns { common2D.Rect } - Returns an Rect object with the specific coordinates (left, top, right, bottom). * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static makeLtrb(left: number, top: number, right: number, bottom: number) : common2D.Rect; + static makeLtrb(left: double, top: double, right: double, bottom: double) : common2D.Rect; /** * Makes a deep copy of a 2D rectangular object. @@ -4963,49 +6875,49 @@ declare namespace drawing { * Gets the width of a 2D rectangular object. * * @param { common2D.Rect } rect - Indicates the Rect object to query. - * @returns { number } - Returns the width. + * @returns { double } - Returns the width. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static getWidth(rect: common2D.Rect): number; + static getWidth(rect: common2D.Rect): double; /** * Gets the height of a 2D rectangular object. * * @param { common2D.Rect } rect - Indicates the Rect object to query. - * @returns { number } - Returns the height. + * @returns { double } - Returns the height. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static getHeight(rect: common2D.Rect): number; + static getHeight(rect: common2D.Rect): double; /** * Calculates the x-coordinate of the center point of the 2D rectangular object. * * @param { common2D.Rect } rect - Indicates the Rect object to query. - * @returns { number } - Returns the center X coordinate. + * @returns { double } - Returns the center X coordinate. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static centerX(rect: common2D.Rect): number; + static centerX(rect: common2D.Rect): double; /** * Calculates the y-coordinate of the center point of the 2D rectangular object. * * @param { common2D.Rect } rect - Indicates the Rect object to query. - * @returns { number } - Returns the center Y coordinate. + * @returns { double } - Returns the center Y coordinate. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static centerY(rect: common2D.Rect): number; + static centerY(rect: common2D.Rect): double; /** * Checks if one 2D rectangular object fully contains another. @@ -5024,46 +6936,46 @@ declare namespace drawing { * Checks if one 2D rectangular object fully contains the specified boundary coordinates. * * @param { common2D.Rect } rect - The container Rect object. - * @param { number } left - Indicates the left boundary of the target region. - * @param { number } top - Indicates the top boundary of the target region. - * @param { number } right - Indicates the right boundary of the target region. - * @param { number } bottom - Indicates the bottom boundary of the target region. + * @param { double } left - Indicates the left boundary of the target region. + * @param { double } top - Indicates the top boundary of the target region. + * @param { double } right - Indicates the right boundary of the target region. + * @param { double } bottom - Indicates the bottom boundary of the target region. * @returns { boolean } - Returns true if 'rect' fully contains the specified boundary coordinates; returns false otherwise. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static contains(rect: common2D.Rect, left: number, top: number, right: number, bottom: number): boolean; + static contains(rect: common2D.Rect, left: double, top: double, right: double, bottom: double): boolean; /** * Checks if one 2D rectangular object contains a specific point. * * @param { common2D.Rect } rect - The container Rect object. - * @param { number } x - Indicates the X-coordinate of the point to check. - * @param { number } y - Indicates the Y-coordinate of the point to check. + * @param { double } x - Indicates the X-coordinate of the point to check. + * @param { double } y - Indicates the Y-coordinate of the point to check. * @returns { boolean } - Returns true if 'rect' contains the specified point; returns false otherwise. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static contains(rect: common2D.Rect, x: number, y: number): boolean; + static contains(rect: common2D.Rect, x: double, y: double): boolean; /** * Modifies a 2D rectangular's boundaries by inward offsets. * * @param { common2D.Rect } rect - The Rect object to adjust. - * @param { number } left - Indicates the amount to add from the left boundary. - * @param { number } top - Indicates the amount to add from the top boundary. - * @param { number } right - Indicates the amount to substract from the right boundary. - * @param { number } bottom - Indicates the amount to substract from the bottom boundary. + * @param { double } left - Indicates the amount to add from the left boundary. + * @param { double } top - Indicates the amount to add from the top boundary. + * @param { double } right - Indicates the amount to substract from the right boundary. + * @param { double } bottom - Indicates the amount to substract from the bottom boundary. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static inset(rect: common2D.Rect, left: number, top: number, right: number, bottom: number): void; + static inset(rect: common2D.Rect, left: double, top: double, right: double, bottom: double): void; /** * Relpace a 2D rectangular object by the intersection of itself and another. @@ -5122,27 +7034,27 @@ declare namespace drawing { * and adding dy to its top and bottom coordinates. * * @param { common2D.Rect } rect - Indicates the Rect object. - * @param { number } dx - Indicates the amount to add to the rectangle's left and right coordinates. - * @param { number } dy - Indicates the amount to add to the rectangle's top and bottom coordinates. + * @param { double } dx - Indicates the amount to add to the rectangle's left and right coordinates. + * @param { double } dy - Indicates the amount to add to the rectangle's top and bottom coordinates. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static offset(rect: common2D.Rect, dx: number, dy: number): void; + static offset(rect: common2D.Rect, dx: double, dy: double): void; /** * Offsets the rectangle to a specific position and kepps the width and height unchanged. * * @param { common2D.Rect } rect - Indicates the Rect object. - * @param { number } newLeft - Indicates the new left coordinates. - * @param { number } newTop - Indicates the new top coordinates. + * @param { double } newLeft - Indicates the new left coordinates. + * @param { double } newTop - Indicates the new top coordinates. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static offsetTo(rect: common2D.Rect, newLeft: number, newTop: number): void; + static offsetTo(rect: common2D.Rect, newLeft: double, newTop: double): void; /** * Sets the boundary coordinates of a 2D rectangular object with that of another. @@ -5158,16 +7070,16 @@ declare namespace drawing { /** * Sets the boundary coordinates of a 2D rectangular object with that of specific value. * @param { common2D.Rect } rect - Indicates the Rect object to be modified. - * @param { number } left - Indicates the X-coordinate of the left edge. - * @param { number } top - Indicates the Y-coordinate of the top edge. - * @param { number } right - Indicates the X-coordinate of the right edge. - * @param { number } bottom - Indicates the Y-coordinate of the bottom edge. + * @param { double } left - Indicates the X-coordinate of the left edge. + * @param { double } top - Indicates the Y-coordinate of the top edge. + * @param { double } right - Indicates the X-coordinate of the right edge. + * @param { double } bottom - Indicates the Y-coordinate of the bottom edge. * @static * @syscap SystemCapability.Graphics.Drawing * @crossplatform * @since 20 */ - static setLtrb(rect: common2D.Rect, left: number, top: number, right: number, bottom: number): void; + static setLtrb(rect: common2D.Rect, left: double, top: double, right: double, bottom: double): void; /** * Sets the boundary coordinates of a 2D rectangular object to zero. @@ -5208,4 +7120,4 @@ declare namespace drawing { } } -export default drawing; +export default drawing; \ No newline at end of file diff --git a/api/@ohos.graphics.hdrCapability.d.ts b/api/@ohos.graphics.hdrCapability.d.ts index 6b261e4f2b5d59a710fcfb81a60517f1a895cfbc..c00f07b942589986ecd0fc176ee22021cef005d8 100644 --- a/api/@ohos.graphics.hdrCapability.d.ts +++ b/api/@ohos.graphics.hdrCapability.d.ts @@ -40,14 +40,14 @@ declare namespace hdrCapability { /** * Enumerates the HDR Format * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphic.Graphic2D.ColorManager.Core * @since 11 */ /** * Enumerates the HDR Format * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphic.Graphic2D.ColorManager.Core * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} diff --git a/api/@ohos.graphics.scene.d.ts b/api/@ohos.graphics.scene.d.ts index 46635a0c9e14bd9721efd48c5a0d6d74a3a64873..7f164ea157c1a4d391180d1c6ad51816159ade4a 100644 --- a/api/@ohos.graphics.scene.d.ts +++ b/api/@ohos.graphics.scene.d.ts @@ -16,7 +16,6 @@ /** * @file Export 3D interfaces * @kit ArkGraphics3D - * @arkts 1.1&1.2 */ /** @@ -25,6 +24,13 @@ * @since 12 */ export { ToneMappingType, ToneMappingSettings, PostProcessSettings, BloomSettings } from './graphics3d/ScenePostProcessSettings'; +/** + * Export post processing settings + * @syscap SystemCapability.ArkUi.Graphics3D + * @since 20 + * @arkts 1.2 + */ +export { ToneMappingType, ToneMappingSettings, PostProcessSettings } from './graphics3d/ScenePostProcessSettings'; /** * Export scene types @@ -33,6 +39,13 @@ export { ToneMappingType, ToneMappingSettings, PostProcessSettings, BloomSetting */ export { Vec2, Vec3, Vec4, Color, Rect, Quaternion, Aabb, Position3, Rotation3, Scale3, GeometryType, GeometryDefinition, PrimitiveTopology, CustomGeometry, CubeGeometry, PlaneGeometry, SphereGeometry } from './graphics3d/SceneTypes'; +/** + * Export scene types + * @syscap SystemCapability.ArkUi.Graphics3D + * @since 20 + * @arkts 1.2 + */ +export { Vec2, Vec3, Vec4, Color, Rect, Quaternion, Position3, Scale3 } from './graphics3d/SceneTypes'; /** * Export scene resources @@ -43,6 +56,13 @@ export { SceneResourceType, SceneResource, Shader, MaterialType, Material, Shade SubMesh, Mesh, Animation, EnvironmentBackgroundType, Environment, Image, CullMode, Blend, RenderSort, MaterialProperty, MetallicRoughnessMaterial, MeshResource, Morpher, Sampler, SamplerFilter, SamplerAddressMode } from './graphics3d/SceneResources'; +/** + * Export scene resources + * @syscap SystemCapability.ArkUi.Graphics3D + * @since 20 + * @arkts 1.2 + */ +export { SceneResource, Animation, EnvironmentBackgroundType, Environment } from './graphics3d/SceneResources'; /** * Export scene nodes @@ -51,6 +71,13 @@ export { SceneResourceType, SceneResource, Shader, MaterialType, Material, Shade */ export { LayerMask, NodeType, Container, Node, Geometry, LightType, Light, SpotLight, DirectionalLight, Camera } from './graphics3d/SceneNodes'; +/** + * Export scene nodes + * @syscap SystemCapability.ArkUi.Graphics3D + * @since 20 + * @arkts 1.2 + */ +export { NodeType, Node, LightType, Light, DirectionalLight, Camera } from './graphics3d/SceneNodes'; /** * Export scene @@ -59,3 +86,11 @@ export { LayerMask, NodeType, Container, Node, Geometry, LightType, Light, SpotL */ export { SceneResourceParameters, SceneNodeParameters, SceneResourceFactory, Scene, RaycastResult, RaycastParameters, RenderParameters, RenderResourceFactory, SceneComponent, RenderContext } from './graphics3d/Scene'; +/** + * Export scene + * @syscap SystemCapability.ArkUi.Graphics3D + * @since 20 + * @arkts 1.2 + */ +export { SceneResourceParameters, SceneNodeParameters, SceneResourceFactory, Scene, RenderParameters, + RenderResourceFactory } from './graphics3d/Scene'; diff --git a/api/@ohos.graphics.text.d.ts b/api/@ohos.graphics.text.d.ts index 8c75136d72295a3bc6840d6c8c9e131f645c86bc..818403dbe494f7d5236c94027462674547357241 100755 --- a/api/@ohos.graphics.text.d.ts +++ b/api/@ohos.graphics.text.d.ts @@ -24,7 +24,7 @@ import { Resource } from './global/resource'; /*** endif */ /** - * The Text module provides a set of APIs for text layout and font management. + * The Text module provides a set of APIs for text layout and font management. * It aims to deliver high-quality typesetting through features like character-to-glyph * conversion, kerning, line breaking, alignment, and text measurement. Additionally, * it provides font management capabilities, including font registration, font descriptors, @@ -1377,15 +1377,13 @@ declare namespace text { * Enumerates the vertical alignment modes of a placeholder relative to the surrounding text. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enum PlaceholderAlignment { /** * Aligns the baseline of the placeholder to the baseline of the text. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ OFFSET_AT_BASELINE, @@ -1393,8 +1391,7 @@ declare namespace text { * Aligns the bottom edge of the placeholder to the baseline of the text. * sits on top of the baseline. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ ABOVE_BASELINE, @@ -1402,8 +1399,7 @@ declare namespace text { * Aligns the top edge of the placeholder to the baseline of the text. * hangs below the baseline. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BELOW_BASELINE, @@ -1411,8 +1407,7 @@ declare namespace text { * Align the top edge of the placeholder with the top edge of the font. When the placeholder is very tall, * the extra space will hang from the top and extend through the bottom of the line. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ TOP_OF_ROW_BOX, @@ -1420,8 +1415,7 @@ declare namespace text { * Align the bottom edge of the placeholder with the bottom edge of the text. When the placeholder is very tall, * the extra space will rise from the bottom and extend through the top of the line. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BOTTOM_OF_ROW_BOX, @@ -1429,8 +1423,7 @@ declare namespace text { * Align the middle of the placeholder with the middle of the text. When the placeholder is very tall, * the extra space will grow equally from the top and bottom of the line. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ CENTER_OF_ROW_BOX, @@ -1446,16 +1439,14 @@ declare namespace text { * Describes the placeholder style. * @typedef PlaceholderSpan * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface PlaceholderSpan { /** * Width of the placeholder, in units of px. The value is a floating point number. * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ width: double; @@ -1463,8 +1454,7 @@ declare namespace text { * Height of the placeholder, in units of px. The value is a floating point number. * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ height: double; @@ -1472,8 +1462,7 @@ declare namespace text { * Vertical alignment of the placeholder relative to the surrounding text. * @type { PlaceholderAlignment } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ align: PlaceholderAlignment; @@ -1481,8 +1470,7 @@ declare namespace text { * Type of the text baseline. * @type { TextBaseline } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ baseline: TextBaseline; @@ -1490,8 +1478,7 @@ declare namespace text { * Offset to the text baseline, in units of px. The value is a floating point number. * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ baselineOffset: double; } @@ -1500,16 +1487,14 @@ declare namespace text { * Describes a left-closed and right-open interval. * @typedef Range * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface Range { /** * Index of the leftmost point of the interval. The value is an integer. * @type { int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ start: int; @@ -1517,8 +1502,7 @@ declare namespace text { * Index of the rightmost point of the interval. The value is an integer. * @type { int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ end: int; } @@ -1527,47 +1511,41 @@ declare namespace text { * Enumerates the font types, which can be combined through bitwise OR operations. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ enum SystemFontType { /** * All font types, including the system font type, style font type, and user-installed font type. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ ALL = 1 << 0, /** * System generic font type. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ GENERIC = 1 << 1, /** * Style font type. The style font type is designed for 2-in-1 devices. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ STYLISH = 1 << 2, /** * Font type that has been installed. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ INSTALLED = 1 << 3, /** * Customized font types. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ CUSTOMIZED = 1 << 4, } @@ -1576,8 +1554,7 @@ declare namespace text { * Describes the font descriptor information. * @typedef FontDescriptor * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ interface FontDescriptor { /** @@ -1585,8 +1562,7 @@ declare namespace text { * The default value is an empty string. * @type { ?string } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ path?: string; @@ -1594,8 +1570,7 @@ declare namespace text { * Unique name of the font. Any string is acceptable. The default value is an empty string. * @type { ?string } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ postScriptName?: string; @@ -1603,8 +1578,7 @@ declare namespace text { * Font name. Any string is acceptable. The default value is an empty string. * @type { ?string } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ fullName?: string; @@ -1612,8 +1586,7 @@ declare namespace text { * Family name of the font. Any string is acceptable. The default value is an empty string. * @type { ?string } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ fontFamily?: string; @@ -1621,8 +1594,7 @@ declare namespace text { * Subfamily name of the font. Any string is acceptable. The default value is an empty string. * @type { ?string } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ fontSubfamily?: string; @@ -1630,8 +1602,7 @@ declare namespace text { * Font weight. The default value is 0. * @type { ?FontWeight } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ weight?: FontWeight; @@ -1639,8 +1610,7 @@ declare namespace text { * Font width. The value is an integer ranging from 1 to 9. The default value is 0. * @type { ?int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ width?: int; @@ -1649,8 +1619,7 @@ declare namespace text { * The default value is 0. * @type { ?int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ italic?: int; @@ -1659,8 +1628,7 @@ declare namespace text { * The default value is false. * @type { ?boolean } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ monoSpace?: boolean; @@ -1668,8 +1636,7 @@ declare namespace text { * Whether the font is symbolic. The value true means that the font is symbolic, and false means the opposite. * @type { ?boolean } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ symbolic?: boolean; } @@ -1699,8 +1666,7 @@ declare namespace text { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ layout(width: double): Promise; @@ -1734,8 +1700,7 @@ declare namespace text { * Obtains the maximum width of the line in the text. * @returns { double } Maximum line width, in units of px. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getMaxWidth(): double; @@ -1743,8 +1708,7 @@ declare namespace text { * Obtains the total height of the text. * @returns { double } Total height, in units of px. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getHeight(): double; @@ -1763,8 +1727,7 @@ declare namespace text { * @returns { double } Width of the longest line, including its indentation. * The value is a floating point number, in px. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ getLongestLineWithIndent(): double; @@ -1772,8 +1735,7 @@ declare namespace text { * Obtains the minimum intrinsic width of the paragraph. * @returns { double } Minimum intrinsic width, in units of px. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getMinIntrinsicWidth(): double; @@ -1781,8 +1743,7 @@ declare namespace text { * Obtains the maximum intrinsic width of the paragraph. * @returns { double } Maximum intrinsic width, in units of px. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getMaxIntrinsicWidth(): double; @@ -1790,8 +1751,7 @@ declare namespace text { * Obtains the alphabetic baseline. * @returns { double } Alphabetic baseline, in units of px. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getAlphabeticBaseline(): double; @@ -1799,8 +1759,7 @@ declare namespace text { * Obtains the ideographic baseline. * @returns { double } Ideographic baseline, in units of px. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getIdeographicBaseline(): double; @@ -1812,8 +1771,7 @@ declare namespace text { * @param { RectHeightStyle } heightStyle - Height of the rectangle. * @returns { Array } Array holding the rectangles obtained. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getRectsForRange(range: Range, widthStyle: RectWidthStyle, heightStyle: RectHeightStyle): Array; @@ -1821,8 +1779,7 @@ declare namespace text { * Obtains the rectangles occupied by all placeholders in the text. * @returns { Array } Array holding the rectangles obtained. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getRectsForPlaceholders(): Array; @@ -1832,27 +1789,24 @@ declare namespace text { * @param { double } y - Y coordinate. The value is a floating point number. * @returns { PositionWithAffinity } Position of the glyph. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getGlyphPositionAtCoordinate(x: double, y: double): PositionWithAffinity; /** * Obtains the range of the word where the glyph with a given offset is located. - * @param { double } offset - Offset of the glyph. The value is an integer. + * @param { int } offset - Offset of the glyph. The value is an integer. * @returns { Range } Range of the word. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - getWordBoundary(offset: double): Range; + getWordBoundary(offset: int): Range; /** * Obtains the number of text lines. * @returns { int } Number of text lines. The value is an integer. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getLineCount(): int; @@ -1861,8 +1815,7 @@ declare namespace text { * @param { int } line - Index of the line. The value is an integer ranging from 0 to getLineCount() – 1. * @returns { double } The line height value returned to the caller. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getLineHeight(line: int): double; @@ -1871,8 +1824,7 @@ declare namespace text { * @param { int } line - Index of the line. The value is an integer ranging from 0 to getLineCount() – 1. * @returns { double } The line width value returned to the caller. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getLineWidth(line: int): double; @@ -1881,8 +1833,7 @@ declare namespace text { * @returns { boolean } Check result. The value true means that the number of lines exceeds the maximum, * and false means the opposite. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ didExceedMaxLines(): boolean; @@ -1890,8 +1841,7 @@ declare namespace text { * Obtains all the text lines. * @returns { Array } Array of text lines. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getTextLines(): Array; @@ -1904,8 +1854,7 @@ declare namespace text { * and false means the opposite. * @returns { Range } Text range obtained. If the line index is invalid, start and end are both 0. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getActualTextRange(lineNumber: int, includeSpaces: boolean): Range; @@ -1952,8 +1901,7 @@ declare namespace text { * individual lines of text. Before calling any of the following APIs, you must use buildLineTypeset() * in the ParagraphBuilder class to create a LineTypeset object. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ class LineTypeset { /** @@ -1965,8 +1913,7 @@ declare namespace text { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getLineBreak(startIndex: int, width: double): int; @@ -1982,8 +1929,7 @@ declare namespace text { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ createLine(startIndex: int, count: int): TextLine; } @@ -1992,16 +1938,14 @@ declare namespace text { * Describes the rectangle that holds the text. * @typedef TextBox * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - interface TextBox{ + interface TextBox { /** * Information about the rectangle. * @type { common2D.Rect } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ rect: common2D.Rect; @@ -2009,8 +1953,7 @@ declare namespace text { * Text direction. * @type { TextDirection } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ direction: TextDirection; } @@ -2019,16 +1962,14 @@ declare namespace text { * Describes the position and affinity of a glyph. * @typedef PositionWithAffinity * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface PositionWithAffinity { /** * Index of the glyph relative to the paragraph. The value is an integer. * @type { int } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ position: int; @@ -2036,8 +1977,7 @@ declare namespace text { * Affinity of the position. * @type { Affinity } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ affinity: Affinity; } @@ -2046,24 +1986,21 @@ declare namespace text { * Enumerates the rectangle width styles. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enum RectWidthStyle { /** * If letterSpacing is not set, the rectangle conforms tightly to the text it contains. * However, if letterSpacing is set, a gap is introduced between the rectangle and text. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ TIGHT, /** * The rectangle's width is extended to align with the widest rectangle across all lines. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ MAX, } @@ -2072,55 +2009,48 @@ declare namespace text { * Enumerates the rectangle height styles. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enum RectHeightStyle { /** * Tight style. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ TIGHT, /** * Extends the height to match the highest rectangle in all lines. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ MAX, /** * The top and bottom of each rect will cover half of the space above and half of the space below the line. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ INCLUDE_LINE_SPACE_MIDDLE, /** * The line spacing will be added to the top of the rect. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ INCLUDE_LINE_SPACE_TOP, /** * The line spacing will be added to the bottom of the rect. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ INCLUDE_LINE_SPACE_BOTTOM, /** * The height of the boxes will be calculated by text strut. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ STRUT, } @@ -2131,23 +2061,20 @@ declare namespace text { * closer to. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ enum Affinity { /** * The position has affinity for the upstream side of the text position. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ UPSTREAM, /** * The position has affinity for the downstream side of the text position. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ DOWNSTREAM, } @@ -2205,8 +2132,7 @@ declare namespace text { * @param { PlaceholderSpan } placeholderSpan - Placeholder span, which describes the size, alignment, * baseline type, and baseline offset of the placeholder. {@link PlaceholderSpan} * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ addPlaceholder(placeholderSpan: PlaceholderSpan): void; @@ -2223,8 +2149,7 @@ declare namespace text { * Builds a line typesetter. * @returns { LineTypeset } LineTypeset object that can be used for subsequent rendering. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ buildLineTypeset(): LineTypeset; @@ -2234,8 +2159,7 @@ declare namespace text { * range 0xF0000-0xF0C97. For details about the configurable symbol codes (unicode values in the list view), * see HarmonyOS Symbol. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ addSymbol(symbolId: int): void; } @@ -2247,16 +2171,14 @@ declare namespace text { * the strings "j" and "E" have identical typographic boundaries, which are independent of the characters themselves. * @typedef TypographicBounds * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ interface TypographicBounds { /** * Ascent of a text line. The value is a floating point number. * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ ascent: double; @@ -2264,8 +2186,7 @@ declare namespace text { * Descent of a text line. The value is a floating point number. * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ descent: double; @@ -2273,8 +2194,7 @@ declare namespace text { * Leading of a text line. The value is a floating point number. * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ leading: double; @@ -2282,8 +2202,7 @@ declare namespace text { * Width of the typographic boundaries. The value is a floating point number. * @type { double } * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ width: double; } @@ -2303,8 +2222,7 @@ declare namespace text { * @returns { boolean } Whether to stop calling the callback. The value true means to stop calling the callback, * and false means to continue calling the callback. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ type CaretOffsetsCallback = (offset: int, index: int, leadingEdge: boolean) => boolean; @@ -2313,16 +2231,14 @@ declare namespace text { * Before calling any of the following APIs, you must use getTextLines() of the Paragraph class or createLine() of * the LineTypeset class to create a TextLine object. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ class TextLine { /** * Obtains the number of glyphs in this text line. * @returns { int } Number of glyphs. The value is an integer. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getGlyphCount(): int; @@ -2330,8 +2246,7 @@ declare namespace text { * Obtains the range of the text in this text line in the entire paragraph. * @returns { Range } Range of the text in this text line in the entire paragraph. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getTextRange(): Range; @@ -2339,8 +2254,7 @@ declare namespace text { * Obtains the array of glyph runs in the text line. * @returns { Array } Array of the runs obtained. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getGlyphRuns(): Array; @@ -2350,8 +2264,7 @@ declare namespace text { * @param { double } x - X coordinate of the upper left corner. The value is a floating point number. * @param { double } y - Y coordinate of the upper left corner. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ paint(canvas: drawing.Canvas, x: double, y: double): void; @@ -2362,8 +2275,7 @@ declare namespace text { * @param { string } ellipsis - String used to mark a truncation. * @returns { TextLine } Truncated text line object. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ createTruncatedLine(width: double, ellipsisMode: EllipsisMode, ellipsis: string): TextLine; @@ -2375,8 +2287,7 @@ declare namespace text { * the characters themselves. * @returns { TypographicBounds } Typographic boundaries of the text line. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getTypographicBounds(): TypographicBounds; @@ -2389,8 +2300,7 @@ declare namespace text { * the boundary for "j" is taller than that for "E". * @returns { common2D.Rect } Image boundary of the text line. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getImageBounds(): common2D.Rect; @@ -2398,8 +2308,7 @@ declare namespace text { * Obtains the width of the spaces at the end of this text line. * @returns { double } Number of spaces at the end of the text line. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getTrailingSpaceWidth(): double; @@ -2408,8 +2317,7 @@ declare namespace text { * @param { common2D.Point } point - Position of the character. * @returns { int } Index of the character in the text line. The value is an integer. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getStringIndexForPosition(point: common2D.Point): int; @@ -2418,8 +2326,7 @@ declare namespace text { * @param { int } index - Index of the character. The value is an integer. * @returns { double } Offset of the character with the specified index. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getOffsetForStringIndex(index: int): double; @@ -2428,8 +2335,7 @@ declare namespace text { * @param { CaretOffsetsCallback } callback - Custom function, which contains the offset and index of each * character in the text line. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ enumerateCaretOffsets(callback: CaretOffsetsCallback): void; @@ -2444,8 +2350,7 @@ declare namespace text { * point number. If the width is less than the actual width of the text line, 0 is returned. * @returns { double } Offset required for alignment. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getAlignmentOffset(alignmentFactor: double, alignmentWidth: double): double; } @@ -2454,16 +2359,14 @@ declare namespace text { * Implements a unit for text layout. * Before calling any of the following APIs, you must use getGlyphRuns() of the TextLine class to create a Run object. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ class Run { /** * Obtains the number of glyphs in this run. * @returns { int } Number of glyphs. The value is an integer. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getGlyphCount(): int; @@ -2471,8 +2374,7 @@ declare namespace text { * Obtains the index of each glyph in this run. * @returns { Array } Array holding the index of each glyph in the run. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getGlyphs(): Array; @@ -2484,8 +2386,7 @@ declare namespace text { * returned. * @returns { Array } Array holding the index of each glyph in the run. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getGlyphs(range: Range): Array; @@ -2494,8 +2395,7 @@ declare namespace text { * @returns { Array } Array holding the position of each glyph relative to the respective line in * the run. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getPositions(): Array; @@ -2507,8 +2407,7 @@ declare namespace text { * @returns { Array } Array holding the position of each glyph relative to the respective line in * the run. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getPositions(range: Range): Array; @@ -2516,8 +2415,7 @@ declare namespace text { * Obtains the offset of each glyph in this run relative to its index. * @returns { Array } Array holding the offset of each glyph in the run relative to its index. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getOffsets(): Array; @@ -2525,8 +2423,7 @@ declare namespace text { * Obtains the Font object of this run. * @returns { drawing.Font } Font object of this run. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ getFont(): drawing.Font; @@ -2536,8 +2433,7 @@ declare namespace text { * @param { double } x - X coordinate of the upper left corner. The value is a floating point number. * @param { double } y - Y coordinate of the upper left corner. The value is a floating point number. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ paint(canvas: drawing.Canvas, x: double, y: double): void; @@ -2550,8 +2446,7 @@ declare namespace text { * If this parameter is not passed, the entire run is obtained. * @returns { Array } Array of character indices. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getStringIndices(range?: Range): Array; @@ -2560,8 +2455,7 @@ declare namespace text { * @returns { Range } Range of the glyphs, where start indicates the start position of the range, which is the * index relative to the entire paragraph, and end indicates the length of the range. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getStringRange(): Range; @@ -2571,8 +2465,7 @@ declare namespace text { * a space after "b"), the typographic boundaries include the spaces at the beginning and end of the line. * @returns { TypographicBounds } Typographic boundaries of the run. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getTypographicBounds(): TypographicBounds; @@ -2583,8 +2476,7 @@ declare namespace text { * spaces at the beginning and end. * @returns { common2D.Rect } Image boundary of the run. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ getImageBounds(): common2D.Rect; @@ -2752,8 +2644,7 @@ declare namespace text { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ function getSystemFontFullNamesByType(fontType: SystemFontType): Promise>; @@ -2768,8 +2659,7 @@ declare namespace text { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'14','1.2':'20'} - * @arkts 1.1&1.2 + * @since 14 */ function getFontDescriptorByFullName(fullName: string, fontType: SystemFontType): Promise; @@ -2784,8 +2674,7 @@ declare namespace text { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since arkts{ '1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ function matchFontDescriptors(desc: FontDescriptor): Promise>; diff --git a/api/@ohos.graphics.uiEffect.d.ts b/api/@ohos.graphics.uiEffect.d.ts index daa434171b69c0fbad11f02ced417bd61ff63faa..e1761d612b5f30e340b4511986c28287606880fa 100644 --- a/api/@ohos.graphics.uiEffect.d.ts +++ b/api/@ohos.graphics.uiEffect.d.ts @@ -39,7 +39,7 @@ declare namespace uiEffect { /** * Set the edge pixel stretch effect of the Component. * - * @param { Array } stretchSizes + * @param { Array } stretchSizes * @param { TileMode } tileMode * @returns { Filter } * @syscap SystemCapability.Graphics.Drawing @@ -47,26 +47,26 @@ declare namespace uiEffect { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - pixelStretch(stretchSizes: Array, tileMode: TileMode): Filter; + pixelStretch(stretchSizes: Array, tileMode: TileMode): Filter; /** * Set blur effect of the Component. * - * @param { number } blurRadius + * @param { double } blurRadius * @returns { Filter } * @syscap SystemCapability.Graphics.Drawing * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - blur(blurRadius: number): Filter; + blur(blurRadius: double): Filter; /** * Set waterRipple effect of the Component. * - * @param { number } progress - Indicates the ripple progress. The value 1 indicates that ripples are displayed on all screens. - * @param { number } waveCount - The number of waves when the water ripples. The maximum count of waves is 3, the minimum value is 1, default is 2. - * @param { number } x - Represents the X-axis position of center point where the water ripple first appears on the screen. - * @param { number } y - Represents the Y-axis position of center point where the water ripple first appears on the screen. + * @param { double } progress - Indicates the ripple progress. The value 1 indicates that ripples are displayed on all screens. + * @param { int } waveCount - The number of waves when the water ripples. The maximum count of waves is 3, the minimum value is 1, default is 2. + * @param { double } x - Represents the X-axis position of center point where the water ripple first appears on the screen. + * @param { double } y - Represents the Y-axis position of center point where the water ripple first appears on the screen. * @param { WaterRippleMode } rippleMode - Set the mode of water ripple, * 0 for mobile to desktop(Receive), 1 for mobile to desktop(Send), 2 for mobile to mobile, 3 for cross platform. * @returns { Filter } - Returns water ripple Filter. @@ -76,12 +76,12 @@ declare namespace uiEffect { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - waterRipple(progress: number, waveCount: number, x: number, y: number, rippleMode: WaterRippleMode): Filter; + waterRipple(progress: double, waveCount: int, x: double, y: double, rippleMode: WaterRippleMode): Filter; /** * Set the fly in or fly out effect of the component. * - * @param { number } degree - set the degree of fly in or fly out effect, value range [0, 1]. + * @param { double } degree - set the degree of fly in or fly out effect, value range [0, 1]. * @param { FlyMode } flyMode - set the location of stretching when fly in or out * If the value is 0, the component keep same, else the value is 1, component are fully fly out or fly in. * @returns { Filter } - Returns fly in fly out Filter. @@ -91,12 +91,12 @@ declare namespace uiEffect { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - flyInFlyOutEffect(degree: number, flyMode: FlyMode): Filter; + flyInFlyOutEffect(degree: double, flyMode: FlyMode): Filter; /** * Set distort effect of the component. * - * @param { number } distortionK - set the degree of distort effect, value range [-1, 1]. + * @param { double } distortionK - set the degree of distort effect, value range [-1, 1]. * If the value is 0, the component keep same, * if the value is less than 0, the component is barrel distortion, * if the value is more than 0, the component is pincushion distortion. @@ -107,13 +107,172 @@ declare namespace uiEffect { * @since arkts {'1.1':'13', '1.2':'20'} * @arkts 1.1&1.2 */ - distort(distortionK: number): Filter; + distort(distortionK: double): Filter; + + /** + * Adds the content radius gradient blurring effect for the current component. The input parameter is the blurring radius. + * + * @param { double } radius - the blurring radius. + * The larger the blurring radius, the more blurring the content, and if the value is 0, the content blurring effect is not blurring. + * @param { LinearGradientBlurOptions } gradientParam - the radius gradient blur options. + * @returns { Filter } - Returns radius gradient blur Filter. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 19 + */ + radiusGradientBlur(radius: double, gradientParam: LinearGradientBlurOptions): Filter; + + /** + * Sets the deformation effect controlled by bezier curves of the component. + * + * @param { Array } controlPoints - The bezier control points, 12 points needed. + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + bezierWarp(controlPoints: Array): Filter; + + /** + * Sets the content light filter. + * + * @param { common2D.Point3d } lightPosition + * @param { common2D.Color } lightColor + * @param { double } lightIntensity + * @param { Mask } [displacementMap] + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + contentLight(lightPosition: common2D.Point3d, lightColor: common2D.Color, lightIntensity: double, + displacementMap?: Mask): Filter; + + /** + * Sets the color gradient filter, may blend with alpha mask. + * + * @param { Array } colors + * @param { Array } positions + * @param { Array } strengths + * @param { Mask } [alphaMask] + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + colorGradient(colors: Array, positions: Array, strengths: Array, + alphaMask?: Mask): Filter; + + /** + * Detects and glows edges of contents. + * + * @param { double } alpha + * @param { Color } [color] + * @param { Mask } [mask] + * @param { boolean } [bloom] + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + edgeLight(alpha: double, color?: Color, mask?: Mask, bloom?: boolean): Filter; + + /** + * Sets distort effect with displacement map. + * + * @param { Mask } displacementMap + * @param { [double, double] } [factor] + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + displacementDistort(displacementMap: Mask, factor?: [double, double]): Filter; + + /** + * Sets dispersion effect with mask map. + * + * @param { Mask } dispersionMap + * @param { double } alpha + * @param { [double, double] } [rFactor] + * @param { [double, double] } [gFactor] + * @param { [double, double] } [bFactor] + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + maskDispersion(dispersionMap: Mask, alpha: double, rFactor?: [double, double], gFactor?: [double, double], + bFactor?: [double, double]): Filter; + + /** + * Applies a high dynamic range (HDR) brightness enhancement filter to the component. + * @param { double } ratio - The brightness multiplier ratio (1.0 = original, >1.0 = brighter). + * @returns { Filter } - Returns hdr brightness Filter. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + hdrBrightnessRatio(ratio: double): Filter; + + /** + * Sets variable radius blur effect with radius map. + * + * @param { double } radius - the blurring radius. + * The larger the blurring radius, the more blurring the content, + * and if the value is 0, the content blurring effect is not blurring. + * @param { Mask } radiusMap - the alpha of the mask determines the degree of blurring. + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + variableRadiusBlur(radius: double, radiusMap: Mask): Filter; + + /** + * Generates lighting effects from mask and directional light. + * + * @param { common2D.Point3d } direction - Direction of light + * @param { Color } color - Color of light + * @param { double } intensity - Intensity of light + * @param { Mask } [mask] - Mask, as a displacement map that affects lighting effects + * @param { double } [factor] - Mask scale factor, used to scale the mask channel values + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + directionLight(direction: common2D.Point3d, color: Color, intensity: double, mask?: Mask, factor?: double): Filter; + + /** + * Applies Transition with alpha mask + * + * @param { Mask } alphaMask - Animatable mask object + * @param { double } [factor] - The coefficient of the mask, defaulting to 1.0f [0~1] + * @param { boolean } [inverse] - Transition mode, default is fasle (true, false) + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + maskTransition(alphaMask: Mask, factor?: double, inverse?: boolean): Filter; } /** * TileMode enumeration description * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} @@ -164,7 +323,7 @@ declare namespace uiEffect { /** * WaterRippleMode enumeration description * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} @@ -215,7 +374,7 @@ declare namespace uiEffect { /** * FlyMode enumeration description * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} @@ -261,6 +420,22 @@ declare namespace uiEffect { * @arkts 1.1&1.2 */ backgroundColorBlender(blender: BrightnessBlender): VisualEffect; + + /** + * Sets the border light effect. + * + * @param { common2D.Point3d } lightPosition + * @param { common2D.Color } lightColor + * @param { double } lightIntensity + * @param { double } borderWidth + * @returns { VisualEffect } - Returns the VisualEffect that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + borderLight(lightPosition: common2D.Point3d, lightColor: common2D.Color, lightIntensity: double, + borderWidth: double): VisualEffect; } /** @@ -285,90 +460,205 @@ declare namespace uiEffect { /** * Defines third-order rate for grayscale adjustment. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - cubicRate: number; + cubicRate: double; /** * Defines second-order rate for grayscale adjustment. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - quadraticRate: number; + quadraticRate: double; /** * Defines linear rate for grayscale adjustment. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - linearRate: number; + linearRate: double; /** * Defines grayscale adjustment degree. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - degree: number; + degree: double; /** * Defines the reference saturation for brightness. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - saturation: number; + saturation: double; /** * Defines the positive adjustment coefficients in RGB channels based on the reference saturation. * - * @type { [number, number, number] } + * @type { [double, double, double] } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - positiveCoefficient: [number, number, number]; + positiveCoefficient: [double, double, double]; /** * Defines the negative adjustment coefficients in RGB channels based on the reference saturation. * - * @type { [number, number, number] } + * @type { [double, double, double] } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - negativeCoefficient: [number, number, number]; + negativeCoefficient: [double, double, double]; /** * Defines the blending fraction for brightness effect. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - fraction: number; + fraction: double; + } + + /** + * The Color of Light. + * @typedef Color + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + interface Color { + /** + * Red component of color. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + red: double; + /** + * Green component of color. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + green: double; + /** + * Blue component of color + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + blue: double; + /** + * Alpha component of color. + * @type { double } + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + alpha: double; + } + + /** + * Defines the mask for Filter or VisualEffect. + * @typedef { Mask } + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + class Mask { + /** + * Create a Mask of ripple. + * @param { common2D.Point } center + * @param { double } radius + * @param { double } width + * @param { double } [offset] + * @returns { Mask } + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + static createRippleMask(center: common2D.Point, radius: double, width: double, offset?: double): Mask; + + /** + * Create a Mask of pixelmap. + * @param { image.PixelMap } pixelMap + * @param { common2D.Rect } srcRect + * @param { common2D.Rect } dstRect + * @param { Color } [fillColor] + * @returns { Mask } + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + static createPixelMapMask(pixelMap: image.PixelMap, srcRect: common2D.Rect, dstRect: common2D.Rect, + fillColor?: Color): Mask; + + /** + * Create a Mask of radial gradient. + * @param { common2D.Point } center + * @param { double } radiusX + * @param { double } radiusY + * @param { Array<[double, double]> } gradients + * @returns { Mask } + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + static createRadialGradientMask(center: common2D.Point, radiusX: double, radiusY: double, + gradients: Array<[double, double]>): Mask; + + /** + * Create a Mask of single wave gradient. + * @param { common2D.Point } center - The wave source center of the single-wave mask. + * @param { double } width - The circular ring width of the single-wave mask. + * @param { double } propagationRadius - The outer diffusion radius of the single-wave mask. + * @param { double } blurRadius - The blur radius of the single-wave mask. + * @param { double } [turbulenceStrength] - The turbulent displacement intensity of the single-wave mask. + * @returns { Mask } - Returns wave gradient mask. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @static + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + static createWaveGradientMask(center: common2D.Point, width: double, propagationRadius: double, + blurRadius: double, turbulenceStrength?: double): Mask; } /** @@ -413,90 +703,90 @@ declare interface BrightnessBlenderParam { /** * Defines third-order rate for grayscale adjustment. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - cubicRate: number; + cubicRate: double; /** * Defines second-order rate for grayscale adjustment. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - quadraticRate: number; + quadraticRate: double; /** * Defines linear rate for grayscale adjustment. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - linearRate: number; + linearRate: double; /** * Defines grayscale adjustment degree. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - degree: number; + degree: double; /** * Defines the reference saturation for brightness. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - saturation: number; + saturation: double; /** * Defines the positive adjustment coefficients in RGB channels based on the reference saturation. * - * @type { [number, number, number] } + * @type { [double, double, double] } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - positiveCoefficient: [number, number, number]; + positiveCoefficient: [double, double, double]; /** * Defines the negative adjustment coefficients in RGB channels based on the reference saturation. * - * @type { [number, number, number] } + * @type { [double, double, double] } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - negativeCoefficient: [number, number, number]; + negativeCoefficient: [double, double, double]; /** * Defines the blending fraction for brightness effect. * - * @type { number } + * @type { double } * @syscap SystemCapability.Graphics.Drawing * @systemapi * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - fraction: number; + fraction: double; } export default uiEffect; \ No newline at end of file diff --git a/api/@ohos.hiSysEvent.d.ts b/api/@ohos.hiSysEvent.d.ts index af3e8719de0df4ef9242c15735489b976e6ca831..f99484595d2053d85b33f72008c986958a3baaeb 100644 --- a/api/@ohos.hiSysEvent.d.ts +++ b/api/@ohos.hiSysEvent.d.ts @@ -140,10 +140,20 @@ declare namespace hiSysEvent { * @type { ?object } * @syscap SystemCapability.HiviewDFX.HiSysEvent * @systemapi hide for inner use - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ params?: object; + + /** + * The params of the event. + * + * @type { ?(Record | null | undefined) } + * @syscap SystemCapability.HiviewDFX.HiSysEvent + * @systemapi hide for inner use + * @since 20 + * @arkts 1.2 + */ + params?: Record | null | undefined; } /** @@ -281,11 +291,21 @@ declare namespace hiSysEvent { * @type { ?string } * @syscap SystemCapability.HiviewDFX.HiSysEvent * @systemapi hide for inner use - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ tag?: string; + /** + * The tag of the event. + * + * @type { ?(string | null | undefined) } + * @syscap SystemCapability.HiviewDFX.HiSysEvent + * @systemapi hide for inner use + * @since 20 + * @arkts 1.2 + */ + tag?: string | null | undefined; + /** * The rule of match system event * @@ -391,21 +411,41 @@ declare namespace hiSysEvent { * @type { ?long } * @syscap SystemCapability.HiviewDFX.HiSysEvent * @systemapi hide for inner use - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ fromSeq?: long; + /** + * Begin sequence + * + * @type { ?(long | null | undefined) } + * @syscap SystemCapability.HiviewDFX.HiSysEvent + * @systemapi hide for inner use + * @since 20 + * @arkts 1.2 + */ + fromSeq?: long | null | undefined; + /** * End sequence * * @type { ?long } * @syscap SystemCapability.HiviewDFX.HiSysEvent * @systemapi hide for inner use - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 + */ + toSeq?: long; + + /** + * End sequence + * + * @type { ?(long | null | undefined) } + * @syscap SystemCapability.HiviewDFX.HiSysEvent + * @systemapi hide for inner use + * @since 20 + * @arkts 1.2 */ - toSeq?: long + toSeq?: long | null | undefined; } /** @@ -446,10 +486,20 @@ declare namespace hiSysEvent { * @type { ?string } * @syscap SystemCapability.HiviewDFX.HiSysEvent * @systemapi hide for inner use - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ condition?: string; + + /** + * Extra parameter condition of event + * + * @type { ?(string | null | undefined) } + * @syscap SystemCapability.HiviewDFX.HiSysEvent + * @systemapi hide for inner use + * @since 20 + * @arkts 1.2 + */ + condition?: string | null | undefined; } /** diff --git a/api/@ohos.hichecker.d.ts b/api/@ohos.hichecker.d.ts index 22e2a89fd3617deec46cd5c7f1c1e251c410a497..ca1a68ee5e5019fefe3b8acee6ea0bd7d824a850 100644 --- a/api/@ohos.hichecker.d.ts +++ b/api/@ohos.hichecker.d.ts @@ -23,7 +23,8 @@ * * @namespace hichecker * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace hichecker { /** @@ -31,45 +32,50 @@ declare namespace hichecker { * * @constant * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ - const RULE_CAUTION_PRINT_LOG: 9223372036854775808n; // 1 << 63 + const RULE_CAUTION_PRINT_LOG = 9223372036854775808n; // 1 << 63 /** * The caution rule trigger crash. * * @constant * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ - const RULE_CAUTION_TRIGGER_CRASH: 4611686018427387904n; // 1 << 62 + const RULE_CAUTION_TRIGGER_CRASH = 4611686018427387904n; // 1 << 62 /** * The thread rule check slow process. * * @constant * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ - const RULE_THREAD_CHECK_SLOW_PROCESS: 1n; + const RULE_THREAD_CHECK_SLOW_PROCESS = 1n; /** * The process rule check ability connection leak. * * @constant * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ - const RULE_CHECK_ABILITY_CONNECTION_LEAK: 8589934592n; // 1 << 33 + const RULE_CHECK_ABILITY_CONNECTION_LEAK = 8589934592n; // 1 << 33 /** * The process rule check ability Arkui performance * * @constant * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ - const RULE_CHECK_ARKUI_PERFORMANCE: 17179869184n; // 1 << 34 + const RULE_CHECK_ARKUI_PERFORMANCE = 17179869184n; // 1 << 34 /** * add one or more rule. @@ -98,7 +104,8 @@ declare namespace hichecker { * * @returns { bigint } all added thread rule and process rule. * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function getRule(): bigint; @@ -120,7 +127,8 @@ declare namespace hichecker { * @param { bigint } rule * @throws { BusinessError } 401 - the parameter check failed, only one bigint type parameter is needed * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function addCheckRule(rule: bigint): void; @@ -130,7 +138,8 @@ declare namespace hichecker { * @param { bigint } rule * @throws { BusinessError } 401 - the parameter check failed, only one bigint type parameter is needed * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function removeCheckRule(rule: bigint): void; @@ -141,7 +150,8 @@ declare namespace hichecker { * @returns { boolean } the result of whether the query rule is added. * @throws { BusinessError } 401 - the parameter check failed, only one bigint type parameter is needed * @syscap SystemCapability.HiviewDFX.HiChecker - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function containsCheckRule(rule: bigint): boolean; } diff --git a/api/@ohos.hilog.d.ts b/api/@ohos.hilog.d.ts index 998320202635cd938c7c1ada1878b9f4169ef097..554c540e4e4e4e0bd30e85a7546c0dd72b860ffa 100644 --- a/api/@ohos.hilog.d.ts +++ b/api/@ohos.hilog.d.ts @@ -16,9 +16,12 @@ /** * @file * @kit PerformanceAnalysisKit - * @arkts 1.1&1.2 */ +/*** if arkts 1.2 */ +import { RecordData } from '@ohos.base'; +/*** endif */ + /** * Provides interfaces to generate system logs. * @@ -60,8 +63,8 @@ declare namespace hilog { /** * Outputs debug-level logs. * - * * @param { number } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF - * if the value exceeds the range, logs cannot be printed. + * @param { number } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF + * if the value exceeds the range, logs cannot be printed. * @param { string } tag Identifies the log tag, length cannot exceed 32 bytes, the excess part will be truncated. * @param { string } format Indicates the log format string. * @param { any[] }args Indicates the log parameters. @@ -82,21 +85,23 @@ declare namespace hilog { * @atomicservice * @since 11 */ + function debug(domain: number, tag: string, format: string, ...args: any[]): void; + /** * Outputs debug-level logs. * - * @param { number } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF + * @param { int } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF * if the value exceeds the range, logs cannot be printed. * @param { string } tag Identifies the log tag, length cannot exceed 32 bytes, the excess part will be truncated. * @param { string } format Indicates the log format string. - * @param { (Object | undefined | null)[] }args Indicates the log parameters. + * @param { RecordData[] }args Indicates the log parameters. * @syscap SystemCapability.HiviewDFX.HiLog * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 + * @arkts 1.2 */ - function debug(domain: number, tag: string, format: string, ...args: (Object | undefined | null)[]): void; + function debug(domain: int, tag: string, format: string, ...args: RecordData[]): void; /** * Outputs info-level logs. @@ -134,21 +139,23 @@ declare namespace hilog { * @atomicservice * @since 11 */ + function info(domain: number, tag: string, format: string, ...args: any[]): void; + /** * Outputs info-level logs. * - * @param { number } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF + * @param { int } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF * if the value exceeds the range, logs cannot be printed. * @param { string } tag Identifies the log tag, length cannot exceed 32 bytes, the excess part will be truncated. * @param { string } format Indicates the log format string. - * @param { (Object | undefined | null)[] }args Indicates the log parameters. + * @param { RecordData[] }args Indicates the log parameters. * @syscap SystemCapability.HiviewDFX.HiLog * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 + * @arkts 1.2 */ - function info(domain: number, tag: string, format: string, ...args: (Object | undefined | null)[]): void; + function info(domain: int, tag: string, format: string, ...args: RecordData[]): void; /** * Outputs warning-level logs. @@ -186,21 +193,23 @@ declare namespace hilog { * @atomicservice * @since 11 */ + function warn(domain: number, tag: string, format: string, ...args: any[]): void; + /** * Outputs warning-level logs. * - * @param { number } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF + * @param { int } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF * if the value exceeds the range, logs cannot be printed. * @param { string } tag Identifies the log tag, length cannot exceed 32 bytes, the excess part will be truncated. * @param { string } format Indicates the log format string. - * @param { (Object | undefined | null)[] }args Indicates the log parameters. + * @param { RecordData[] }args Indicates the log parameters. * @syscap SystemCapability.HiviewDFX.HiLog * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 + * @arkts 1.2 */ - function warn(domain: number, tag: string, format: string, ...args: (Object | undefined | null)[]): void; + function warn(domain: int, tag: string, format: string, ...args: RecordData[]): void; /** * Outputs error-level logs. @@ -238,21 +247,23 @@ declare namespace hilog { * @atomicservice * @since 11 */ + function error(domain: number, tag: string, format: string, ...args: any[]): void; + /** * Outputs error-level logs. * - * @param { number } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF + * @param { int } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF * if the value exceeds the range, logs cannot be printed. * @param { string } tag Identifies the log tag, length cannot exceed 32 bytes, the excess part will be truncated. * @param { string } format Indicates the log format string. - * @param { (Object | undefined | null)[] }args Indicates the log parameters. + * @param { RecordData[] }args Indicates the log parameters. * @syscap SystemCapability.HiviewDFX.HiLog * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 + * @arkts 1.2 */ - function error(domain: number, tag: string, format: string, ...args: (Object | undefined | null)[]): void; + function error(domain: int, tag: string, format: string, ...args: RecordData[]): void; /** * Outputs fatal-level logs. @@ -290,21 +301,23 @@ declare namespace hilog { * @atomicservice * @since 11 */ + function fatal(domain: number, tag: string, format: string, ...args: any[]): void; + /** * Outputs fatal-level logs. * - * @param { number } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF + * @param { int } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF * if the value exceeds the range, logs cannot be printed. * @param { string } tag Identifies the log tag, length cannot exceed 32 bytes, the excess part will be truncated. * @param { string } format Indicates the log format string. - * @param { (Object | undefined | null)[] }args Indicates the log parameters. + * @param { RecordData[] }args Indicates the log parameters. * @syscap SystemCapability.HiviewDFX.HiLog * @crossplatform * @atomicservice * @since 20 - * @arkts 1.1&1.2 + * @arkts 1.2 */ - function fatal(domain: number, tag: string, format: string, ...args: (Object | undefined | null)[]): void; + function fatal(domain: int, tag: string, format: string, ...args: RecordData[]): void; /** * Checks whether logs of the specified tag, and level can be printed. @@ -320,7 +333,7 @@ declare namespace hilog { /** * Checks whether logs of the specified tag, and level can be printed. * - * @param { number } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF + * @param { int } domain Indicates the service domain, which is a hexadecimal integer ranging from 0x0 to 0xFFFF * if the value exceeds the range, logs cannot be printed. * @param { string } tag Identifies the log tag, length cannot exceed 32 bytes, the excess part will be truncated. * @param { LogLevel } level log level @@ -330,7 +343,7 @@ declare namespace hilog { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - function isLoggable(domain: number, tag: string, level: LogLevel): boolean; + function isLoggable(domain: int, tag: string, level: LogLevel): boolean; /** * Sets the lowest log level of the current application process. diff --git a/api/@ohos.hiviewdfx.hiAppEvent.d.ts b/api/@ohos.hiviewdfx.hiAppEvent.d.ts index 7dc81bdeb32591d2ab251ed109e8266943010b27..1978cb3f4b38abf29dfabf802c2222713e94da26 100644 --- a/api/@ohos.hiviewdfx.hiAppEvent.d.ts +++ b/api/@ohos.hiviewdfx.hiAppEvent.d.ts @@ -16,10 +16,12 @@ /** * @file * @kit PerformanceAnalysisKit - * @arkts 1.1&1.2 */ import type { AsyncCallback } from './@ohos.base'; +/*** if arkts 1.2 */ +import type { RecordData } from './@ohos.base' +/*** endif */ /** * Provides the event logging function for applications to log the fault, statistical, security, @@ -399,7 +401,6 @@ declare namespace hiAppEvent { * @syscap SystemCapability.HiviewDFX.HiAppEvent * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ const APP_KILLED: string; } @@ -814,10 +815,34 @@ declare namespace hiAppEvent { * @syscap SystemCapability.HiviewDFX.HiAppEvent * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ params: object; + + /** + * Event parameter object, which consists of a parameter name and a parameter value. In system events, the fields + * contained in params are defined by system. For details about the fields, you can see the overviews of system + * events, for example, Crash Event Overview. For application events, you need to define the parameters of the + * Write API. The specifications are as follows: + *
- A parameter name is a string that contains a maximum of 32 characters, including digits (0 to 9), letters + * (a to z), underscore (_), and dollar sign ($). It must start with a letter or dollar sign ($) and end with a + * digit or letter. For example, testName and $123_name. + *
- The parameter value can be a string, number, boolean, or array. The string type parameter can contain a + * maximum of 8 x 1024 characters. If the length exceeds the limit, the parameter and its name will be discarded. + * The value of the number type parameter must be within the range of Number.MIN_SAFE_INTEGER to + * Number.MAX_SAFE_INTEGER. If the value exceeds the range, an uncertain value may be generated. The element type + * in the array type parameter can only be string, number, or boolean. The number of elements must be less than + * 100. If this limit is exceeded, excess elements will be discarded. + *
- The maximum number of parameters is 32. If this limit is exceeded, excess parameters will be discarded. + * + * @type { RecordData } + * @syscap SystemCapability.HiviewDFX.HiAppEvent + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + params: RecordData; } /** @@ -1381,10 +1406,25 @@ declare namespace hiAppEvent { * @syscap SystemCapability.HiviewDFX.HiAppEvent * @crossplatform * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ takeNext(): AppEventPackage; + /** + * Obtains the subscription event. + *
The system obtains the subscription event data based on the data size threshold specified by setSize or the + * number of data records specified by setRow. By default, one subscription event data record is obtained. When all + * subscription event data is obtained, null is returned. + *
When setRow and setSize are called at the same time, only setRow takes effect. + * + * @returns { AppEventPackage | null } Event package object. If all subscription event data has been retrieved, null is + * returned. + * @syscap SystemCapability.HiviewDFX.HiAppEvent + * @crossplatform + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + takeNext(): AppEventPackage | null; } /** @@ -2344,7 +2384,6 @@ declare namespace hiAppEvent { * @syscap SystemCapability.HiviewDFX.HiAppEvent * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ configName?: string; } @@ -2381,7 +2420,6 @@ declare namespace hiAppEvent { * @syscap SystemCapability.HiviewDFX.HiAppEvent * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ function addProcessorFromConfig(processorName: string, configName?: string): Promise; diff --git a/api/@ohos.i18n.d.ts b/api/@ohos.i18n.d.ts index ab1b00a6f4707bc8c7a3dab8c3e2f6bf099e84ae..0dcb20174c84a220d1502c39406fddad06acc261 100644 --- a/api/@ohos.i18n.d.ts +++ b/api/@ohos.i18n.d.ts @@ -511,7 +511,6 @@ declare namespace i18n { * of the preferred language list. * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission * required to call the API. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; * 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. @@ -530,7 +529,6 @@ declare namespace i18n { * @param { int } index - Position of the preferred language to delete. * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission * required to call the API. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; * 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. @@ -1311,8 +1309,8 @@ declare namespace i18n { * localization. * * @param { string } path - Path to mirror, for example, "/data/out/tmp". - * @param [ string ] delimiter - Path delimiter. The default value is "/"". - * @param [ intl.Locale ] locale - Locale object. The default value is the current system locale. + * @param { string } [delimiter] - Path delimiter. The default value is "/"". + * @param { intl.Locale } [locale] - Locale object. The default value is the current system locale. * @returns { string } File path after localization. If the specified locale object corresponds to an RTL language, * the processed file path contains a direction control character to ensure that the file path * is displayed in mirror mode. @@ -1322,6 +1320,7 @@ declare namespace i18n { * @atomicservice * @since 18 * @deprecated since 20 + * @useinstead getUnicodeWrappedFilePath */ static getUnicodeWrappedFilePath(path: string, delimiter?: string, locale?: intl.Locale): string; @@ -1340,6 +1339,7 @@ declare namespace i18n { * @syscap SystemCapability.Global.I18n * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ static getUnicodeWrappedFilePath(path: string, delimiter?: string, locale?: Intl.Locale): string; } @@ -2483,7 +2483,7 @@ declare namespace i18n { * checked. * @returns { boolean } true if the input character is a white space, and false otherwise. * @syscap SystemCapability.Global.I18n - * @since arkts 8 + * @since 8 * @deprecated since 9 * @useinstead Unicode.isWhitespace */ @@ -2496,7 +2496,7 @@ declare namespace i18n { * checked. * @returns { boolean } true if the input character is of the RTL language, and false otherwise. * @syscap SystemCapability.Global.I18n - * @since arkts 8 + * @since 8 * @deprecated since 9 * @useinstead Unicode.isRTL */ @@ -4246,6 +4246,7 @@ declare namespace i18n { * @atomicservice * @since 18 * @deprecated since 20 + * @useinstead getSimpleDateTimeFormatByPattern */ export function getSimpleDateTimeFormatByPattern(pattern: string, locale?: intl.Locale): SimpleDateTimeFormat; @@ -4263,6 +4264,7 @@ declare namespace i18n { * @syscap SystemCapability.Global.I18n * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ export function getSimpleDateTimeFormatByPattern(pattern: string, locale?: Intl.Locale): SimpleDateTimeFormat; @@ -4280,6 +4282,7 @@ declare namespace i18n { * @atomicservice * @since 18 * @deprecated since 20 + * @useinstead getSimpleDateTimeFormatBySkeleton */ export function getSimpleDateTimeFormatBySkeleton(skeleton: string, locale?: intl.Locale): SimpleDateTimeFormat; @@ -4296,6 +4299,7 @@ declare namespace i18n { * @syscap SystemCapability.Global.I18n * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ export function getSimpleDateTimeFormatBySkeleton(skeleton: string, locale?: Intl.Locale): SimpleDateTimeFormat; @@ -4334,6 +4338,7 @@ declare namespace i18n { * @atomicservice * @since 18 * @deprecated since 20 + * @useinstead getSimpleNumberFormatBySkeleton */ export function getSimpleNumberFormatBySkeleton(skeleton: string, locale?: intl.Locale): SimpleNumberFormat; @@ -4349,6 +4354,7 @@ declare namespace i18n { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ export function getSimpleNumberFormatBySkeleton(skeleton: string, locale?: Intl.Locale): SimpleNumberFormat; @@ -4391,9 +4397,9 @@ declare namespace i18n { * The default value is the default text style. * @syscap SystemCapability.Global.I18n * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since 18 * @deprecated since 20 - * @arkts 1.1&1.2 + * @useinstead constructor */ constructor(numberFormat: intl.NumberFormat | SimpleNumberFormat, options?: StyledNumberFormatOptions); @@ -4405,6 +4411,7 @@ declare namespace i18n { * @syscap SystemCapability.Global.I18n * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ constructor(numberFormat: Intl.NumberFormat | SimpleNumberFormat, options?: StyledNumberFormatOptions); diff --git a/api/@ohos.inputMethodEngine.d.ts b/api/@ohos.inputMethodEngine.d.ts index 5fc66ea191b98b174b095981adf9a37ded7cde66..d6e081b899e9d04abbe6911c505c536a7d5d37ff 100644 --- a/api/@ohos.inputMethodEngine.d.ts +++ b/api/@ohos.inputMethodEngine.d.ts @@ -179,6 +179,7 @@ declare namespace inputMethodEngine { /** * Editor of type PATTERN_USER_NAME * + * @constant * @syscap SystemCapability.MiscServices.InputMethodFramework * @since 20 */ @@ -187,6 +188,7 @@ declare namespace inputMethodEngine { /** * Editor of type PATTERN_NEW_PASSWORD * + * @constant * @syscap SystemCapability.MiscServices.InputMethodFramework * @since 20 */ @@ -195,6 +197,7 @@ declare namespace inputMethodEngine { /** * Editor of type PATTERN_NUMBER_DECIMAL * + * @constant * @syscap SystemCapability.MiscServices.InputMethodFramework * @since 20 */ @@ -203,6 +206,7 @@ declare namespace inputMethodEngine { /** * Editor of type PATTERN_ONE_TIME_CODE * + * @constant * @syscap SystemCapability.MiscServices.InputMethodFramework * @since 20 */ diff --git a/api/@ohos.intl.d.ts b/api/@ohos.intl.d.ts index dd77c2628e3d167ba1c496b66c6ea587857e29ae..0cbfb8e4cc7db463464282d8fdee70b5a1ecbb83 100644 --- a/api/@ohos.intl.d.ts +++ b/api/@ohos.intl.d.ts @@ -434,7 +434,7 @@ declare namespace intl { * @atomicservice * @since 12 * @deprecated since 20 - * @useinstead i18n.System.getSystemLocaleObject + * @useinstead i18n.System.getSystemLocaleInstance */ constructor(); diff --git a/api/@ohos.matrix4.d.ets b/api/@ohos.matrix4.d.ets deleted file mode 100644 index b3d8a459df2d7beb5585b177ccb696628f5b1641..0000000000000000000000000000000000000000 --- a/api/@ohos.matrix4.d.ets +++ /dev/null @@ -1,1062 +0,0 @@ -/* - * Copyright (c) 2020-2023 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit ArkUI - */ - -/** - * Used to do matrix operations - * - * @namespace matrix4 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ -/** - * Used to do matrix operations - * - * @namespace matrix4 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ -/** - * Used to do matrix operations - * - * @namespace matrix4 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ -declare namespace matrix4 { - /** - * Set translation parameters - * - * @interface TranslateOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Set translation parameters - * - * @interface TranslateOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Set translation parameters - * - * @interface TranslateOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - interface TranslateOption { - /** - * Indicates the translation distance of the x-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Indicates the translation distance of the x-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Indicates the translation distance of the x-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - x?: number; - - /** - * Indicates the translation distance of the y-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Indicates the translation distance of the y-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Indicates the translation distance of the y-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - y?: number; - - /** - * Indicates the translation distance of the z-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Indicates the translation distance of the z-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Indicates the translation distance of the z-axis, in px. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - z?: number; - } - - /** - * Set scaling parameters - * - * @interface ScaleOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Set scaling parameters - * - * @interface ScaleOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Set scaling parameters - * - * @interface ScaleOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - interface ScaleOption { - /** - * Zoom factor of the x-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Zoom factor of the x-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Zoom factor of the x-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - x?: number; - - /** - * Zoom factor of the y-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Zoom factor of the y-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Zoom factor of the y-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - y?: number; - - /** - * Zoom factor of the z-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Zoom factor of the z-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Zoom factor of the z-axis. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - z?: number; - - /** - * Transform the x-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Transform the x-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Transform the x-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - centerX?: number; - - /** - * Transform the y-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Transform the y-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Transform the y-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - centerY?: number; - } - - /** - * Set Rotation Parameters. - * - * @interface RotateOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Set Rotation Parameters. - * - * @interface RotateOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Set Rotation Parameters. - * - * @interface RotateOption - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - interface RotateOption { - /** - * Axis of rotation vector x coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Axis of rotation vector x coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Axis of rotation vector x coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - x?: number; - - /** - * Axis of rotation vector y coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Axis of rotation vector y coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Axis of rotation vector y coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - y?: number; - - /** - * Axis of rotation vector z coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Axis of rotation vector z coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Axis of rotation vector z coordinate. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - z?: number; - - /** - * Transform the x-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Transform the x-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Transform the x-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - centerX?: number; - - /** - * Transform the y-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Transform the y-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Transform the y-axis coordinate of the center point. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - centerY?: number; - - /** - * Rotation angle. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Rotation angle. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Rotation angle. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - angle?: number; - } - - - /** - * Set poly to poly point. - * - * @interface Point - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - export interface Point { - - /** - * Point x. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - x: number; - - /** - * Point y. - * - * @type { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - y: number; - } - - /** - * Set poly to poly point options. - * - * @interface PolyToPolyOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - export interface PolyToPolyOptions { - - /** - * Array of point coordinates for the source polygon. - * - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - src: Array; - - /** - * Start point index of the source polygon, which defaults to 0. - * @type { ?number } - * @default 0 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - srcIndex?: number; - - /** - * Array of point coordinates for the target polygon. - * - * @type { Array } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - dst:Array; - - /** - * Start index of the target polygon, which defaults to 0. - * - * @type { ?number } - * @default src.Length/2 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - dstIndex?: number; - - /** - * The number of points to be used. - * If it is 0, it returns the identity matrix. - * If it is 1, it returns a translation matrix that changed before two points. - * If it is 2-4, it returns a transformation matrix. - * @type { ?number } - * @default 0 - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - pointCount?:number; - - } - /** - * Matrix4Transit. - * - * @interface Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Matrix4Transit. - * - * @interface Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Matrix4Transit. - * - * @interface Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - interface Matrix4Transit { - /** - * Copy function of Matrix, which can copy a copy of the current matrix object. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Copy function of Matrix, which can copy a copy of the current matrix object. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Copy function of Matrix, which can copy a copy of the current matrix object. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - copy(): Matrix4Transit; - - /** - * The inverse function of Matrix returns an inverse matrix of the current matrix object, that is, the effect is exactly the opposite. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * The inverse function of Matrix returns an inverse matrix of the current matrix object, that is, the effect is exactly the opposite. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * The inverse function of Matrix returns an inverse matrix of the current matrix object, that is, the effect is exactly the opposite. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - invert(): Matrix4Transit; - - /** - * Matrix superposition function, which can superpose the effects of two matrices to generate a new matrix object. - * - * @param { Matrix4Transit } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Matrix superposition function, which can superpose the effects of two matrices to generate a new matrix object. - * - * @param { Matrix4Transit } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Matrix superposition function, which can superpose the effects of two matrices to generate a new matrix object. - * - * @param { Matrix4Transit } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - combine(options: Matrix4Transit): Matrix4Transit; - - /** - * Matrix translation function, which can add the x-axis, Y-axis, or Z-axis translation effect to the current matrix. - * - * @param { TranslateOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Matrix translation function, which can add the x-axis, Y-axis, or Z-axis translation effect to the current matrix. - * - * @param { TranslateOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Matrix translation function, which can add the x-axis, Y-axis, or Z-axis translation effect to the current matrix. - * - * @param { TranslateOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - translate(options: TranslateOption): Matrix4Transit; - - /** - * Scaling function of the Matrix, which can add the x-axis, Y-axis, or Z-axis scaling effect to the current matrix. - * - * @param { ScaleOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Scaling function of the Matrix, which can add the x-axis, Y-axis, or Z-axis scaling effect to the current matrix. - * - * @param { ScaleOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Scaling function of the Matrix, which can add the x-axis, Y-axis, or Z-axis scaling effect to the current matrix. - * - * @param { ScaleOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - scale(options: ScaleOption): Matrix4Transit; - - /** - * Skew function of the Matrix, which can add the x-axis, y-axis skew effect to the current matrix. - * Skew function takes a generic point with coordinates (x0, y0, z0) to the point (x0 + x*y0, y0 + y*x0, z0), - * where x, y are fixed parameters, called the shear factors. - * - * @param { number } x - the shear factor of x-axis. - * @param { number } y - the shear factor of y-axis. - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - skew(x: number, y: number): Matrix4Transit; - - /** - * Rotation function of the Matrix. You can add the x-axis, Y-axis, or Z-axis rotation effect to the current matrix. - * - * @param { RotateOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Rotation function of the Matrix. You can add the x-axis, Y-axis, or Z-axis rotation effect to the current matrix. - * - * @param { RotateOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Rotation function of the Matrix. You can add the x-axis, Y-axis, or Z-axis rotation effect to the current matrix. - * - * @param { RotateOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - rotate(options: RotateOption): Matrix4Transit; - - /** - * Matrix coordinate point conversion function, which can apply the current transformation effect to a coordinate point. - * - * @param { [number, number] } options - * @returns { [number, number] } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Matrix coordinate point conversion function, which can apply the current transformation effect to a coordinate point. - * - * @param { [number, number] } options - * @returns { [number, number] } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Matrix coordinate point conversion function, which can apply the current transformation effect to a coordinate point. - * - * @param { [number, number] } options - * @returns { [number, number] } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - transformPoint(options: [number, number]): [number, number]; - - /** - * Sets matrix to map src to dst. - * - * @param { PolyToPolyOptions } options - polyToPoly options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - setPolyToPoly(options: PolyToPolyOptions): Matrix4Transit - - } - - /** - * Constructor of Matrix, which can create a fourth-order matrix based on the input parameters. The matrix is column-first. - * - * @param { [number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number] } options - * options indicates a fourth-order matrix - * The default value: - * [1, 0, 0, 0, - * 0, 1, 0, 0, - * 0, 0, 1, 0, - * 0, 0, 0, 1] - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Constructor of Matrix, which can create a fourth-order matrix based on the input parameters. The matrix is column-first. - * - * @param { [number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number] } options - * options indicates a fourth-order matrix - * The default value: - * [1, 0, 0, 0, - * 0, 1, 0, 0, - * 0, 0, 1, 0, - * 0, 0, 0, 1] - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Constructor of Matrix, which can create a fourth-order matrix based on the input parameters. The matrix is column-first. - * - * @param { [number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number] } options - * options indicates a fourth-order matrix - * The default value: - * [1, 0, 0, 0, - * 0, 1, 0, 0, - * 0, 0, 1, 0, - * 0, 0, 0, 1] - * Fourth-order matrix notes: - * m00 { number } -The x-axis scale value, the identity matrix defaults to 1. - * m01 { number } -The second value, the rotation of the xyz axis affects this value. - * m02 { number } -The third value, the rotation of the xyz axis affects this value. - * m03 { number } -Meaningless. - * m10 { number } -The fifth value, the rotation of the xyz axis affects this value. - * m11 { number } -The y-axis scales the value, and the identity matrix defaults to 1. - * m12 { number } -The 7th value, the rotation of the xyz axis affects this value. - * m13 { number } -Meaningless. - * m20 { number } -The 9th value, the rotation of the xyz axis affects this value. - * m21 { number } -The 10th value, xyz axis rotation affects this value. - * m22 { number } -The z-axis scale value, the identity matrix defaults to 1. - * m23 { number } -Meaningless. - * m30 { number } -The x-axis translation value in px, the identity matrix defaults to 0. - * m31 { number } -Y-axis translation value, in px, the identity matrix defaults to 0. - * m32 { number } -The z-axis translation value in px, the identity matrix defaults to 0. - * m33 { number } -It takes effect in homogeneous coordinates to produce a perspective projection effect. - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Constructor of Matrix, which can create a fourth-order matrix based on the input parameters. The matrix is column-first. - * - * @param { [number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number] } options - * options indicates a fourth-order matrix - * The default value: - * [1, 0, 0, 0, - * 0, 1, 0, 0, - * 0, 0, 1, 0, - * 0, 0, 0, 1] - * Fourth-order matrix notes: - * m00 { number } -The x-axis scale value, the identity matrix defaults to 1. - * m01 { number } -The second value, the rotation and skew of the xyz axis affects this value. - * m02 { number } -The third value, the rotation of the xyz axis affects this value. - * m03 { number } -The fourth value, the perspective projection affects this value. - * m10 { number } -The fifth value, the rotation and skew of the xyz axis affects this value. - * m11 { number } -The y-axis scales the value, and the identity matrix defaults to 1. - * m12 { number } -The 7th value, the rotation of the xyz axis affects this value. - * m13 { number } -The 8th value, the perspective projection affects this value. - * m20 { number } -The 9th value, the rotation of the xyz axis affects this value. - * m21 { number } -The 10th value, xyz axis rotation affects this value. - * m22 { number } -The z-axis scale value, the identity matrix defaults to 1. - * m23 { number } -The 12th value, the perspective projection affects this value. - * m30 { number } -The x-axis translation value in px, the identity matrix defaults to 0. - * m31 { number } -Y-axis translation value, in px, the identity matrix defaults to 0. - * m32 { number } -The z-axis translation value in px, the identity matrix defaults to 0. - * m33 { number } -It takes effect in homogeneous coordinates to produce a perspective projection effect. - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ - function init( - options: [ - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number - ] - ): Matrix4Transit; - - /** - * Matrix initialization function, which can return an identity matrix object. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Matrix initialization function, which can return an identity matrix object. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Matrix initialization function, which can return an identity matrix object. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - function identity(): Matrix4Transit; - - /** - * Copy function of Matrix, which can copy a copy of the current matrix object. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 10 - */ - function copy(): Matrix4Transit; - - /** - * The inverse function of Matrix returns an inverse matrix of the current matrix object, that is, the effect is exactly the opposite. - * - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 10 - */ - function invert(): Matrix4Transit; - - /** - * Matrix superposition function, which can superpose the effects of two matrices to generate a new matrix object. - * - * @param { Matrix4Transit } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 10 - */ - function combine(options: Matrix4Transit): Matrix4Transit; - - /** - * Matrix translation function, which can add the x-axis, Y-axis, or Z-axis translation effect to the current matrix. - * - * @param { TranslateOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 10 - */ - function translate(options: TranslateOption): Matrix4Transit; - - /** - * Scaling function of the Matrix, which can add the x-axis, Y-axis, or Z-axis scaling effect to the current matrix. - * - * @param { ScaleOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 10 - */ - function scale(options: ScaleOption): Matrix4Transit; - - /** - * Rotation function of the Matrix. You can add the x-axis, Y-axis, or Z-axis rotation effect to the current matrix. - * - * @param { RotateOption } options - * @returns { Matrix4Transit } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 10 - */ - function rotate(options: RotateOption): Matrix4Transit; - - /** - * Matrix coordinate point conversion function, which can apply the current transformation effect to a coordinate point. - * - * @param { [number, number] } options - * @returns { [number, number] } Return to Matrix4Transit - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - * @deprecated since 10 - */ - function transformPoint(options: [number, number]): [number, number]; -} -export default matrix4; \ No newline at end of file diff --git a/api/@ohos.matrix4.d.ts b/api/@ohos.matrix4.d.ts index ae8ae432e4aefa318ac4d98a197e100b7602ed31..1aa87f826f96aeffd783336f434280a9e5b337d6 100644 --- a/api/@ohos.matrix4.d.ts +++ b/api/@ohos.matrix4.d.ts @@ -40,8 +40,7 @@ * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare namespace matrix4 { /** @@ -66,10 +65,9 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export interface TranslateOption { + interface TranslateOption { /** * Indicates the translation distance of the x-axis, in px. * @@ -95,8 +93,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ x?: number; @@ -125,8 +122,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ y?: number; @@ -155,8 +151,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ z?: number; } @@ -183,10 +178,9 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export interface ScaleOption { + interface ScaleOption { /** * Zoom factor of the x-axis. * @@ -213,8 +207,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ x?: number; @@ -244,8 +237,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ y?: number; @@ -275,8 +267,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ z?: number; @@ -305,8 +296,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ centerX?: number; @@ -335,8 +325,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ centerY?: number; } @@ -363,10 +352,9 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export interface RotateOption { + interface RotateOption { /** * Axis of rotation vector x coordinate. * @@ -391,8 +379,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ x?: number; @@ -420,8 +407,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ y?: number; @@ -450,8 +436,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ z?: number; @@ -482,8 +467,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ centerX?: number; @@ -514,8 +498,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ centerY?: number; @@ -542,8 +525,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ angle?: number; } @@ -556,8 +538,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface Point { @@ -568,8 +549,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ x: number; @@ -580,8 +560,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ y: number; } @@ -593,8 +572,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface PolyToPolyOptions { @@ -605,8 +583,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ src: Array; @@ -617,8 +594,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ srcIndex?: number; @@ -629,8 +605,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dst:Array; @@ -642,8 +617,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dstIndex?: number; @@ -657,8 +631,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ pointCount?:number; @@ -685,10 +658,9 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - export interface Matrix4Transit { + interface Matrix4Transit { /** * Copy function of Matrix, which can copy a copy of the current matrix object. * @@ -711,8 +683,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ copy(): Matrix4Transit; @@ -738,8 +709,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ invert(): Matrix4Transit; @@ -768,8 +738,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ combine(options: Matrix4Transit): Matrix4Transit; @@ -798,8 +767,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ translate(options: TranslateOption): Matrix4Transit; @@ -828,8 +796,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ scale(options: ScaleOption): Matrix4Transit; @@ -842,8 +809,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ skew(x: number, y: number): Matrix4Transit; @@ -872,8 +838,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ rotate(options: RotateOption): Matrix4Transit; @@ -902,8 +867,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ transformPoint(options: [number, number]): [number, number]; @@ -915,11 +879,9 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ setPolyToPoly(options: PolyToPolyOptions): Matrix4Transit - } /** @@ -1012,8 +974,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ function init( options: [ @@ -1058,8 +1019,7 @@ declare namespace matrix4 { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function identity(): Matrix4Transit; diff --git a/api/@ohos.matrix4.static.d.ets b/api/@ohos.matrix4.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..317ab6849d39a291c313464c25b9855ea35deab6 --- /dev/null +++ b/api/@ohos.matrix4.static.d.ets @@ -0,0 +1,450 @@ +'use static' +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +/** + * Used to do matrix operations + * + * @namespace matrix4 + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace matrix4 { + + /** + * Set translation parameters + * + * @interface TranslateOption + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface TranslateOption { + + /** + * Indicates the translation distance of the x-axis, in px. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + x?: number; + + /** + * Indicates the translation distance of the y-axis, in px. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + y?: number; + + /** + * Indicates the translation distance of the z-axis, in px. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + z?: number; + } + + /** + * Set scaling parameters + * + * @interface ScaleOption + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface ScaleOption { + + /** + * Zoom factor of the x-axis. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + x?: number; + + + /** + * Zoom factor of the y-axis. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + y?: number; + + /** + * Zoom factor of the z-axis. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + z?: number; + + + /** + * Transform the x-axis coordinate of the center point. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + centerX?: number; + + /** + * Transform the y-axis coordinate of the center point. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + centerY?: number; + } + + /** + * Set Rotation Parameters. + * + * @interface RotateOption + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface RotateOption { + + /** + * Axis of rotation vector x coordinate. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + x?: number; + + /** + * Axis of rotation vector y coordinate. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + y?: number; + + /** + * Axis of rotation vector z coordinate. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + z?: number; + + /** + * Transform the x-axis coordinate of the center point. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + centerX?: number; + + /** + * Transform the y-axis coordinate of the center point. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + centerY?: number; + + /** + * Rotation angle. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + angle?: number; + } + /** + * Set poly to poly point. + * + * @interface Point + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface Point { + /** + * Point x. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + x: number; + /** + * Point y. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + y: number; + } + /** + * Set poly to poly point options. + * + * @interface PolyToPolyOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface PolyToPolyOptions { + /** + * Array of point coordinates for the source polygon. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + src: Array; + /** + * Start point index of the source polygon, which defaults to 0. + * @type { ?number } + * @default 0 + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + srcIndex?: number; + /** + * Array of point coordinates for the target polygon. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + dst: Array; + /** + * Start index of the target polygon, which defaults to 0. + * + * @type { ?number } + * @default src.Length/2 + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + dstIndex?: number; + /** + * The number of points to be used. + * If it is 0, it returns the identity matrix. + * If it is 1, it returns a translation matrix that changed before two points. + * If it is 2-4, it returns a transformation matrix. + * @type { ?number } + * @default 0 + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + pointCount?: number; + } + + + /** + * Matrix4Transit. + * + * @interface Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface Matrix4Transit { + + + /** + * Copy function of Matrix, which can copy a copy of the current matrix object. + * + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + copy(): Matrix4Transit; + + + /** + * The inverse function of Matrix returns an inverse matrix of the current matrix object + * that is, the effect is exactly the opposite. + * + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + invert(): Matrix4Transit; + + + /** + * Matrix superposition function + * which can superpose the effects of two matrices to generate a new matrix object. + * + * @param { Matrix4Transit } options + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + combine(options: Matrix4Transit): Matrix4Transit; + + + /** + * Matrix translation function + * which can add the x-axis, Y-axis, or Z-axis translation effect to the current matrix. + * + * @param { TranslateOption } options + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + translate(options: TranslateOption): Matrix4Transit; + + + /** + * Scaling function of the Matrix + * which can add the x-axis, Y-axis, or Z-axis scaling effect to the current matrix. + * + * @param { ScaleOption } options + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + scale(options: ScaleOption): Matrix4Transit; + /** + * Skew function of the Matrix, which can add the x-axis, y-axis skew effect to the current matrix. + * Skew function takes a generic point with coordinates (x0, y0, z0) to the point (x0 + x*y0, y0 + y*x0, z0), + * where x, y are fixed parameters, called the shear factors. + * + * @param { number } x - the shear factor of x-axis. + * @param { number } y - the shear factor of y-axis. + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + skew(x: number, y: number): Matrix4Transit; + + + /** + * Rotation function of the Matrix. + * You can add the x-axis, Y-axis, or Z-axis rotation effect to the current matrix. + * + * @param { RotateOption } options + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + rotate(options: RotateOption): Matrix4Transit; + + + /** + * Matrix coordinate point conversion function + * which can apply the current transformation effect to a coordinate point. + * + * @param { [number, number] } options + * @returns { [number, number] } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + transformPoint(options: [ + number, + number + ]): [ + number, + number + ]; + /** + * Sets matrix to map src to dst. + * + * @param { PolyToPolyOptions } options - polyToPoly options + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + setPolyToPoly(options: PolyToPolyOptions): Matrix4Transit; + } + + + + /** + * Constructor of Matrix, which can create a fourth-order matrix based on the input parameters. + * The matrix is column-first. + * + * @param { [number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number] } options + * options indicates a fourth-order matrix + * The default value: + * [1, 0, 0, 0, + * 0, 1, 0, 0, + * 0, 0, 1, 0, + * 0, 0, 0, 1] + * Fourth-order matrix notes: + * m00 { number } -The x-axis scale value, the identity matrix defaults to 1. + * m01 { number } -The second value, the rotation and skew of the xyz axis affects this value. + * m02 { number } -The third value, the rotation of the xyz axis affects this value. + * m03 { number } -The fourth value, the perspective projection affects this value. + * m10 { number } -The fifth value, the rotation and skew of the xyz axis affects this value. + * m11 { number } -The y-axis scales the value, and the identity matrix defaults to 1. + * m12 { number } -The 7th value, the rotation of the xyz axis affects this value. + * m13 { number } -The 8th value, the perspective projection affects this value. + * m20 { number } -The 9th value, the rotation of the xyz axis affects this value. + * m21 { number } -The 10th value, xyz axis rotation affects this value. + * m22 { number } -The z-axis scale value, the identity matrix defaults to 1. + * m23 { number } -The 12th value, the perspective projection affects this value. + * m30 { number } -The x-axis translation value in px, the identity matrix defaults to 0. + * m31 { number } -Y-axis translation value, in px, the identity matrix defaults to 0. + * m32 { number } -The z-axis translation value in px, the identity matrix defaults to 0. + * m33 { number } -It takes effect in homogeneous coordinates to produce a perspective projection effect. + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + function init(options: [ + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number + ]): Matrix4Transit; + + + /** + * Matrix initialization function, which can return an identity matrix object. + * + * @returns { Matrix4Transit } Return to Matrix4Transit + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + function identity(): Matrix4Transit; +} +export default matrix4; diff --git a/api/@ohos.measure.d.ts b/api/@ohos.measure.d.ts index 4df04ccd50f063a9bf987b413ed4ba8aba399d4f..3f7396fd46559538b10fbb8e86e865298fbe7da3 100644 --- a/api/@ohos.measure.d.ts +++ b/api/@ohos.measure.d.ts @@ -1,424 +1,402 @@ -/* - * Copyright (c) 2022-2024 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit ArkUI - */ - -/*** if arkts 1.2 */ -import { FontStyle, FontWeight, TextAlign, TextOverflow, TextCase, WordBreak } from './arkui/component/enums' -import { SizeOptions } from './arkui/component/units'; -import { Resource } from './global/resource' -/*** endif */ - -/** - * Defines the options of MeasureText. - * - * @interface MeasureOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ -/** - * Defines the options of MeasureText. - * - * @interface MeasureOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ -/** - * Defines the options of MeasureText. - * - * @interface MeasureOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ -export interface MeasureOptions { - /** - * Text to display. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Text to display. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Text to display. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - textContent: string | Resource; - - /** - * Text display area of width. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Text display area of width. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - constraintWidth?: number | string | Resource; - - /** - * Font Size. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Font Size. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - fontSize?: number | string | Resource; - - /** - * Font style. - * - * @type { ?(number | FontStyle) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Font style. - * - * @type { ?(number | FontStyle) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - fontStyle?: number | FontStyle; - - /** - * Font weight. - * - * @type { ?(number | string | FontWeight) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Font weight. - * - * @type { ?(number | string | FontWeight) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - fontWeight?: number | string | FontWeight; - - /** - * Font list of text. - * - * @type { ?(string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Font list of text. - * - * @type { ?(string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - fontFamily?: string | Resource; - - /** - * Distance between text fonts. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Distance between text fonts. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - letterSpacing?: number | string; - - /** - * Alignment of text. - * - * @type { ?(number | TextAlign) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Alignment of text. - * - * @type { ?(number | TextAlign) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - textAlign?: number | TextAlign; - - /** - * Overflow mode of the font. - * - * @type { ?(number | TextOverflow) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Overflow mode of the font. - * - * @type { ?(number | TextOverflow) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - overflow?: number | TextOverflow; - - /** - * Maximum number of lines of text. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Maximum number of lines of text. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - maxLines?: number; - - /** - * Vertical center mode of the font. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Vertical center mode of the font. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - lineHeight?: number | string | Resource; - - /** - * Baseline offset. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Baseline offset. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - baselineOffset?: number | string; - - /** - * Type of letter in the text font - * - * @type { ?(number | TextCase) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Type of letter in the text font - * - * @type { ?(number | TextCase) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - textCase?: number | TextCase; - - /** - * Specify the indentation of the first line in a text-block. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ - /** - * Specify the indentation of the first line in a text-block. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - textIndent?: number | string; - - /** - * Set the word break type. - * - * @type { ?WordBreak } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ - /** - * Set the word break type. - * - * @type { ?WordBreak } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - wordBreak?: WordBreak; -} - -/** - * Defines the Measure interface. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ -/** - * Defines the Measure interface. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ -export default class MeasureText { - /** - * Displays the textWidth. - * - * @param { MeasureOptions } options - Options. - * @returns { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Displays the textWidth. - * - * @param { MeasureOptions } options - Options. - * @returns { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ - /** - * Displays the textWidth. - * - * @param { MeasureOptions } options - Options. - * @returns { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - * @deprecated since 18 - * @useinstead ohos.arkui.UIContext.MeasureUtils#measureText - */ - static measureText(options: MeasureOptions): number; - - /** - * Displays the text width and height. - * - * @param { MeasureOptions } options - Options of measure area occupied by text. - * @returns { SizeOptions } width and height for text to display \ - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Displays the text width and height. - * - * @param { MeasureOptions } options - Options of measure area occupied by text. - * @returns { SizeOptions } width and height for text to display \ - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ - /** - * Displays the text width and height. - * - * @param { MeasureOptions } options - Options of measure area occupied by text. - * @returns { SizeOptions } width and height for text to display \ - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - * @deprecated since 18 - * @useinstead ohos.arkui.UIContext.MeasureUtils#measureTextSize - */ - static measureTextSize(options: MeasureOptions): SizeOptions; -} +/* + * Copyright (c) 2022-2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + */ + +/** + * Defines the options of MeasureText. + * + * @interface MeasureOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ +/** + * Defines the options of MeasureText. + * + * @interface MeasureOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 11 + */ +/** + * Defines the options of MeasureText. + * + * @interface MeasureOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ +export interface MeasureOptions { + /** + * Text to display. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Text to display. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Text to display. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + textContent: string | Resource; + + /** + * Text display area of width. + * + * @type { ?(number | string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Text display area of width. + * + * @type { ?(number | string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + constraintWidth?: number | string | Resource; + + /** + * Font Size. + * + * @type { ?(number | string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Font Size. + * + * @type { ?(number | string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + fontSize?: number | string | Resource; + + /** + * Font style. + * + * @type { ?(number | FontStyle) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Font style. + * + * @type { ?(number | FontStyle) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + fontStyle?: number | FontStyle; + + /** + * Font weight. + * + * @type { ?(number | string | FontWeight) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Font weight. + * + * @type { ?(number | string | FontWeight) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + fontWeight?: number | string | FontWeight; + + /** + * Font list of text. + * + * @type { ?(string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Font list of text. + * + * @type { ?(string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + fontFamily?: string | Resource; + + /** + * Distance between text fonts. + * + * @type { ?(number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Distance between text fonts. + * + * @type { ?(number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + letterSpacing?: number | string; + + /** + * Alignment of text. + * + * @type { ?(number | TextAlign) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Alignment of text. + * + * @type { ?(number | TextAlign) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + textAlign?: number | TextAlign; + + /** + * Overflow mode of the font. + * + * @type { ?(number | TextOverflow) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Overflow mode of the font. + * + * @type { ?(number | TextOverflow) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + overflow?: number | TextOverflow; + + /** + * Maximum number of lines of text. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Maximum number of lines of text. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + maxLines?: number; + + /** + * Vertical center mode of the font. + * + * @type { ?(number | string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Vertical center mode of the font. + * + * @type { ?(number | string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + lineHeight?: number | string | Resource; + + /** + * Baseline offset. + * + * @type { ?(number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Baseline offset. + * + * @type { ?(number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + baselineOffset?: number | string; + + /** + * Type of letter in the text font + * + * @type { ?(number | TextCase) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Type of letter in the text font + * + * @type { ?(number | TextCase) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + textCase?: number | TextCase; + + /** + * Specify the indentation of the first line in a text-block. + * + * @type { ?(number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 11 + */ + /** + * Specify the indentation of the first line in a text-block. + * + * @type { ?(number | string) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + textIndent?: number | string; + + /** + * Set the word break type. + * + * @type { ?WordBreak } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 11 + */ + /** + * Set the word break type. + * + * @type { ?WordBreak } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + wordBreak?: WordBreak; +} + +/** + * Defines the Measure interface. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ +/** + * Defines the Measure interface. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ +export default class MeasureText { + /** + * Displays the textWidth. + * + * @param { MeasureOptions } options - Options. + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Displays the textWidth. + * + * @param { MeasureOptions } options - Options. + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 11 + */ + /** + * Displays the textWidth. + * + * @param { MeasureOptions } options - Options. + * @returns { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + * @deprecated since 18 + * @useinstead ohos.arkui.UIContext.MeasureUtils#measureText + */ + static measureText(options: MeasureOptions): number; + + /** + * Displays the text width and height. + * + * @param { MeasureOptions } options - Options of measure area occupied by text. + * @returns { SizeOptions } width and height for text to display \ + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 10 + */ + /** + * Displays the text width and height. + * + * @param { MeasureOptions } options - Options of measure area occupied by text. + * @returns { SizeOptions } width and height for text to display \ + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 11 + */ + /** + * Displays the text width and height. + * + * @param { MeasureOptions } options - Options of measure area occupied by text. + * @returns { SizeOptions } width and height for text to display \ + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + * @deprecated since 18 + * @useinstead ohos.arkui.UIContext.MeasureUtils#measureTextSize + */ + static measureTextSize(options: MeasureOptions): SizeOptions; +} \ No newline at end of file diff --git a/api/@ohos.measure.d.ets b/api/@ohos.measure.static.d.ets similarity index 46% rename from api/@ohos.measure.d.ets rename to api/@ohos.measure.static.d.ets index 617503d81be79cc7b123421e8027a5ba4479bbd4..10b3e6f04f9b44f69919bb048202cf69b1938563 100644 --- a/api/@ohos.measure.d.ets +++ b/api/@ohos.measure.static.d.ets @@ -1,5 +1,5 @@ /* - * Copyright (c) 2022-2024 Huawei Device Co., Ltd. + * Copyright (c) 2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -16,8 +16,12 @@ /** * @file * @kit ArkUI + * @arkts 1.2 */ + + + import { FontStyle, FontWeight, TextAlign, TextOverflow, TextCase, WordBreak } from './arkui/component/enums' import { SizeOptions } from './arkui/component/units'; import { Resource } from './global/resource' @@ -27,24 +31,7 @@ import { Resource } from './global/resource' * * @interface MeasureOptions * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ -/** - * Defines the options of MeasureText. - * - * @interface MeasureOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ -/** - * Defines the options of MeasureText. - * - * @interface MeasureOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ export interface MeasureOptions { /** @@ -52,23 +39,7 @@ export interface MeasureOptions { * * @type { string | Resource } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Text to display. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Text to display. - * - * @type { string | Resource } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ textContent: string | Resource; @@ -77,16 +48,7 @@ export interface MeasureOptions { * * @type { ?(number | string | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Text display area of width. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ constraintWidth?: number | string | Resource; @@ -95,16 +57,7 @@ export interface MeasureOptions { * * @type { ?(number | string | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Font Size. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ fontSize?: number | string | Resource; @@ -113,16 +66,7 @@ export interface MeasureOptions { * * @type { ?(number | FontStyle) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Font style. - * - * @type { ?(number | FontStyle) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ fontStyle?: number | FontStyle; @@ -131,16 +75,7 @@ export interface MeasureOptions { * * @type { ?(number | string | FontWeight) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Font weight. - * - * @type { ?(number | string | FontWeight) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ fontWeight?: number | string | FontWeight; @@ -149,16 +84,7 @@ export interface MeasureOptions { * * @type { ?(string | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Font list of text. - * - * @type { ?(string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ fontFamily?: string | Resource; @@ -167,16 +93,7 @@ export interface MeasureOptions { * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Distance between text fonts. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ letterSpacing?: number | string; @@ -185,16 +102,7 @@ export interface MeasureOptions { * * @type { ?(number | TextAlign) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Alignment of text. - * - * @type { ?(number | TextAlign) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ textAlign?: number | TextAlign; @@ -203,16 +111,7 @@ export interface MeasureOptions { * * @type { ?(number | TextOverflow) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Overflow mode of the font. - * - * @type { ?(number | TextOverflow) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ overflow?: number | TextOverflow; @@ -221,16 +120,7 @@ export interface MeasureOptions { * * @type { ?number } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Maximum number of lines of text. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ maxLines?: number; @@ -239,16 +129,7 @@ export interface MeasureOptions { * * @type { ?(number | string | Resource) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Vertical center mode of the font. - * - * @type { ?(number | string | Resource) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ lineHeight?: number | string | Resource; @@ -257,16 +138,7 @@ export interface MeasureOptions { * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Baseline offset. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ baselineOffset?: number | string; @@ -275,35 +147,16 @@ export interface MeasureOptions { * * @type { ?(number | TextCase) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Type of letter in the text font - * - * @type { ?(number | TextCase) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ textCase?: number | TextCase; - - /** - * Specify the indentation of the first line in a text-block. - * - * @type { ?(number | string) } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ + /** * Specify the indentation of the first line in a text-block. * * @type { ?(number | string) } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ textIndent?: number | string; @@ -312,17 +165,7 @@ export interface MeasureOptions { * * @type { ?WordBreak } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ - /** - * Set the word break type. - * - * @type { ?WordBreak } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ wordBreak?: WordBreak; } @@ -331,43 +174,16 @@ export interface MeasureOptions { * Defines the Measure interface. * * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 + * @since 20 */ -/** - * Defines the Measure interface. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 - */ -export declare class MeasureText { - /** - * Displays the textWidth. - * - * @param { MeasureOptions } options - Options. - * @returns { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Displays the textWidth. - * - * @param { MeasureOptions } options - Options. - * @returns { number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ +export default declare class MeasureText { /** * Displays the textWidth. * * @param { MeasureOptions } options - Options. * @returns { number } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ static measureText(options: MeasureOptions): number; @@ -377,26 +193,7 @@ export declare class MeasureText { * @param { MeasureOptions } options - Options of measure area occupied by text. * @returns { SizeOptions } width and height for text to display \ * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 10 - */ - /** - * Displays the text width and height. - * - * @param { MeasureOptions } options - Options of measure area occupied by text. - * @returns { SizeOptions } width and height for text to display \ - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 11 - */ - /** - * Displays the text width and height. - * - * @param { MeasureOptions } options - Options of measure area occupied by text. - * @returns { SizeOptions } width and height for text to display \ - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 12 + * @since 20 */ static measureTextSize(options: MeasureOptions): SizeOptions; } diff --git a/api/@ohos.mediaquery.d.ets b/api/@ohos.mediaquery.d.ets deleted file mode 100644 index 4d345de895572f6e280ff7ba45d6ee15d00ddccc..0000000000000000000000000000000000000000 --- a/api/@ohos.mediaquery.d.ets +++ /dev/null @@ -1,344 +0,0 @@ -/* - * Copyright (c) 2021-2023 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * @file - * @kit ArkUI - */ - -import { Callback } from './@ohos.base'; - -/** - * Used to do mediaquery operations. - * - * @namespace mediaquery - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ -/** - * Used to do mediaquery operations. - * - * @namespace mediaquery - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ -/** - * Used to do mediaquery operations. - * - * @namespace mediaquery - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ -/** - * Used to do mediaquery operations. - * - * @namespace mediaquery - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ -declare namespace mediaquery { - - /** - * Defines the Result of mediaquery. - * - * @interface MediaQueryResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Defines the Result of mediaquery. - * - * @interface MediaQueryResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Defines the Result of mediaquery. - * - * @interface MediaQueryResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Defines the Result of mediaquery. - * - * @interface MediaQueryResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - export interface MediaQueryResult { - /** - * Whether the match condition is met. - * This parameter is read-only. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Whether the match condition is met. - * This parameter is read-only. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Whether the match condition is met. - * This parameter is read-only. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Whether the match condition is met. - * This parameter is read-only. - * - * @type { boolean } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - readonly matches: boolean; - - /** - * Matching condition of a media event. - * This parameter is read-only. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Matching condition of a media event. - * This parameter is read-only. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Matching condition of a media event. - * This parameter is read-only. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Matching condition of a media event. - * This parameter is read-only. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - readonly media: string; - } - - /** - * Defines the Listener of mediaquery. - * - * @interface MediaQueryListener - * @extends MediaQueryResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Defines the Listener of mediaquery. - * - * @interface MediaQueryListener - * @extends MediaQueryResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Defines the Listener of mediaquery. - * - * @interface MediaQueryListener - * @extends MediaQueryResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Defines the Listener of mediaquery. - * - * @interface MediaQueryListener - * @extends MediaQueryResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - export interface MediaQueryListener extends MediaQueryResult { - /** - * Registers a callback with the corresponding query condition by using the handle. - * This callback is triggered when the media attributes change. - * - * @param { 'change' } type - * @param { Callback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Registers a callback with the corresponding query condition by using the handle. - * This callback is triggered when the media attributes change. - * - * @param { 'change' } type - * @param { Callback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Registers a callback with the corresponding query condition by using the handle. - * This callback is triggered when the media attributes change. - * - * @param { 'change' } type - * @param { Callback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Registers a callback with the corresponding query condition by using the handle. - * This callback is triggered when the media attributes change. - * - * @param { 'change' } type - * @param { Callback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - on(type: 'change', callback: Callback): void; - - /** - * Deregisters a callback with the corresponding query condition by using the handle. - * This callback is not triggered when the media attributes chang. - * - * @param { 'change' } type - * @param { Callback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Deregisters a callback with the corresponding query condition by using the handle. - * This callback is not triggered when the media attributes chang. - * - * @param { 'change' } type - * @param { Callback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Deregisters a callback with the corresponding query condition by using the handle. - * This callback is not triggered when the media attributes chang. - * - * @param { 'change' } type - * @param { Callback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Deregisters a callback with the corresponding query condition by using the handle. - * This callback is not triggered when the media attributes chang. - * - * @param { 'change' } type - * @param { Callback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - off(type: 'change', callback?: Callback): void; - } - - /** - * Sets the media query criteria and returns the corresponding listening handle - * - * @param { string } condition - * @returns { MediaQueryListener } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 7 - */ - /** - * Sets the media query criteria and returns the corresponding listening handle - * - * @param { string } condition - * @returns { MediaQueryListener } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * Sets the media query criteria and returns the corresponding listening handle - * - * @param { string } condition - * @returns { MediaQueryListener } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since 11 - */ - /** - * Sets the media query criteria and returns the corresponding listening handle - * - * @param { string } condition - * @returns { MediaQueryListener } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @form - * @atomicservice - * @since 12 - */ - export function matchMediaSync(condition: string): MediaQueryListener; -} - -export default mediaquery; \ No newline at end of file diff --git a/api/@ohos.mediaquery.d.ts b/api/@ohos.mediaquery.d.ts index 16540d063afab82db2b618c99e1ffbc50b0d4f21..eea1e126235de20fe746504523c520a9bae251c5 100644 --- a/api/@ohos.mediaquery.d.ts +++ b/api/@ohos.mediaquery.d.ts @@ -18,13 +18,7 @@ * @kit ArkUI */ -/*** if arkts 1.1 */ import { Callback } from './@ohos.base'; -/*** endif */ - -/*** if arkts 1.2 */ -import { Callback } from './@ohos.base'; -/*** endif */ /** * Used to do mediaquery operations. @@ -58,8 +52,7 @@ import { Callback } from './@ohos.base'; * @crossplatform * @form * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ declare namespace mediaquery { @@ -95,8 +88,7 @@ declare namespace mediaquery { * @crossplatform * @form * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ interface MediaQueryResult { /** @@ -139,8 +131,7 @@ declare namespace mediaquery { * @crossplatform * @form * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ readonly matches: boolean; @@ -184,8 +175,7 @@ declare namespace mediaquery { * @crossplatform * @form * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ readonly media: string; } @@ -226,8 +216,7 @@ declare namespace mediaquery { * @crossplatform * @form * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ interface MediaQueryListener extends MediaQueryResult { /** @@ -270,8 +259,7 @@ declare namespace mediaquery { * @crossplatform * @form * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ on(type: 'change', callback: Callback): void; @@ -315,8 +303,7 @@ declare namespace mediaquery { * @crossplatform * @form * @atomicservice - * @since arkts { '1.1':'12','1.2':'20' } - * @arkts 1.1&1.2 + * @since 12 */ off(type: 'change', callback?: Callback): void; } diff --git a/api/@ohos.mediaquery.static.d.ets b/api/@ohos.mediaquery.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..f7605eeff394f71fc95ca2fbc813bccf312944a2 --- /dev/null +++ b/api/@ohos.mediaquery.static.d.ets @@ -0,0 +1,107 @@ +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +import { Callback } from './@ohos.base'; + +/** + * Used to do mediaquery operations. + * + * @namespace mediaquery + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +declare namespace mediaquery { + + /** + * Defines the Result of mediaquery. + * + * @interface MediaQueryResult + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface MediaQueryResult { + + /** + * Whether the match condition is met. + * This parameter is read-only. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + readonly matches: boolean; + + /** + * Matching condition of a media event. + * This parameter is read-only. + * + * @type { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + readonly media: string; + } + + /** + * Defines the Listener of mediaquery. + * + * @interface MediaQueryListener + * @extends MediaQueryResult + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export interface MediaQueryListener extends MediaQueryResult { + + /** + * Registers a callback with the corresponding query condition by using the handle. + * This callback is triggered when the media attributes change. + * + * @param { 'change' } type + * @param { Callback } callback + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + on(type: 'change', callback: Callback): void; + + /** + * Deregisters a callback with the corresponding query condition by using the handle. + * This callback is not triggered when the media attributes chang. + * + * @param { 'change' } type + * @param { Callback } callback + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + off(type: 'change', callback?: Callback): void; + } + + /** + * Sets the media query criteria and returns the corresponding listening handle + * + * @param { string } condition + * @returns { MediaQueryListener } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + export function matchMediaSync(condition: string): MediaQueryListener; +} + +export default mediaquery; \ No newline at end of file diff --git a/api/@ohos.multimedia.audio.d.ts b/api/@ohos.multimedia.audio.d.ts index 8b0980542e330ef7c5ed5e8070665ab414c23ce1..e3bae4b9b86e3632c1b2392e56bf250b56768bbf 100644 --- a/api/@ohos.multimedia.audio.d.ts +++ b/api/@ohos.multimedia.audio.d.ts @@ -10055,7 +10055,7 @@ declare namespace audio { * @returns { Promise } The Promise used to return timestamp info. * @throws { BusinessError } 6800103 - Operation not permit at current state. * @syscap SystemCapability.Multimedia.Audio.Capturer - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts {'1.1':'19','1.2':'20'} * @arkts 1.1&1.2 */ getAudioTimestampInfo(): Promise; @@ -10066,7 +10066,7 @@ declare namespace audio { * @returns { AudioTimestampInfo } The returned timestamp info. * @throws { BusinessError } 6800103 - Operation not permit at current state. * @syscap SystemCapability.Multimedia.Audio.Capturer - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts {'1.1':'19','1.2':'20'} * @arkts 1.1&1.2 */ getAudioTimestampInfoSync(): AudioTimestampInfo; diff --git a/api/@ohos.multimedia.avsession.d.ts b/api/@ohos.multimedia.avsession.d.ts index 6ad3e24f29bff0b0030b8283aff39f1a02972de5..cda64792ad60396ac36558d615498083cc164d29 100644 --- a/api/@ohos.multimedia.avsession.d.ts +++ b/api/@ohos.multimedia.avsession.d.ts @@ -19,7 +19,7 @@ */ import type { ErrorCallback, AsyncCallback, Callback } from './@ohos.base'; -import { WantAgent } from './@ohos.wantAgent'; +import { WantAgent } from './@ohos.app.ability.wantAgent'; import { KeyEvent } from './@ohos.multimodalInput.keyEvent'; import { ElementName } from './bundleManager/ElementName'; import image from './@ohos.multimedia.image'; @@ -99,7 +99,7 @@ declare namespace avSession { * @arkts 1.1&1.2 */ function getAllSessionDescriptors(callback: AsyncCallback>>): void; - + /** * Get all avsession descriptors of the system * @permission ohos.permission.MANAGE_MEDIA_RESOURCES @@ -1171,8 +1171,7 @@ declare namespace avSession { * @readonly * @syscap SystemCapability.Multimedia.AVSession.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ readonly sessionType: AVSessionType; @@ -2938,7 +2937,7 @@ declare namespace avSession { /** * Activate the session, indicating that the session can accept control commands - * @returns { Promise } void result promise when executed successfully + * @returns { Promise } void result promise when executed successfully * @throws { BusinessError } 6600101 - Session service exception. * @throws { BusinessError } 6600102 - The session does not exist. * @syscap SystemCapability.Multimedia.AVSession.Core @@ -2946,7 +2945,7 @@ declare namespace avSession { */ /** * Activate the session, indicating that the session can accept control commands - * @returns { Promise } void result promise when executed successfully + * @returns { Promise } void result promise when executed successfully * @throws { BusinessError } 6600101 - Session service exception. * @throws { BusinessError } 6600102 - The session does not exist. * @syscap SystemCapability.Multimedia.AVSession.Core @@ -3064,8 +3063,7 @@ declare namespace avSession { * @type { AVCastControlCommandType } * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ command: AVCastControlCommandType; @@ -3092,8 +3090,7 @@ declare namespace avSession { * @type { ?(media.PlaybackSpeed | double | string | LoopMode) } * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ parameter?: media.PlaybackSpeed | double | string | LoopMode; } @@ -4419,8 +4416,7 @@ declare namespace avSession { * Defination of avc codec type. * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ OH_AVCODEC_MIMETYPE_VIDEO_AVC = "video/avc", @@ -4428,8 +4424,7 @@ declare namespace avSession { * Defination of hevc codec type. * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ OH_AVCODEC_MIMETYPE_VIDEO_HEVC = "video/hevc", @@ -4437,8 +4432,7 @@ declare namespace avSession { * Defination of audio vivid codec type. * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ OH_AVCODEC_MIMETYPE_AUDIO_VIVID = "audio/av3a" } @@ -4456,8 +4450,7 @@ declare namespace avSession { * Defination of 480P which typically resolution is 640*480. * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ RESOLUTION_480P = 0, @@ -4465,8 +4458,7 @@ declare namespace avSession { * Defination of 720P which typically resolution is 1280*720. * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ RESOLUTION_720P = 1, @@ -4474,8 +4466,7 @@ declare namespace avSession { * Defination of 1080P which typically resolution is 1920*1080. * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ RESOLUTION_1080P = 2, @@ -4483,8 +4474,7 @@ declare namespace avSession { * Defination of 2K which typically resolution is 2560*1440. * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ RESOLUTION_2K = 3, @@ -4492,8 +4482,7 @@ declare namespace avSession { * Defination of 4K which typically resolution is 4096*3840. * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'19','1.2':'20'} - * @arkts 1.1&1.2 + * @since 19 */ RESOLUTION_4K = 4 } @@ -4601,8 +4590,7 @@ declare namespace avSession { * @type { ?string } * @syscap SystemCapability.Multimedia.AVSession.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ title?: string; @@ -4754,8 +4742,7 @@ declare namespace avSession { * The publishDate of the media * @type { ?Date } * @syscap SystemCapability.Multimedia.AVSession.Core - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ publishDate?: Date; @@ -4966,8 +4953,7 @@ declare namespace avSession { * @type { ?string } * @syscap SystemCapability.Multimedia.AVSession.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ description?: string; @@ -4984,8 +4970,7 @@ declare namespace avSession { * @type { ?(image.PixelMap | string) } * @syscap SystemCapability.Multimedia.AVSession.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ mediaImage?: image.PixelMap | string; /** @@ -5014,8 +4999,7 @@ declare namespace avSession { * @type { ?string } * @syscap SystemCapability.Multimedia.AVSession.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ mediaType?: string; @@ -5539,7 +5523,6 @@ declare namespace avSession { * @syscap SystemCapability.Multimedia.AVSession.Core * @atomicservice * @since 20 - * @arkts 1.1&1.2 */ extras?: Record; } @@ -6014,7 +5997,8 @@ declare namespace avSession { * @type { DeviceType } * @syscap SystemCapability.Multimedia.AVSession.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ deviceType: DeviceType; @@ -6023,8 +6007,7 @@ declare namespace avSession { * @type { ?string } * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ manufacturer?: string; @@ -6033,8 +6016,7 @@ declare namespace avSession { * @type { ?string } * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'13','1.2':'20'} - * @arkts 1.1&1.2 + * @since 13 */ modelName?: string; @@ -6079,8 +6061,7 @@ declare namespace avSession { * @type { ?int } * @syscap SystemCapability.Multimedia.AVSession.AVCast * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ supportedProtocols?: int; @@ -7835,9 +7816,9 @@ declare namespace avSession { * Unregister the active state of this session changed callback * @param { 'activeStateChange' } type - 'activeStateChange' * @param { function } callback - The callback used to handle the active state of this session changed event. - * The callback function provides the changed session state. + * The callback function provides the changed session state. * @throws { BusinessError } 401 - parameter check failed. 1.Mandatory parameters are left unspecified. - * 2.Incorrect parameter types. + * 2.Incorrect parameter types. * @throws { BusinessError } 6600101 - Session service exception. * @throws { BusinessError } 6600103 - The session controller does not exist. * @syscap SystemCapability.Multimedia.AVSession.Core @@ -7847,17 +7828,28 @@ declare namespace avSession { * Unregister the active state of this session changed callback * @param { 'activeStateChange' } type - 'activeStateChange' * @param { function } callback - The callback used to handle the active state of this session changed event. - * The callback function provides the changed session state. + * The callback function provides the changed session state. * @throws { BusinessError } 401 - parameter check failed. 1.Mandatory parameters are left unspecified. - * 2.Incorrect parameter types. + * 2.Incorrect parameter types. * @throws { BusinessError } 6600101 - Session service exception. * @throws { BusinessError } 6600103 - The session controller does not exist. * @syscap SystemCapability.Multimedia.AVSession.Core * @atomicservice - * @since arkts { '1.1':'12','1.2':'20'} + * @since 12 + */ + /** + * Unregister the active state of this session changed callback + * @param { 'activeStateChange' } type - 'activeStateChange' + * @param { function } callback - The callback used to handle the active state of this session changed event. + * The callback function provides the changed session state. + * @throws { BusinessError } 6600101 - Session service exception. + * @throws { BusinessError } 6600103 - The session controller does not exist. + * @syscap SystemCapability.Multimedia.AVSession.Core + * @atomicservice + * @since 20 * @arkts 1.1&1.2 */ - off(type: 'activeStateChange', callback?: (isActive: boolean) => void); + off(type: 'activeStateChange', callback?: (isActive: boolean) => void): void; /** * Register the valid commands of the session changed callback @@ -8298,12 +8290,13 @@ declare namespace avSession { /** * The type of control command, add new support 'playWithAssetId' * @typedef { 'play' | 'pause' | 'stop' | 'playNext' | 'playPrevious' | 'fastForward' | 'rewind' | 'seek' | - * 'setSpeed' | 'setLoopMode' | 'toggleFavorite' | 'playFromAssetId' | 'playWithAssetId' | 'answer' | 'hangUp' | - * 'toggleCallMute' | 'setTargetLoopMode' } AVControlCommandType - * @syscap SystemCapability.Multimedia.AVSession.Core - * @atomicservice - * @since 20 - */ + * 'setSpeed' | 'setLoopMode' | 'toggleFavorite' | 'playFromAssetId' | 'playWithAssetId' | 'answer' | 'hangUp' | + * 'toggleCallMute' | 'setTargetLoopMode'} AVControlCommandType + * @syscap SystemCapability.Multimedia.AVSession.Core + * @atomicservice + * @since 20 + * @arkts 1.1&1.2 + */ type AVControlCommandType = 'play' | 'pause' | 'stop' | 'playNext' | 'playPrevious' | 'fastForward' | 'rewind' | 'seek' | 'setSpeed' | 'setLoopMode' | 'toggleFavorite' | 'playFromAssetId' | 'playWithAssetId' | 'answer' | 'hangUp' | 'toggleCallMute' | 'setTargetLoopMode'; diff --git a/api/@ohos.multimedia.camera.d.ts b/api/@ohos.multimedia.camera.d.ts index a8d27470139d527f40b57b4ab97abdd095d7dace..79e4f95f6b15707b6aee9e942c90f1e82695a290 100644 --- a/api/@ohos.multimedia.camera.d.ts +++ b/api/@ohos.multimedia.camera.d.ts @@ -1373,7 +1373,8 @@ declare namespace camera { * @throws { BusinessError } 7400201 - Camera service fatal error. * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ getCameraDevice(position: CameraPosition, type: CameraType): CameraDevice; @@ -1396,7 +1397,8 @@ declare namespace camera { * @throws { BusinessError } 7400201 - Camera service fatal error. * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ getCameraConcurrentInfos(cameras: Array): Array; @@ -2808,7 +2810,8 @@ declare namespace camera { * @throws { BusinessError } 7400201 - Camera service fatal error. * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ open(type: CameraConcurrentType): Promise; @@ -2950,7 +2953,8 @@ declare namespace camera { * @throws { BusinessError } 7400201 - Camera service fatal error. * @syscap SystemCapability.Multimedia.Camera.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ usedAsPosition(position: CameraPosition): void; @@ -3225,7 +3229,8 @@ declare namespace camera { * * @syscap SystemCapability.Multimedia.Camera.Core * @systemapi - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ CAMERA_FORMAT_DNG_XDRAW = 5, @@ -8629,7 +8634,8 @@ declare namespace camera { * @throws { BusinessError } 202 - Not System Application.[object Object] * @syscap SystemCapability.Multimedia.Camera.Core * @systemapi - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ on(type: 'effectSuggestionChange', callback: AsyncCallback): void; @@ -8641,7 +8647,8 @@ declare namespace camera { * @throws { BusinessError } 202 - Not System Application.[object Object] * @syscap SystemCapability.Multimedia.Camera.Core * @systemapi - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ off(type: 'effectSuggestionChange', callback?: AsyncCallback): void; @@ -11733,7 +11740,8 @@ declare namespace camera { * * @syscap SystemCapability.Multimedia.Camera.Core * @systemapi - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ EFFECT_SUGGESTION_STAGE = 5 } @@ -13232,7 +13240,8 @@ declare namespace camera { * @throws { BusinessError } 7400201 - Camera service fatal error. * @syscap SystemCapability.Multimedia.Camera.Core * @systemapi - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} + * @arkts 1.1&1.2 */ enableAutoCloudImageEnhancement(enabled: boolean): void; @@ -15043,17 +15052,18 @@ declare namespace camera { /** * Enum for camera concurrent type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Multimedia.Camera.Core * @since 18 */ /** * Enum for camera concurrent type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ enum CameraConcurrentType { /** @@ -15067,7 +15077,8 @@ declare namespace camera { * * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ CAMERA_LIMITED_CAPABILITY = 0, @@ -15082,7 +15093,8 @@ declare namespace camera { * * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ CAMERA_FULL_CAPABILITY = 1, } @@ -15100,7 +15112,8 @@ declare namespace camera { * @interface CameraConcurrentInfo * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ interface CameraConcurrentInfo { /** @@ -15118,7 +15131,8 @@ declare namespace camera { * @readonly * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ readonly device: CameraDevice; @@ -15137,7 +15151,8 @@ declare namespace camera { * @readonly * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ readonly type: CameraConcurrentType; @@ -15156,7 +15171,8 @@ declare namespace camera { * @readonly * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ readonly modes: Array; @@ -15175,7 +15191,8 @@ declare namespace camera { * @readonly * @syscap SystemCapability.Multimedia.Camera.Core * @atomicservice - * @since 19 + * @since arkts {'1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ readonly outputCapabilities: Array; } diff --git a/api/@ohos.multimedia.drm.d.ts b/api/@ohos.multimedia.drm.d.ts index bcd02832a23ef9621a25fc8d13aaa530bc2f2898..507346a43db527b5bdd744b2a7a6615ebf524c4c 100644 --- a/api/@ohos.multimedia.drm.d.ts +++ b/api/@ohos.multimedia.drm.d.ts @@ -2043,7 +2043,7 @@ declare namespace drm { * @syscap SystemCapability.Multimedia.Drm.Core * @atomicservice * @since arkts {'1.1':'12','1.2':'20'} - * arkts 1.1&1.2 + * @arkts 1.1&1.2 */ off(type: 'vendorDefined', callback?: (eventInfo: EventInfo) => void): void; diff --git a/api/@ohos.multimedia.image.d.ts b/api/@ohos.multimedia.image.d.ts index e9e9f3662902313e735311e2a4f0a2c577fc3968..010dcfa5982ea65b1d25e56a0985c2ed2528fb24 100644 --- a/api/@ohos.multimedia.image.d.ts +++ b/api/@ohos.multimedia.image.d.ts @@ -6743,8 +6743,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise; @@ -6759,8 +6758,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise): void; @@ -6849,8 +6846,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise; @@ -6865,8 +6861,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise} Promise used to return the result. If the operation is successful, an + * **AVTranscoder** instance is returned; otherwise, **null** is returned. The instance can be used for video + * transcoding. + * @throws { BusinessError } 5400101 - No memory. Return by promise. + * @syscap SystemCapability.Multimedia.Media.AVTranscoder + * @atomicservice + * @since 21 + * @arkts 1.2 + */ function createAVTranscoder(): Promise; /** @@ -6646,7 +6662,7 @@ declare namespace media { * @throws { BusinessError } 5400103 - I/O error. * @throws { BusinessError } 5400105 - Service died. Return by callback. * @syscap SystemCapability.Multimedia.Media.AVRecorder - * @since arkts {'1.1':'11','1.2':'20'} + * @since 11 * @example * import { audio } from '@kit.AudioKit'; * @@ -6660,10 +6676,41 @@ declare namespace media { * currentCapturerInfo = capturerInfo; * } * }); - * @arkts 1.1&1.2 */ getCurrentAudioCapturerInfo(callback: AsyncCallback): void; + /** + * Obtains the information about the current audio capturer. + * This API uses an asynchronous callback to return the result. + * + * This API can be called only after the **prepare()** API is called. + * If this API is called after **stop()** is successfully called, an error is reported. + * @param { AsyncCallback } callback - Callback used to return the result. + * If the operation is successful, **err** is **undefined** and **data** is the + * **audio.AudioCapturerChangeInfo** object obtained; otherwise, **err** is an error object. + * @throws { BusinessError } 5400102 - Operation not allowed. + * @throws { BusinessError } 5400103 - I/O error. + * @throws { BusinessError } 5400105 - Service died. Return by callback. + * @syscap SystemCapability.Multimedia.Media.AVRecorder + * @since 20 + * @example + * import { audio } from '@kit.AudioKit'; + * + * let currentCapturerInfo: audio.AudioCapturerChangeInfo; + * + * avRecorder.getCurrentAudioCapturerInfo((err: BusinessError, capturerInfo: audio.AudioCapturerChangeInfo) => { + * if (err) { + * console.error('Failed to get CurrentAudioCapturerInfo and error is ' + err.message); + * } else { + * console.info('Succeeded in getting CurrentAudioCapturerInfo'); + * currentCapturerInfo = capturerInfo; + * } + * }); + * @arkts 1.2 + */ + getCurrentAudioCapturerInfo(callback: AsyncCallback): void; + + /** * Obtains the information about the current audio capturer. This API uses a promise to return the result. * @@ -6674,7 +6721,7 @@ declare namespace media { * @throws { BusinessError } 5400103 - I/O error. * @throws { BusinessError } 5400105 - Service died. Return by promise. * @syscap SystemCapability.Multimedia.Media.AVRecorder - * @since arkts {'1.1':'11','1.2':'20'} + * @since 11 * @example * import { audio } from '@kit.AudioKit'; * @@ -6686,10 +6733,35 @@ declare namespace media { * }).catch((err: BusinessError) => { * console.error('Failed to get CurrentAudioCapturerInfo and catch error is ' + err.message); * }); - * @arkts 1.1&1.2 */ getCurrentAudioCapturerInfo(): Promise; + /** + * Obtains the information about the current audio capturer. This API uses a promise to return the result. + * + * This API can be called only after the **prepare()** API is called. + * If this API is called after **stop()** is successfully called, an error is reported. + * @returns { Promise } Promise used to return the audio capturer information. + * @throws { BusinessError } 5400102 - Operation not allowed. + * @throws { BusinessError } 5400103 - I/O error. + * @throws { BusinessError } 5400105 - Service died. Return by promise. + * @syscap SystemCapability.Multimedia.Media.AVRecorder + * @since 20 + * @example + * import { audio } from '@kit.AudioKit'; + * + * let currentCapturerInfo: audio.AudioCapturerChangeInfo; + * + * avRecorder.getCurrentAudioCapturerInfo().then((capturerInfo: audio.AudioCapturerChangeInfo) => { + * console.info('Succeeded in getting CurrentAudioCapturerInfo'); + * currentCapturerInfo = capturerInfo; + * }).catch((err: BusinessError) => { + * console.error('Failed to get CurrentAudioCapturerInfo and catch error is ' + err.message); + * }); + * @arkts 1.2 + */ + getCurrentAudioCapturerInfo(): Promise; + /** * Obtains the maximum amplitude of the current audio capturer. * This API uses an asynchronous callback to return the result. diff --git a/api/@ohos.multimedia.movingphotoview.d.ts b/api/@ohos.multimedia.movingphotoview.d.ts index 44055a162b614aea10094a115b66231f2c134a32..e5be7717a6ee1ecabd92e14f4e3a5a6bb45ed0e1 100644 --- a/api/@ohos.multimedia.movingphotoview.d.ts +++ b/api/@ohos.multimedia.movingphotoview.d.ts @@ -20,102 +20,6 @@ import photoAccessHelper from './@ohos.file.photoAccessHelper'; -/** - * Enumerates pixel map formats. - * - * @enum { number } - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @systemapi - * @since 14 - */ -export declare enum PixelMapFormat { - /** - * Indicates an unknown format. - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @systemapi - * @since 14 - */ - UNKNOWN = 0, - /** - * Indicates that each pixel is stored on 32 bits. Each pixel contains 4 components:B(8bits), G(8bits), R(8bits), A(8bits) - * and are stored from the higher-order to the lower-order bits. - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @systemapi - * @since 14 - */ - RGBA_8888 = 1, - /** - * Indicates that the storage order is to store Y first and then V U alternately each occupies 8 bits - * and are stored from the higher-order to the lower-order bits. - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @systemapi - * @since 14 - */ - NV21 = 2, - /** - * Indicates that each pixel is stored on 32 bits. Each pixel contains 4 components: - * R(10bits), G(10bits), B(10bits), A(2bits) and are stored from the higher-order to the lower-order bits. - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @since 14 - */ - RGBA_1010102 = 3, - - /** - * Indicates that the storage order is to store Y first and then U V alternately each occupies 10 bits - * and are stored from the higher-order to the lower-order bits. - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @since 14 - */ - YCBCR_P010 = 4, - - /** - * Indicates that the storage order is to store Y first and then V U alternately each occupies 10 bits - * and are stored from the higher-order to the lower-order bits. - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @since 14 - */ - YCRCB_P010 = 5 -} -/** - * Dynamic range mode of moving photo. - * - * @enum { number } - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @systemapi - * @since 14 - */ -export declare enum DynamicRangeMode { - /** - * Allow image content to use an unrestricted extended range - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @systemapi - * @since 14 - */ - HIGH = 0, - /** - * Allow image content to use some extended range - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @systemapi - * @since 14 - */ - CONSTRAINT = 1, - /** - * Restrict the image content to dynamic range to the standard range - * - * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core - * @systemapi - * @since 14 - */ - STANDARD = 2, -} /** * Defines the moving photo view options. * @@ -123,7 +27,8 @@ export declare enum DynamicRangeMode { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice - * @since 12 + * @since arkts{ '1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ declare interface MovingPhotoViewOptions { /** @@ -133,7 +38,8 @@ declare interface MovingPhotoViewOptions { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice - * @since 12 + * @since arkts{ '1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ movingPhoto: photoAccessHelper.MovingPhoto; /** @@ -143,7 +49,8 @@ declare interface MovingPhotoViewOptions { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice - * @since 12 + * @since arkts{ '1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ controller?: MovingPhotoViewController; /** @@ -153,16 +60,19 @@ declare interface MovingPhotoViewOptions { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice - * @since 18 + * @since arkts{ '1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ imageAIOptions?: ImageAIOptions; + /** * format of MovingPhotoView. * * @type { ?PixelMapFormat } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi - * @since 14 + * @since arkts{ '1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ movingPhotoFormat?: PixelMapFormat; /** @@ -171,7 +81,8 @@ declare interface MovingPhotoViewOptions { * @type { ?DynamicRangeMode } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi - * @since 14 + * @since arkts{ '1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ dynamicRangeMode?: DynamicRangeMode; /** @@ -180,7 +91,8 @@ declare interface MovingPhotoViewOptions { * @type { ?boolean } * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @systemapi - * @since 19 + * @since arkts{ '1.1':'19','1.2':'20'} + * @arkts 1.1&1.2 */ playWithMask?: boolean; } @@ -191,7 +103,8 @@ declare interface MovingPhotoViewOptions { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice - * @since 12 + * @since arkts{ '1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ interface MovingPhotoViewInterface { /** @@ -202,7 +115,8 @@ interface MovingPhotoViewInterface { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice - * @since 12 + * @since arkts{ '1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ (options: MovingPhotoViewOptions): MovingPhotoViewAttribute; } @@ -214,7 +128,8 @@ interface MovingPhotoViewInterface { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice - * @since 12 + * @since arkts{ '1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ declare type MovingPhotoViewEventCallback = () => void; @@ -225,7 +140,8 @@ declare type MovingPhotoViewEventCallback = () => void; * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @atomicservice - * @since 12 + * @since arkts{ '1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ declare class MovingPhotoViewAttribute extends CommonMethod { /** @@ -236,7 +152,8 @@ declare class MovingPhotoViewAttribute extends CommonMethod; @@ -1207,7 +1208,8 @@ declare namespace systemSoundManager { * @throws { BusinessError } 20700003 - Unsupported operation. * @syscap SystemCapability.Multimedia.SystemSound.Core * @systemapi - * @since 14 + * @since arkts {'1.1':'14','1.2':'20'} + * @arkts 1.1&1.2 */ setToneHapticsSettings(context: BaseContext, type: ToneHapticsType, settings: ToneHapticsSettings): Promise; diff --git a/api/@ohos.multimodalInput.inputDevice.d.ts b/api/@ohos.multimodalInput.inputDevice.d.ts index c93165c80edf91f152cc0edc001424034191a5a5..70fedd711529d34e1aa5ae88fa508b4e197baed8 100644 --- a/api/@ohos.multimodalInput.inputDevice.d.ts +++ b/api/@ohos.multimodalInput.inputDevice.d.ts @@ -213,7 +213,8 @@ declare namespace inputDevice { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.MultimodalInput.Input.InputDevice - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'change', listener?: Callback): void; @@ -464,31 +465,31 @@ declare namespace inputDevice { * Obtains the IDs of all input devices. * This API uses an asynchronous callback to return the result. * - * @param { AsyncCallback> } callback - Callback used to return the IDs of all input devices. id is the unique ID of an input device. + * @param { AsyncCallback> } callback - Callback used to return the IDs of all input devices. id is the unique ID of an input device. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.MultimodalInput.Input.InputDevice * @since arkts {'1.1':'9', '1.2':'20'} * @arkts 1.1&1.2 */ - function getDeviceList(callback: AsyncCallback>): void; + function getDeviceList(callback: AsyncCallback>): void; /** * Obtains the IDs of all input devices. * This API uses a promise to return the result. * - * @returns { Promise> } - Promise used to return the IDs of all input devices. + * @returns { Promise> } - Promise used to return the IDs of all input devices. * @syscap SystemCapability.MultimodalInput.Input.InputDevice * @since arkts {'1.1':'9', '1.2':'20'} * @arkts 1.1&1.2 */ - function getDeviceList(): Promise>; + function getDeviceList(): Promise>; /** * Obtains information about the specified input device. * This API uses an asynchronous callback to return the result. * - * @param { number } deviceId - ID of the input device. + * @param { int } deviceId - ID of the input device. * @param { AsyncCallback } callback - Callback used to return information about the input device, * including device ID, name, supported source, physical address, version information, and product information. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; @@ -497,13 +498,13 @@ declare namespace inputDevice { * @since arkts {'1.1':'9', '1.2':'20'} * @arkts 1.1&1.2 */ - function getDeviceInfo(deviceId: number, callback: AsyncCallback): void; + function getDeviceInfo(deviceId: int, callback: AsyncCallback): void; /** * Obtains the information about the input device with the specified ID. * This API uses a promise to return the result. * - * @param { number } deviceId - ID of the input device. + * @param { int } deviceId - ID of the input device. * @returns { Promise } Promise used to return the information about the input device. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. @@ -511,7 +512,7 @@ declare namespace inputDevice { * @since arkts {'1.1':'9', '1.2':'20'} * @arkts 1.1&1.2 */ - function getDeviceInfo(deviceId: number): Promise; + function getDeviceInfo(deviceId: int): Promise; /** * Obtains information about the specified input device. diff --git a/api/@ohos.multimodalInput.keyCode.d.ts b/api/@ohos.multimodalInput.keyCode.d.ts index 633f1fa9f730cde63366df7bf93be4f5744e07cd..65e9efc910084c207699694c4008fed5520609c7 100644 --- a/api/@ohos.multimodalInput.keyCode.d.ts +++ b/api/@ohos.multimodalInput.keyCode.d.ts @@ -1025,8 +1025,7 @@ export declare enum KeyCode { * KEYCODE_MEDIA_PLAY * * @syscap SystemCapability.MultimodalInput.Input.Core - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ /** * KEYCODE_MEDIA_PLAY diff --git a/api/@ohos.multimodalInput.pointer.d.ts b/api/@ohos.multimodalInput.pointer.d.ts index 09ff8ae4681c72f79c3fce9d1238046798ef1559..113fa39176d27d10798290f915c2021f9273bf0a 100644 --- a/api/@ohos.multimodalInput.pointer.d.ts +++ b/api/@ohos.multimodalInput.pointer.d.ts @@ -444,8 +444,7 @@ declare namespace pointer { * Loading state with dynamic cursor * * @syscap SystemCapability.MultimodalInput.Input.Pointer - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Loading state with dynamic cursor @@ -461,8 +460,7 @@ declare namespace pointer { * Running state with dynamic cursor * * @syscap SystemCapability.MultimodalInput.Input.Pointer - * @since arkts {'1.1':'10', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Running state with dynamic cursor diff --git a/api/@ohos.net.connection.d.ts b/api/@ohos.net.connection.d.ts index c7b58cbc512ceb680bfbbbf84ed2db3fa6635339..b62e262a3ce7cc58f48f146dba78a2fe1a8f3ba7 100644 --- a/api/@ohos.net.connection.d.ts +++ b/api/@ohos.net.connection.d.ts @@ -44,7 +44,7 @@ import type socket from './@ohos.net.socket'; * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ declare namespace connection { @@ -127,7 +127,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function createNetConnection(netSpecifier?: NetSpecifier, timeout?: int): NetConnection; @@ -155,7 +155,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function getDefaultNet(callback: AsyncCallback): void; @@ -182,7 +182,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function getDefaultNet(): Promise; @@ -209,7 +209,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function getDefaultNetSync(): NetHandle; @@ -224,7 +224,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ function getAllNets(callback: AsyncCallback>): void; @@ -238,7 +238,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ function getAllNets(): Promise>; @@ -252,7 +252,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getAllNetsSync(): Array; @@ -269,7 +269,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ function getConnectionProperties(netHandle: NetHandle, callback: AsyncCallback): void; @@ -286,7 +286,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ function getConnectionProperties(netHandle: NetHandle): Promise; @@ -303,7 +303,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getConnectionPropertiesSync(netHandle: NetHandle): ConnectionProperties; @@ -335,7 +335,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function getNetCapabilities(netHandle: NetHandle, callback: AsyncCallback): void; @@ -367,7 +367,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function getNetCapabilities(netHandle: NetHandle): Promise; @@ -399,7 +399,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function getNetCapabilitiesSync(netHandle: NetHandle): NetCapabilities; @@ -475,8 +475,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function isDefaultNetMetered(callback: AsyncCallback): void; @@ -488,8 +487,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function isDefaultNetMetered(): Promise; @@ -501,8 +499,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function isDefaultNetMeteredSync(): boolean; @@ -529,7 +526,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function hasDefaultNet(callback: AsyncCallback): void; @@ -554,7 +551,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function hasDefaultNet(): Promise; @@ -567,7 +564,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function hasDefaultNetSync(): boolean; @@ -584,7 +581,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. Only used for system app. - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ function enableAirplaneMode(callback: AsyncCallback): void; @@ -600,7 +597,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. Only used for system app. - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ function enableAirplaneMode(): Promise; @@ -617,7 +614,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. Only used for system app. - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ function disableAirplaneMode(callback: AsyncCallback): void; @@ -633,7 +630,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. Only used for system app. - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ function disableAirplaneMode(): Promise; @@ -649,8 +646,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ function reportNetConnected(netHandle: NetHandle, callback: AsyncCallback): void; @@ -665,8 +661,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ function reportNetConnected(netHandle: NetHandle): Promise; @@ -681,8 +676,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ function reportNetDisconnected(netHandle: NetHandle, callback: AsyncCallback): void; @@ -697,8 +691,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ function reportNetDisconnected(netHandle: NetHandle): Promise; @@ -713,8 +706,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ function getAddressesByName(host: string, callback: AsyncCallback>): void; @@ -729,8 +721,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ function getAddressesByName(host: string): Promise>; @@ -742,8 +733,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function getAppNet(callback: AsyncCallback): void; @@ -753,8 +743,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function getAppNet(): Promise; @@ -764,8 +753,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getAppNetSync(): NetHandle; @@ -782,7 +770,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function setAppNet(netHandle: NetHandle, callback: AsyncCallback): void; @@ -800,8 +788,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'9','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function setAppNet(netHandle: NetHandle): Promise; @@ -817,7 +804,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getDefaultHttpProxy(callback: AsyncCallback): void; @@ -834,7 +821,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getDefaultHttpProxy(): Promise; @@ -848,7 +835,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getGlobalHttpProxy(callback: AsyncCallback): void; @@ -861,7 +848,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getGlobalHttpProxy(): Promise; @@ -872,7 +859,7 @@ declare namespace connection { * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 2100001 - Invalid http proxy. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function setAppHttpProxy(httpProxy: HttpProxy): void; @@ -890,7 +877,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function setGlobalHttpProxy(httpProxy: HttpProxy, callback: AsyncCallback): void; @@ -908,7 +895,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function setGlobalHttpProxy(httpProxy: HttpProxy): Promise; @@ -923,8 +910,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ function setPacUrl(pacUrl: string): void; @@ -934,8 +920,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ function getPacUrl(): string; @@ -966,8 +951,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ function addCustomDnsRule(host: string, ip: Array, callback: AsyncCallback): void; @@ -998,8 +982,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ function addCustomDnsRule(host: string, ip: Array): Promise; @@ -1028,8 +1011,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ function removeCustomDnsRule(host: string, callback: AsyncCallback): void; @@ -1058,8 +1040,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ function removeCustomDnsRule(host: string): Promise; @@ -1073,8 +1054,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function clearCustomDnsRules(callback: AsyncCallback): void; @@ -1087,8 +1067,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function clearCustomDnsRules(): Promise; @@ -1104,7 +1083,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. Only used for system app. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function factoryReset(): Promise; @@ -1128,7 +1107,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetConnection { @@ -1154,7 +1133,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ on(type: 'netAvailable', callback: Callback): void; @@ -1171,8 +1150,7 @@ declare namespace connection { * @param { 'netBlockStatusChange' } type - Indicates Event name. * @param { Callback } callback - the callback used to return the result. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ on(type: 'netBlockStatusChange', callback: Callback): void; @@ -1198,7 +1176,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ on(type: 'netCapabilitiesChange', callback: Callback): void; @@ -1215,7 +1193,7 @@ declare namespace connection { * @param { 'netConnectionPropertiesChange' } type - Indicates Event name. * @param { Callback } callback - the callback used to return the result. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ on(type: 'netConnectionPropertiesChange', callback: Callback): void; @@ -1242,8 +1220,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ on(type: 'netLost', callback: Callback): void; @@ -1269,8 +1246,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ on(type: 'netUnavailable', callback: Callback): void; @@ -1314,7 +1290,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ register(callback: AsyncCallback): void; @@ -1365,7 +1341,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ unregister(callback: AsyncCallback): void; @@ -1382,7 +1358,7 @@ declare namespace connection { * @interface NetSpecifier * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetSpecifier { @@ -1397,7 +1373,7 @@ declare namespace connection { * @type {NetCapabilities} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ netCapabilities: NetCapabilities; @@ -1413,7 +1389,7 @@ declare namespace connection { * @type {?string} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ bearerPrivateIdentifier?: string; @@ -1432,7 +1408,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetCapabilityInfo { @@ -1449,7 +1425,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ netHandle: NetHandle; @@ -1467,7 +1443,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ netCap: NetCapabilities; @@ -1492,7 +1468,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1': '11', '1.2': '20'} + * @since arkts{'1.1': '11', '1.2': '20'} * @arkts 1.1&1.2 */ export interface NetHandle { @@ -1515,7 +1491,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ netId: int; @@ -1575,8 +1551,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ getAddressesByName(host: string, callback: AsyncCallback>): void; @@ -1605,8 +1580,7 @@ declare namespace connection { * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ getAddressesByName(host: string): Promise>; @@ -1621,8 +1595,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ getAddressByName(host: string, callback: AsyncCallback): void; @@ -1637,8 +1610,7 @@ declare namespace connection { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} - * @arkts 1.1&1.2 + * @since 8 */ getAddressByName(host: string): Promise; } @@ -1662,7 +1634,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetCapabilities { @@ -1670,7 +1642,7 @@ declare namespace connection { * Uplink (device-to-network) bandwidth. * @type {?int} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ linkUpBandwidthKbps?: int; @@ -1679,7 +1651,7 @@ declare namespace connection { * Downstream (network-to-device) bandwidth. * @type {?int} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ linkDownBandwidthKbps?: int; @@ -1695,7 +1667,7 @@ declare namespace connection { * @type {?Array} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ networkCap?: Array; @@ -1719,7 +1691,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ bearerTypes: Array; @@ -1729,7 +1701,7 @@ declare namespace connection { * Get information about network connections. * @interface NetConnectionPropertyInfo * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetConnectionPropertyInfo { @@ -1737,7 +1709,7 @@ declare namespace connection { * Defines the handle of the data network. * @type { NetHandle } * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ netHandle: NetHandle; @@ -1745,7 +1717,7 @@ declare namespace connection { * Defines the network connection properties. * @type { ConnectionProperties } * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ connectionProperties: ConnectionProperties; @@ -1755,7 +1727,7 @@ declare namespace connection { * Get network status information. * @interface NetBlockStatusInfo * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetBlockStatusInfo { @@ -1763,7 +1735,7 @@ declare namespace connection { * Defines the handle of the data network. * @type { NetHandle } * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ netHandle: NetHandle; @@ -1771,7 +1743,7 @@ declare namespace connection { * Check whether the current state is blocked. * @type { boolean } * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ blocked: boolean; @@ -1779,16 +1751,16 @@ declare namespace connection { /** * Defines the network capability. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetManager.Core * @since 8 */ /** * Defines the network capability. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export enum NetCap { @@ -1801,7 +1773,7 @@ declare namespace connection { * Indicates that the network can access the carrier's MMSC to send and receive multimedia messages. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NET_CAPABILITY_MMS = 0, @@ -1815,7 +1787,7 @@ declare namespace connection { * Indicates that the network traffic is not metered. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NET_CAPABILITY_NOT_METERED = 11, @@ -1829,7 +1801,7 @@ declare namespace connection { * Indicates that the network can access the Internet. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NET_CAPABILITY_INTERNET = 12, @@ -1843,7 +1815,7 @@ declare namespace connection { * Indicates that the network does not use a VPN. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NET_CAPABILITY_NOT_VPN = 15, @@ -1857,7 +1829,7 @@ declare namespace connection { * Indicates that the network is available. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NET_CAPABILITY_VALIDATED = 16, @@ -1865,7 +1837,7 @@ declare namespace connection { * Indicates that the network is portal. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ NET_CAPABILITY_PORTAL = 17, @@ -1874,7 +1846,7 @@ declare namespace connection { * Indicates that the network is checking connectivity. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ NET_CAPABILITY_CHECKING_CONNECTIVITY = 31 @@ -1882,24 +1854,24 @@ declare namespace connection { /** * Enumerates network types. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetManager.Core * @since 8 */ /** * Enumerates network types. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @since 10 */ /** * Enumerates network types. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export enum NetBearType { @@ -1919,7 +1891,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ BEARER_CELLULAR = 0, @@ -1940,7 +1912,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ BEARER_WIFI = 1, @@ -1950,8 +1922,7 @@ declare namespace connection { * @syscap SystemCapability.Communication.NetManager.Core * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ BEARER_BLUETOOTH = 2, @@ -1964,7 +1935,7 @@ declare namespace connection { * Indicates that the network is an Ethernet network. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ BEARER_ETHERNET = 3, @@ -1972,7 +1943,7 @@ declare namespace connection { /** * Indicates that the network is based on a VPN network. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ BEARER_VPN = 4, @@ -1982,7 +1953,7 @@ declare namespace connection { * Defines the network connection properties. * @interface ConnectionProperties * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ export interface ConnectionProperties { @@ -1990,7 +1961,7 @@ declare namespace connection { * Network card name. * @type {string} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ interfaceName: string; @@ -1998,7 +1969,7 @@ declare namespace connection { * Domain. The default value is "". * @type {string} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ domains: string; @@ -2006,7 +1977,7 @@ declare namespace connection { * Link information. * @type {Array} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ linkAddresses: Array; @@ -2015,7 +1986,7 @@ declare namespace connection { * Network address, refer to [NetAddress]. * @type {Array} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ dnses: Array; @@ -2024,7 +1995,7 @@ declare namespace connection { * Routing information. * @type {Array} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ routes: Array; @@ -2033,7 +2004,7 @@ declare namespace connection { * Maximum transmission unit. * @type {int} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ mtu: int; @@ -2043,7 +2014,7 @@ declare namespace connection { * Defines network route information. * @interface RouteInfo * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ export interface RouteInfo { @@ -2059,7 +2030,7 @@ declare namespace connection { * Destination Address * @type {LinkAddress} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ destination: LinkAddress; @@ -2068,7 +2039,7 @@ declare namespace connection { * Gateway address. * @type {NetAddress} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ gateway: NetAddress; @@ -2077,7 +2048,7 @@ declare namespace connection { * Whether a gateway is present. * @type {boolean} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ hasGateway: boolean; @@ -2086,7 +2057,7 @@ declare namespace connection { * Whether the route is the default route. * @type {boolean} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ isDefaultRoute: boolean; @@ -2096,7 +2067,7 @@ declare namespace connection { * Defines network link information. * @interface LinkAddress * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ export interface LinkAddress { @@ -2104,7 +2075,7 @@ declare namespace connection { * Link address. * @type {NetAddress} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ address: NetAddress; @@ -2112,7 +2083,7 @@ declare namespace connection { * The length of the link address prefix. * @type {int} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'8','1.2':'20'} + * @since arkts{'1.1':'8','1.2':'20'} * @arkts 1.1&1.2 */ prefixLength: int; @@ -2129,7 +2100,7 @@ declare namespace connection { * @interface NetAddress * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetAddress { @@ -2144,7 +2115,7 @@ declare namespace connection { * @type {string} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ address: string; @@ -2160,7 +2131,7 @@ declare namespace connection { * @type {?int} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ family?: int; @@ -2176,7 +2147,7 @@ declare namespace connection { * @type {?int} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ port?: int; @@ -2193,7 +2164,7 @@ declare namespace connection { * @interface HttpProxy * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface HttpProxy { @@ -2208,7 +2179,7 @@ declare namespace connection { * @type {string} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ host: string; @@ -2224,7 +2195,7 @@ declare namespace connection { * @type {int} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ port: int; @@ -2233,7 +2204,7 @@ declare namespace connection { * Http proxy username. * @type {?string} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ username?: string; @@ -2242,7 +2213,7 @@ declare namespace connection { * Http proxy password. * @type {?string} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ password?: string; @@ -2258,7 +2229,7 @@ declare namespace connection { * @type {Array} * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ exclusionList: Array; diff --git a/api/@ohos.net.http.d.ts b/api/@ohos.net.http.d.ts index fbb2c980064be5e97be2fb655c40e10bf2df20fc..f4537f343a7f06059ce8e6653c8aefcd4df6b0e9 100644 --- a/api/@ohos.net.http.d.ts +++ b/api/@ohos.net.http.d.ts @@ -40,7 +40,7 @@ import type connection from './@ohos.net.connection'; * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ declare namespace http { @@ -61,7 +61,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ type HttpProxy = connection.HttpProxy; @@ -85,7 +85,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function createHttp(): HttpRequest; @@ -94,31 +94,27 @@ declare namespace http { * Enum for Address Family * @enum {string} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ export enum AddressFamily { /** * Default, can use addresses of all IP versions that your system allows. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ DEFAULT = 'CURL_IPRESOLVE_WHATEVER', /** * ONLYV4 Uses only IPv4 addresses. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ONLY_V4 = 'CURL_IPRESOLVE_V4', /** * ONLYV6 Uses only IPv6 addresses. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ ONLY_V6 = 'CURL_IPRESOLVE_V6' } @@ -142,7 +138,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface HttpRequestOptions { @@ -165,7 +161,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ method?: RequestMethod; @@ -192,7 +188,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ extraData?: string | Object | ArrayBuffer; @@ -216,7 +212,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ expectDataType?: HttpDataType; @@ -240,7 +236,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ usingCache?: boolean; @@ -264,7 +260,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ priority?: int; @@ -288,7 +284,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ header?: Object; @@ -312,7 +308,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ readTimeout?: int; @@ -336,7 +332,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ connectTimeout?: int; @@ -360,7 +356,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ usingProtocol?: HttpProtocol; @@ -387,13 +383,13 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ usingProxy?: boolean | HttpProxy; /** - * If this parameter is set, the system will use ca path specified by user, or else use preset ca by the system. + * If this parameter is set, the system will use ca path specified by user, or else use preset ca by the system. * @type {?string} * @syscap SystemCapability.Communication.NetStack * @since 10 @@ -411,8 +407,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ caPath?: string; @@ -420,7 +415,7 @@ declare namespace http { * Used to set to uploading or downloading the start bytes. The default value is 0. * HTTP standard (RFC 7233 section 3.1) allows servers to ignore range requests. * For HTTP PUT uploads this option should not be used, since it may conflict with other options. - * @type {?int} + * @type {?long} * @syscap SystemCapability.Communication.NetStack * @since 11 */ @@ -428,19 +423,18 @@ declare namespace http { * Used to set to uploading or downloading the start bytes. The default value is 0. * HTTP standard (RFC 7233 section 3.1) allows servers to ignore range requests. * For HTTP PUT uploads this option should not be used, since it may conflict with other options. - * @type {?int} + * @type {?long} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - resumeFrom?: int; + resumeFrom?: long; /** * Used to set to uploading or downloading the end bytes. Translate to the end if not set. * HTTP standard (RFC 7233 section 3.1) allows servers to ignore range requests. * For HTTP PUT uploads this option should not be used, since it may conflict with other options. - * @type {?int} + * @type {?long} * @syscap SystemCapability.Communication.NetStack * @since 11 */ @@ -448,13 +442,12 @@ declare namespace http { * Used to set to uploading or downloading the end bytes. Translate to the end if not set. * HTTP standard (RFC 7233 section 3.1) allows servers to ignore range requests. * For HTTP PUT uploads this option should not be used, since it may conflict with other options. - * @type {?int} + * @type {?long} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - resumeTo?: int; + resumeTo?: long; /** * Support the application to pass in client certificates, allowing the server to verify the client's identity. @@ -467,7 +460,7 @@ declare namespace http { * @type {?ClientCert} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ clientCert?: ClientCert; @@ -487,8 +480,7 @@ declare namespace http { * @type {?string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dnsOverHttps?: string; @@ -507,8 +499,7 @@ declare namespace http { * @type {?Array} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ dnsServers?: Array; @@ -525,8 +516,7 @@ declare namespace http { * @type {?int} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ maxLimit?: int; @@ -545,7 +535,7 @@ declare namespace http { * @type {?Array} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ multiFormDataList?: Array; @@ -555,8 +545,7 @@ declare namespace http { * {@link CertificatePinning.publicKeyHash}, request will fail. * @type {?(CertificatePinning | CertificatePinning[])} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ certificatePinning?: CertificatePinning | CertificatePinning[]; @@ -565,8 +554,7 @@ declare namespace http { * @type {?RemoteValidation} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ remoteValidation?: RemoteValidation; @@ -575,8 +563,7 @@ declare namespace http { * @type {?TlsOptions} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ tlsOptions?: TlsOptions; @@ -585,8 +572,7 @@ declare namespace http { * @type {?ServerAuthentication} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ serverAuthentication?: ServerAuthentication; @@ -594,8 +580,7 @@ declare namespace http { * Address family option. * @type {?AddressFamily} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ addressFamily?: AddressFamily; } @@ -605,7 +590,7 @@ declare namespace http { * @typedef ServerAuthentication * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export interface ServerAuthentication { @@ -614,7 +599,7 @@ declare namespace http { * @type {Credential} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ credential: Credential; @@ -623,7 +608,7 @@ declare namespace http { * @type {?AuthenticationType} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ authenticationType?: AuthenticationType; @@ -636,7 +621,7 @@ declare namespace http { * @typedef {'system' | TlsConfig} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type TlsOptions = 'system' | TlsConfig; @@ -646,7 +631,7 @@ declare namespace http { * @typedef {'system' | 'skip'} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type RemoteValidation = 'system' | 'skip'; @@ -656,7 +641,7 @@ declare namespace http { * @typedef {'basic' | 'ntlm' | 'digest'} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type AuthenticationType = 'basic' | 'ntlm' | 'digest'; @@ -666,7 +651,7 @@ declare namespace http { * @typedef Credential * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export interface Credential { @@ -675,7 +660,7 @@ declare namespace http { * @type {string} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ username: string; @@ -684,7 +669,7 @@ declare namespace http { * @type {string} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ password: string; @@ -695,7 +680,7 @@ declare namespace http { * @typedef TlsConfig * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export interface TlsConfig { @@ -704,7 +689,7 @@ declare namespace http { * @type {TlsVersion} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ tlsVersionMin: TlsVersion; @@ -713,7 +698,7 @@ declare namespace http { * @type {TlsVersion} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ tlsVersionMax: TlsVersion; @@ -722,7 +707,7 @@ declare namespace http { * @type {?CipherSuite[]} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ cipherSuites?: CipherSuite[]; @@ -734,7 +719,7 @@ declare namespace http { * @typedef {'TLS_AES_128_GCM_SHA256' | 'TLS_AES_256_GCM_SHA384' | 'TLS_CHACHA20_POLY1305_SHA256'} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type TlsV13SpecificCipherSuite = 'TLS_AES_128_GCM_SHA256' | 'TLS_AES_256_GCM_SHA384' | 'TLS_CHACHA20_POLY1305_SHA256'; @@ -744,7 +729,7 @@ declare namespace http { * @typedef {'TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256' | 'TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256' | 'TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384' | 'TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384' | 'TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256' | 'TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256' | 'TLS_RSA_WITH_AES_128_GCM_SHA256' | 'TLS_RSA_WITH_AES_256_GCM_SHA384'} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type TlsV12SpecificCipherSuite = 'TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256' | 'TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256' | 'TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384' | 'TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384' | 'TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256' | 'TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256' | 'TLS_RSA_WITH_AES_128_GCM_SHA256' | 'TLS_RSA_WITH_AES_256_GCM_SHA384'; @@ -754,7 +739,7 @@ declare namespace http { * @typedef {'TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA' | 'TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA' | 'TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA' | 'TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA' | 'TLS_RSA_WITH_AES_128_CBC_SHA' | 'TLS_RSA_WITH_AES_256_CBC_SHA' | 'TLS_RSA_WITH_3DES_EDE_CBC_SHA'} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type TlsV10SpecificCipherSuite = 'TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA' | 'TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA' | 'TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA' | 'TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA' | 'TLS_RSA_WITH_AES_128_CBC_SHA' | 'TLS_RSA_WITH_AES_256_CBC_SHA' | 'TLS_RSA_WITH_3DES_EDE_CBC_SHA'; @@ -764,7 +749,7 @@ declare namespace http { * @typedef {TlsV13CipherSuite} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type CipherSuite = TlsV13CipherSuite; @@ -774,7 +759,7 @@ declare namespace http { * @typedef {TlsV12CipherSuite | TlsV13SpecificCipherSuite} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type TlsV13CipherSuite = TlsV12CipherSuite | TlsV13SpecificCipherSuite; @@ -784,7 +769,7 @@ declare namespace http { * @typedef {TlsV11CipherSuite | TlsV12SpecificCipherSuite} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type TlsV12CipherSuite = TlsV11CipherSuite | TlsV12SpecificCipherSuite; @@ -794,7 +779,7 @@ declare namespace http { * @typedef {TlsV10CipherSuite} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type TlsV11CipherSuite = TlsV10CipherSuite; @@ -804,17 +789,17 @@ declare namespace http { * @typedef {TlsV10SpecificCipherSuite} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export type TlsV10CipherSuite = TlsV10SpecificCipherSuite; /** * Enum for Tls version - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ export enum TlsVersion { @@ -822,7 +807,7 @@ declare namespace http { * Tls version 1.0 * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ TLS_V_1_0 = 4, @@ -831,7 +816,7 @@ declare namespace http { * Tls version 1.1 * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ TLS_V_1_1 = 5, @@ -840,7 +825,7 @@ declare namespace http { * Tls version 1.2 * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ TLS_V_1_2 = 6, @@ -849,7 +834,7 @@ declare namespace http { * Tls version 1.3 * @syscap SystemCapability.Communication.NetStack * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ TLS_V_1_3 = 7 @@ -866,7 +851,7 @@ declare namespace http { * @interface MultiFormData * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ export interface MultiFormData { @@ -881,7 +866,7 @@ declare namespace http { * @type {string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ name: string; @@ -897,7 +882,7 @@ declare namespace http { * @type {string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ contentType: string; @@ -913,7 +898,7 @@ declare namespace http { * @type {?string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ remoteFileName?: string; @@ -929,7 +914,7 @@ declare namespace http { * @type {?(string | Object | ArrayBuffer)} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ data?: string | Object | ArrayBuffer; @@ -951,7 +936,7 @@ declare namespace http { * @type {?string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ filePath?: string; @@ -968,7 +953,7 @@ declare namespace http { * @enum {string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ export enum CertType { @@ -981,7 +966,7 @@ declare namespace http { * PEM format certificate * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ PEM = 'PEM', @@ -995,7 +980,7 @@ declare namespace http { * DER format certificate * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ DER = 'DER', @@ -1009,7 +994,7 @@ declare namespace http { * P12 format certificate * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ P12 = 'P12' @@ -1028,7 +1013,7 @@ declare namespace http { * @interface ClientCert * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ export interface ClientCert { @@ -1043,7 +1028,7 @@ declare namespace http { * @type {string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ certPath: string; @@ -1059,7 +1044,7 @@ declare namespace http { * @type {?CertType} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ certType?: CertType; @@ -1075,7 +1060,7 @@ declare namespace http { * @type {string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ keyPath: string; @@ -1091,7 +1076,7 @@ declare namespace http { * @type {?string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ keyPassword?: string; @@ -1101,24 +1086,21 @@ declare namespace http { * Certificate pinning option. * @interface CertificatePinning * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface CertificatePinning { /** * Public key hash. * @type {string} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ publicKeyHash: string; /** * Certificate public key hash algorithm. * @type {'SHA-256'} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ hashAlgorithm: 'SHA-256'; } @@ -1145,7 +1127,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface HttpRequest { @@ -1153,7 +1135,7 @@ declare namespace http { * Initiates an HTTP request to a given URL. * @permission ohos.permission.INTERNET * @param { string } url - URL for initiating an HTTP request. - * @param { AsyncCallback } callback - the callback of request. + * @param { AsyncCallback } callback - the callback of request. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2300001 - Unsupported protocol. @@ -1352,7 +1334,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ request(url: string, callback: AsyncCallback): void; @@ -1565,7 +1547,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ request(url: string, options: HttpRequestOptions, callback: AsyncCallback): void; @@ -1575,7 +1557,7 @@ declare namespace http { * @permission ohos.permission.INTERNET * @param { string } url - URL for initiating an HTTP request. * @param { HttpRequestOptions } [options] - Optional parameters {@link HttpRequestOptions}. - * @returns { Promise } The promise returned by the function. + * @returns { Promise } The promise returned by the function. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2300001 - Unsupported protocol. @@ -1615,7 +1597,7 @@ declare namespace http { * @permission ohos.permission.INTERNET * @param { string } url - URL for initiating an HTTP request. * @param { HttpRequestOptions } [options] - Optional parameters {@link HttpRequestOptions}. - * @returns { Promise } The promise returned by the function. + * @returns { Promise } The promise returned by the function. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2300001 - Unsupported protocol. @@ -1778,7 +1760,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} + * @since arkts{'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 */ request(url: string, options?: HttpRequestOptions): Promise; @@ -1788,7 +1770,7 @@ declare namespace http { * @permission ohos.permission.INTERNET * @param { string } url - URL for initiating an HTTP request. * @param { AsyncCallback } callback - Returns the callback of requestInStream {@link ResponseCode}, - * should use on_headersReceive and on_dataReceive to get http response. + * should use on_headersReceive and on_dataReceive to get http response. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2300001 - Unsupported protocol. @@ -1828,7 +1810,7 @@ declare namespace http { * @permission ohos.permission.INTERNET * @param { string } url - URL for initiating an HTTP request. * @param { AsyncCallback } callback - Returns the callback of requestInStream {@link ResponseCode}, - * should use on_headersReceive and on_dataReceive to get http response. + * should use on_headersReceive and on_dataReceive to get http response. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2300001 - Unsupported protocol. @@ -1869,7 +1851,7 @@ declare namespace http { * @permission ohos.permission.INTERNET * @param { string } url - URL for initiating an HTTP request. * @param { AsyncCallback } callback - Returns the callback of requestInStream {@link ResponseCode}, - * should use on_headersReceive and on_dataReceive to get http response. + * should use on_headersReceive and on_dataReceive to get http response. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2300001 - Unsupported protocol. @@ -1911,7 +1893,7 @@ declare namespace http { * @permission ohos.permission.INTERNET * @param { string } url - URL for initiating an HTTP request. * @param { AsyncCallback } callback - Returns the callback of requestInStream {@link ResponseCode}, - * should use on_headersReceive and on_dataReceive to get http response. + * should use on_headersReceive and on_dataReceive to get http response. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 2300001 - Unsupported protocol. @@ -1948,8 +1930,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ requestInStream(url: string, callback: AsyncCallback): void; @@ -2080,7 +2061,7 @@ declare namespace http { * Initiates an HTTP request to a given URL, applicable to scenarios where http response supports streaming. * @permission ohos.permission.INTERNET * @param { string } url - URL for initiating an HTTP request. - * @param { HttpRequestOptions } option - Optional parameters {@link HttpRequestOptions}. + * @param { HttpRequestOptions } options - Optional parameters {@link HttpRequestOptions}. * @param { AsyncCallback } callback - the callback of requestInStream. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 201 - Permission denied. @@ -2118,10 +2099,9 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ - requestInStream(url: string, option: HttpRequestOptions, callback: AsyncCallback): void; + requestInStream(url: string, options: HttpRequestOptions, callback: AsyncCallback): void; /** * Initiates an HTTP request to a given URL, applicable to scenarios where http response supports streaming. @@ -2288,8 +2268,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ requestInStream(url: string, options?: HttpRequestOptions): Promise; @@ -2309,7 +2288,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ destroy(): void; @@ -2656,7 +2635,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export enum RequestMethod { @@ -2676,7 +2655,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ OPTIONS = "OPTIONS", @@ -2697,7 +2676,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ GET = "GET", @@ -2718,7 +2697,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ HEAD = "HEAD", @@ -2739,7 +2718,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ POST = "POST", @@ -2760,7 +2739,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ PUT = "PUT", @@ -2781,7 +2760,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ DELETE = "DELETE", @@ -2802,7 +2781,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ TRACE = "TRACE", @@ -2823,7 +2802,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ CONNECT = "CONNECT" @@ -2831,24 +2810,24 @@ declare namespace http { /** * Enumerates the response codes for an HTTP request. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetStack * @since 6 */ /** * Enumerates the response codes for an HTTP request. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetStack * @crossplatform * @since 10 */ /** * Enumerates the response codes for an HTTP request. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export enum ResponseCode { @@ -2868,7 +2847,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ OK = 200, @@ -2889,7 +2868,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ CREATED, @@ -2910,7 +2889,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ ACCEPTED, @@ -2931,7 +2910,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NOT_AUTHORITATIVE, @@ -2952,7 +2931,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NO_CONTENT, @@ -2973,7 +2952,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ RESET, @@ -2994,7 +2973,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ PARTIAL, @@ -3015,7 +2994,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ MULT_CHOICE = 300, @@ -3039,7 +3018,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ MOVED_PERM, @@ -3060,7 +3039,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ MOVED_TEMP, @@ -3081,7 +3060,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ SEE_OTHER, @@ -3102,7 +3081,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NOT_MODIFIED, @@ -3123,7 +3102,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ USE_PROXY, @@ -3144,7 +3123,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ BAD_REQUEST = 400, @@ -3165,7 +3144,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ UNAUTHORIZED, @@ -3186,7 +3165,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ PAYMENT_REQUIRED, @@ -3207,7 +3186,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ FORBIDDEN, @@ -3228,7 +3207,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NOT_FOUND, @@ -3249,7 +3228,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ BAD_METHOD, @@ -3270,7 +3249,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NOT_ACCEPTABLE, @@ -3291,7 +3270,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ PROXY_AUTH, @@ -3312,7 +3291,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ CLIENT_TIMEOUT, @@ -3336,7 +3315,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ CONFLICT, @@ -3357,7 +3336,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ GONE, @@ -3378,7 +3357,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ LENGTH_REQUIRED, @@ -3399,7 +3378,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ PRECON_FAILED, @@ -3420,7 +3399,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ ENTITY_TOO_LARGE, @@ -3441,7 +3420,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ REQ_TOO_LONG, @@ -3462,7 +3441,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ UNSUPPORTED_TYPE, @@ -3472,8 +3451,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ RANGE_NOT_SATISFIABLE, @@ -3493,7 +3471,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ INTERNAL_ERROR = 500, @@ -3514,7 +3492,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ NOT_IMPLEMENTED, @@ -3535,7 +3513,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ BAD_GATEWAY, @@ -3556,7 +3534,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ UNAVAILABLE, @@ -3577,7 +3555,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ GATEWAY_TIMEOUT, @@ -3598,7 +3576,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ VERSION @@ -3623,7 +3601,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ @@ -3644,7 +3622,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ HTTP1_1, @@ -3665,7 +3643,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ HTTP2, @@ -3683,7 +3661,7 @@ declare namespace http { * Fallback to http2 or http1.1 if needed. * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ HTTP3 @@ -3691,24 +3669,24 @@ declare namespace http { /** * Indicates the type of the returned data. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetStack * @since 9 */ /** * Indicates the type of the returned data. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetStack * @crossplatform * @since 10 */ /** * Indicates the type of the returned data. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export enum HttpDataType { @@ -3728,7 +3706,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ STRING, @@ -3749,7 +3727,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ OBJECT = 1, @@ -3770,7 +3748,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ ARRAY_BUFFER = 2 @@ -3795,7 +3773,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface HttpResponse { @@ -3821,7 +3799,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ result: string | Object | ArrayBuffer; @@ -3851,7 +3829,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ resultType: HttpDataType; @@ -3875,7 +3853,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ responseCode: ResponseCode | int; @@ -3899,7 +3877,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ header: Object; @@ -3923,7 +3901,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ cookies: string; @@ -3939,7 +3917,7 @@ declare namespace http { * @type {PerformanceTiming} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ performanceTiming: PerformanceTiming; @@ -3956,169 +3934,169 @@ declare namespace http { * @interface PerformanceTiming * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ export interface PerformanceTiming { /** * Time taken from startup to DNS resolution completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from startup to DNS resolution completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - dnsTiming: int; + dnsTiming: double; /** * Time taken from startup to TCP connection completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from startup to TCP connection completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - tcpTiming: int; + tcpTiming: double; /** * Time taken from startup to TLS connection completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from startup to TLS connection completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - tlsTiming: int; + tlsTiming: double; /** * Time taken from startup to start sending the first byte, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from startup to start sending the first byte, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - firstSendTiming: int; + firstSendTiming: double; /** * Time taken from startup to receiving the first byte, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from startup to receiving the first byte, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - firstReceiveTiming: int; + firstReceiveTiming: double; /** * Time taken from startup to the completion of the request, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from startup to the completion of the request, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - totalFinishTiming: int; + totalFinishTiming: double; /** * Time taken from startup to completion of all redirection steps, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from startup to completion of all redirection steps, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - redirectTiming: int; + redirectTiming: double; /** * Time taken from HTTP request to header completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from HTTP request to header completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - responseHeaderTiming: int; + responseHeaderTiming: double; /** * Time taken from HTTP Request to body completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from HTTP Request to body completion, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - responseBodyTiming: int; + responseBodyTiming: double; /** * Time taken from HTTP Request to callback to the application, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @since 11 */ /** * Time taken from HTTP Request to callback to the application, in milliseconds. - * @type {int} + * @type {double} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ - totalTiming: int; + totalTiming: double; } /** @@ -4140,8 +4118,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ export interface DataReceiveProgressInfo { /** @@ -4163,8 +4140,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ receiveSize: int; /** @@ -4186,8 +4162,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ totalSize: int; } @@ -4233,7 +4208,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} + * @since arkts{'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ sendSize: int; @@ -4256,7 +4231,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} + * @since arkts{'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ totalSize: int; @@ -4284,7 +4259,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function createHttpResponseCache(cacheSize?: int): HttpResponseCache; @@ -4308,7 +4283,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface HttpResponseCache { @@ -4331,7 +4306,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ flush(callback: AsyncCallback): void; @@ -4355,8 +4330,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ flush(): Promise; @@ -4379,7 +4353,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ delete(callback: AsyncCallback): void; @@ -4403,7 +4377,7 @@ declare namespace http { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ delete(): Promise; diff --git a/api/@ohos.net.networkSecurity.d.ts b/api/@ohos.net.networkSecurity.d.ts index 3db7aabf6d5d8cc41995d6a182bdfd5fb165c644..b91598e6df76689e549cbd7410389dbaec66cdd1 100644 --- a/api/@ohos.net.networkSecurity.d.ts +++ b/api/@ohos.net.networkSecurity.d.ts @@ -24,22 +24,22 @@ import type { AsyncCallback } from './@ohos.base'; * Provides networkSecurity related APIs. * @namespace networkSecurity * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ declare namespace networkSecurity { /** * Defines the certificate type. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export enum CertType { /** * PEM type certificate. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ CERT_TYPE_PEM = 0, @@ -47,7 +47,7 @@ declare namespace networkSecurity { /** * DER type certificate. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ CERT_TYPE_DER = 1 @@ -57,7 +57,7 @@ declare namespace networkSecurity { * Define the certificate content. * @interface CertBlob * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface CertBlob { @@ -65,7 +65,7 @@ declare namespace networkSecurity { * Certificate type. * @type { CertType } * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ type: CertType; @@ -74,7 +74,7 @@ declare namespace networkSecurity { * Certificate data. * @type {string | ArrayBuffer} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ data: string | ArrayBuffer; @@ -130,7 +130,7 @@ declare namespace networkSecurity { * @throws { BusinessError } 2305027 - Certificate is untrusted. * @throws { BusinessError } 2305069 - Invalid certificate verification context. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ export function certVerification(cert: CertBlob, caCert?: CertBlob): Promise; @@ -139,7 +139,7 @@ declare namespace networkSecurity { * Certificate verification to the server. * @param { CertBlob } cert - Certificates to be verified. * @param { CertBlob } [caCert] - Incoming custom CA cert. - * @returns { number } Returns 0 if verify of certification from server succeed, else verify failed. + * @returns { int } Returns 0 if verify of certification from server succeed, else verify failed. * @throws { BusinessError } 401 - Parameter error. * @throws { BusinessError } 2305001 - Unspecified error. * @throws { BusinessError } 2305002 - Unable to get issuer certificate. @@ -183,7 +183,7 @@ declare namespace networkSecurity { * @throws { BusinessError } 2305027 - Certificate is untrusted. * @throws { BusinessError } 2305069 - Invalid certificate verification context. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ export function certVerificationSync(cert: CertBlob, caCert?: CertBlob): int; @@ -195,8 +195,7 @@ declare namespace networkSecurity { * @returns { boolean } Returns true if the Cleartext traffic is permitted, else returns false. * @throws { BusinessError } 201 - Permission denied. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ export function isCleartextPermitted(): boolean; @@ -208,8 +207,7 @@ declare namespace networkSecurity { * @returns { boolean } Returns true if the Cleartext traffic is permitted, else returns false. * @throws { BusinessError } 201 - Permission denied. * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ export function isCleartextPermittedByHostName(hostName: string): boolean; } diff --git a/api/@ohos.net.sharing.d.ts b/api/@ohos.net.sharing.d.ts index c341206cef817c8b7a1030b59694e7506864724b..bb3f87353e089aa48aea2b82296a46fd7aa749be 100644 --- a/api/@ohos.net.sharing.d.ts +++ b/api/@ohos.net.sharing.d.ts @@ -25,7 +25,7 @@ import type connection from './@ohos.net.connection'; * Provides network sharing related interfaces. * @namespace sharing * @syscap SystemCapability.Communication.NetManager.NetSharing - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ declare namespace sharing { @@ -33,7 +33,7 @@ declare namespace sharing { * Get the handle of the data network. * @typedef { connection.NetHandle } * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ type NetHandle = connection.NetHandle; @@ -50,7 +50,7 @@ declare namespace sharing { * @throws { BusinessError } 2202011 - Cannot get network sharing configuration. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function isSharingSupported(callback: AsyncCallback): void; @@ -66,7 +66,7 @@ declare namespace sharing { * @throws { BusinessError } 2202011 - Cannot get network sharing configuration. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function isSharingSupported(): Promise; @@ -83,7 +83,7 @@ declare namespace sharing { * @throws { BusinessError } 2202011 - Cannot get network sharing configuration. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function isSharing(callback: AsyncCallback): void; @@ -99,7 +99,7 @@ declare namespace sharing { * @throws { BusinessError } 2202011 - Cannot get network sharing configuration. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function isSharing(): Promise; @@ -122,7 +122,7 @@ declare namespace sharing { * @throws { BusinessError } 2202011 - Cannot get network sharing configuration. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function startSharing(type: SharingIfaceType, callback: AsyncCallback): void; @@ -145,7 +145,7 @@ declare namespace sharing { * @throws { BusinessError } 2202011 - Cannot get network sharing configuration. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function startSharing(type: SharingIfaceType): Promise; @@ -167,7 +167,7 @@ declare namespace sharing { * @throws { BusinessError } 2202011 - Cannot get network sharing configuration. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function stopSharing(type: SharingIfaceType, callback: AsyncCallback): void; @@ -189,7 +189,7 @@ declare namespace sharing { * @throws { BusinessError } 2202011 - Cannot get network sharing configuration. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function stopSharing(type: SharingIfaceType): Promise; @@ -205,7 +205,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getStatsRxBytes(callback: AsyncCallback): void; @@ -220,7 +220,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getStatsRxBytes(): Promise; @@ -236,7 +236,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getStatsTxBytes(callback: AsyncCallback): void; @@ -251,7 +251,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getStatsTxBytes(): Promise; @@ -267,7 +267,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getStatsTotalBytes(callback: AsyncCallback): void; @@ -282,7 +282,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getStatsTotalBytes(): Promise; @@ -300,7 +300,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getSharingIfaces(state: SharingIfaceState, callback: AsyncCallback>): void; @@ -318,7 +318,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getSharingIfaces(state: SharingIfaceState): Promise>; @@ -336,7 +336,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getSharingState(type: SharingIfaceType, callback: AsyncCallback): void; @@ -354,7 +354,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getSharingState(type: SharingIfaceType): Promise; @@ -372,7 +372,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getSharableRegexes(type: SharingIfaceType, callback: AsyncCallback>): void; @@ -390,7 +390,7 @@ declare namespace sharing { * @throws { BusinessError } 2200003 - System internal error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function getSharableRegexes(type: SharingIfaceType): Promise>; @@ -405,7 +405,7 @@ declare namespace sharing { * @throws { BusinessError } 401 - Parameter error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function on(type: 'sharingStateChange', callback: Callback): void; @@ -420,7 +420,7 @@ declare namespace sharing { * @throws { BusinessError } 401 - Parameter error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function off(type: 'sharingStateChange', callback?: Callback): void; @@ -447,7 +447,7 @@ declare namespace sharing { * @throws { BusinessError } 401 - Parameter error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function on(type: 'interfaceSharingStateChange', callback: Callback): void; @@ -474,7 +474,7 @@ declare namespace sharing { * @throws { BusinessError } 401 - Parameter error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ function off(type: 'interfaceSharingStateChange', callback?: Callback): void; @@ -489,7 +489,7 @@ declare namespace sharing { * @throws { BusinessError } 401 - Parameter error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function on(type: 'sharingUpstreamChange', callback: Callback): void; @@ -504,17 +504,17 @@ declare namespace sharing { * @throws { BusinessError } 401 - Parameter error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ function off(type: 'sharingUpstreamChange', callback?: Callback): void; /** * Enumerates the network sharing states of an NIC. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ export enum SharingIfaceState { @@ -522,7 +522,7 @@ declare namespace sharing { * Indicates the names of the NICs that are serving as network sharing. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ SHARING_NIC_SERVING = 1, @@ -531,7 +531,7 @@ declare namespace sharing { * Indicates the names of the NICs that can serve as network sharing. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ SHARING_NIC_CAN_SERVER = 2, @@ -540,7 +540,7 @@ declare namespace sharing { * Indicates the names of the NICs that serving error. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ SHARING_NIC_ERROR = 3 @@ -551,7 +551,7 @@ declare namespace sharing { * @interface InterfaceSharingStateInfo * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface InterfaceSharingStateInfo { @@ -560,7 +560,7 @@ declare namespace sharing { * @type { SharingIfaceType } * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ type: SharingIfaceType; @@ -569,7 +569,7 @@ declare namespace sharing { * @type { string } * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ iface: string; @@ -578,7 +578,7 @@ declare namespace sharing { * @type { SharingIfaceState } * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ state: SharingIfaceState; @@ -586,10 +586,10 @@ declare namespace sharing { /** * Enumerates the network sharing types of an NIC. - * @enum {number} + * @enum {int} * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ export enum SharingIfaceType { @@ -597,7 +597,7 @@ declare namespace sharing { * Network sharing type for Wi-Fi. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ SHARING_WIFI = 0, @@ -606,7 +606,7 @@ declare namespace sharing { * Network sharing type for USB. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ SHARING_USB = 1, @@ -615,7 +615,7 @@ declare namespace sharing { * Network sharing type for BLUETOOTH. * @syscap SystemCapability.Communication.NetManager.NetSharing * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'9','1.2':'20'} + * @since arkts{'1.1':'9','1.2':'20'} * @arkts 1.1&1.2 */ SHARING_BLUETOOTH = 2 diff --git a/api/@ohos.net.statistics.d.ts b/api/@ohos.net.statistics.d.ts index e6a4df6f445d0d45a633897a8f9eaad04a47dbf4..6a7a355e151f7b7baa130ae718db4019e05def19 100644 --- a/api/@ohos.net.statistics.d.ts +++ b/api/@ohos.net.statistics.d.ts @@ -32,14 +32,14 @@ import type connection from './@ohos.net.connection'; * @namespace statistics * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} + * @since arkts{'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ declare namespace statistics { /** * @typedef {connection.NetBearType} * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ type NetBearType = connection.NetBearType; @@ -55,7 +55,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @throws { BusinessError } 2103012 - Failed to obtain the NIC name. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getIfaceRxBytes(nic: string, callback: AsyncCallback): void; @@ -71,7 +71,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @throws { BusinessError } 2103012 - Failed to obtain the NIC name. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getIfaceRxBytes(nic: string): Promise; @@ -87,7 +87,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @throws { BusinessError } 2103012 - Failed to obtain the NIC name. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getIfaceTxBytes(nic: string, callback: AsyncCallback): void; @@ -103,7 +103,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @throws { BusinessError } 2103012 - Failed to obtain the NIC name. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getIfaceTxBytes(nic: string): Promise; @@ -117,8 +117,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @throws { BusinessError } 2103012 - Failed to obtain the NIC name. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getCellularRxBytes(callback: AsyncCallback): void; @@ -131,8 +130,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @throws { BusinessError } 2103012 - Failed to obtain the NIC name. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getCellularRxBytes(): Promise; @@ -145,8 +143,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @throws { BusinessError } 2103012 - Failed to obtain the NIC name. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getCellularTxBytes(callback: AsyncCallback): void; @@ -159,8 +156,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @throws { BusinessError } 2103012 - Failed to obtain the NIC name. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getCellularTxBytes(): Promise; @@ -183,7 +179,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} + * @since arkts{'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ function getAllRxBytes(callback: AsyncCallback): void; @@ -207,7 +203,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} + * @since arkts{'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ function getAllRxBytes(): Promise; @@ -231,7 +227,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} + * @since arkts{'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ function getAllTxBytes(callback: AsyncCallback): void; @@ -255,7 +251,7 @@ declare namespace statistics { * @throws { BusinessError } 2103011 - Failed to create a system map. * @syscap SystemCapability.Communication.NetManager.Core * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} + * @since arkts{'1.1':'15','1.2':'20'} * @arkts 1.1&1.2 */ function getAllTxBytes(): Promise; @@ -270,8 +266,7 @@ declare namespace statistics { * @throws { BusinessError } 2103005 - Failed to read the system map. * @throws { BusinessError } 2103011 - Failed to create a system map. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getUidRxBytes(uid: int, callback: AsyncCallback): void; @@ -285,8 +280,7 @@ declare namespace statistics { * @throws { BusinessError } 2103005 - Failed to read the system map. * @throws { BusinessError } 2103011 - Failed to create a system map. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getUidRxBytes(uid: int): Promise; @@ -300,8 +294,7 @@ declare namespace statistics { * @throws { BusinessError } 2103005 - Failed to read the system map. * @throws { BusinessError } 2103011 - Failed to create a system map. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getUidTxBytes(uid: int, callback: AsyncCallback): void; @@ -315,8 +308,7 @@ declare namespace statistics { * @throws { BusinessError } 2103005 - Failed to read the system map. * @throws { BusinessError } 2103011 - Failed to create a system map. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ function getUidTxBytes(uid: int): Promise; @@ -394,7 +386,7 @@ declare namespace statistics { * @throws { BusinessError } 2103017 - Failed to read the database. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getTrafficStatsByIface(ifaceInfo: IfaceInfo, callback: AsyncCallback): void; @@ -413,7 +405,7 @@ declare namespace statistics { * @throws { BusinessError } 2103017 - Failed to read the database. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getTrafficStatsByIface(ifaceInfo: IfaceInfo): Promise; @@ -432,7 +424,7 @@ declare namespace statistics { * @throws { BusinessError } 2103017 - Failed to read the database. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getTrafficStatsByUid(uidInfo: UidInfo, callback: AsyncCallback): void; @@ -451,7 +443,7 @@ declare namespace statistics { * @throws { BusinessError } 2103017 - Failed to read the database. * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ function getTrafficStatsByUid(uidInfo: UidInfo): Promise; @@ -465,8 +457,7 @@ declare namespace statistics { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function getSockfdRxBytes(sockfd: int, callback: AsyncCallback): void; @@ -479,8 +470,7 @@ declare namespace statistics { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function getSockfdRxBytes(sockfd: int): Promise; @@ -493,8 +483,7 @@ declare namespace statistics { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function getSockfdTxBytes(sockfd: int, callback: AsyncCallback): void; @@ -507,8 +496,7 @@ declare namespace statistics { * @throws { BusinessError } 2100002 - Failed to connect to the service. * @throws { BusinessError } 2100003 - System internal error. * @syscap SystemCapability.Communication.NetManager.Core - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ function getSockfdTxBytes(sockfd: int): Promise; @@ -517,7 +505,7 @@ declare namespace statistics { * @interface IfaceInfo * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ export interface IfaceInfo { @@ -526,7 +514,7 @@ declare namespace statistics { * @type {string} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ iface: string; @@ -536,7 +524,7 @@ declare namespace statistics { * @type {int} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ startTime: int; @@ -546,7 +534,7 @@ declare namespace statistics { * @type {int} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ endTime: int; @@ -557,7 +545,7 @@ declare namespace statistics { * @interface UidInfo * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ export interface UidInfo { @@ -566,7 +554,7 @@ declare namespace statistics { * @type {IfaceInfo} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ ifaceInfo: IfaceInfo; @@ -576,7 +564,7 @@ declare namespace statistics { * @type {int} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ uid: int; @@ -587,7 +575,7 @@ declare namespace statistics { * @interface NetStatsInfo * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetStatsInfo { @@ -596,7 +584,7 @@ declare namespace statistics { * @type {long} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ rxBytes: long; @@ -606,7 +594,7 @@ declare namespace statistics { * @type {long} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ txBytes: long; @@ -616,7 +604,7 @@ declare namespace statistics { * @type {long} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ rxPackets: long; @@ -626,7 +614,7 @@ declare namespace statistics { * @type {long} * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} + * @since arkts{'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ txPackets: long; @@ -637,7 +625,7 @@ declare namespace statistics { * @interface NetStatsChangeInfo * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetStatsChangeInfo { @@ -646,7 +634,7 @@ declare namespace statistics { * @type { string } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ iface: string; @@ -655,7 +643,7 @@ declare namespace statistics { * @type { ?int } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'11','1.2':'20'} + * @since arkts{'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ uid?: int; @@ -673,7 +661,7 @@ declare namespace statistics { * @type { int } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ startTime: int; @@ -682,7 +670,7 @@ declare namespace statistics { * @type { int } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ endTime: int; @@ -691,7 +679,7 @@ declare namespace statistics { * @type { NetStatsInfo } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ info: NetStatsInfo; @@ -712,7 +700,7 @@ declare namespace statistics { * @interface NetworkInfo * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ export interface NetworkInfo { @@ -721,7 +709,7 @@ declare namespace statistics { * @type { NetBearType } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ type: NetBearType; @@ -730,7 +718,7 @@ declare namespace statistics { * @type { int } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ startTime: int; @@ -739,7 +727,7 @@ declare namespace statistics { * @type { int } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ endTime: int; @@ -748,7 +736,7 @@ declare namespace statistics { * @type { ?int } * @syscap SystemCapability.Communication.NetManager.Core * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'12','1.2':'20'} + * @since arkts{'1.1':'12','1.2':'20'} * @arkts 1.1&1.2 */ simId?: int; diff --git a/api/@ohos.net.webSocket.d.ts b/api/@ohos.net.webSocket.d.ts index e582a5f2edc446444a307ec222ad33fd60c302cd..27998aa472fbc9100e29e5ef20103d42fc355b93 100644 --- a/api/@ohos.net.webSocket.d.ts +++ b/api/@ohos.net.webSocket.d.ts @@ -118,8 +118,7 @@ declare namespace webSocket { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ header?: Object; @@ -134,8 +133,7 @@ declare namespace webSocket { * @type {?string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ caPath?: string; @@ -150,8 +148,7 @@ declare namespace webSocket { * @type {?ClientCert} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ clientCert?: ClientCert; @@ -159,8 +156,7 @@ declare namespace webSocket { * HTTP proxy configuration. Use 'system' if this filed is not set. * @type {?ProxyConfiguration} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ proxy?: ProxyConfiguration; @@ -168,8 +164,7 @@ declare namespace webSocket { * Self defined protocol. * @type {?string} * @syscap SystemCapability.Communication.NetStack - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ protocol?: string; } @@ -201,8 +196,7 @@ declare namespace webSocket { * @interface ClientCert * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ export interface ClientCert { /** @@ -216,8 +210,7 @@ declare namespace webSocket { * @type {string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ certPath: string; @@ -232,8 +225,7 @@ declare namespace webSocket { * @type {string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ keyPath: string; @@ -248,8 +240,7 @@ declare namespace webSocket { * @type {?string} * @syscap SystemCapability.Communication.NetStack * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ keyPassword?: string; } @@ -618,8 +609,7 @@ declare namespace webSocket { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ send(data: string | ArrayBuffer, callback: AsyncCallback): void; @@ -654,8 +644,7 @@ declare namespace webSocket { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ send(data: string | ArrayBuffer): Promise; @@ -723,8 +712,7 @@ declare namespace webSocket { * @syscap SystemCapability.Communication.NetStack * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ close(options: WebSocketCloseOptions, callback: AsyncCallback): void; diff --git a/api/@ohos.nfc.controller.d.ts b/api/@ohos.nfc.controller.d.ts index 63aa9d95448cf681bc66adb63f4ea29072d2fb01..f0a866e129a5d53c5d84c96a44c7c1db2a0e1040 100644 --- a/api/@ohos.nfc.controller.d.ts +++ b/api/@ohos.nfc.controller.d.ts @@ -33,7 +33,8 @@ import { Callback } from './@ohos.base'; * @namespace nfcController * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace nfcController { /** @@ -49,7 +50,8 @@ declare namespace nfcController { * @enum { number } * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ enum NfcState { /** @@ -63,7 +65,8 @@ declare namespace nfcController { * * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ STATE_OFF = 1, @@ -78,7 +81,8 @@ declare namespace nfcController { * * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ STATE_TURNING_ON = 2, @@ -93,7 +97,8 @@ declare namespace nfcController { * * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ STATE_ON = 3, @@ -108,7 +113,8 @@ declare namespace nfcController { * * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ STATE_TURNING_OFF = 4 } @@ -139,7 +145,8 @@ declare namespace nfcController { * @param { Callback } callback Callback used to listen to the nfc state changed event. * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'nfcStateChange', callback: Callback): void; @@ -158,7 +165,8 @@ declare namespace nfcController { * @param { Callback } callback Callback used to listen to the nfc state changed event. * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'nfcStateChange', callback?: Callback): void; @@ -183,7 +191,8 @@ declare namespace nfcController { * @throws { BusinessError } 801 - Capability not supported. * @throws { BusinessError } 3100101 - The NFC state is abnormal in the service. * @syscap SystemCapability.Communication.NFC.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function enableNfc(): void; @@ -208,7 +217,8 @@ declare namespace nfcController { * @throws { BusinessError } 801 - Capability not supported. * @throws { BusinessError } 3100101 - The NFC state is abnormal in the service. * @syscap SystemCapability.Communication.NFC.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function disableNfc(): void; @@ -225,7 +235,8 @@ declare namespace nfcController { * @returns { boolean } Returns {@code true} if NFC is enabled; returns {@code false} otherwise. * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function isNfcOpen(): boolean; @@ -250,7 +261,8 @@ declare namespace nfcController { * @returns { NfcState } Returns the NFC status. * @syscap SystemCapability.Communication.NFC.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function getNfcState(): NfcState; } diff --git a/api/@ohos.nfc.tag.d.ts b/api/@ohos.nfc.tag.d.ts index da104445a27553fd597146f35835b930d0358d21..096bfae1a18925ca52330a6dae8d2d7eb6a1f11a 100644 --- a/api/@ohos.nfc.tag.d.ts +++ b/api/@ohos.nfc.tag.d.ts @@ -17,7 +17,7 @@ * @file * @kit ConnectivityKit */ - +/*** if arkts 1.1 */ import type { NfcATag as _NfcATag, NfcBTag as _NfcBTag, NfcFTag as _NfcFTag, NfcVTag as _NfcVTag } from './tag/nfctech'; import { IsoDepTag as _IsoDepTag, @@ -30,6 +30,7 @@ import { import { NdefMessage as _NdefMessage } from './tag/nfctech'; import { TagSession as _TagSession } from './tag/tagSession'; import type { PacMap } from './ability/dataAbilityHelper'; +/*** endif */ import type rpc from './@ohos.rpc'; import type { AsyncCallback } from './@ohos.base'; import Want from './@ohos.app.ability.Want'; @@ -48,7 +49,8 @@ import type { ElementName } from './bundleManager/ElementName'; * @namespace tag * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace tag { /** @@ -64,7 +66,8 @@ declare namespace tag { * @constant * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ const NFC_A = 1; @@ -81,7 +84,8 @@ declare namespace tag { * @constant * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ const NFC_B = 2; @@ -98,7 +102,8 @@ declare namespace tag { * @constant * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ const ISO_DEP = 3; @@ -115,7 +120,8 @@ declare namespace tag { * @constant * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ const NFC_F = 4; @@ -132,7 +138,8 @@ declare namespace tag { * @constant * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ const NFC_V = 5; @@ -149,7 +156,8 @@ declare namespace tag { * @constant * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ const NDEF = 6; @@ -183,7 +191,8 @@ declare namespace tag { * @constant * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ const MIFARE_CLASSIC = 8; @@ -200,7 +209,8 @@ declare namespace tag { * @constant * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ const MIFARE_ULTRALIGHT = 9; @@ -349,7 +359,8 @@ declare namespace tag { * @enum { number } * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ enum NfcForumType { /** @@ -423,7 +434,8 @@ declare namespace tag { * * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ MIFARE_CLASSIC = 101 } @@ -1265,7 +1277,8 @@ declare namespace tag { * @typedef TagInfo * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export interface TagInfo { /** @@ -1282,7 +1295,8 @@ declare namespace tag { * @type { number[] } * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ uid: number[]; @@ -1300,7 +1314,8 @@ declare namespace tag { * @type { number[] } * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ technology: number[]; @@ -1444,7 +1459,8 @@ declare namespace tag { * @namespace ndef * @syscap SystemCapability.Communication.NFC.Tag * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ namespace ndef { /** diff --git a/api/@ohos.notificationManager.d.ts b/api/@ohos.notificationManager.d.ts index 8761db8051e0deb0a64c2bfe3f1fc43ed068ea5a..8494233ed3ef6312b96bf3ceb061fb52a86e1613 100644 --- a/api/@ohos.notificationManager.d.ts +++ b/api/@ohos.notificationManager.d.ts @@ -52,6 +52,7 @@ import type UIAbilityContext from './application/UIAbilityContext'; /*** if arkts 1.2 */ import { AsyncCallback } from '@ohos.base'; import { NotificationLiveViewContent as _NotificationLiveViewContent } from './notification/notificationContent'; +import { NotificationIconButton as _NotificationIconButton } from './notification/notificationContent'; import { LiveViewStatus as _LiveViewStatus } from './notification/notificationContent'; import { LiveViewTypes as _LiveViewTypes } from './notification/notificationContent'; import { NotificationFilter as _NotificationFilter } from './notification/notificationRequest'; @@ -1537,7 +1538,8 @@ declare namespace notificationManager { * @throws { BusinessError } 17700001 - The specified bundle name was not found. * @syscap SystemCapability.Notification.Notification * @systemapi - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ function getSlotByBundle(bundle: BundleOption, slotType: SlotType): Promise; @@ -3835,6 +3837,7 @@ declare namespace notificationManager { * @throws { BusinessError } 1600003 - Failed to connect to the service. * @syscap SystemCapability.Notification.Notification * @since 20 + * @arkts 1.1&1.2 */ function getNotificationSetting(): Promise; @@ -4284,6 +4287,7 @@ declare namespace notificationManager { * @typedef NotificationSetting * @syscap SystemCapability.Notification.Notification * @since 20 + * @arkts 1.1&1.2 */ export interface NotificationSetting { /** @@ -4292,6 +4296,7 @@ declare namespace notificationManager { * @type { boolean } * @syscap SystemCapability.Notification.Notification * @since 20 + * @arkts 1.1&1.2 */ vibrationEnabled: boolean; @@ -4301,6 +4306,7 @@ declare namespace notificationManager { * @type { boolean } * @syscap SystemCapability.Notification.Notification * @since 20 + * @arkts 1.1&1.2 */ soundEnabled: boolean; } @@ -5241,6 +5247,16 @@ declare namespace notificationManager { * @arkts 1.1&1.2 */ export type NotificationProgress = _NotificationProgress; + + /** + * Describes a system live view button with icon. + * + * @typedef { _NotificationIconButton } NotificationIconButton + * @syscap SystemCapability.Notification.Notification + * @since 20 + * @arkts 1.2 + */ + export type NotificationIconButton = _NotificationIconButton; } export default notificationManager; diff --git a/api/@ohos.pluginComponent.d.ts b/api/@ohos.pluginComponent.d.ts index b0666d852ad2fd587758bbfdd71c7dfc34d22a20..aacb631200c52f908c5319b226918937379495fc 100644 --- a/api/@ohos.pluginComponent.d.ts +++ b/api/@ohos.pluginComponent.d.ts @@ -103,7 +103,7 @@ declare namespace pluginComponentManager { * @atomicservice * @since 12 */ - type KVObject = { [key: string]: number | string | boolean | [] | KVObject } + type KVObject = { [key: string]: number | string | boolean | [] | KVObject }; /** * Plugin component push parameters. diff --git a/api/@ohos.pluginComponent.d.ets b/api/@ohos.pluginComponent.static.d.ets similarity index 58% rename from api/@ohos.pluginComponent.d.ets rename to api/@ohos.pluginComponent.static.d.ets index 5f79e3d5e1f839e9f833ff1489d5993f2f0c87c2..865cbb7e2622bcaea91a24249820e8bdbaaea2c4 100644 --- a/api/@ohos.pluginComponent.d.ets +++ b/api/@ohos.pluginComponent.static.d.ets @@ -1,5 +1,6 @@ +'use static'; /* - * Copyright (c) 2021-2023 Huawei Device Co., Ltd. + * Copyright (c) 2021-2025 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -16,6 +17,7 @@ /** * @file * @kit ArkUI + * @arkts 1.2 */ import { AsyncCallback } from './@ohos.base'; @@ -26,15 +28,7 @@ import Want from './@ohos.app.ability.Want'; * * @interface PluginComponentTemplate * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ -/** - * Plugin component template property. - * - * @interface PluginComponentTemplate - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export interface PluginComponentTemplate { /** @@ -42,15 +36,7 @@ export interface PluginComponentTemplate { * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines the source - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ source: string; @@ -59,15 +45,7 @@ export interface PluginComponentTemplate { * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines the ability - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ ability: string; } @@ -77,15 +55,7 @@ export interface PluginComponentTemplate { * * @namespace pluginComponentManager * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ -/** - * Plugin component manager interface. - * - * @namespace pluginComponentManager - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ declare namespace pluginComponentManager { /** @@ -93,32 +63,22 @@ declare namespace pluginComponentManager { * * @typedef { object } KVObject * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 + * @since 20 */ /** * Defines KVObject * - * @typedef { object } KVObject + * @typedef { Record | KVObject> } KVObject * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ - export type KVObject = Record> - + export type KVObject = Record | KVObject>; /** * Plugin component push parameters. * * @interface PushParameters * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component push parameters. - * - * @interface PushParameters - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export interface PushParameters { /** @@ -126,15 +86,7 @@ declare namespace pluginComponentManager { * * @type { Want } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines want. - * - * @type { Want } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ want: Want; @@ -143,15 +95,7 @@ declare namespace pluginComponentManager { * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines name. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ name: string; @@ -160,15 +104,7 @@ declare namespace pluginComponentManager { * * @type { KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines data. - * - * @type { KVObject } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ data: KVObject; @@ -177,15 +113,7 @@ declare namespace pluginComponentManager { * * @type { KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines extraData. - * - * @type { KVObject } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ extraData: KVObject; @@ -194,15 +122,7 @@ declare namespace pluginComponentManager { * * @type { ?string } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines jsonPath. - * - * @type { ?string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ jsonPath?: string; } @@ -213,7 +133,7 @@ declare namespace pluginComponentManager { * @interface PushParameterForStage * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ export interface PushParameterForStage { /** @@ -222,7 +142,7 @@ declare namespace pluginComponentManager { * @type { Want } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ owner: Want; @@ -232,7 +152,7 @@ declare namespace pluginComponentManager { * @type { Want } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ target: Want; @@ -242,7 +162,7 @@ declare namespace pluginComponentManager { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ name: string; @@ -252,7 +172,7 @@ declare namespace pluginComponentManager { * @type { KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ data: KVObject; @@ -262,7 +182,7 @@ declare namespace pluginComponentManager { * @type { KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ extraData: KVObject; @@ -272,7 +192,7 @@ declare namespace pluginComponentManager { * @type { ?string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ jsonPath?: string; } @@ -282,15 +202,7 @@ declare namespace pluginComponentManager { * * @interface RequestParameters * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component request parameters. - * - * @interface RequestParameters - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export interface RequestParameters { /** @@ -298,15 +210,7 @@ declare namespace pluginComponentManager { * * @type { Want } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines want. - * - * @type { Want } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ want: Want; @@ -315,32 +219,16 @@ declare namespace pluginComponentManager { * * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines name. - * - * @type { string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ name: string; - - /** - * Defines data. - * - * @type { KVObject } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ + /** * Defines data. * * @type { KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ data: KVObject; @@ -349,15 +237,7 @@ declare namespace pluginComponentManager { * * @type { ?string } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines jsonPath. - * - * @type { ?string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ jsonPath?: string; } @@ -368,7 +248,7 @@ declare namespace pluginComponentManager { * @interface RequestParameterForStage * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ export interface RequestParameterForStage { /** @@ -377,7 +257,7 @@ declare namespace pluginComponentManager { * @type { Want } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ owner: Want; @@ -387,7 +267,7 @@ declare namespace pluginComponentManager { * @type { Want } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ target: Want; /** @@ -396,7 +276,7 @@ declare namespace pluginComponentManager { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ name: string; @@ -406,7 +286,7 @@ declare namespace pluginComponentManager { * @type { KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ data: KVObject; @@ -416,7 +296,7 @@ declare namespace pluginComponentManager { * @type { ?string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 9 + * @since 20 */ jsonPath?: string; } @@ -426,15 +306,7 @@ declare namespace pluginComponentManager { * * @interface RequestCallbackParameters * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component request callback parameters. - * - * @interface RequestCallbackParameters - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export interface RequestCallbackParameters { @@ -443,32 +315,16 @@ declare namespace pluginComponentManager { * * @type { PluginComponentTemplate } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines componentTemplate. - * - * @type { PluginComponentTemplate } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ componentTemplate: PluginComponentTemplate; - - /** - * Defines data. - * - * @type { KVObject } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ + /** * Defines data. * * @type { KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ data: KVObject; @@ -477,15 +333,7 @@ declare namespace pluginComponentManager { * * @type { KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines extraData. - * - * @type { KVObject } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ extraData: KVObject; } @@ -495,15 +343,7 @@ declare namespace pluginComponentManager { * * @interface RequestEventResult * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component request event result value. - * - * @interface RequestEventResult - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export interface RequestEventResult { /** @@ -511,15 +351,7 @@ declare namespace pluginComponentManager { * * @type { ?string } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines template. - * - * @type { ?string } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ template?: string; @@ -528,15 +360,7 @@ declare namespace pluginComponentManager { * * @type { ?KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines data. - * - * @type { ?KVObject } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ data?: KVObject; @@ -545,15 +369,7 @@ declare namespace pluginComponentManager { * * @type { ?KVObject } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Defines extraData. - * - * @type { ?KVObject } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ extraData?: KVObject; } @@ -562,16 +378,12 @@ declare namespace pluginComponentManager { * Plugin component push event callback. * * @typedef { function } OnPushEventCallback + * @param { Want } source - Push request sender's relevant information. + * @param { PluginComponentTemplate } template - Request component template name. + * @param { KVObject } data - data info. + * @param { KVObject } extraData - extra data info. * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component push event callback. - * - * @typedef { function } OnPushEventCallback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export type OnPushEventCallback = (source: Want, template: PluginComponentTemplate, data: KVObject, extraData: KVObject) => void; @@ -580,18 +392,13 @@ declare namespace pluginComponentManager { * Plugin component request event callback. * * @typedef { function } OnRequestEventCallback + * @param { Want } source - Request the sender to provide relevant information. + * @param { string } name - Template name. + * @param { KVObject } data - data info. + * @returns { RequestEventResult } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component request event callback. - * - * @typedef { function } OnRequestEventCallback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ - export type OnRequestEventCallback = (source: Want, name: string, data: KVObject) => RequestEventResult; /** @@ -600,16 +407,7 @@ declare namespace pluginComponentManager { * @param { PushParameters } param * @param { AsyncCallback } callback * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component push method. - * - * @param { PushParameters } param - * @param { AsyncCallback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export function push(param: PushParameters, callback: AsyncCallback): void; @@ -619,16 +417,7 @@ declare namespace pluginComponentManager { * @param { RequestParameters } param * @param { AsyncCallback } callback * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component request method. - * - * @param { RequestParameters } param - * @param { AsyncCallback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export function request(param: RequestParameters, callback: AsyncCallback): void; @@ -639,8 +428,7 @@ declare namespace pluginComponentManager { * @param { AsyncCallback } callback - Plugin component push event callback. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @StageModelOnly - * @since 9 + * @since 20 */ export function push(param: PushParameterForStage, callback: AsyncCallback): void; @@ -651,8 +439,7 @@ declare namespace pluginComponentManager { * @param { AsyncCallback } callback - Plugin component request event callback. * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @StageModelOnly - * @since 9 + * @since 20 */ export function request(param: RequestParameterForStage, callback: AsyncCallback): void; @@ -662,16 +449,7 @@ declare namespace pluginComponentManager { * @param { string } eventType * @param { OnPushEventCallback | OnRequestEventCallback } callback * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 8 - */ - /** - * Plugin component event listener. - * - * @param { string } eventType - * @param { OnPushEventCallback | OnRequestEventCallback } callback - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @atomicservice - * @since 12 + * @since 20 */ export function on(eventType: string, callback: OnPushEventCallback | OnRequestEventCallback): void; } diff --git a/api/@ohos.print.d.ts b/api/@ohos.print.d.ts index 328e8520cb97e2db0e0cb9180efa804841721791..191dbccc26703b7996e139c2f4717cf2975784cd 100644 --- a/api/@ohos.print.d.ts +++ b/api/@ohos.print.d.ts @@ -159,7 +159,7 @@ declare namespace print { * @param { string } jobId - Indicates print job id. * @param { PrintAttributes } oldAttrs - Indicates old print attributes. * @param { PrintAttributes } newAttrs - Indicates new print attributes. - * @param { number } fd - Indicates print file fd. + * @param { int } fd - Indicates print file fd. * @param { function } writeResultCallback - Indicates this function should execute after the file is updated. * @throws { BusinessError } 201 - the application does not have permission to call this function. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. @@ -167,7 +167,7 @@ declare namespace print { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - onStartLayoutWrite(jobId: string, oldAttrs: PrintAttributes, newAttrs: PrintAttributes, fd: number, + onStartLayoutWrite(jobId: string, oldAttrs: PrintAttributes, newAttrs: PrintAttributes, fd: int, writeResultCallback: (jobId: string, writeResult: PrintFileCreationState) => void): void; /** @@ -265,12 +265,12 @@ declare namespace print { interface PrintAttributes { /** * Copies of document list. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - copyNumber?: number; + copyNumber?: int; /** * Range size to be printed. @@ -328,30 +328,30 @@ declare namespace print { interface PrintPageRange { /** * Start page of sequence. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - startPage?: number; + startPage?: int; /** * End page of sequence. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - endPage?: number; + endPage?: int; /** * Discrete page of sequence. - * @type { ?Array } + * @type { ?Array } * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - pages?: Array; + pages?: Array; } /** @@ -365,43 +365,43 @@ declare namespace print { interface PrintMargin { /** * Top margin. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - top?: number; + top?: int; /** * Bottom margin. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - bottom?: number; + bottom?: int; /** * Left margin. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - left?: number; + left?: int; /** * Right margin. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - right?: number; + right?: int; } /** @@ -415,33 +415,33 @@ declare namespace print { interface PrinterRange { /** * Start page of sequence. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - startPage?: number; + startPage?: int; /** * End page of sequence. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - endPage?: number; + endPage?: int; /** * Discrete page of sequence. - * @type { ?Array } + * @type { ?Array } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - pages?: Array; + pages?: Array; } /** @@ -465,13 +465,13 @@ declare namespace print { /** * Preview file result. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - result?: number; + result?: int; } /** @@ -495,23 +495,23 @@ declare namespace print { /** * Horizontal DPI. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - horizontalDpi: number; + horizontalDpi: int; /** * Vertical DPI. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - verticalDpi: number; + verticalDpi: int; } /** @@ -542,21 +542,21 @@ declare namespace print { /** * Unit: millimeter width. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - width: number; + width: int; /** * Unit: millimeter height. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - height: number; + height: int; } /** @@ -570,23 +570,23 @@ declare namespace print { interface PrinterCapability { /** * Color mode. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - colorMode: number; + colorMode: int; /** * Duplex mode. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - duplexMode: number; + duplexMode: int; /** * The page size list supported by the printer. @@ -670,13 +670,13 @@ declare namespace print { /** * Resource id of printer icon. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - printerIcon?: number; + printerIcon?: int; /** * Printer description. @@ -720,13 +720,13 @@ declare namespace print { interface PrintJob { /** * Document fd list to be printed. - * @type { Array } + * @type { Array } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - fdList: Array; + fdList: Array; /** * Job id. @@ -770,13 +770,13 @@ declare namespace print { /** * Copies of document list. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - copyNumber: number; + copyNumber: int; /** * Range size to be printed. @@ -820,23 +820,23 @@ declare namespace print { /** * Color mode. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - colorMode: number; + colorMode: int; /** * Duplex mode. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - duplexMode: number; + duplexMode: int; /** * Current margin setting. @@ -871,7 +871,7 @@ declare namespace print { /** * Enumeration of Print Direction Mode. - * @enum { number } PrintDirectionMode + * @enum { int } PrintDirectionMode * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 @@ -904,7 +904,7 @@ declare namespace print { /** * Enumeration of Print Color Mode. - * @enum { number } PrintColorMode + * @enum { int } PrintColorMode * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 @@ -929,7 +929,7 @@ declare namespace print { /** * Enumeration of Print Duplex Mode. - * @enum { number } PrintDuplexMode + * @enum { int } PrintDuplexMode * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 @@ -962,7 +962,7 @@ declare namespace print { /** * Enumeration of Print Page Type. - * @enum { number } PrintPageType + * @enum { int } PrintPageType * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 @@ -1067,7 +1067,7 @@ declare namespace print { /** * Enumeration of Print Document Adapter State. - * @enum { number } PrintDocumentAdapterState + * @enum { int } PrintDocumentAdapterState * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 @@ -1116,7 +1116,7 @@ declare namespace print { /** * Enumeration of Print File Creation State. - * @enum { number } PrintFileCreationState + * @enum { int } PrintFileCreationState * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 @@ -1149,7 +1149,7 @@ declare namespace print { /** * Enumeration of Printer State. - * @enum { number } PrinterState + * @enum { int } PrinterState * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 @@ -1206,7 +1206,7 @@ declare namespace print { /** * Enumeration of Print Job State. - * @enum { number } PrintJobState + * @enum { int } PrintJobState * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 @@ -1255,7 +1255,7 @@ declare namespace print { /** * Enumeration of Print Job Sub State. - * @enum { number } PrintJobSubState + * @enum { int } PrintJobSubState * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 @@ -1528,7 +1528,7 @@ declare namespace print { /** * Enumeration of Print error Code. - * @enum { number } PrintErrorCode + * @enum { int } PrintErrorCode * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 @@ -1625,7 +1625,7 @@ declare namespace print { /** * Enumeration of application event. - * @enum { number } ApplicationEvent + * @enum { int } ApplicationEvent * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 @@ -1697,13 +1697,13 @@ declare namespace print { /** * Vendor icon. - * @type { number } + * @type { int } * @syscap SystemCapability.Print.PrintFramework * @systemapi * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - vendorIcon: number; + vendorIcon: int; /** * Version of current printer extension. @@ -1754,8 +1754,7 @@ declare namespace print { * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Load the specific printer extension and start to discover printer. @@ -1782,8 +1781,7 @@ declare namespace print { * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Load the specific printer extension and start to discover printer. @@ -1806,8 +1804,7 @@ declare namespace print { * @throws { BusinessError } 202 - not system application * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Stop discovering the printer with specific printer extension. @@ -1828,8 +1825,7 @@ declare namespace print { * @throws { BusinessError } 202 - not system application * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Stop discovering the printer with specific printer extension. @@ -1853,8 +1849,7 @@ declare namespace print { * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Connect the specific printer. @@ -1879,8 +1874,7 @@ declare namespace print { * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. * @syscap SystemCapability.Print.PrintFramework * @systemapi Hide this for inner system use. - * @since arkts {'1.1':'10','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ /** * Connect the specific printer. @@ -2032,7 +2026,7 @@ declare namespace print { * Request preview of the print job. * @permission ohos.permission.MANAGE_PRINT_JOB * @param { PrintJob } jobInfo - Indicates the information of print job. - * @param { Callback } callback - The callback function for indcating the result of API execution. + * @param { Callback } callback - The callback function for indcating the result of API execution. * @throws { BusinessError } 201 - the application does not have permission to call this function. * @throws { BusinessError } 202 - not system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. @@ -2041,13 +2035,13 @@ declare namespace print { * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - function requestPrintPreview(jobInfo: PrintJob, callback: Callback): void; + function requestPrintPreview(jobInfo: PrintJob, callback: Callback): void; /** * Request preview of the print job. * @permission ohos.permission.MANAGE_PRINT_JOB * @param { PrintJob } jobInfo - Indicates the information of print job. - * @returns { Promise } the promise returned by the function. + * @returns { Promise } the promise returned by the function. * @throws { BusinessError } 201 - the application does not have permission to call this function. * @throws { BusinessError } 202 - not system application * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. @@ -2056,7 +2050,7 @@ declare namespace print { * @since arkts {'1.1':'10','1.2':'20'} * @arkts 1.1&1.2 */ - function requestPrintPreview(jobInfo: PrintJob): Promise; + function requestPrintPreview(jobInfo: PrintJob): Promise; /** * Register event callback for the state change of printer. @@ -2438,7 +2432,7 @@ declare namespace print { * @permission ohos.permission.MANAGE_PRINT_JOB * @param { string } jobId - Indicates id of the print job. * @param { PrintAttributes } printAttributes - Indicates print attributes. - * @param { number } fd - Indicates print file fd. + * @param { int } fd - Indicates print file fd. * @param { Callback } onFileStateChanged - The callback function for update the file state. * @throws { BusinessError } 201 - the application does not have permission to call this function. * @throws { BusinessError } 202 - not system application @@ -2448,7 +2442,7 @@ declare namespace print { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - function startGettingPrintFile(jobId: string, printAttributes: PrintAttributes, fd: number, + function startGettingPrintFile(jobId: string, printAttributes: PrintAttributes, fd: int, onFileStateChanged: Callback): void; /** @@ -2750,7 +2744,7 @@ declare namespace print { /** * Enumeration of Print Quality. - * @enum { number } PrintQuality + * @enum { int } PrintQuality * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 @@ -2783,7 +2777,7 @@ declare namespace print { /** * Enumeration of Print OrientationMode. - * @enum { number } PrintOrientationMode + * @enum { int } PrintOrientationMode * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 @@ -2832,7 +2826,7 @@ declare namespace print { /** * Enumeration of Printer Status. - * @enum { number } PrinterStatus + * @enum { int } PrinterStatus * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'14','1.2':'20'} * @arkts 1.1&1.2 @@ -2937,7 +2931,7 @@ declare namespace print { /** * Enumeration of Printer Change Events. - * @enum { number } PrinterEvent + * @enum { int } PrinterEvent * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 @@ -2994,7 +2988,7 @@ declare namespace print { /** * Enumeration of default printer type. - * @enum { number } DefaultPrinterType + * @enum { int } DefaultPrinterType * @syscap SystemCapability.Print.PrintFramework * @since arkts {'1.1':'18','1.2':'20'} * @arkts 1.1&1.2 diff --git a/api/@ohos.privacyManager.d.ts b/api/@ohos.privacyManager.d.ts index da3c676ade9bb69c4cc1caa1dfe9d051ad016be6..fbba0091ac7dff1a14aca321360a86f6a9b27614 100644 --- a/api/@ohos.privacyManager.d.ts +++ b/api/@ohos.privacyManager.d.ts @@ -127,8 +127,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function getPermissionUsedRecord(request: PermissionUsedRequest): Promise; @@ -148,8 +147,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function getPermissionUsedRecord( request: PermissionUsedRequest, @@ -176,8 +174,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function startUsingPermission(tokenID: int, permissionName: Permissions): Promise; @@ -203,8 +200,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ function startUsingPermission( tokenID: int, @@ -233,8 +229,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function startUsingPermission(tokenID: int, permissionName: Permissions, callback: AsyncCallback): void; @@ -257,8 +252,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function stopUsingPermission(tokenID: int, permissionName: Permissions): Promise; @@ -282,8 +276,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ function stopUsingPermission( tokenID: int, @@ -310,8 +303,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100008 - Out of memory. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ function stopUsingPermission(tokenID: int, permissionName: Permissions, callback: AsyncCallback): void; @@ -381,10 +373,29 @@ declare namespace privacyManager { * @throws { BusinessError } 12100003 - The input permissionName does not exist. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ - function getPermissionUsedTypeInfos(tokenId?: int, permissionName?: Permissions): Promise>; + + /** + * Obtains the used type of the permission accessed. + * + * @permission ohos.permission.PERMISSION_USED_STATS + * @param { int | null } [tokenId] - Token ID of the application. By default, all token IDs of the device + * are returned. + * @param { Permissions } [permissionName] - Name of the permission to query. By default, all permissions + * of the device are returned. + * @returns { Promise> } Promise used to return the information obtained. + * @throws { BusinessError } 201 - Permission denied. Interface caller does not have permission + * "ohos.permission.PERMISSION_USED_STATS". + * @throws { BusinessError } 202 - Not system app. Interface caller is not a system app. + * @throws { BusinessError } 12100001 - Invalid parameter. PermissionName exceeds 256 characters. + * @throws { BusinessError } 12100002 - The input tokenId does not exist. + * @throws { BusinessError } 12100003 - The input permissionName does not exist. + * @syscap SystemCapability.Security.AccessToken + * @systemapi + * @since 20 + */ + function getPermissionUsedTypeInfos(tokenId?: int | null, permissionName?: Permissions): Promise>; /** * Sets the toggle state of permission access records for the current user. @@ -399,8 +410,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100009 - Common inner error. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ function setPermissionUsedRecordToggleStatus(status: boolean): Promise; @@ -414,8 +424,7 @@ declare namespace privacyManager { * @throws { BusinessError } 12100007 - The service is abnormal. * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'18', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ function getPermissionUsedRecordToggleStatus(): Promise; @@ -543,8 +552,7 @@ declare namespace privacyManager { * @enum { int } PermissionUsageFlag * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ enum PermissionUsageFlag { /** @@ -552,8 +560,7 @@ declare namespace privacyManager { * * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ FLAG_PERMISSION_USAGE_SUMMARY = 0, /** @@ -561,8 +568,7 @@ declare namespace privacyManager { * * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ FLAG_PERMISSION_USAGE_DETAIL = 1 } @@ -573,8 +579,7 @@ declare namespace privacyManager { * @interface PermissionUsedRequest * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface PermissionUsedRequest { /** @@ -583,8 +588,7 @@ declare namespace privacyManager { * @type { ?int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ tokenId?: int; @@ -595,8 +599,7 @@ declare namespace privacyManager { * @default false * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ isRemote?: boolean; @@ -606,8 +609,7 @@ declare namespace privacyManager { * @type { ?string } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ deviceId?: string; @@ -617,8 +619,7 @@ declare namespace privacyManager { * @type { ?string } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ bundleName?: string; @@ -628,8 +629,7 @@ declare namespace privacyManager { * @type { ?Array } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ permissionNames?: Array; @@ -640,8 +640,7 @@ declare namespace privacyManager { * @default 0 * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ beginTime?: long; @@ -652,8 +651,7 @@ declare namespace privacyManager { * @default 0 * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ endTime?: long; @@ -663,8 +661,7 @@ declare namespace privacyManager { * @type { PermissionUsageFlag } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ flag: PermissionUsageFlag; } @@ -675,8 +672,7 @@ declare namespace privacyManager { * @interface PermissionUsedResponse * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface PermissionUsedResponse { /** @@ -685,8 +681,7 @@ declare namespace privacyManager { * @type { long } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ beginTime: long; @@ -696,8 +691,7 @@ declare namespace privacyManager { * @type { long } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ endTime: long; @@ -707,8 +701,7 @@ declare namespace privacyManager { * @type { Array } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ bundleRecords: Array; } @@ -719,8 +712,7 @@ declare namespace privacyManager { * @interface BundleUsedRecord * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface BundleUsedRecord { /** @@ -729,8 +721,7 @@ declare namespace privacyManager { * @type { int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ tokenId: int; @@ -740,8 +731,7 @@ declare namespace privacyManager { * @type { boolean } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ isRemote: boolean; @@ -751,8 +741,7 @@ declare namespace privacyManager { * @type { string } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ deviceId: string; @@ -762,8 +751,7 @@ declare namespace privacyManager { * @type { string } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ bundleName: string; @@ -773,8 +761,7 @@ declare namespace privacyManager { * @type { Array } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ permissionRecords: Array; } @@ -785,8 +772,7 @@ declare namespace privacyManager { * @interface PermissionUsedRecord * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface PermissionUsedRecord { /** @@ -795,8 +781,7 @@ declare namespace privacyManager { * @type { Permissions } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ permissionName: Permissions; @@ -806,8 +791,7 @@ declare namespace privacyManager { * @type { int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ accessCount: int; @@ -817,8 +801,7 @@ declare namespace privacyManager { * @type { int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ rejectCount: int; @@ -828,8 +811,7 @@ declare namespace privacyManager { * @type { long } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ lastAccessTime: long; @@ -839,8 +821,7 @@ declare namespace privacyManager { * @type { long } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ lastRejectTime: long; @@ -850,8 +831,7 @@ declare namespace privacyManager { * @type { long } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ lastAccessDuration: long; @@ -861,8 +841,7 @@ declare namespace privacyManager { * @type { Array } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ accessRecords: Array; @@ -872,8 +851,7 @@ declare namespace privacyManager { * @type { Array } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ rejectRecords: Array; } @@ -884,8 +862,7 @@ declare namespace privacyManager { * @interface UsedRecordDetail * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ interface UsedRecordDetail { /** @@ -894,8 +871,7 @@ declare namespace privacyManager { * @type { int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ status: int; @@ -905,8 +881,7 @@ declare namespace privacyManager { * @type { ?int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ lockScreenStatus?: int; @@ -916,8 +891,7 @@ declare namespace privacyManager { * @type { long } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ timestamp: long; @@ -927,8 +901,7 @@ declare namespace privacyManager { * @type { ?int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'11', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ count?: int; @@ -938,8 +911,7 @@ declare namespace privacyManager { * @type { long } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ accessDuration: long; @@ -949,8 +921,7 @@ declare namespace privacyManager { * @type { ?PermissionUsedType } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ usedType?: PermissionUsedType; } @@ -1002,8 +973,7 @@ declare namespace privacyManager { * @interface PermissionUsedTypeInfo * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ interface PermissionUsedTypeInfo { /** @@ -1012,8 +982,7 @@ declare namespace privacyManager { * @type { int } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ tokenId: int; @@ -1023,8 +992,7 @@ declare namespace privacyManager { * @type { Permissions } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ permissionName: Permissions; @@ -1034,8 +1002,7 @@ declare namespace privacyManager { * @type { PermissionUsedType } * @syscap SystemCapability.Security.AccessToken * @systemapi - * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 12 */ usedType: PermissionUsedType; } diff --git a/api/@ohos.promptAction.d.ts b/api/@ohos.promptAction.d.ts index b34241988724706a04e8b95583090b4f71a32706..7f2024b18f5d2756719e53b83a5e6dd859961401 100644 --- a/api/@ohos.promptAction.d.ts +++ b/api/@ohos.promptAction.d.ts @@ -12,29 +12,11 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - /** * @file * @kit ArkUI */ - -/*** if arkts 1.1 */ import { AsyncCallback } from './@ohos.base'; -/*** endif */ - -/*** if arkts 1.2 */ -import { ResourceColor, Offset, Dimension, EdgeStyles, EdgeColors,EdgeWidths, BorderRadiuses } from './arkui/component/units'; -import { AsyncCallback, Callback } from './@ohos.base'; -import { BlurStyle, ShadowOptions, ShadowStyle, HoverModeAreaType, Rectangle, TransitionEffect, KeyboardAvoidMode, DismissReason, - BackgroundBlurStyleOptions, BackgroundEffectOptions } from './arkui/component/common'; -import { CustomBuilder } from './arkui/component/builder'; -import { DialogAlignment } from './arkui/component/alertDialog'; -import { DismissDialogAction } from './arkui/component/actionSheet'; -import { BorderStyle,Alignment } from './arkui/component/enums'; -import { Resource } from './global/resource'; -import { LengthMetrics } from './arkui/Graphics'; -/*** endif */ - /** * Define the display mode of all kind of dialog * @@ -42,33 +24,28 @@ import { LengthMetrics } from './arkui/Graphics'; * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ export enum LevelMode { - /** - * Display above all page levels. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 - */ - OVERLAY = 0, - - /** - * Display within the current page. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 - */ - EMBEDDED = 1, + /** + * Display above all page levels. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 15 + */ + OVERLAY = 0, + /** + * Display within the current page. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 15 + */ + EMBEDDED = 1 } - /** * Define the immersive mode of all kind of dialog * @@ -76,70 +53,60 @@ export enum LevelMode { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 + * @since 15 */ export enum ImmersiveMode { - /** - * Mask covering the parent node. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 - */ - DEFAULT = 0, - - /** - * Mask extend safe area includes status bar and navigation bar. - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'15','1.2':'20'} - * @arkts 1.1&1.2 - */ - EXTEND = 1, + /** + * Mask covering the parent node. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 15 + */ + DEFAULT = 0, + /** + * Mask extend safe area includes status bar and navigation bar. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 15 + */ + EXTEND = 1 } - /** * Defines level order. * * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 + * @since 18 */ -export declare class LevelOrder { - /** - * Generate valid level order. - * - * @param { number } order - Clamp order with mininum number -100000 and maximum number 100000. - * @returns { LevelOrder } the order object. - * @static - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - static clamp(order: number): LevelOrder; - - /** - * Get the order from LevelOrder object. - * - * @returns { number } the order number. - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'18','1.2':'20'} - * @arkts 1.1&1.2 - */ - getOrder(): number; +export class LevelOrder { + /** + * Generate valid level order. + * + * @param { number } order - Clamp order with mininum number -100000 and maximum number 100000. + * @returns { LevelOrder } the order object. + * @static + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ + static clamp(order: number): LevelOrder; + /** + * Get the order from LevelOrder object. + * + * @returns { number } the order number. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 18 + */ + getOrder(): number; } - /** * @namespace promptAction * @syscap SystemCapability.ArkUI.ArkUI.Full @@ -156,2371 +123,2053 @@ export declare class LevelOrder { * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ declare namespace promptAction { - /** - * @typedef ShowToastOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * @typedef ShowToastOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 - */ - /** - * @typedef ShowToastOptions - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - export interface ShowToastOptions { - /** - * Text to display. - * - * @type { string | Resource } + * @typedef ShowToastOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 9 */ /** - * Text to display. - * - * @type { string | Resource } + * @typedef ShowToastOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * Text to display. - * - * @type { string | Resource } + * @typedef ShowToastOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - message: string | Resource; - - /** - * Duration of toast dialog box. The default value is 1500. - * The recommended value ranges from 1500ms to 10000ms. - * NOTE: A value less than 1500 is automatically changed to 1500. The maximum value is 10000ms. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 9 - */ - /** - * Duration of toast dialog box. The default value is 1500. - * The recommended value ranges from 1500ms to 10000ms. - * NOTE: A value less than 1500 is automatically changed to 1500. The maximum value is 10000ms. - * - * @type { ?number } - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @since 10 + * @since 11 */ - /** - * Duration of toast dialog box. The default value is 1500. - * The recommended value ranges from 1500ms to 10000ms. - * NOTE: A value less than 1500 is automatically changed to 1500. The maximum value is 10000ms. - * - * @type { ?number } + interface ShowToastOptions { + /** + * Text to display. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Text to display. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Text to display. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + message: string | Resource; + /** + * Duration of toast dialog box. The default value is 1500. + * The recommended value ranges from 1500ms to 10000ms. + * NOTE: A value less than 1500 is automatically changed to 1500. The maximum value is 10000ms. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Duration of toast dialog box. The default value is 1500. + * The recommended value ranges from 1500ms to 10000ms. + * NOTE: A value less than 1500 is automatically changed to 1500. The maximum value is 10000ms. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Duration of toast dialog box. The default value is 1500. + * The recommended value ranges from 1500ms to 10000ms. + * NOTE: A value less than 1500 is automatically changed to 1500. The maximum value is 10000ms. + * + * @type { ?number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + duration?: number; + /** + * The distance between toast dialog box and the bottom of screen. + * + * @type { ?(string | number) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * The distance between toast dialog box and the bottom of screen. + * + * @type { ?(string | number) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * The distance between toast dialog box and the bottom of screen. + * + * @type { ?(string | number) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + bottom?: string | number; + /** + * Determine the show mode of the toast. + * + * @type { ?ToastShowMode } + * @default ToastShowMode.DEFAULT + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 11 + */ + /** + * Determine the show mode of the toast. + * + * @type { ?ToastShowMode } + * @default ToastShowMode.DEFAULT + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + showMode?: ToastShowMode; + /** + * Defines the toast alignment of the screen. + * + * @type { ?Alignment } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + alignment?: Alignment; + /** + * Defines the toast offset. + * + * @type { ?Offset } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + offset?: Offset; + /** + * Background color of toast. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + backgroundColor?: ResourceColor; + /** + * Text color of toast. + * + * @type { ?ResourceColor } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + textColor?: ResourceColor; + /** + * Background blur Style of toast. + * + * @type { ?BlurStyle } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + backgroundBlurStyle?: BlurStyle; + /** + * Shadow of toast. + * + * @type { ?(ShadowOptions | ShadowStyle) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + shadow?: ShadowOptions | ShadowStyle; + /** + * Define whether to respond to the hover mode. + * + * @type { ?boolean } + * @default false + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + enableHoverMode?: boolean; + /** + * Defines the toast's display area in hover mode. + * + * @type { ?HoverModeAreaType } + * @default HoverModeAreaType.BOTTOM_SCREEN + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 14 + */ + hoverModeArea?: HoverModeAreaType; + } + /** + * Enum for the toast showMode. + * + * @enum { number } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - duration?: number; - /** - * The distance between toast dialog box and the bottom of screen. - * - * @type { ?(string | number) } + * Enum for the toast showMode. + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + export enum ToastShowMode { + /** + * Toast shows in app. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 11 + */ + /** + * Toast shows in app. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + DEFAULT = 0, + /** + * Toast shows at the top. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 11 + */ + /** + * Toast shows at the top. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + TOP_MOST = 1, + /** + * Toast shows in SYSTEM_TOAST window. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 12 + */ + SYSTEM_TOP_MOST = 2 + } + /** + * @typedef Button * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 9 */ /** - * The distance between toast dialog box and the bottom of screen. - * - * @type { ?(string | number) } + * @typedef Button * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @since 10 */ /** - * The distance between toast dialog box and the bottom of screen. - * - * @type { ?(string | number) } + * @typedef Button * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @arkts 1.1&1.2 - */ - bottom?: string | number; - - /** - * Determine the show mode of the toast. - * - * @type { ?ToastShowMode } - * @default ToastShowMode.DEFAULT - * @syscap SystemCapability.ArkUI.ArkUI.Full * @since 11 */ - /** - * Determine the show mode of the toast. - * - * @type { ?ToastShowMode } - * @default ToastShowMode.DEFAULT - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 - */ - showMode?: ToastShowMode; - /** - * Defines the toast alignment of the screen. - * - * @type { ?Alignment } + interface Button { + /** + * The text displayed in the button. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * The text displayed in the button. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * The text displayed in the button. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + text: string | Resource; + /** + * The foreground color of button. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * The foreground color of button. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * The foreground color of button. + * + * @type { string | Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + color: string | Resource; + /** + * Define whether the button responds to Enter/Space key by default. + * + * @type { ?boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 12 + */ + primary?: boolean; + } + /** + * @typedef ShowDialogSuccessResponse * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ - alignment?: Alignment; /** - * Defines the toast offset. - * - * @type { ?Offset } + * @typedef ShowDialogSuccessResponse * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ - offset?: Offset; /** - * Background color of toast. - * - * @type { ?ResourceColor } + * @typedef ShowDialogSuccessResponse * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - backgroundColor?: ResourceColor; - /** - * Text color of toast. - * - * @type { ?ResourceColor } + interface ShowDialogSuccessResponse { + /** + * Index of the selected button, starting from 0. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Index of the selected button, starting from 0. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Index of the selected button, starting from 0. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + index: number; + } + /** + * @typedef ShowDialogOptions * @syscap SystemCapability.ArkUI.ArkUI.Full - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ - textColor?: ResourceColor; /** - * Background blur Style of toast. - * - * @type { ?BlurStyle } + * @typedef ShowDialogOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 10 */ - backgroundBlurStyle?: BlurStyle; /** - * Shadow of toast. - * - * @type { ?(ShadowOptions | ShadowStyle) } + * @typedef ShowDialogOptions * @syscap SystemCapability.ArkUI.ArkUI.Full * @crossplatform * @atomicservice - * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 + * @since 11 */ - shadow?: ShadowOptions | ShadowStyle; - - /** - * Define whether to respond to the hover mode. - * - * @type { ?boolean } - * @default false + interface ShowDialogOptions { + /** + * Title of the text to display. + * + * @type { ?(string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Title of the text to display. + * + * @type { ?(string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Title of the text to display. + * + * @type { ?(string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + title?: string | Resource; + /** + * Text body. + * + * @type { ?(string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 9 + */ + /** + * Text body. + * + * @type { ?(string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 10 + */ + /** + * Text body. + * + * @type { ?(string | Resource) } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @atomicservice + * @since 11 + */ + message?: string | Resource; + /** + * Array of buttons in the dialog box. + * The array structure is {text:'button', color: '#666666'}. + * One to three buttons are supported. + * The first button is of the positiveButton type, the second is of the negativeButton type, and the third is of the neutralButton type. + * + * @type { ?Array