NOTE:
+ * If showInSubWindow is set to true in UIExtension, the dialog box is aligned with the host window based
+ * on UIExtension.
+ *
*
* @type { ?DialogAlignment }
+ * @default DialogAlignment.Bottom
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -615,7 +675,9 @@ interface ActionSheetOptions
* @since 11
*/
/**
- * Offset of the pop-up window relative to the alignment position.
+ * Offset of the dialog box relative to the alignment position.
+ * When alignment is set to Top, TopStart, or TopEnd: {dx: 0,dy: "40vp"}
+ * When alignment is set to any other value: {dx: 0,dy: "-40vp"}
*
* @type { ?ActionSheetOffset }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -634,9 +696,14 @@ interface ActionSheetOptions
* @since 10
*/
/**
- * Mask Region of dialog. The size cannot exceed the main window.
+ * Mask area of the dialog box. Events outside the mask area are transparently transmitted,
+ * and events within the mask area are not.
+ *
NOTE:
+ * maskRect does not take effect when showInSubWindow is set to true.
+ *
*
* @type { ?Rectangle }
+ * @default - {x:0,y:0, width:'100%', height:'100%'}
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -654,8 +721,12 @@ interface ActionSheetOptions
* @since 11
*/
/**
- * Whether to display in the sub window.
- *
+ * Whether to show the dialog box in a subwindow when the dialog box needs to be displayed outside the main window.
+ *
NOTE:
+ * A dialog box whose showInSubWindow attribute is true cannot trigger the display of another dialog box whose
+ * showInSubWindow attribute is also true.
+ *
+ *
* @type { ?boolean }
* @default false
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -674,7 +745,7 @@ interface ActionSheetOptions
* @since 11
*/
/**
- * Whether it is a modal dialog
+ * Whether the dialog box is a modal. A modal dialog box has a mask applied, while a non-modal dialog box does not.
* @type { ?boolean }
* @default true
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -694,7 +765,11 @@ interface ActionSheetOptions
* @since 11
*/
/**
- * Defines the actionSheet's background color
+ * Background color of the dialog box.
+ *
NOTE:
+ * When backgroundColor is set to a non-transparent color, backgroundBlurStyle must be set to BlurStyle.NONE;
+ * otherwise, the color display may not meet the expected effect.
+ *
NOTE:
+ * Setting this parameter to BlurStyle.NONE disables the background blur. When backgroundBlurStyle is set to a
+ * value other than NONE, do not set backgroundColor. If you do, the color display may not produce the expected
+ * visual effect.
+ *
NOTE:
+ * 1. If this callback is registered, the dialog box will not be closed immediately after the user touches the
+ * mask or the Back button, presses the Esc key, or swipes left or right on the screen. The reason parameter in
+ * the callback is used to determine whether the dialog box can be closed. The reason returned by the component
+ * does not support the value CLOSE_BUTTON.
+ * 2. In the onWillDismiss callback, another onWillDismiss callback is not allowed.
+ *
*
* @type { ?Callback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -760,7 +847,14 @@ interface ActionSheetOptions
onWillDismiss?: Callback;
/**
- * Transition parameters of opening/closing ActionSheet.
+ * Transition effect for the entrance and exit of the dialog box.
+ *
NOTE:
+ * 1. If this parameter is not set, the default effect is used.
+ * 2. Touching the Back button during the entrance animation pauses the entrance animation and starts the exit
+ * animation. The final effect is one obtained after the curves of the entrance and exit animations are combined.
+ * 3. Touching the Back button during the exit animation does not affect the animation playback. Touching the
+ * Back button again closes the application.
+ *
*
* @type { ?TransitionEffect }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -771,9 +865,13 @@ interface ActionSheetOptions
transition?: TransitionEffect;
/**
- * Defines the actionSheet's corner radius.
+ * Corner radius of the background. You can set the radius for each of the four corners individually.
*
* @type { ?(Dimension | BorderRadiuses | LocalizedBorderRadiuses) }
+ * @default - {topLeft:'32vp', topRight:'32vp', bottomLeft:'32vp', bottomRight:'32vp'}, The corner radius is subject
+ * to the component size, with the maximum value being half of the component width or height. If the value is
+ * negative, the default value is used. When set to a percentage, the value defines the radius as a percentage of the
+ * parent component's width or height.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -782,9 +880,12 @@ interface ActionSheetOptions
cornerRadius?: Dimension | BorderRadiuses | LocalizedBorderRadiuses;
/**
- * Defines the actionSheet's width.
+ * Width of the dialog box.
*
* @type { ?Dimension }
+ * @default - Default maximum width of the dialog box: 400 vp,
+ * When this parameter is set to a percentage, the reference width of the dialog box is the width of the window
+ * where the dialog box is located. You can decrease or increase the width as needed.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -793,9 +894,12 @@ interface ActionSheetOptions
width?: Dimension;
/**
- * Defines the actionSheet's height.
+ * Height of the dialog box.
*
* @type { ?Dimension }
+ * @default - Default maximum height of the dialog box: 0.9 x (Window height – Safe area)
+ * When this parameter is set to a percentage, the reference height of the dialog box is the height of the
+ * window where the dialog box is located minus the safe area. You can decrease or increase the height as needed.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -804,9 +908,13 @@ interface ActionSheetOptions
height?: Dimension;
/**
- * Defines the actionSheet's border width.
+ * Border width of the dialog box.
+ * You can set the width for all four sides or set separate widths for individual sides.
*
* @type { ?(Dimension | EdgeWidths | LocalizedEdgeWidths) }
+ * @default 0 - When set to a percentage, the value defines the border width as a percentage of the parent dialog
+ * box's width. If the left and right borders are greater than its width, or the top and bottom borders are greater
+ * than its height, the dialog box may not display as expected.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -815,9 +923,14 @@ interface ActionSheetOptions
borderWidth?: Dimension | EdgeWidths | LocalizedEdgeWidths;
/**
- * Defines the actionSheet's border color.
+ * Border color of the dialog box.
+ *
NOTE:
+ * When borderColor is of type LocalizedEdgeColors, the layout order can be dynamically adjusted based on the
+ * user's language settings.
+ *
*
* @type { ?(ResourceColor | EdgeColors | LocalizedEdgeColors) }
+ * @default Color.Black - borderColor must be used with borderWidth in pairs.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -826,9 +939,10 @@ interface ActionSheetOptions
borderColor?: ResourceColor | EdgeColors | LocalizedEdgeColors;
/**
- * Defines the actionSheet's border style.
+ * Border style of the dialog box.
*
* @type { ?(BorderStyle | EdgeStyles) }
+ * @default BorderStyle.Solid - borderStyle must be used with borderWidth in pairs.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -837,9 +951,11 @@ interface ActionSheetOptions
borderStyle?: BorderStyle | EdgeStyles;
/**
- * Defines the actionSheet's shadow.
+ * Shadow of the dialog box.
*
* @type { ?(ShadowOptions | ShadowStyle) }
+ * @default - Default value on 2-in-1 devices: ShadowStyle.OUTER_FLOATING_MD when the dialog box is focused and
+ * ShadowStyle.OUTER_FLOATING_SM otherwise.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -848,10 +964,10 @@ interface ActionSheetOptions
shadow?: ShadowOptions | ShadowStyle;
/**
- * Defines whether to respond to the hover mode.
+ * Whether to enable the hover mode.
*
* @type { ?boolean }
- * @default false
+ * @default false - meaning not to enable the hover mode.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -860,7 +976,7 @@ interface ActionSheetOptions
enableHoverMode?: boolean;
/**
- * Defines the actionSheet's display area in hover mode.
+ * Display area of the dialog box in hover mode.
*
* @type { ?HoverModeAreaType }
* @default HoverModeAreaType.BOTTOM_SCREEN
@@ -878,7 +994,7 @@ interface ActionSheetOptions
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
onDidAppear?: Callback;
@@ -889,7 +1005,7 @@ interface ActionSheetOptions
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
onDidDisappear?: Callback;
@@ -900,7 +1016,7 @@ interface ActionSheetOptions
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
onWillAppear?: Callback;
@@ -911,15 +1027,15 @@ interface ActionSheetOptions
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
onWillDisappear?: Callback;
/**
- * Determine the display level of the dialog.
+ * Display level of the dialog box.
*
* @type { ?LevelMode }
- * @default LevelMode.OVERLAY
+ * @default LevelMode.OVERLAY - This parameter takes effect only when showInSubWindow is set to false.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -928,7 +1044,10 @@ interface ActionSheetOptions
levelMode?: LevelMode;
/**
- * The uniqueId of any node in the router or navigation page.
+ * Unique ID of the node under the display level for the page-level dialog box.
+ *
NOTE:
+ * This parameter takes effect only when levelMode is set to LevelMode.EMBEDDED.
+ *
+ *
+ * @type { ?(number | ResourceStr) }
+ * @default 10
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ fontSize?: number | ResourceStr;
/**
* Size of a badge.
@@ -291,7 +310,26 @@ declare interface BadgeStyle {
* @atomicservice
* @since 11
*/
- badgeSize?: number | string;
+ /**
+ * Badge size.
+ * For the string type, numeric string values with optional units.
+ * The value must be greater than or equal to 0. If the value is less than 0, the default value is used.
+ * Unit: vp
+ *
+ *
NOTE:
+ * This parameter cannot be set in percentage.
+ * If it is set to an invalid value, the default value is used.
+ *
+ *
+ * @type { ?(number | ResourceStr) }
+ * @default 16
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ badgeSize?: number | ResourceStr;
/**
* Color of the badge.
@@ -318,9 +356,10 @@ declare interface BadgeStyle {
* @since 10
*/
/**
- * Color of the badge.
+ * Badge color.
*
* @type { ?ResourceColor }
+ * @default Color.Red
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -338,9 +377,10 @@ declare interface BadgeStyle {
* @since 10
*/
/**
- * Define the border color of the badge.
+ * Border color of the background.
*
* @type { ?ResourceColor }
+ * @default Color.Red
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -357,9 +397,12 @@ declare interface BadgeStyle {
* @since 10
*/
/**
- * Define the border width of the badge.
+ * Border width of the background.
+ * This parameter cannot be set in percentage.
+ * Unit: vp
*
* @type { ?Length }
+ * @default 1
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -384,7 +427,23 @@ declare interface BadgeStyle {
* @atomicservice
* @since 11
*/
- fontWeight?: number | FontWeight | string;
+ /**
+ * Font weight of the text.
+ * For the number type, the value ranges from 100 to 900, at an interval of 100. Default value: 400
+ * A larger value indicates a heavier font weight.
+ * For the string type, only strings that represent a number. Default value: FontWeight.Normal
+ *
+ *
NOTE:
+ * This parameter cannot be set in percentage.
+ *
+ *
+ * @type { ?(number | FontWeight | ResourceStr) }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ fontWeight?: number | FontWeight | ResourceStr;
}
/**
@@ -412,7 +471,7 @@ declare interface BadgeStyle {
* @since 10
*/
/**
- * Defines the base param of badge.
+ * Provides basic parameters for creating a badge.
*
* @interface BadgeParam
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -447,9 +506,17 @@ declare interface BadgeParam {
* @since 10
*/
/**
- * Set the display position of the prompt point.
+ * Position to display the badge relative to the parent component.
+ *
+ *
NOTE:
+ * With the Position type, percentage values are not supported.
+ * If an invalid value is set, the default value (0,0),
+ * which indicates the upper left corner of the component, will be used.
+ * With the BadgePosition type, the position is mirrored based on the Direction property.
+ *
*
* @type { ?(BadgePosition | Position) }
+ * @default BadgePosition.RightTop
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -483,7 +550,7 @@ declare interface BadgeParam {
* @since 10
*/
/**
- * Defines the style of the Badge component, including the text color, size, dot color, and size.
+ * Style of the badge, including the font color, font size, badge color, and badge size.
*
* @type { BadgeStyle }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -523,7 +590,7 @@ declare interface BadgeParam {
* @since 10
*/
/**
- * Defines the badge param with count and maxCount.
+ * Inherits from BadgeParam and has all attributes of BadgeParam.
*
* @extends BadgeParam
* @interface BadgeParamWithNumber
@@ -559,7 +626,15 @@ declare interface BadgeParamWithNumber extends BadgeParam {
* @since 10
*/
/**
- * Set the number of reminder messages.
+ * Number of notifications.
+ *
+ *
NOTE:
+ * If the value is less than or equal to 0 and less than the value of maxCount, no badge is displayed.
+ * Value range: [-2147483648, 2147483647]
+ * If the value is out of the range,
+ * it will be adjusted by adding or subtracting 4294967296 to bring it back within the range.
+ * If the value is not an integer, it is rounded off to the nearest integer.
+ *
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -595,9 +670,17 @@ declare interface BadgeParamWithNumber extends BadgeParam {
* @since 10
*/
/**
- * Maximum number of messages. If the number of messages exceeds the maximum, only maxCount+ is displayed.
+ * Maximum number of notifications. When the maximum number is reached, only maxCount+ is displayed.
+ *
+ *
NOTE:
+ * Value range: [-2147483648, 2147483647]
+ * If the value is out of the range,
+ * it will be adjusted by adding or subtracting 4294967296 to bring it back within the range.
+ * If the value is not an integer, it is rounded off to the nearest integer.
+ *
*
* @type { ?number }
+ * @default 99
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -635,7 +718,7 @@ declare interface BadgeParamWithNumber extends BadgeParam {
* @since 10
*/
/**
- * Defines the badge param with string value.
+ * Inherits from BadgeParam and has all attributes of BadgeParam.
*
* @extends BadgeParam
* @interface BadgeParamWithString
@@ -680,7 +763,17 @@ declare interface BadgeParamWithString extends BadgeParam {
* @atomicservice
* @since 11
*/
- value: string;
+ /**
+ * Prompt content.
+ *
+ * @type { ResourceStr }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ value: ResourceStr;
}
/**
diff --git a/api/@internal/component/ets/blank.d.ts b/api/@internal/component/ets/blank.d.ts
index 9f7182728f048faa8ecb67c34736d72643d96ee6..19c7cf5a0f0814a37dfe4dc51bb82d7071d3a021 100644
--- a/api/@internal/component/ets/blank.d.ts
+++ b/api/@internal/component/ets/blank.d.ts
@@ -81,7 +81,8 @@ interface BlankInterface {
* @since 10
*/
/**
- * The minimum size of the blank fill assembly on the container spindle.
+ * Minimum size of the Blank component in the container along the main axis.
+ * Default value: **0**.
*
* @param { number | string } min
* @returns { BlankAttribute }
@@ -157,7 +158,8 @@ declare class BlankAttribute extends CommonMethod {
* @since 10
*/
/**
- * color: set color.
+ * Sets the color to fill the blank.
+ * Default value: **Color.Transparent**.
*
* @param { ResourceColor } value
* @returns { BlankAttribute }
diff --git a/api/@internal/component/ets/button.d.ts b/api/@internal/component/ets/button.d.ts
index 31894becbee97034c3ebae2ea3eb69aff129920a..1818a77db92979a7e9857f42cb4f43cea67d12d0 100644
--- a/api/@internal/component/ets/button.d.ts
+++ b/api/@internal/component/ets/button.d.ts
@@ -1263,6 +1263,16 @@ declare class ButtonAttribute extends CommonMethod {
* @atomicservice
* @since 18
*/
+ /**
+ * Sets the minimum zoom-out ratio of the button text.
+ *
+ * @param { number | Resource } scale
+ * @returns { ButtonAttribute }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
minFontScale(scale: number | Resource): ButtonAttribute;
/**
@@ -1274,6 +1284,16 @@ declare class ButtonAttribute extends CommonMethod {
* @atomicservice
* @since 18
*/
+ /**
+ * Sets the maximum magnification of the button text.
+ *
+ * @param { number | Resource } scale
+ * @returns { ButtonAttribute }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
maxFontScale(scale: number | Resource): ButtonAttribute;
}
diff --git a/api/@internal/component/ets/calendar_picker.d.ts b/api/@internal/component/ets/calendar_picker.d.ts
index fce47754f636ae7d8814abd7fa5a8b3a16423c20..2ae7c8c787cde6ac58eb41bc6fa7850ffb1c0d2e 100644
--- a/api/@internal/component/ets/calendar_picker.d.ts
+++ b/api/@internal/component/ets/calendar_picker.d.ts
@@ -157,7 +157,7 @@ declare interface CalendarOptions {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
disabledDateRange?: DateRange[];
}
@@ -296,6 +296,7 @@ declare class CalendarPickerAttribute extends CommonMethod } callback - callback for selected date changed.
* @returns { CalendarPickerAttribute } the attribute of the CalendarPicker.
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -324,7 +325,7 @@ declare class CalendarPickerAttribute extends CommonMethod }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -389,6 +391,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
*/
/**
* Called when the Cancel button in the dialog is clicked.
+ * Anonymous Object Rectification.
* @type { ?VoidCallback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -414,6 +417,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
*/
/**
* This event is triggered when a date is selected in dialog.
+ * Anonymous Object Rectification.
* @type { ?Callback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -471,7 +475,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
backgroundBlurStyleOptions?: BackgroundBlurStyleOptions;
@@ -482,7 +486,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
backgroundEffect?: BackgroundEffectOptions;
@@ -519,6 +523,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
*/
/**
* Callback function when the dialog appears.
+ * Anonymous Object Rectification.
*
* @type { ?VoidCallback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -539,6 +544,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
*/
/**
* Callback function when the dialog disappears.
+ * Anonymous Object Rectification.
*
* @type { ?VoidCallback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -559,6 +565,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
*/
/**
* Callback function before the dialog openAnimation starts.
+ * Anonymous Object Rectification.
*
* @type { ?VoidCallback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -579,6 +586,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
*/
/**
* Callback function before the dialog closeAnimation starts.
+ * Anonymous Object Rectification.
*
* @type { ?VoidCallback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -631,7 +639,7 @@ declare interface CalendarDialogOptions extends CalendarOptions {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
markToday?: boolean;
}
diff --git a/api/@internal/component/ets/canvas.d.ts b/api/@internal/component/ets/canvas.d.ts
index 65124aa016c37ca2bdc341176c610922b47f5d6f..8821d237aae769bbb3b14515abdd94b2cb83a5e1 100644
--- a/api/@internal/component/ets/canvas.d.ts
+++ b/api/@internal/component/ets/canvas.d.ts
@@ -246,9 +246,9 @@ declare type CanvasDirection = "inherit" | "ltr" | "rtl";
* "center": The text is centered.
* "end": Where text aligns lines end (Left alignment refers to the local from left to right,
* and right alignment refers to the local from right to left)
- * "left": The text is left-aligned.
+ * "left": (Default) The text is left-aligned.
* "right": The text is right-aligned.
- * "start": (Default) Where the text snap line begins (Left alignment refers to the local from left to right,
+ * "start": Where the text snap line begins (Left alignment refers to the local from left to right,
* and right alignment refers to the local from right to left)
*
* @typedef { "center" | "end" | "left" | "right" | "start" } CanvasTextAlign
@@ -260,9 +260,9 @@ declare type CanvasDirection = "inherit" | "ltr" | "rtl";
* "center": The text is centered.
* "end": Where text aligns lines end (Left alignment refers to the local from left to right,
* and right alignment refers to the local from right to left)
- * "left": The text is left-aligned.
+ * "left": (Default) The text is left-aligned.
* "right": The text is right-aligned.
- * "start": (Default) Where the text snap line begins (Left alignment refers to the local from left to right,
+ * "start": Where the text snap line begins (Left alignment refers to the local from left to right,
* and right alignment refers to the local from right to left)
*
* @typedef { "center" | "end" | "left" | "right" | "start" } CanvasTextAlign
@@ -275,9 +275,9 @@ declare type CanvasDirection = "inherit" | "ltr" | "rtl";
* "center": The text is centered.
* "end": Where text aligns lines end (Left alignment refers to the local from left to right,
* and right alignment refers to the local from right to left)
- * "left": The text is left-aligned.
+ * "left": (Default) The text is left-aligned.
* "right": The text is right-aligned.
- * "start": (Default) Where the text snap line begins (Left alignment refers to the local from left to right,
+ * "start": Where the text snap line begins (Left alignment refers to the local from left to right,
* and right alignment refers to the local from right to left)
*
* @typedef { "center" | "end" | "left" | "right" | "start" } CanvasTextAlign
@@ -291,9 +291,9 @@ declare type CanvasDirection = "inherit" | "ltr" | "rtl";
* "center": The text is centered.
* "end": Where text aligns lines end (Left alignment refers to the local from left to right,
* and right alignment refers to the local from right to left)
- * "left": The text is left-aligned.
+ * "left": (Default) The text is left-aligned.
* "right": The text is right-aligned.
- * "start": (Default) Where the text snap line begins (Left alignment refers to the local from left to right,
+ * "start": Where the text snap line begins (Left alignment refers to the local from left to right,
* and right alignment refers to the local from right to left)
*
* @typedef { "center" | "end" | "left" | "right" | "start" } CanvasTextAlign
@@ -506,6 +506,20 @@ declare class CanvasGradient {
* @since 11
*/
addColorStop(offset: number, color: string): void;
+
+ /**
+ * Add a breakpoint defined by offset and color to the gradient
+ *
+ * @param { number } offset - Value between 0 and 1.
+ * @param { string | ColorMetrics } color - Set the gradient color.
+ * @throws { BusinessError } 103701 - The color's ColorSpace is not the same as the last color's.
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ addColorStop(offset: number, color: string | ColorMetrics): void;
}
/**
@@ -995,6 +1009,25 @@ declare class CanvasPath {
* @since 11
*/
rect(x: number, y: number, w: number, h: number): void;
+
+ /**
+ * Draw rounded Rectangular Paths
+ *
+ * @param { number } x - The x-axis coordinate of the start point of the rectangle.
+ * @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.
+ * @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.
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ roundRect(x: number, y: number, w: number, h: number, radii?: number | Array): void;
}
/**
@@ -4719,7 +4752,7 @@ declare class CanvasRenderer extends CanvasPath {
* Text alignment mode. For details, see {@link CanvasTextAlign}.
*
* @type { CanvasTextAlign }
- * @default start
+ * @default left
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 8
*/
@@ -4727,7 +4760,7 @@ declare class CanvasRenderer extends CanvasPath {
* Text alignment mode. For details, see {@link CanvasTextAlign}.
*
* @type { CanvasTextAlign }
- * @default start
+ * @default left
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @form
* @since 9
@@ -4736,7 +4769,7 @@ declare class CanvasRenderer extends CanvasPath {
* Text alignment mode. For details, see {@link CanvasTextAlign}.
*
* @type { CanvasTextAlign }
- * @default start
+ * @default left
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -4746,7 +4779,7 @@ declare class CanvasRenderer extends CanvasPath {
* Text alignment mode. For details, see {@link CanvasTextAlign}.
*
* @type { CanvasTextAlign }
- * @default start
+ * @default left
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -5418,6 +5451,7 @@ declare class CanvasRenderingContext2D extends CanvasRenderer {
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 110001 - Image analysis feature is not supported.
* @throws { BusinessError } 110002 - Image analysis is currently being executed.
+ * @throws { BusinessError } 110003 - Image analysis is stopped.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 12
diff --git a/api/@internal/component/ets/checkbox.d.ts b/api/@internal/component/ets/checkbox.d.ts
index 8a2718bdf318093a455b61ae2f33bb963f569f02..10261869716ca770c8a0fa1bf81aa97e006c9bd2 100644
--- a/api/@internal/component/ets/checkbox.d.ts
+++ b/api/@internal/component/ets/checkbox.d.ts
@@ -264,6 +264,7 @@ interface CheckboxInterface {
/**
* Defines a Checkbox callback when onChange.
+ * Anonymous Object Rectification.
*
* @typedef { function } OnCheckboxChangeCallback
* @param { boolean } value - selected status
@@ -558,6 +559,7 @@ declare class CheckboxAttribute extends CommonMethod {
*/
/**
* Called when the selection status changes.
+ * Anonymous Object Rectification.
*
* @param { OnCheckboxChangeCallback } callback
* @returns { CheckboxAttribute }
diff --git a/api/@internal/component/ets/checkboxgroup.d.ts b/api/@internal/component/ets/checkboxgroup.d.ts
index 73155224395b0ad57e5aff8ebed347ebb946fd12..7d33b8fd86c87ac39076badec21bfbc102fb1940 100644
--- a/api/@internal/component/ets/checkboxgroup.d.ts
+++ b/api/@internal/component/ets/checkboxgroup.d.ts
@@ -405,6 +405,7 @@ interface CheckboxGroupInterface {
/**
* Defines a CheckboxGroup callback when onChange.
+ * Anonymous Object Rectification.
*
* @typedef { function } OnCheckboxGroupChangeCallback
* @param { CheckboxGroupResult } value - checkbox group result
@@ -663,6 +664,7 @@ declare class CheckboxGroupAttribute extends CommonMethod {
/**
@@ -280,7 +295,8 @@ declare class ColumnAttribute extends CommonMethod {
* @crossplatform
* @form
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11','1.2':'20'}
+ * @arkts 1.1&1.2
*/
alignItems(value: HorizontalAlign): ColumnAttribute;
@@ -320,7 +336,8 @@ declare class ColumnAttribute extends CommonMethod {
* @crossplatform
* @form
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11','1.2':'20'}
+ * @arkts 1.1&1.2
*/
justifyContent(value: FlexAlign): ColumnAttribute;
/**
@@ -330,7 +347,8 @@ declare class ColumnAttribute extends CommonMethod {
* @returns { ColumnAttribute } The attribute of the column.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @systemapi
- * @since 11
+ * @since arkts {'1.1':'11','1.2':'20'}
+ * @arkts 1.1&1.2
*/
pointLight(value: PointLightStyle): ColumnAttribute;
/**
@@ -342,7 +360,8 @@ declare class ColumnAttribute extends CommonMethod {
* @crossplatform
* @form
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12','1.2':'20'}
+ * @arkts 1.1&1.2
*/
reverse(isReversed: Optional): ColumnAttribute;
}
diff --git a/api/@internal/component/ets/common.d.ts b/api/@internal/component/ets/common.d.ts
index c864a1812c96f3d479a626672a7fe117238c8300..aaf98cf2a9983142adfea3e7f265dc7f44b7555c 100644
--- a/api/@internal/component/ets/common.d.ts
+++ b/api/@internal/component/ets/common.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
@@ -91,6 +91,21 @@ declare interface InputCounterOptions {
/**
* 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,6 +126,16 @@ 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
@@ -1053,7 +1078,13 @@ declare interface IMonitorValue {
}
/**
- * Define AnimatableArithmetic interface
+ * 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.
*
* @interface AnimatableArithmetic
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -1061,7 +1092,13 @@ declare interface IMonitorValue {
* @since 10
*/
/**
- * Define AnimatableArithmetic interface
+ * 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.
*
* @interface AnimatableArithmetic
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -1071,7 +1108,7 @@ declare interface IMonitorValue {
*/
declare interface AnimatableArithmetic {
/**
- * Define plus method
+ * Defines the addition rule of the data type.
*
* @param { AnimatableArithmetic } rhs - another value
* @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface
@@ -1080,7 +1117,7 @@ declare interface IMonitorValue {
* @since 10
*/
/**
- * Define plus method
+ * Defines the addition rule of the data type.
*
* @param { AnimatableArithmetic } rhs - another value
* @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface
@@ -1092,7 +1129,7 @@ declare interface IMonitorValue {
plus(rhs: AnimatableArithmetic): AnimatableArithmetic;
/**
- * Define subtract method
+ * Defines the subtraction rule of the data type.
*
* @param { AnimatableArithmetic } rhs - another value
* @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface
@@ -1101,7 +1138,7 @@ declare interface IMonitorValue {
* @since 10
*/
/**
- * Define subtract method
+ * Defines the subtraction rule of the data type.
*
* @param { AnimatableArithmetic } rhs - another value
* @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface
@@ -1113,7 +1150,7 @@ declare interface IMonitorValue {
subtract(rhs: AnimatableArithmetic): AnimatableArithmetic;
/**
- * Define multiply method
+ * Defines the multiplication rule of the data type.
*
* @param { number } scale - scale value
* @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface
@@ -1122,7 +1159,7 @@ declare interface IMonitorValue {
* @since 10
*/
/**
- * Define multiply method
+ * Defines the multiplication rule of the data type.
*
* @param { number } scale - scale value
* @returns { AnimatableArithmetic } new value which implements AnimatableArithmetic interface
@@ -1134,7 +1171,7 @@ declare interface IMonitorValue {
multiply(scale: number): AnimatableArithmetic;
/**
- * Define equals method
+ * Defines the equality judgment rule of the data type.
*
* @param { AnimatableArithmetic } rhs - another value
* @returns { boolean } is equals
@@ -1143,7 +1180,7 @@ declare interface IMonitorValue {
* @since 10
*/
/**
- * Define equals method
+ * Defines the equality judgment rule of the data type.
*
* @param { AnimatableArithmetic } rhs - another value
* @returns { boolean } is equals
@@ -1269,7 +1306,14 @@ 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
@@ -1278,7 +1322,14 @@ 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
@@ -1288,7 +1339,14 @@ 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
@@ -1741,7 +1799,7 @@ declare interface Rectangle {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
declare interface ExpectedFrameRateRange {
/**
@@ -1766,7 +1824,7 @@ declare interface ExpectedFrameRateRange {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
min: number,
/**
@@ -1791,7 +1849,7 @@ declare interface ExpectedFrameRateRange {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
max: number,
/**
@@ -1822,7 +1880,7 @@ declare interface ExpectedFrameRateRange {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
expected: number,
}
@@ -1831,6 +1889,11 @@ 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
@@ -1840,6 +1903,11 @@ 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
@@ -1850,6 +1918,11 @@ 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
@@ -1861,6 +1934,11 @@ 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
@@ -1875,6 +1953,10 @@ 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
@@ -1883,6 +1965,10 @@ 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
@@ -1892,6 +1978,10 @@ 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
@@ -1902,6 +1992,10 @@ 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
@@ -1921,7 +2015,8 @@ 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
+ * 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
@@ -3088,6 +3183,89 @@ declare enum AccessibilityRoleType {
*/
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,
+ /**
+ * the accessibility action need to bubble up for execution
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ ACTION_RISE = 2,
+}
+
+/**
+ * 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 type AccessibilityActionInterceptCallback = (action: AccessibilityAction) => AccessibilityActionInterceptResult;
+
/**
* Enum for FinishCallbackType.
*
@@ -3109,7 +3287,7 @@ declare type AccessibilityFocusCallback = (isFocus: boolean) => void;
*/
declare enum FinishCallbackType {
/**
- * When the entire animation ends and will be removed immediately, the callback is triggered.
+ * The callback is invoked when the entire animation is removed once it has finished.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -3117,7 +3295,7 @@ declare enum FinishCallbackType {
* @since 11
*/
/**
- * When the entire animation ends and will be removed immediately, the callback is triggered.
+ * The callback is invoked when the entire animation is removed once it has finished.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -3135,7 +3313,8 @@ declare enum FinishCallbackType {
* @since 11
*/
/**
- * When the animation is logically down but may still be in its long tail, the callback is triggered.
+ * The callback is invoked when the animation logically enters the falling state,
+ * though it may still be in its long tail state.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -3175,7 +3354,7 @@ declare enum TouchTestStrategy {
* @since 11
*/
/**
- * Do framework touch test.
+ * Custom dispatch has no effect; the system distributes events based on the hit status of the current node.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -3194,7 +3373,8 @@ declare enum TouchTestStrategy {
* @since 11
*/
/**
- * Specify the component to do touch test and follow the framework touch test
+ * 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
@@ -3213,7 +3393,8 @@ declare enum TouchTestStrategy {
* @since 11
*/
/**
- * Specify the component to do touch test and not follow the framework touch test
+ * 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
@@ -3301,6 +3482,7 @@ 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
@@ -3310,6 +3492,7 @@ 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
@@ -3370,7 +3553,7 @@ declare interface AnimateParam {
curve?: Curve | string | ICurve;
/**
- * Animation plays with delay,when set to a negative number, the animation plays in advance.
+ * Animation delay time, in ms. By default, the animation has no delay.
*
* @type { ?number }
* @default 0
@@ -3378,7 +3561,7 @@ declare interface AnimateParam {
* @since 7
*/
/**
- * Animation delay time, in ms.
+ * Animation delay time, in ms. By default, the animation has no delay.
*
* @type { ?number }
* @default 0
@@ -3387,7 +3570,7 @@ declare interface AnimateParam {
* @since 10
*/
/**
- * Animation delay time, in ms.
+ * Animation delay time, in ms. By default, the animation has no delay.
*
* @type { ?number }
* @default 0
@@ -3399,7 +3582,9 @@ declare interface AnimateParam {
delay?: number;
/**
- * Animation iterations. When set to -1, the animation playing it repeatedly. The value range is greater than or equal to -1.
+ * 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.
*
* @type { ?number }
* @default 1
@@ -3407,7 +3592,9 @@ declare interface AnimateParam {
* @since 7
*/
/**
- * Animation iterations. When set to -1, the animation playing it repeatedly. The value range is greater than or equal to -1.
+ * 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.
*
* @type { ?number }
* @default 1
@@ -3416,7 +3603,9 @@ declare interface AnimateParam {
* @since 10
*/
/**
- * Animation iterations. When set to -1, the animation playing it repeatedly. The value range is greater than or equal to -1.
+ * 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.
*
* @type { ?number }
* @default 1
@@ -3428,7 +3617,7 @@ declare interface AnimateParam {
iterations?: number;
/**
- * Animation playback mode. By default, the animation is played from the beginning after the playback is complete.
+ * Playback mode. By default, the animation is played from the beginning after the playback is complete.
*
* @type { ?PlayMode }
* @default PlayMode.Normal
@@ -3436,7 +3625,7 @@ declare interface AnimateParam {
* @since 7
*/
/**
- * Animation playback mode. By default, the animation is played from the beginning after the playback is complete.
+ * Playback mode. By default, the animation is played from the beginning after the playback is complete.
*
* @type { ?PlayMode }
* @default PlayMode.Normal
@@ -3445,7 +3634,7 @@ declare interface AnimateParam {
* @since 9
*/
/**
- * Animation playback mode. By default, the animation is played from the beginning after the playback is complete.
+ * Playback mode. By default, the animation is played from the beginning after the playback is complete.
*
* @type { ?PlayMode }
* @default PlayMode.Normal
@@ -3455,7 +3644,7 @@ declare interface AnimateParam {
* @since 10
*/
/**
- * Animation playback mode. By default, the animation is played from the beginning after the playback is complete.
+ * Playback mode. By default, the animation is played from the beginning after the playback is complete.
*
* @type { ?PlayMode }
* @default PlayMode.Normal
@@ -3468,14 +3657,14 @@ declare interface AnimateParam {
playMode?: PlayMode;
/**
- * Callback invoked when the animation playback is complete or the ability is about to enter the background.
+ * Callback invoked when the animation playback is complete.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * Callback invoked when the animation playback is complete or the ability is about to enter the background.
+ * Callback invoked when the animation playback is complete.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -3483,7 +3672,7 @@ declare interface AnimateParam {
* @since 9
*/
/**
- * Callback invoked when the animation playback is complete or the ability is about to enter the background.
+ * Callback invoked when the animation playback is complete.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -3492,7 +3681,7 @@ declare interface AnimateParam {
* @since 10
*/
/**
- * Callback invoked when the animation playback is complete or the ability is about to enter the background.
+ * Callback invoked when the animation playback is complete.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -3504,7 +3693,7 @@ declare interface AnimateParam {
onFinish?: () => void;
/**
- * Define the type of onFinish callback in animation.
+ * Type of the **onFinish** callback.
*
* @type { ?FinishCallbackType }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -3513,7 +3702,8 @@ declare interface AnimateParam {
* @since 11
*/
/**
- * Define the type of onFinish callback in animation.
+ * Type of the **onFinish** callback.
+ * Default value: FinishCallbackType.REMOVED.
*
* @type { ?FinishCallbackType }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -3525,14 +3715,14 @@ declare interface AnimateParam {
finishCallbackType?: FinishCallbackType;
/**
- * Indicates expectedFrameRateRange including minimum、maximum and expected frame rate.
+ * Expected frame rate range of the animation.
*
* @type { ?ExpectedFrameRateRange }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 11
*/
/**
- * Indicates expectedFrameRateRange including minimum、maximum and expected frame rate.
+ * Expected frame rate range of the animation.
*
* @type { ?ExpectedFrameRateRange }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -3571,20 +3761,24 @@ declare interface AnimateParam {
*/
interface ICurve {
/**
- * Get curve value by fraction.
+ * Implements calculation.
*
- * @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.
+ * @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**.
+ *
* @returns { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @form
* @since 9
*/
/**
- * Get curve value by fraction.
+ * Implements calculation.
*
- * @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.
+ * @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**.
+ *
* @returns { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -3592,10 +3786,12 @@ interface ICurve {
* @since 10
*/
/**
- * Get curve value by fraction.
+ * Implements calculation.
*
- * @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.
+ * @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**.
+ *
* @returns { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -3632,14 +3828,22 @@ interface ICurve {
*/
declare interface MotionPathOptions {
/**
- * The path info.
+ * 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.
*
* @type { string }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The path info.
+ * 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.
*
* @type { string }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -3647,7 +3851,11 @@ declare interface MotionPathOptions {
* @since 10
*/
/**
- * The path info.
+ * 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.
*
* @type { string }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -3658,7 +3866,9 @@ declare interface MotionPathOptions {
path: string;
/**
- * The origin point info in range [0,1).
+ * 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**.
*
* @type { ?number }
* @default 0.0
@@ -3666,7 +3876,9 @@ declare interface MotionPathOptions {
* @since 7
*/
/**
- * The origin point info in range [0,1).
+ * 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**.
*
* @type { ?number }
* @default 0.0
@@ -3675,7 +3887,9 @@ declare interface MotionPathOptions {
* @since 10
*/
/**
- * The origin point info in range [0,1).
+ * 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**.
*
* @type { ?number }
* @default 0.0
@@ -3687,7 +3901,10 @@ declare interface MotionPathOptions {
from?: number;
/**
- * he distance point info in range (0,1].
+ * 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**.
*
* @type { ?number }
* @default 1.0
@@ -3695,7 +3912,10 @@ declare interface MotionPathOptions {
* @since 7
*/
/**
- * he distance point info in range (0,1].
+ * 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**.
*
* @type { ?number }
* @default 1.0
@@ -3704,7 +3924,10 @@ declare interface MotionPathOptions {
* @since 10
*/
/**
- * The distance point info in range (0,1].
+ * 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**.
*
* @type { ?number }
* @default 1.0
@@ -3716,7 +3939,7 @@ declare interface MotionPathOptions {
to?: number;
/**
- * The rotate info.
+ * Whether to rotate along the path.
*
* @type { ?boolean }
* @default false
@@ -3724,7 +3947,7 @@ declare interface MotionPathOptions {
* @since 7
*/
/**
- * The rotate info.
+ * Whether to rotate along the path.
*
* @type { ?boolean }
* @default false
@@ -3733,7 +3956,7 @@ declare interface MotionPathOptions {
* @since 10
*/
/**
- * The rotate info.
+ * Whether to rotate along the path.
*
* @type { ?boolean }
* @default false
@@ -3779,7 +4002,10 @@ declare interface sharedTransitionOptions {
* @since 7
*/
/**
- * Animation duration, in ms.
+ * Animation duration.
+ * Default value: **1000**.
+ * Unit: ms.
+ * Value range: [0, +∞).
*
* @type { ?number }
* @default 1000
@@ -3788,7 +4014,10 @@ declare interface sharedTransitionOptions {
* @since 10
*/
/**
- * Animation duration, in ms.
+ * Animation duration.
+ * Default value: **1000**.
+ * Unit: ms.
+ * Value range: [0, +∞).
*
* @type { ?number }
* @default 1000
@@ -3800,7 +4029,7 @@ declare interface sharedTransitionOptions {
duration?: number;
/**
- * Animation duration, in ms.
+ * Animation curve. You are advised to specify the curve using the Curve or ICurve type.
*
* @type { ?(Curve | string | ICurve) }
* @default 1000
@@ -3808,7 +4037,11 @@ declare interface sharedTransitionOptions {
* @since 7
*/
/**
- * Animation curve.
+ * 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**.
*
* @type { ?(Curve | string | ICurve) }
* @default 1000
@@ -3817,7 +4050,11 @@ declare interface sharedTransitionOptions {
* @since 10
*/
/**
- * Animation curve.
+ * 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**.
*
* @type { ?(Curve | string | ICurve) }
* @default 1000
@@ -4540,6 +4777,18 @@ 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
@@ -4942,14 +5191,18 @@ declare enum TransitionHierarchyStrategy {
*/
declare interface TranslateOptions {
/**
- * The param of x direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of x direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -4957,7 +5210,9 @@ declare interface TranslateOptions {
* @since 9
*/
/**
- * The param of x direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -4966,7 +5221,9 @@ declare interface TranslateOptions {
* @since 10
*/
/**
- * The param of x direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -4978,14 +5235,18 @@ declare interface TranslateOptions {
x?: number | string;
/**
- * The param of y direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of y direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -4993,7 +5254,9 @@ declare interface TranslateOptions {
* @since 9
*/
/**
- * The param of y direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5002,7 +5265,9 @@ declare interface TranslateOptions {
* @since 10
*/
/**
- * The param of y direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5014,14 +5279,16 @@ declare interface TranslateOptions {
y?: number | string;
/**
- * The param of z direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of z direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5029,7 +5296,8 @@ declare interface TranslateOptions {
* @since 9
*/
/**
- * The param of z direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5038,7 +5306,8 @@ declare interface TranslateOptions {
* @since 10
*/
/**
- * The param of z direction.
+ * 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.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5086,14 +5355,20 @@ declare interface TranslateOptions {
*/
declare interface ScaleOptions {
/**
- * The param of x direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of x direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5101,7 +5376,10 @@ declare interface ScaleOptions {
* @since 9
*/
/**
- * The param of x direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5110,7 +5388,10 @@ declare interface ScaleOptions {
* @since 10
*/
/**
- * The param of x direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5122,14 +5403,20 @@ declare interface ScaleOptions {
x?: number;
/**
- * The param of y direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of y direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5137,7 +5424,10 @@ declare interface ScaleOptions {
* @since 9
*/
/**
- * The param of y direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5146,7 +5436,10 @@ declare interface ScaleOptions {
* @since 10
*/
/**
- * The param of y direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5158,14 +5451,18 @@ declare interface ScaleOptions {
y?: number;
/**
- * The param of z direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of z direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5173,7 +5470,9 @@ declare interface ScaleOptions {
* @since 9
*/
/**
- * The param of z direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5182,7 +5481,9 @@ declare interface ScaleOptions {
* @since 10
*/
/**
- * The param of z direction.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5194,14 +5495,14 @@ declare interface ScaleOptions {
z?: number;
/**
- * The param of center point of x.
+ * X coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of center point of x.
+ * X coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5209,7 +5510,7 @@ declare interface ScaleOptions {
* @since 9
*/
/**
- * The param of center point of x.
+ * X coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5218,7 +5519,7 @@ declare interface ScaleOptions {
* @since 10
*/
/**
- * The param of center point of x.
+ * X coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5230,14 +5531,14 @@ declare interface ScaleOptions {
centerX?: number | string;
/**
- * The param of center point of y.
+ * Y coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of center point of y.
+ * Y coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5245,7 +5546,7 @@ declare interface ScaleOptions {
* @since 9
*/
/**
- * The param of center point of y.
+ * Y coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5254,7 +5555,7 @@ declare interface ScaleOptions {
* @since 10
*/
/**
- * The param of center point of y.
+ * Y coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5312,7 +5613,9 @@ declare interface AlignRuleOption {
* @since 10
*/
/**
- * The param of left align.
+ * Left alignment.
+ * anchor: ID of the component that functions as the anchor point.
+ * align: alignment mode relative to the anchor component.
*
* @type { ?object }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5341,7 +5644,9 @@ declare interface AlignRuleOption {
* @since 10
*/
/**
- * The param of right align.
+ * Right alignment.
+ * anchor: ID of the component that functions as the anchor point.
+ * align: alignment mode relative to the anchor component.
*
* @type { ?object }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5370,7 +5675,9 @@ declare interface AlignRuleOption {
* @since 10
*/
/**
- * The param of middle align.
+ * Horizontal center alignment.
+ * anchor: ID of the component that functions as the anchor point.
+ * align: alignment mode relative to the anchor component.
*
* @type { ?object }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5399,7 +5706,9 @@ declare interface AlignRuleOption {
* @since 10
*/
/**
- * The param of top align.
+ * Top alignment.
+ * anchor: ID of the component that functions as the anchor point.
+ * align: alignment mode relative to the anchor component.
*
* @type { ?object }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5427,7 +5736,9 @@ declare interface AlignRuleOption {
* @since 10
*/
/**
- * The param of bottom align.
+ * Bottom alignment.
+ * anchor: ID of the component that functions as the anchor point.
+ * align: alignment mode relative to the anchor component.
*
* @type { ?object }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5455,7 +5766,9 @@ declare interface AlignRuleOption {
* @since 10
*/
/**
- * The param of center align.
+ * Vertical center alignment.
+ * anchor: ID of the component that functions as the anchor point.
+ * align: alignment mode relative to the anchor component.
*
* @type { ?object }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5477,7 +5790,8 @@ declare interface AlignRuleOption {
* @since 11
*/
/**
- * Defines the bias ratio in horizontal and vertical direction.
+ * 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.
*
* @type { ?Bias }
* @default {horizontal:0.5,vertical:0.5}
@@ -5501,7 +5815,7 @@ declare interface AlignRuleOption {
*/
declare interface LocalizedHorizontalAlignParam {
/**
- * The anchor of localized align param.
+ * ID of the component that serves as the anchor.
*
* @type { string }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5512,7 +5826,7 @@ declare interface LocalizedHorizontalAlignParam {
anchor: string;
/**
- * The align of localized align param.
+ * Horizontal alignment mode relative to the anchor component.
*
* @type { HorizontalAlign }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5534,7 +5848,7 @@ declare interface LocalizedHorizontalAlignParam {
*/
declare interface LocalizedVerticalAlignParam {
/**
- * The anchor of localized align param.
+ * ID of the component that serves as the anchor.
*
* @type { string }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5545,7 +5859,7 @@ declare interface LocalizedVerticalAlignParam {
anchor: string;
/**
- * The align of localized align param.
+ * Vertical alignment mode relative to the anchor component.
*
* @type { VerticalAlign }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5567,7 +5881,7 @@ declare interface LocalizedVerticalAlignParam {
*/
declare interface LocalizedAlignRuleOptions {
/**
- * The param of start align.
+ * Left alignment with left-to-right scripts and right alignment with right-to-left scripts in the horizontal direction.
*
* @type { ?LocalizedHorizontalAlignParam }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5578,7 +5892,7 @@ declare interface LocalizedAlignRuleOptions {
start?: LocalizedHorizontalAlignParam;
/**
- * The param of end align.
+ * Right alignment with left-to-right scripts and left alignment with right-to-left scripts in the horizontal direction.
*
* @type { ?LocalizedHorizontalAlignParam }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5589,7 +5903,7 @@ declare interface LocalizedAlignRuleOptions {
end?: LocalizedHorizontalAlignParam;
/**
- * The param of middle align.
+ * Center alignment in the horizontal direction.
*
* @type { ?LocalizedHorizontalAlignParam }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5600,7 +5914,7 @@ declare interface LocalizedAlignRuleOptions {
middle?: LocalizedHorizontalAlignParam;
/**
- * The param of top align.
+ * Top alignment in the vertical direction.
*
* @type { ?LocalizedVerticalAlignParam }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5611,7 +5925,7 @@ declare interface LocalizedAlignRuleOptions {
top?: LocalizedVerticalAlignParam;
/**
- * The param of bottom align.
+ * Bottom alignment in the vertical direction.
*
* @type { ?LocalizedVerticalAlignParam }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5622,7 +5936,7 @@ declare interface LocalizedAlignRuleOptions {
bottom?: LocalizedVerticalAlignParam;
/**
- * The param of center align.
+ * Center alignment in the vertical direction.
*
* @type { ?LocalizedVerticalAlignParam }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5633,7 +5947,8 @@ declare interface LocalizedAlignRuleOptions {
center?: LocalizedVerticalAlignParam;
/**
- * Defines the bias ratio in horizontal and vertical direction.
+ * 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.
*
* @type { ?Bias }
* @default {horizontal:0.5,vertical:0.5}
@@ -5646,7 +5961,7 @@ declare interface LocalizedAlignRuleOptions {
}
/**
- * Defines the style of the chain in relative container.
+ * Enumerates the chain styles in relative container.
*
* @enum { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5656,7 +5971,7 @@ declare interface LocalizedAlignRuleOptions {
*/
declare enum ChainStyle {
/**
- * Elements of the chain will be spread out.
+ * Child components are evenly distributed among constraint anchors.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -5666,7 +5981,7 @@ declare enum ChainStyle {
SPREAD,
/**
- * Elements except chain's head and tail will be spread out.
+ * All child components except the first and last ones are evenly distributed among constraint anchors.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -5676,7 +5991,7 @@ declare enum ChainStyle {
SPREAD_INSIDE,
/**
- * Elements of the chain will be packed together.
+ * There is no gap between child components in the chain.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -5722,14 +6037,14 @@ declare enum ChainStyle {
*/
declare interface RotateOptions {
/**
- * The param of x direction.
+ * X coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of x direction.
+ * X coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5737,7 +6052,7 @@ declare interface RotateOptions {
* @since 9
*/
/**
- * The param of x direction.
+ * X coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5746,7 +6061,7 @@ declare interface RotateOptions {
* @since 10
*/
/**
- * The param of x direction.
+ * X coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5758,14 +6073,14 @@ declare interface RotateOptions {
x?: number;
/**
- * The param of y direction.
+ * Y coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of y direction.
+ * Y coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5773,7 +6088,7 @@ declare interface RotateOptions {
* @since 9
*/
/**
- * The param of y direction.
+ * Y coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5782,7 +6097,7 @@ declare interface RotateOptions {
* @since 10
*/
/**
- * The param of y direction.
+ * Y coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5794,14 +6109,14 @@ declare interface RotateOptions {
y?: number;
/**
- * The param of z direction.
+ * Z coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of z direction.
+ * Z coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5809,7 +6124,7 @@ declare interface RotateOptions {
* @since 9
*/
/**
- * The param of z direction.
+ * Z coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5818,7 +6133,7 @@ declare interface RotateOptions {
* @since 10
*/
/**
- * The param of z direction.
+ * Z coordinate of the rotation axis vector.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5830,14 +6145,14 @@ declare interface RotateOptions {
z?: number;
/**
- * The param of center point of x.
+ * X coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of center point of x.
+ * X coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5845,7 +6160,7 @@ declare interface RotateOptions {
* @since 9
*/
/**
- * The param of center point of x.
+ * X coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5854,7 +6169,7 @@ declare interface RotateOptions {
* @since 10
*/
/**
- * The param of center point of x.
+ * X coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5866,21 +6181,21 @@ declare interface RotateOptions {
centerX?: number | string;
/**
- * The param of center point of y.
+ * Y coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * The param of center point of y.
+ * Y coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 9
*/
/**
- * The param of center point of y.
+ * Y coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5889,7 +6204,7 @@ declare interface RotateOptions {
* @since 10
*/
/**
- * The param of center point of y.
+ * Y coordinate of the transformation center point (anchor). Unit is vp.
*
* @type { ?(number | string) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5901,7 +6216,7 @@ declare interface RotateOptions {
centerY?: number | string;
/**
- * The param of center point of z.
+ * Z-axis anchor, that is, the z-component of the 3D rotation center point.
*
* @type { ?number }
* @default 0
@@ -5911,7 +6226,7 @@ declare interface RotateOptions {
* @since 10
*/
/**
- * The param of center point of z.
+ * Z-axis anchor, that is, the z-component of the 3D rotation center point.
*
* @type { ?number }
* @default 0
@@ -5924,7 +6239,10 @@ declare interface RotateOptions {
centerZ?: number;
/**
- * The param of camera distance, value range (-∞, ∞).
+ * 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.
+ *
* @type { ?number }
* @default 0
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5933,7 +6251,10 @@ declare interface RotateOptions {
* @since 10
*/
/**
- * The param of camera distance, value range (-∞, ∞).
+ * 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.
+ *
* @type { ?number }
* @default 0
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -5981,6 +6302,108 @@ declare interface RotateOptions {
angle: number | string;
}
+/**
+ * The param of rotate about angle.
+ *
+ * @interface RotateAngleOptions
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+declare interface RotateAngleOptions {
+ /**
+ * the angle of the x-axis direction.
+ *
+ * @type { ?(number | string) }
+ * @default 0
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ angleX?: number | string;
+
+ /**
+ * the angle of the y-axis direction.
+ *
+ * @type { ?(number | string) }
+ * @default 0
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ angleY?: number | string;
+
+ /**
+ * the angle of the z-axis direction.
+ *
+ * @type { ?(number | string) }
+ * @default 0
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ angleZ?: number | string;
+
+ /**
+ * The param of center point of x.
+ *
+ * @type { ?(number | string) }
+ * @default '50%'
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ centerX?: number | string;
+
+ /**
+ * The param of center point of y.
+ *
+ * @type { ?(number | string) }
+ * @default '50%'
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ centerY?: number | string;
+
+ /**
+ * The param of center point of z.
+ *
+ * @type { ?number }
+ * @default 0
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ centerZ?: number;
+
+ /**
+ * The param of camera distance, value range (-∞, ∞).
+ * @type { ?number }
+ * @default 0
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ perspective?: number;
+}
+
/**
* Defines the param of transition.
*
@@ -5992,7 +6415,10 @@ declare interface RotateOptions {
*/
declare interface TransitionOptions {
/**
- * Defines the param of type.
+ * 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.
*
* @type { ?TransitionType }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -6001,7 +6427,11 @@ declare interface TransitionOptions {
*/
type?: TransitionType;
/**
- * Defines the param of opacity.
+ * 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.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -6010,7 +6440,11 @@ declare interface TransitionOptions {
*/
opacity?: number;
/**
- * Defines the param of translate.
+ * 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.
*
* @type { ?TranslateOptions }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -6019,7 +6453,15 @@ declare interface TransitionOptions {
*/
translate?: TranslateOptions;
/**
- * Defines the param of scale.
+ * 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.
+ *
*
* @type { ?ScaleOptions }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -6028,7 +6470,11 @@ declare interface TransitionOptions {
*/
scale?: ScaleOptions;
/**
- * Defines the param of rotate.
+ * 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.
*
* @type { ?RotateOptions }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -6078,7 +6524,7 @@ declare enum TransitionEdge {
TOP,
/**
- * Bottom edge
+ * Bottom edge of the window.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6086,7 +6532,7 @@ declare enum TransitionEdge {
* @since 10
*/
/**
- * Bottom edge
+ * Bottom edge of the window.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6097,7 +6543,8 @@ declare enum TransitionEdge {
BOTTOM,
/**
- * Start edge
+ * Start edge of the window, which is the left edge for left-to-right
+ * scripts and the right edge for right-to-left scripts.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6105,7 +6552,8 @@ declare enum TransitionEdge {
* @since 10
*/
/**
- * Start edge
+ * Start edge of the window, which is the left edge for left-to-right
+ * scripts and the right edge for right-to-left scripts.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6116,7 +6564,8 @@ declare enum TransitionEdge {
START,
/**
- * End edge
+ * End edge of the window, which is the right edge for left-to-right scripts
+ * and the left edge for right-to-left scripts.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6124,7 +6573,8 @@ declare enum TransitionEdge {
* @since 10
*/
/**
- * End edge
+ * End edge of the window, which is the right edge for left-to-right scripts
+ * and the left edge for right-to-left scripts.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6170,6 +6620,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
@@ -6210,9 +6661,20 @@ 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
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @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
@@ -6269,7 +6731,8 @@ declare class TransitionEffect<
static readonly IDENTITY: TransitionEffect<"identity">;
/**
- * Specifies a transition effect with transparency of 0, which is equivalent to TransitionEffect.opacity(0).
+ * 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)**
*
* @type { TransitionEffect<"opacity"> }
* @readonly
@@ -6280,7 +6743,8 @@ declare class TransitionEffect<
* @since 10
*/
/**
- * Specifies a transition effect with transparency of 0, which is equivalent to TransitionEffect.opacity(0).
+ * 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)**
*
* @type { TransitionEffect<"opacity"> }
* @readonly
@@ -6294,7 +6758,13 @@ declare class TransitionEffect<
static readonly OPACITY: TransitionEffect<"opacity">;
/**
- * Defines a slide transition effect
+ * 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)).
*
* @type { TransitionEffect<
* "asymmetric",
@@ -6309,7 +6779,13 @@ declare class TransitionEffect<
* @since 10
*/
/**
- * Defines a slide transition effect
+ * 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)).
*
* @type { TransitionEffect<
* "asymmetric",
@@ -6333,11 +6809,13 @@ declare class TransitionEffect<
>;
/**
- * 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).
- *
+ * 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.
+ *
* @type { TransitionEffect<"slideSwitch"> }
* @readonly
* @static
@@ -6347,11 +6825,13 @@ declare class TransitionEffect<
* @since 10
*/
/**
- * 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).
- *
+ * 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.
+ *
* @type { TransitionEffect<"slideSwitch"> }
* @readonly
* @static
@@ -6364,9 +6844,13 @@ declare class TransitionEffect<
static readonly SLIDE_SWITCH: TransitionEffect<"slideSwitch">;
/**
- * Creates a translate transition effect
+ * Translation of the component during transition, which is the value of the start point
+ * of insertion and the end point of deletion.
*
- * @param { TranslateOptions } options - translate options
+ * @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.
* @returns { TransitionEffect<"translate"> }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6374,9 +6858,13 @@ declare class TransitionEffect<
* @since 10
*/
/**
- * Creates a translate transition effect
+ * Translation of the component during transition, which is the value of the start point
+ * of insertion and the end point of deletion.
*
- * @param { TranslateOptions } options - translate options
+ * @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.
* @returns { TransitionEffect<"translate"> }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6387,19 +6875,20 @@ declare class TransitionEffect<
static translate(options: TranslateOptions): TransitionEffect<"translate">;
/**
- * 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.
+ * 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.
* @returns { TransitionEffect<"rotate"> }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6407,19 +6896,20 @@ declare class TransitionEffect<
* @since 10
*/
/**
- * Creates a rotation transition effect
+ * 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
- * 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.
+ * @param { RotateOptions } options - Rotate options.
* @returns { TransitionEffect<"rotate"> }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -6430,7 +6920,8 @@ declare class TransitionEffect<
static rotate(options: RotateOptions): TransitionEffect<"rotate">;
/**
- * Creates a scale transition effect
+ * Scaling of the component during transition, which is the value of the start point of insertion and
+ * the end point of deletion.
*
* @param { ScaleOptions } options - scale options
* @returns { TransitionEffect<"scale"> }
@@ -6440,7 +6931,8 @@ declare class TransitionEffect<
* @since 10
*/
/**
- * Creates a scale transition effect
+ * Scaling of the component during transition, which is the value of the start point of insertion and
+ * the end point of deletion.
*
* @param { ScaleOptions } options - scale options
* @returns { TransitionEffect<"scale"> }
@@ -6488,7 +6980,9 @@ declare class TransitionEffect<
static opacity(alpha: number): TransitionEffect<"opacity">;
/**
- * Creates a move transition effect
+ * 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.
*
* @param { TransitionEdge } edge - the edge that component will move to
* @returns { TransitionEffect<"move"> }
@@ -6498,7 +6992,9 @@ declare class TransitionEffect<
* @since 10
*/
/**
- * Creates a move transition effect
+ * 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.
*
* @param { TransitionEdge } edge - the edge that component will move to
* @returns { TransitionEffect<"move"> }
@@ -6585,7 +7081,7 @@ declare class TransitionEffect<
animation(value: AnimateParam): TransitionEffect;
/**
- * Combines another transition effect
+ * Combination of transition effects.
*
* @param { TransitionEffect } transitionEffect - transition effect which is be combined
* @returns { TransitionEffect } combined transition effect
@@ -6595,7 +7091,7 @@ declare class TransitionEffect<
* @since 10
*/
/**
- * Combines another transition effect
+ * Combination of transition effects.
*
* @param { TransitionEffect } transitionEffect - transition effect which is be combined
* @returns { TransitionEffect } combined transition effect
@@ -7137,7 +7633,9 @@ declare interface DragItemInfo {
declare function animateTo(value: AnimateParam, event: () => void): void;
/**
- * Define animation functions for immediate distribution.
+ * 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.
*
* @param { AnimateParam } value - Set animation effect parameters.
* @param { function } event - Specify the closure function that displays dynamic effects,
@@ -7150,26 +7648,38 @@ 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
@@ -7177,9 +7687,13 @@ 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
@@ -7192,26 +7706,38 @@ 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
@@ -7219,9 +7745,13 @@ 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
@@ -7236,7 +7766,9 @@ 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
*/
@@ -7244,7 +7776,9 @@ 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
@@ -7253,7 +7787,9 @@ 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
@@ -7263,7 +7799,9 @@ 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
@@ -7278,7 +7816,9 @@ 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
*/
@@ -7286,7 +7826,9 @@ 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
@@ -7295,7 +7837,9 @@ 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
@@ -7305,7 +7849,9 @@ 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
@@ -7320,7 +7866,9 @@ 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
*/
@@ -7328,7 +7876,9 @@ 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
@@ -7337,7 +7887,9 @@ 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
@@ -7347,7 +7899,9 @@ 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
@@ -7362,7 +7916,9 @@ 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
*/
@@ -7370,7 +7926,9 @@ 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
@@ -7379,7 +7937,9 @@ 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
@@ -7389,7 +7949,9 @@ 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
@@ -7495,7 +8057,7 @@ declare namespace cursorControl {
/**
* Change the mouse cursor style by param: 'PointerStyle'.
*
- * @param { PointerStyle } value
+ * @param { PointerStyle } value - Cursor style.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -7581,7 +8143,7 @@ declare interface EventTarget {
* @since 10
*/
/**
- * Area of current target.
+ * Area information of the target element.
*
* @type { Area }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -7644,7 +8206,7 @@ declare enum SourceType {
* @since 10
*/
/**
- * Unknown type.
+ * Unknown device type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -7739,7 +8301,7 @@ declare enum SourceTool {
* @since 10
*/
/**
- * Unknown type.
+ * Unknown input source.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -7869,7 +8431,7 @@ declare enum RepeatMode {
* @since 10
*/
/**
- * Repeat mode.
+ * The source image's slices are tiled. Tiles beyond the border box will be clipped.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -7895,7 +8457,7 @@ declare enum RepeatMode {
* @since 10
*/
/**
- * Stretch mode.
+ * The source image's slices are stretched to fill the border box.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -7921,7 +8483,7 @@ declare enum RepeatMode {
* @since 10
*/
/**
- * Round mode.
+ * The source image's slices are tiled to fill the border box. Tiles may be compressed when needed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -7947,7 +8509,7 @@ declare enum RepeatMode {
* @since 10
*/
/**
- * Space mode.
+ * 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
* @crossplatform
@@ -7987,14 +8549,14 @@ declare enum RepeatMode {
*/
declare enum BlurStyle {
/**
- * Defines the thin card material.
+ * Thin material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @form
* @since 9
*/
/**
- * Defines the thin card material.
+ * Thin material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8002,7 +8564,7 @@ declare enum BlurStyle {
* @since 10
*/
/**
- * Defines the thin card material.
+ * Thin material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8013,14 +8575,14 @@ declare enum BlurStyle {
Thin,
/**
- * Defines the regular card material.
+ * Regular material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @form
* @since 9
*/
/**
- * Defines the regular card material.
+ * Regular material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8028,7 +8590,7 @@ declare enum BlurStyle {
* @since 10
*/
/**
- * Defines the regular card material.
+ * Regular material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8039,14 +8601,14 @@ declare enum BlurStyle {
Regular,
/**
- * Defines the thick card material.
+ * Thick material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @form
* @since 9
*/
/**
- * Defines the thick card material.
+ * Thick material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8054,7 +8616,7 @@ declare enum BlurStyle {
* @since 10
*/
/**
- * Defines the thick card material.
+ * Thick material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8065,14 +8627,14 @@ declare enum BlurStyle {
Thick,
/**
- * Defines the thin background material.
+ * Material that creates the minimum depth of field effect.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the thin background material.
+ * Material that creates the minimum depth of field effect.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8083,14 +8645,14 @@ declare enum BlurStyle {
BACKGROUND_THIN,
/**
- * Defines the thin regular material.
+ * Material that creates a medium shallow depth of field effect.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the thin regular material.
+ * Material that creates a medium shallow depth of field effect.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8101,14 +8663,14 @@ declare enum BlurStyle {
BACKGROUND_REGULAR,
/**
- * Defines the thin thick material.
+ * Material that creates a high shallow depth of field effect.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the thin thick material.
+ * Material that creates a high shallow depth of field effect.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8119,14 +8681,14 @@ declare enum BlurStyle {
BACKGROUND_THICK,
/**
- * Defines the thin ultra thick material.
+ * Material that creates the maximum depth of field effect.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the thin ultra thick material.
+ * Material that creates the maximum depth of field effect.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8137,7 +8699,7 @@ declare enum BlurStyle {
BACKGROUND_ULTRA_THICK,
/**
- * Defines none material.
+ * No blur.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8145,7 +8707,7 @@ declare enum BlurStyle {
* @since 10
*/
/**
- * Defines none material.
+ * No blur.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8156,7 +8718,7 @@ declare enum BlurStyle {
NONE,
/**
- * Defines the ultra thin component material.
+ * Component ultra-thin material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8164,7 +8726,7 @@ declare enum BlurStyle {
* @since 11
*/
/**
- * Defines the ultra thin component material.
+ * Component ultra-thin material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8183,7 +8745,7 @@ declare enum BlurStyle {
* @since 11
*/
/**
- * Defines the thin component material.
+ * Component thin material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8202,7 +8764,7 @@ declare enum BlurStyle {
* @since 11
*/
/**
- * Defines the regular component material.
+ * Component regular material.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8381,14 +8943,16 @@ declare enum ThemeColorMode {
*/
declare enum AdaptiveColor {
/**
- * Defines the fixed value color adaptive mode.
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the fixed value color adaptive mode.
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8398,14 +8962,14 @@ declare enum AdaptiveColor {
DEFAULT,
/**
- * Defines the background average color adaptive mode.
+ * Adaptive color mode is used. The average color value of the color picking area is used as the mask color.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the background average color adaptive mode.
+ * Adaptive color mode is used. The average color value of the color picking area is used as the mask color.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8434,14 +8998,14 @@ declare enum AdaptiveColor {
*/
declare enum ModalTransition {
/**
- * Use default animation.
+ * Slide-up and slide-down animation for the modal.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Use default animation.
+ * Slide-up and slide-down animation for the modal.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8451,14 +9015,14 @@ declare enum ModalTransition {
DEFAULT,
/**
- * Use none animation.
+ * No transition animation for the modal.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Use none animation.
+ * No transition animation for the modal.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8468,14 +9032,14 @@ declare enum ModalTransition {
NONE,
/**
- * Use alpha animation.
+ * Opacity gradient animation for the modal.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Use alpha animation.
+ * Opacity gradient animation for the modal.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -8596,7 +9160,7 @@ declare interface BlurOptions {
* @crossplatform
* @form
* @atomicservice
- * @since 18
+ * @since 19
*/
declare interface SystemAdaptiveOptions {
/**
@@ -8607,7 +9171,7 @@ declare interface SystemAdaptiveOptions {
* @crossplatform
* @form
* @atomicservice
- * @since 18
+ * @since 19
*/
disableSystemAdaptation?: boolean;
}
@@ -8631,7 +9195,8 @@ declare interface SystemAdaptiveOptions {
*/
declare interface BlurStyleOptions {
/**
- * color mode
+ * Color mode used for the foreground blur.
+ * Default value: **ThemeColorMode.SYSTEM**.
*
* @type { ?ThemeColorMode }
* @default ThemeColorMode.SYSTEM
@@ -8639,7 +9204,8 @@ declare interface BlurStyleOptions {
* @since 10
*/
/**
- * color mode
+ * Color mode used for the foreground blur.
+ * Default value: **ThemeColorMode.SYSTEM**.
*
* @type { ?ThemeColorMode }
* @default ThemeColorMode.SYSTEM
@@ -8651,7 +9217,8 @@ declare interface BlurStyleOptions {
colorMode?: ThemeColorMode;
/**
- * adaptive color
+ * Adaptive color mode.
+ * Default value: **AdaptiveColor.DEFAULT**.
*
* @type { ?AdaptiveColor }
* @default AdaptiveColor.DEFAULT
@@ -8659,7 +9226,8 @@ declare interface BlurStyleOptions {
* @since 10
*/
/**
- * adaptive color
+ * Adaptive color mode.
+ * Default value: **AdaptiveColor.DEFAULT**.
*
* @type { ?AdaptiveColor }
* @default AdaptiveColor.DEFAULT
@@ -8671,9 +9239,9 @@ declare interface BlurStyleOptions {
adaptiveColor?: AdaptiveColor;
/**
- * 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.
+ * Foreground blur scale.
+ * Default value: **1.0**.
+ * Value range: [0.0, 1.0].
*
* @type { ?number }
* @default 1.0
@@ -8725,7 +9293,9 @@ declare interface BlurStyleOptions {
declare interface BackgroundEffectOptions {
/**
- * Define the radius size of BackgroundEffect.The range of this value is [0, ∞)
+ * Blur radius.
+ * Value range: [0, +∞).
+ * Default value: **0**.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -8733,7 +9303,9 @@ declare interface BackgroundEffectOptions {
* @since 11
*/
/**
- * Define the radius size of BackgroundEffect.The range of this value is [0, ∞)
+ * Blur radius.
+ * Value range: [0, +∞).
+ * Default value: **0**.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -8744,7 +9316,9 @@ declare interface BackgroundEffectOptions {
radius: number;
/**
- * Define the saturation of BackgroundEffect. Value range [0, ∞)
+ * Saturation.
+ * Value range: [0, +∞).
+ * Recommended value range: [0, 50].
*
* @type { ?number }
* @default 1
@@ -8753,7 +9327,9 @@ declare interface BackgroundEffectOptions {
* @since 11
*/
/**
- * Define the saturation of BackgroundEffect. Value range [0, ∞)
+ * Saturation.
+ * Value range: [0, +∞).
+ * Recommended value range: [0, 50].
*
* @type { ?number }
* @default 1
@@ -8765,8 +9341,10 @@ declare interface BackgroundEffectOptions {
saturation?: number;
/**
- * 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.
+ * Brightness.
+ * Value range: [0, +∞).
+ * Default value: **1** Recommended value range: [0, 2].
+ *
* @type { ?number }
* @default 1
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -8774,8 +9352,10 @@ declare interface BackgroundEffectOptions {
* @since 11
*/
/**
- * 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.
+ * Brightness.
+ * Value range: [0, +∞).
+ * Default value: **1** Recommended value range: [0, 2].
+ *
* @type { ?number }
* @default 1
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -8786,7 +9366,7 @@ declare interface BackgroundEffectOptions {
brightness?: number;
/**
- * color the brightness of BackgroundEffect.
+ * Color.
*
* @type { ?ResourceColor }
* @default Color.Transparent
@@ -8795,7 +9375,7 @@ declare interface BackgroundEffectOptions {
* @since 11
*/
/**
- * color the brightness of BackgroundEffect.
+ * Color.
*
* @type { ?ResourceColor }
* @default Color.Transparent
@@ -8923,7 +9503,7 @@ declare interface PickerTextStyle {
* @since 10
*/
/**
- * Define the text color of picker.
+ * Font color.
*
* @type { ?ResourceColor }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -8943,8 +9523,7 @@ declare interface PickerTextStyle {
* @since 10
*/
/**
- * Define the text font of picker.
- * Only support size and weight.
+ * Text style.
*
* @type { ?Font }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9123,14 +9702,14 @@ declare enum ShadowType {
COLOR,
/**
- * Define a blur type of shadow
+ * Blur.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Define a blur type of shadow
+ * Blur.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9176,14 +9755,14 @@ declare enum ShadowType {
*/
declare interface ShadowOptions {
/**
- * Define the radius size of shadow
+ * Blur radius of the shadow.
*
* @type { number | Resource }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * Define the radius size of shadow
+ * Blur radius of the shadow.
*
* @type { number | Resource }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9191,7 +9770,7 @@ declare interface ShadowOptions {
* @since 9
*/
/**
- * Define the radius size of shadow
+ * Blur radius of the shadow.
*
* @type { number | Resource }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9200,7 +9779,7 @@ declare interface ShadowOptions {
* @since 10
*/
/**
- * Define the radius size of shadow
+ * Blur radius of the shadow.
*
* @type { number | Resource }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9212,7 +9791,8 @@ declare interface ShadowOptions {
radius: number | Resource;
/**
- * Define the type of shadow
+ * Shadow type.
+ * Default value: **COLOR**.
*
* @type { ?ShadowType }
* @default ShadowType.COLOR
@@ -9221,7 +9801,8 @@ declare interface ShadowOptions {
* @since 10
*/
/**
- * Define the type of shadow
+ * Shadow type.
+ * Default value: **COLOR**.
*
* @type { ?ShadowType }
* @default ShadowType.COLOR
@@ -9233,14 +9814,14 @@ declare interface ShadowOptions {
type?: ShadowType;
/**
- * Define the color of shadow
+ * Color of the shadow. Default value: **Black**
*
* @type { ?(Color | string | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * Define the color of shadow
+ * Color of the shadow. Default value: **Black**
*
* @type { ?(Color | string | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9248,7 +9829,7 @@ declare interface ShadowOptions {
* @since 9
*/
/**
- * Define the color of shadow
+ * Color of the shadow. Default value: **Black**
*
* @type { ?(Color | string | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9257,7 +9838,7 @@ declare interface ShadowOptions {
* @since 10
*/
/**
- * Define the color or the color strategy of shadow
+ * Color of the shadow. Default value: **Black**
*
* @type { ?(Color | string | Resource| ColoringStrategy) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9269,14 +9850,14 @@ declare interface ShadowOptions {
color?: Color | string | Resource | ColoringStrategy;
/**
- * Define the horizontal offset size of shadow
+ * Offset of the shadow along the x-axis. Unit is px. Default value is 0.
*
* @type { ?(number | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * Define the horizontal offset size of shadow
+ * Offset of the shadow along the x-axis. Unit is px. Default value is 0.
*
* @type { ?(number | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9284,7 +9865,7 @@ declare interface ShadowOptions {
* @since 9
*/
/**
- * Define the horizontal offset size of shadow
+ * Offset of the shadow along the x-axis. Unit is px. Default value is 0.
*
* @type { ?(number | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9293,7 +9874,7 @@ declare interface ShadowOptions {
* @since 10
*/
/**
- * Define the horizontal offset size of shadow
+ * Offset of the shadow along the x-axis. Unit is px. Default value is 0.
*
* @type { ?(number | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9305,14 +9886,14 @@ declare interface ShadowOptions {
offsetX?: number | Resource;
/**
- * Define the vertical offset size of shadow
+ * Offset of the shadow along the y-axis. Unit is px. Default value is 0.
*
* @type { ?(number | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @since 7
*/
/**
- * Define the vertical offset size of shadow
+ * Offset of the shadow along the y-axis. Unit is px. Default value is 0.
*
* @type { ?(number | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9320,7 +9901,7 @@ declare interface ShadowOptions {
* @since 9
*/
/**
- * Define the vertical offset size of shadow
+ * Offset of the shadow along the y-axis. Unit is px. Default value is 0.
*
* @type { ?(number | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9329,7 +9910,7 @@ declare interface ShadowOptions {
* @since 10
*/
/**
- * Define the vertical offset size of shadow
+ * Offset of the shadow along the y-axis. Unit is px. Default value is 0.
*
* @type { ?(number | Resource) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9341,7 +9922,11 @@ declare interface ShadowOptions {
offsetY?: number | Resource;
/**
- * Define whether the shadow should fill the area
+ * 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.
*
* @type { ?boolean }
* @default false
@@ -9350,7 +9935,11 @@ declare interface ShadowOptions {
* @since 11
*/
/**
- * Define whether the shadow should fill the area
+ * 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.
*
* @type { ?boolean }
* @default false
@@ -9415,14 +10004,14 @@ declare enum ShadowStyle {
OUTER_DEFAULT_SM,
/**
- * Defines the medium default shadow style.
+ * Medium shadow.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the medium default shadow style.
+ * Medium shadow.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9432,14 +10021,14 @@ declare enum ShadowStyle {
OUTER_DEFAULT_MD,
/**
- * Defines the large default shadow style.
+ * Large shadow.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the large default shadow style.
+ * Large shadow.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9449,14 +10038,14 @@ declare enum ShadowStyle {
OUTER_DEFAULT_LG,
/**
- * Defines the small floating shadow style.
+ * Floating medium shadow.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the small floating shadow style.
+ * Floating medium shadow.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9473,7 +10062,7 @@ declare enum ShadowStyle {
* @since 10
*/
/**
- * Defines the medium floating shadow style.
+ * Floating medium shadow.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9502,7 +10091,11 @@ declare enum ShadowStyle {
*/
declare interface MultiShadowOptions {
/**
- * Current shadow radius.
+ * Shadow blur radius.
+ * Unit: vp.
+ *
**NOTE**:
+ * A value less than or equal to 0 is handled as the default value.
+ *
**NOTE**:
+ * A value less than or equal to 0 is handled as the default value.
+ *
*
* @type { ?(number | Resource) }
* @default 20
@@ -9523,7 +10120,8 @@ declare interface MultiShadowOptions {
radius?: number | Resource;
/**
- * Current shadow offsetX.
+ * Offset on the x-axis.
+ * Unit: vp.
*
* @type { ?(number | Resource) }
* @default 5
@@ -9532,7 +10130,8 @@ declare interface MultiShadowOptions {
* @since 10
*/
/**
- * Current shadow offsetX.
+ * Offset on the x-axis.
+ * Unit: vp.
*
* @type { ?(number | Resource) }
* @default 5
@@ -9544,7 +10143,8 @@ declare interface MultiShadowOptions {
offsetX?: number | Resource;
/**
- * Current shadow offsetY
+ * Offset on the y-axis.
+ * Unit: vp.
*
* @type { ?(number | Resource) }
* @default 5
@@ -9553,7 +10153,8 @@ declare interface MultiShadowOptions {
* @since 10
*/
/**
- * Current shadow offsetY
+ * Offset on the y-axis.
+ * Unit: vp.
*
* @type { ?(number | Resource) }
* @default 5
@@ -9573,7 +10174,7 @@ declare interface MultiShadowOptions {
* @since 10
*/
/**
- * Enumerates the safe area types.
+ * The types of expanded safe areas.
*
* @enum { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9589,7 +10190,7 @@ declare enum SafeAreaType {
* @since 10
*/
/**
- * Default area of the system, including the status bar and navigation bar.
+ * Default non-safe area of the system, including the status bar and navigation bar.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9605,7 +10206,7 @@ declare enum SafeAreaType {
* @since 10
*/
/**
- * Notch or punch hole.
+ * Non-safe area of the device like Notch or punch hole.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9655,7 +10256,7 @@ declare enum SafeAreaEdge {
* @since 10
*/
/**
- * Top edge of the safe area.
+ * Top edge.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9671,7 +10272,7 @@ declare enum SafeAreaEdge {
* @since 10
*/
/**
- * Bottom edge of the safe area.
+ * Bottom edge.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9687,7 +10288,7 @@ declare enum SafeAreaEdge {
* @since 10
*/
/**
- * Start edge of the safe area.
+ * Start edge.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9703,7 +10304,7 @@ declare enum SafeAreaEdge {
* @since 10
*/
/**
- * End edge of the safe area.
+ * End edge.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9714,7 +10315,7 @@ declare enum SafeAreaEdge {
}
/**
- * Enumerates the safe area types can be ignored.
+ * Describe the types for expanding the safe area in layout.
*
* @enum { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9724,7 +10325,7 @@ declare enum SafeAreaEdge {
*/
declare enum LayoutSafeAreaType {
/**
- * Default area of the system, including the status bar and navigation bar.
+ * Default non-safe area of the system, including the status bar and navigation bar.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9732,20 +10333,40 @@ declare enum LayoutSafeAreaType {
* @since 12
*/
SYSTEM = 0,
-}
-/**
- * Enumerates the safe area edges can be ignored.
- *
- * @enum { number }
- * @syscap SystemCapability.ArkUI.ArkUI.Full
- * @crossplatform
- * @atomicservice
- * @since 12
- */
-declare enum LayoutSafeAreaEdge {
/**
- * Top edge of the safe area.
+ * Soft keyboard area.
+ *
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ KEYBOARD = 1,
+
+ /**
+ * All safe area regions.
+ *
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ ALL = 2,
+}
+
+/**
+ * Define the edges for expanding the safe area in layout.
+ *
+ * @enum { number }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 12
+ */
+declare enum LayoutSafeAreaEdge {
+ /**
+ * Top edge.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9755,7 +10376,7 @@ declare enum LayoutSafeAreaEdge {
TOP = 0,
/**
- * Bottom edge of the safe area.
+ * Bottom edge.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9763,6 +10384,56 @@ declare enum LayoutSafeAreaEdge {
* @since 12
*/
BOTTOM = 1,
+
+ /**
+ * Start edge of the safe area.
+ *
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ START = 2,
+
+ /**
+ * End edge of the safe area.
+ *
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ END = 3,
+
+ /**
+ * Vertical edge of the safe area.
+ *
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ VERTICAL = 4,
+
+ /**
+ * Horizontal edge of the safe area.
+ *
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ HORIZONTAL = 5,
+
+ /**
+ * All edges of the safe area.
+ *
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ ALL = 6,
}
/**
@@ -9784,14 +10455,14 @@ declare enum LayoutSafeAreaEdge {
*/
declare enum SheetSize {
/**
- * Defines the sheet size medium height type. The height is half the screen height
+ * The sheet height is half of the screen height.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the sheet size medium height type. The height is half the screen height
+ * The sheet height is half of the screen height.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9801,14 +10472,14 @@ declare enum SheetSize {
MEDIUM,
/**
- * Defines the sheet size large height type. The height is almost screen height.
+ * The sheet height is almost the screen height.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * Defines the sheet size large height type. The height is almost screen height.
+ * The sheet height is almost the screen height.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9818,14 +10489,14 @@ declare enum SheetSize {
LARGE,
/**
- * Defines the sheet size fit content height type. The height fit content.
+ * The sheet height automatically adapts to the content.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 11
*/
/**
- * Defines the sheet size fit content height type. The height fit content.
+ * The sheet height automatically adapts to the content.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -9895,7 +10566,7 @@ declare interface BaseEvent {
* @since 10
*/
/**
- * Defines the current target which fires this event.
+ * Display area of the element that triggers the gesture event.
*
* @type { EventTarget }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9931,7 +10602,7 @@ declare interface BaseEvent {
* @since 10
*/
/**
- * Event timestamp.
+ * Timestamp of the event.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -9967,7 +10638,7 @@ declare interface BaseEvent {
* @since 10
*/
/**
- * the event source info.
+ * Event input device.
*
* @type { SourceType }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10020,7 +10691,7 @@ declare interface BaseEvent {
* @since 10
*/
/**
- * Touch pressure.
+ * Press pressure.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10049,7 +10720,7 @@ declare interface BaseEvent {
* @since 10
*/
/**
- * The angle between pencil projection on plane-X-Y and axis-Z.
+ * Angle between the projection of the stylus on the device plane and the x-axis.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10078,7 +10749,7 @@ declare interface BaseEvent {
* @since 10
*/
/**
- * The angle between pencil projection on plane-Y-Z and axis-Z.
+ * Angle between the projection of the stylus on the device plane and the y-axis.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10097,7 +10768,7 @@ declare interface BaseEvent {
* @crossplatform
* @form
* @atomicservice
- * @since 18
+ * @since 17
*/
rollAngle?: number;
@@ -10119,7 +10790,7 @@ declare interface BaseEvent {
* @since 10
*/
/**
- * The event tool type info.
+ * Event input source.
*
* @type { SourceTool }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10131,7 +10802,7 @@ declare interface BaseEvent {
sourceTool: SourceTool;
/**
- * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift'|'fn'
+ * Obtains the pressed status of modifier keys. The following modifier keys are supported: 'Ctrl'|'Alt'|'Shift'.
*
* @param { Array } keys - indicate the keys of the ModifierKey.
* @returns { boolean }
@@ -10222,9 +10893,11 @@ declare interface BorderImageOption {
* @since 11
*/
/**
- * Border image slice
+ * Slice width of the upper left corner, upper right corner, lower left corner,
+ * and lower right corner of the border image.
*
* @type { ?(Length | EdgeWidths | LocalizedEdgeWidths) }
+ * @default 0
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -10251,9 +10924,10 @@ declare interface BorderImageOption {
* @since 10
*/
/**
- * Border image repeat
+ * Repeat mode of the source image's slices on the border.
*
* @type { ?RepeatMode }
+ * @default RepeatMode.Stretch
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -10280,7 +10954,13 @@ declare interface BorderImageOption {
* @since 10
*/
/**
- * Border image source
+ * 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.
+ *
*
* @type { ?(string | Resource | LinearGradient) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10319,9 +10999,10 @@ declare interface BorderImageOption {
* @since 11
*/
/**
- * Border image width
+ * Width of the border image.
*
* @type { ?(Length | EdgeWidths | LocalizedEdgeWidths) }
+ * @default 0
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -10358,9 +11039,10 @@ declare interface BorderImageOption {
* @since 11
*/
/**
- * Border image outset
+ * Amount by which the border image is extended beyond the border box.
*
* @type { ?(Length | EdgeWidths | LocalizedEdgeWidths) }
+ * @default 0
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -10387,9 +11069,12 @@ declare interface BorderImageOption {
* @since 10
*/
/**
- * Border image center fill
+ * 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.
*
* @type { ?boolean }
+ * @default false
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @form
@@ -10422,6 +11107,32 @@ 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.
+ *
+ * @type { LayoutPolicy }
+ * @readonly
+ * @static
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ static readonly wrapContent: LayoutPolicy;
+ /**
+ * The component fills its content which means its size is as large as its children.
+ *
+ * @type { LayoutPolicy }
+ * @readonly
+ * @static
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @form
+ * @atomicservice
+ * @since 20
+ */
+ static readonly fixAtIdealSize: LayoutPolicy;
}
/**
@@ -10472,7 +11183,7 @@ declare interface ClickEvent extends BaseEvent {
* @since 10
*/
/**
- * X coordinate of the click point relative to the left edge of the device screen.
+ * X coordinate of the click relative to the upper left corner of the application screen.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10491,7 +11202,7 @@ declare interface ClickEvent extends BaseEvent {
* @since 10
*/
/**
- * Y coordinate of the click point relative to the upper edge of the device screen.
+ * Y coordinate of the click relative to the upper left corner of the application screen.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10510,7 +11221,7 @@ declare interface ClickEvent extends BaseEvent {
* @since 10
*/
/**
- * X coordinate of the click point relative to the left edge of the current window.
+ * X coordinate of the click relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10529,7 +11240,7 @@ declare interface ClickEvent extends BaseEvent {
* @since 10
*/
/**
- * Y coordinate of the click point relative to the upper edge of the current window.
+ * Y coordinate of the click relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10540,7 +11251,7 @@ declare interface ClickEvent extends BaseEvent {
windowY: number;
/**
- * X coordinate of the click point relative to the left edge of the current window.
+ * X coordinate of the click relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10551,7 +11262,7 @@ declare interface ClickEvent extends BaseEvent {
screenX: number;
/**
- * Y coordinate of the click point relative to the upper edge of the current window.
+ * Y coordinate of the click relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10634,7 +11345,7 @@ declare interface ClickEvent extends BaseEvent {
y: number;
/**
- * Type of the touch hand.
+ * Whether the event is triggered by a left-hand or right-hand tap.
*
* @type { InteractionHand }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10648,6 +11359,7 @@ declare interface ClickEvent extends BaseEvent {
* Prevent the default function.
*
* @type { function }
+ * @throws { BusinessError } 100017 - Component does not support prevent function.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -10812,7 +11524,7 @@ declare interface MouseEvent extends BaseEvent {
* @since 10
*/
/**
- * X coordinate of the mouse point relative to the left edge of the device screen.
+ * X coordinate of the mouse pointer relative to the upper left corner of the application screen.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10829,7 +11541,7 @@ declare interface MouseEvent extends BaseEvent {
* @since 10
*/
/**
- * Y coordinate of the mouse point relative to the upper edge of the device screen.
+ * Y coordinate of the mouse pointer relative to the upper left corner of the application screen.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10846,7 +11558,7 @@ declare interface MouseEvent extends BaseEvent {
* @since 10
*/
/**
- * X coordinate of the mouse point relative to the left edge of the current window.
+ * X coordinate of the mouse pointer relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10863,7 +11575,7 @@ declare interface MouseEvent extends BaseEvent {
* @since 10
*/
/**
- * Y coordinate of the mouse point relative to the upper edge of the current window.
+ * Y coordinate of the mouse pointer relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10873,7 +11585,7 @@ declare interface MouseEvent extends BaseEvent {
windowY: number;
/**
- * X coordinate of the mouse point relative to the left edge of the current window.
+ * X coordinate of the mouse pointer relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10884,7 +11596,7 @@ declare interface MouseEvent extends BaseEvent {
screenX: number;
/**
- * Y coordinate of the mouse point relative to the upper edge of the current window.
+ * Y coordinate of the mouse pointer relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10902,7 +11614,7 @@ declare interface MouseEvent extends BaseEvent {
* @since 8
*/
/**
- * X coordinate of the mouse point relative to the left edge of the mouse hit element.
+ * X coordinate of the mouse pointer relative to the upper left corner of the component being clicked.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10919,7 +11631,7 @@ declare interface MouseEvent extends BaseEvent {
* @since 8
*/
/**
- * Y coordinate of the mouse point relative to the upper edge of the mouse hit element.
+ * Y coordinate of the mouse pointer relative to the upper left corner of the component being clicked.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10936,7 +11648,7 @@ declare interface MouseEvent extends BaseEvent {
* @since 8
*/
/**
- * The blocking event pops up.
+ * Stops the event from bubbling upwards or downwards.
*
* @type { function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -10968,7 +11680,7 @@ declare interface MouseEvent extends BaseEvent {
rawDeltaY?: number;
/**
- * The pressed buttons of the mouse event.
+ * Array of all mouse buttons that are currently pressed.
*
* @type { ?MouseButton[] }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11126,7 +11838,7 @@ declare interface TouchObject {
* @since 10
*/
/**
- * Finger unique identifier.
+ * Unique identifier of a finger.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11145,7 +11857,7 @@ declare interface TouchObject {
* @since 10
*/
/**
- * X coordinate of the touch point relative to the left edge of the device screen.
+ * X coordinate of the touch point relative to the upper left corner of the application screen.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11164,7 +11876,7 @@ declare interface TouchObject {
* @since 10
*/
/**
- * Y coordinate of the touch point relative to the upper edge of the device screen.
+ * Y coordinate of the touch point relative to the upper left corner of the application screen.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11183,7 +11895,7 @@ declare interface TouchObject {
* @since 10
*/
/**
- * X coordinate of the touch point relative to the left edge of the current window.
+ * X coordinate of the touch point relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11202,7 +11914,7 @@ declare interface TouchObject {
* @since 10
*/
/**
- * Y coordinate of the touch point relative to the upper edge of the current window.
+ * Y coordinate of the touch point relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11213,7 +11925,7 @@ declare interface TouchObject {
windowY: number;
/**
- * X coordinate of the touch point relative to the left edge of the current window.
+ * X coordinate of the touch point relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11224,7 +11936,7 @@ declare interface TouchObject {
screenX: number;
/**
- * Y coordinate of the touch point relative to the upper edge of the current window.
+ * Y coordinate of the touch point relative to the upper left corner of the application window.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11250,7 +11962,7 @@ declare interface TouchObject {
* @since 10
*/
/**
- * X coordinate of the touch point relative to the left edge of the touched element.
+ * X coordinate of the touch point relative to the upper left corner of the event responding component.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11276,7 +11988,7 @@ declare interface TouchObject {
* @since 10
*/
/**
- * Y coordinate of the touch point relative to the upper edge of the touched element.
+ * Y coordinate of the touch point relative to the upper left corner of the event responding component.
*
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11287,7 +11999,7 @@ declare interface TouchObject {
y: number;
/**
- * Type of the touch hand.
+ * Whether the event is triggered by a left-hand or right-hand tap.
*
* @type { InteractionHand }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11298,7 +12010,7 @@ declare interface TouchObject {
hand?: InteractionHand;
/**
- * Time stamp when the touch point is pressed.
+ * Time when the finger is pressed.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11308,7 +12020,7 @@ declare interface TouchObject {
*/
pressedTime?: number;
/**
- * Pressure of a specific touch point.
+ * Pressure value of the finger press.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11319,7 +12031,7 @@ declare interface TouchObject {
pressure?: number;
/**
- * Width of the contact area when touch is pressed of a specific touch point.
+ * Width of the area pressed by the finger.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11330,7 +12042,7 @@ declare interface TouchObject {
width?: number;
/**
- * Height of the contact area when touch is pressed of a specific touch point.
+ * Height of the area pressed by the finger.
*
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11532,7 +12244,7 @@ declare interface TouchEvent extends BaseEvent {
* @since 10
*/
/**
- * Indicates the current changed finger information.
+ * Finger information changed.
*
* @type { TouchObject[] }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11558,7 +12270,7 @@ declare interface TouchEvent extends BaseEvent {
* @since 10
*/
/**
- * The blocking event pops up.
+ * Stops the event from bubbling upwards or downwards.
*
* @type { function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11577,7 +12289,7 @@ declare interface TouchEvent extends BaseEvent {
* @since 10
*/
/**
- * Get the historical points.
+ * Obtains all historical points of the current frame.
*
* @returns { Array } - return all historical points.
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11588,9 +12300,10 @@ declare interface TouchEvent extends BaseEvent {
getHistoricalPoints(): Array;
/**
- * Prevent the default function.
+ * Blocks the default event.
*
* @type { function }
+ * @throws { BusinessError } 100017 - Component does not support prevent function.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -11606,7 +12319,7 @@ declare interface TouchEvent extends BaseEvent {
* @interface AxisEvent
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
declare interface AxisEvent extends BaseEvent {
/**
@@ -11615,7 +12328,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { AxisAction }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
action: AxisAction;
@@ -11625,7 +12338,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
displayX: number;
@@ -11635,7 +12348,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
displayY: number;
@@ -11645,7 +12358,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
windowX: number;
@@ -11655,7 +12368,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
windowY: number;
@@ -11665,7 +12378,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
x: number;
@@ -11675,7 +12388,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
y: number;
@@ -11685,7 +12398,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { ?number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
scrollStep?: number;
@@ -11695,7 +12408,7 @@ declare interface AxisEvent extends BaseEvent {
* @type { Callback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
propagation: Callback;
@@ -11705,7 +12418,7 @@ declare interface AxisEvent extends BaseEvent {
* @returns { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
getHorizontalAxisValue(): number;
@@ -11715,15 +12428,15 @@ declare interface AxisEvent extends BaseEvent {
* @returns { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 17
*/
getVerticalAxisValue(): number;
}
/**
* Defines the callback type used in onSizeChange.
- * The value of oldValue is last size of the component.
- * The value of newValue is new size of the component.
+ * oldValue - the width and height of the component before the change.
+ * newValue - the width and height of the component after the change.
*
* @typedef { function } SizeChangeCallback
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -11747,7 +12460,21 @@ declare type SizeChangeCallback = (oldValue: SizeOptions, newValue: SizeOptions)
* @atomicservice
* @since 12
*/
-declare type GestureRecognizerJudgeBeginCallback = (event: BaseGestureEvent, current: GestureRecognizer, recognizers: Array) => GestureJudgeResult;
+/**
+ * Defines the callback type used in onGestureRecognizerJudgeBegin.
+ *
+ * @typedef { function } GestureRecognizerJudgeBeginCallback
+ * @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
+ * @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;
/**
* Defines the callback type used in shouldBuiltInRecognizerParallelWith.
@@ -11776,6 +12503,22 @@ declare type ShouldBuiltInRecognizerParallelWithCallback = (current: GestureReco
*/
declare type TransitionFinishCallback = (transitionIn: boolean) => void;
+/**
+ * Defines the callback type used in onTouchTestDone.
+ * When the user touch down, the system performs hit test process to collect all gesture recognizers
+ * based on the press location, when the collection is completed, and before gesture begin to be recognizing,
+ * the callback is triggered, you can get all recognizer's information from this callback.
+ *
+ * @typedef { function } TouchTestDoneCallback
+ * @param { BaseGestureEvent } event - the event information, basicly is the touch down information
+ * @param { Array } recognizers - the gesture recognizers of the component on the response chain
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+declare type TouchTestDoneCallback = (event: BaseGestureEvent, recognizers: Array) => void;
+
/**
* Defines the PixelMap type object for ui component.
*
@@ -11836,6 +12579,10 @@ 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
@@ -11954,6 +12701,26 @@ declare type UniformDataType = import('../api/@ohos.data.uniformTypeDescriptor')
*/
declare type DataSyncOptions = import('../api/@ohos.data.unifiedDataChannel').default.GetDataParams;
+/**
+ * The type for SpringLoadingContext, see the detailed description in dragController.
+ *
+ * @typedef {import('../api/@ohos.arkui.dragController').default.SpringLoadingContext} SpringLoadingContext
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @atomicservice
+ * @since 20
+ */
+declare type SpringLoadingContext = import('../api/@ohos.arkui.dragController').default.SpringLoadingContext;
+
+/**
+ * The type for DragSpringLoadingConfiguration, see the detailed description in dragController.
+ *
+ * @typedef {import('../api/@ohos.arkui.dragController').default.DragSpringLoadingConfiguration} DragSpringLoadingConfiguration
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @atomicservice
+ * @since 20
+ */
+declare type DragSpringLoadingConfiguration = import('../api/@ohos.arkui.dragController').default.DragSpringLoadingConfiguration;
+
/**
* Enum for Drag Result.
*
@@ -12094,7 +12861,7 @@ declare enum DragResult {
*/
declare enum BlendMode {
/**
- * Hybrid mode does not take effect
+ * The top image is superimposed on the bottom image without any blending.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12102,7 +12869,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * Hybrid mode does not take effect
+ * The top image is superimposed on the bottom image without any blending.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12112,7 +12879,7 @@ declare enum BlendMode {
*/
NONE = 0,
/**
- * Clear destination color covered by the source to 0.
+ * The target pixels covered by the source pixels are erased by being turned to completely transparent.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12120,7 +12887,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * Clear destination color covered by the source to 0.
+ * The target pixels covered by the source pixels are erased by being turned to completely transparent.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12130,7 +12897,7 @@ declare enum BlendMode {
*/
CLEAR = 1,
/**
- * r = s
+ * r = s: Only the source pixels are displayed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12138,7 +12905,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = s
+ * r = s: Only the source pixels are displayed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12166,7 +12933,7 @@ declare enum BlendMode {
*/
DST = 3,
/**
- * r = s + (1 - sa) * d
+ * r = s + (1 - sa) * d: The source pixels are blended based on opacity and cover the target pixels.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12174,7 +12941,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = s + (1 - sa) * d
+ * r = s + (1 - sa) * d: The source pixels are blended based on opacity and cover the target pixels.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12184,7 +12951,7 @@ declare enum BlendMode {
*/
SRC_OVER = 4,
/**
- * r = d + (1 - da) * s
+ * r = d + (1 - da) * s: The target pixels are blended based on opacity and cover on the source pixels.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12192,7 +12959,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = d + (1 - da) * s
+ * r = d + (1 - da) * s: The target pixels are blended based on opacity and cover on the source pixels.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12202,7 +12969,7 @@ declare enum BlendMode {
*/
DST_OVER = 5,
/**
- * r = s * da
+ * r = s * da: Only the part of the source pixels that overlap with the target pixels is displayed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12210,7 +12977,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = s * da
+ * r = s * da: Only the part of the source pixels that overlap with the target pixels is displayed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12220,7 +12987,7 @@ declare enum BlendMode {
*/
SRC_IN = 6,
/**
- * r = d * sa
+ * r = d * sa: Only the part of the target pixels that overlap with the source pixels is displayed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12228,7 +12995,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = d * sa
+ * r = d * sa: Only the part of the target pixels that overlap with the source pixels is displayed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12264,7 +13031,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = d * (1 - sa)
+ * r = d * (1 - sa), retains the parts of the destination pixels that do not overlap with the source.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12274,7 +13041,8 @@ declare enum BlendMode {
*/
DST_OUT = 9,
/**
- * r = s * da + d * (1 - sa)
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12282,7 +13050,8 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = s * da + d * (1 - sa)
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12300,7 +13069,8 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = d * sa + s * (1 - da)
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12336,7 +13106,8 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = min(s + d, 1)
+ * r = min(s + d, 1):
+ * New pixels resulting from adding the source pixels to the target pixels are displayed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12490,7 +13261,7 @@ declare enum BlendMode {
*/
HARD_LIGHT = 21,
/**
- * lighten or darken, depending on source
+ * The LIGHTEN or DARKEN mode is used, depending on the source pixels.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12498,7 +13269,7 @@ declare enum BlendMode {
* @since 11
*/
/**
- * lighten or darken, depending on source
+ * The LIGHTEN or DARKEN mode is used, depending on the source pixels.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12516,7 +13287,8 @@ declare enum BlendMode {
* @since 11
*/
/**
- * rc = s + d - 2 * (min(s * da, d * sa)), ra = kSrcOver
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12544,7 +13316,8 @@ declare enum BlendMode {
*/
EXCLUSION = 24,
/**
- * r = s * (1 - da) + d * (1 - sa) + s * d
+ * r = s * (1 - da) + d * (1 - sa) + s * d:
+ * The final pixel is the result of multiplying the source pixel by the target pixel.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12552,7 +13325,8 @@ declare enum BlendMode {
* @since 11
*/
/**
- * r = s * (1 - da) + d * (1 - sa) + s * d
+ * r = s * (1 - da) + d * (1 - sa) + s * d:
+ * The final pixel is the result of multiplying the source pixel by the target pixel.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12660,7 +13434,7 @@ declare enum BlendMode {
*/
declare enum BlendApplyType {
/**
- * Blend view's content in sequence over dst
+ * The content of the view is blended in sequence on the target image.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12668,7 +13442,7 @@ declare enum BlendApplyType {
* @since 11
*/
/**
- * Blend view's content in sequence over dst
+ * The content of the view is blended in sequence on the target image.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12679,8 +13453,8 @@ declare enum BlendApplyType {
FAST = 0,
/**
- * Composite this views's contents into an
- * offscreen image and then blend over dst
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -12688,8 +13462,8 @@ declare enum BlendApplyType {
* @since 11
*/
/**
- * Composite this views's contents into an
- * offscreen image and then blend over dst
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -13091,7 +13865,7 @@ declare interface DragEvent {
getVelocity(): number;
/**
- * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift'|'fn'
+ * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift'
*
* @param { Array } keys - indicate the keys of the ModifierKey.
* @returns { boolean }
@@ -13101,7 +13875,7 @@ declare interface DragEvent {
* @since 12
*/
/**
- * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift'|'fn'
+ * Query the ModifierKey press state, support 'ctrl'|'alt'|'shift'
*
* @param { Array } keys - indicate the keys of the ModifierKey.
* @returns { boolean }
@@ -13136,12 +13910,61 @@ 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 no allowed for current pharse.
+ * @throws { BusinessError } 190003 - Operation not allowed for current pharse.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 15
*/
startDataLoading(options: DataSyncOptions): string;
+
+ /**
+ * Retrieve the bundle information of the drag source application.
+ *
+ * @returns { string }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @atomicservice
+ * @since 20
+ */
+ getDragSource(): string;
+
+ /**
+ * Call this method to determine whether the current drag operation is a cross-device drag.
+ *
+ * @returns { boolean }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @atomicservice
+ * @since 20
+ */
+ isRemote(): boolean;
+
+ /**
+ * Get the id of display which the drag event is occuring on.
+ *
+ * @returns { number }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ getDisplayId(): number;
+
+ /**
+ * Enable the internal drop animation, which is only avaiable for system applications.
+ *
+ * The animations' configuration need to be provided through the input paramerter, and it is a string in json format.
+ *
+ * This method can only be called in onDrop, and please do not use custom drop animation after this method,
+ * as it will reset the calling result, and use custom drop animation insteadly.
+ *
+ * @param { string } configuration - the internal drop animation's configuration.
+ * @throws { BusinessError } 202 - Permission verification failed, application which is not a system application uses system API.
+ * @throws { BusinessError } 801 - Capability not supported.
+ * @throws { BusinessError } 190003 - Operation not allowed for current phase.
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @systemapi
+ * @since 20
+ */
+ enableInternalDropAnimation(configuration: string): void;
}
/**
@@ -13459,7 +14282,7 @@ declare interface KeyEvent {
intentionCode: IntentionCode;
/**
- * Get the modifier keys press state, support 'ctrl'|'alt'|'shift'|'fn'
+ * Get the modifier keys press state, support 'ctrl'|'alt'|'shift'
*
* @param { Array } keys - indicate the modifier keys.
* @returns { boolean }
@@ -13469,7 +14292,7 @@ declare interface KeyEvent {
* @since 12
*/
/**
- * Get the modifier keys press state, support 'ctrl'|'alt'|'shift'|'fn'
+ * Get the modifier keys press state, support 'ctrl'|'alt'|'shift'
*
* @param { Array } keys - indicate the modifier keys.
* @returns { boolean }
@@ -13490,6 +14313,36 @@ declare interface KeyEvent {
* @since 14
*/
unicode?: number;
+
+ /**
+ * Whether Num Lock is on
+ *
+ * @type { ?boolean }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @atomicservice
+ * @since 19
+ */
+ isNumLockOn?: boolean;
+
+ /**
+ * Whether Caps Lock is on
+ *
+ * @type { ?boolean }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @atomicservice
+ * @since 19
+ */
+ isCapsLockOn?: boolean;
+
+ /**
+ * Whether Scroll Lock is on
+ *
+ * @type { ?boolean }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @atomicservice
+ * @since 19
+ */
+ isScrollLockOn?: boolean;
}
/**
@@ -13602,7 +14455,8 @@ declare interface CrownEvent {
*/
declare interface BindOptions {
/**
- * Defines the background color
+ * Background color of the sheet.
+ * Default value: **Color.White**.
*
* @type { ?ResourceColor }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -13610,7 +14464,8 @@ declare interface BindOptions {
* @since 10
*/
/**
- * Defines the background color
+ * Background color of the sheet.
+ * Default value: **Color.White**.
*
* @type { ?ResourceColor }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -13621,7 +14476,7 @@ declare interface BindOptions {
backgroundColor?: ResourceColor;
/**
- * Callback function when overlay interface appears
+ * Callback for when the sheet is displayed (after the animation ends).
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -13629,7 +14484,7 @@ declare interface BindOptions {
* @since 10
*/
/**
- * Callback function when overlay interface appears
+ * Callback for when the sheet is displayed (after the animation ends).
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -13640,7 +14495,7 @@ declare interface BindOptions {
onAppear?: () => void;
/**
- * Callback function when overlay interface exits
+ * Callback for when the sheet disappears (after the animation ends).
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -13648,7 +14503,7 @@ declare interface BindOptions {
* @since 10
*/
/**
- * Callback function when overlay interface exits
+ * Callback for when the sheet disappears (after the animation ends).
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -13659,7 +14514,7 @@ declare interface BindOptions {
onDisappear?: () => void;
/**
- * Callback function before overlay animation starts.
+ * Callback for when the sheet is about to be displayed (before the animation starts).
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -13776,6 +14631,18 @@ declare interface ContentCoverOptions extends BindOptions {
* @since 12
*/
transition?: TransitionEffect;
+
+ /**
+ * Set contentCover content adapts to safeArea.
+ *
+ * @type { ?boolean }
+ * @default false
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ enableSafeArea?: boolean;
}
/**
@@ -13854,14 +14721,14 @@ declare interface SheetTitleOptions {
*/
declare enum SheetType {
/**
- * Defines bottom sheet type.
+ * Bottom sheet.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 11
*/
/**
- * Defines bottom sheet type.
+ * Bottom sheet.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -13871,14 +14738,14 @@ declare enum SheetType {
BOTTOM = 0,
/**
- * Defines center sheet type.
+ * Center sheet.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 11
*/
/**
- * Defines center sheet type.
+ * Center sheet.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -13888,14 +14755,14 @@ declare enum SheetType {
CENTER = 1,
/**
- * Defines popup sheet type.
+ * Popup sheet. The popup sheet cannot be dismissed with a pull-down gesture.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 11
*/
/**
- * Defines popup sheet type.
+ * Popup sheet. The popup sheet cannot be dismissed with a pull-down gesture.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -13903,6 +14770,16 @@ declare enum SheetType {
* @since 12
*/
POPUP = 2,
+
+ /**
+ * Defines side sheet type.
+ *
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ SIDE = 3,
}
/**
@@ -13916,7 +14793,8 @@ declare enum SheetType {
*/
declare enum SheetMode {
/**
- * Sheet displays above all page levels.
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -13926,7 +14804,16 @@ declare enum SheetMode {
OVERLAY = 0,
/**
- * Sheet displays within the current page.
+ * 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.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -14156,7 +15043,9 @@ declare interface SheetOptions extends BindOptions {
height?: SheetSize | Length;
/**
- * Defines whether the control bar is displayed.
+ * 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.
*
* @type { ?boolean }
* @default true
@@ -14165,7 +15054,9 @@ declare interface SheetOptions extends BindOptions {
* @since 10
*/
/**
- * Defines whether the control bar is displayed.
+ * 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.
*
* @type { ?boolean }
* @default true
@@ -14177,7 +15068,19 @@ declare interface SheetOptions extends BindOptions {
dragBar?: boolean;
/**
- * Defines sheet maskColor
+ * Defines whether the sheet dragbar is floating, when it's displayed.
+ *
+ * @type { ?boolean }
+ * @default false
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ enableFloatingDragBar?: boolean;
+
+ /**
+ * Mask color of the sheet.
*
* @type { ?ResourceColor }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14185,7 +15088,7 @@ declare interface SheetOptions extends BindOptions {
* @since 10
*/
/**
- * Defines sheet maskColor
+ * Mask color of the sheet.
*
* @type { ?ResourceColor }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14197,14 +15100,28 @@ declare interface SheetOptions extends BindOptions {
/**
* Defines sheet detents
- *
* @type { ?[(SheetSize | Length), (SheetSize | Length)?, (SheetSize | Length)?] }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 11
*/
/**
- * Defines sheet detents
+ * 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%.
+ *
*
* @type { ?[(SheetSize | Length), (SheetSize | Length)?, (SheetSize | Length)?] }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14215,7 +15132,7 @@ declare interface SheetOptions extends BindOptions {
detents?: [(SheetSize | Length), (SheetSize | Length)?, (SheetSize | Length)?];
/**
- * Defines sheet background blur Style
+ * Background blur of the sheet. By default, there is no background blur.
*
* @type { ?BlurStyle }
* @default BlurStyle.NONE
@@ -14224,7 +15141,7 @@ declare interface SheetOptions extends BindOptions {
* @since 11
*/
/**
- * Defines sheet background blur Style
+ * Background blur of the sheet. By default, there is no background blur.
*
* @type { ?BlurStyle }
* @default BlurStyle.NONE
@@ -14257,7 +15174,11 @@ declare interface SheetOptions extends BindOptions {
showClose?: boolean | Resource;
/**
- * Defines the sheet prefer type
+ * 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).
*
* @type { ?(SheetType.CENTER | SheetType.POPUP) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14265,7 +15186,11 @@ declare interface SheetOptions extends BindOptions {
* @since 11
*/
/**
- * Defines the sheet prefer type
+ * 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).
*
* @type { ?SheetType }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14276,7 +15201,7 @@ declare interface SheetOptions extends BindOptions {
preferType?: SheetType;
/**
- * Defines the sheet title
+ * Title of the sheet.
*
* @type { ?(SheetTitleOptions | CustomBuilder) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14284,7 +15209,7 @@ declare interface SheetOptions extends BindOptions {
* @since 11
*/
/**
- * Defines the sheet title
+ * Title of the sheet.
*
* @type { ?(SheetTitleOptions | CustomBuilder) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14295,7 +15220,12 @@ declare interface SheetOptions extends BindOptions {
title?: SheetTitleOptions | CustomBuilder;
/**
- * Callback function when the sheet interactive dismiss
+ * 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.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14303,7 +15233,12 @@ declare interface SheetOptions extends BindOptions {
* @since 11
*/
/**
- * Callback function when the sheet interactive dismiss
+ * 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.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14314,7 +15249,18 @@ declare interface SheetOptions extends BindOptions {
shouldDismiss?: (sheetDismiss: SheetDismiss) => void;
/**
- * Callback function when the sheet will dismiss
+ * 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.
+ *
*
* @type { ?Callback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14325,8 +15271,16 @@ declare interface SheetOptions extends BindOptions {
onWillDismiss?: Callback;
/**
- * Sheet springs back callback when dismiss
- *
+ * 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.
+ *
+ *
* @type { ?Callback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -14336,7 +15290,12 @@ declare interface SheetOptions extends BindOptions {
onWillSpringBackWhenDismiss?: Callback;
/**
- * Set whether interaction is allowed outside the sheet
+ * 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.
*
* @type { ?boolean }
* @default false
@@ -14345,7 +15304,12 @@ declare interface SheetOptions extends BindOptions {
* @since 11
*/
/**
- * Set whether interaction is allowed outside the sheet
+ * 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.
*
* @type { ?boolean }
* @default false
@@ -14357,7 +15321,8 @@ declare interface SheetOptions extends BindOptions {
enableOutsideInteractive?: boolean;
/**
- * Defines the sheet's width.
+ * Width of the sheet.
+ * Percentage parameter method: Set the width of the sheet as a percentage of the width of the parent element.
*
* @type { ?Dimension }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14368,7 +15333,16 @@ declare interface SheetOptions extends BindOptions {
width?: Dimension;
/**
- * Defines the sheet's border width.
+ * 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.
+ *
*
* @type { ?(Dimension | EdgeWidths | LocalizedEdgeWidths) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14379,9 +15353,14 @@ declare interface SheetOptions extends BindOptions {
borderWidth?: Dimension | EdgeWidths | LocalizedEdgeWidths;
/**
- * Defines the sheet's border color.
- *
+ * Border color of the sheet.
+ * **borderColor** must be used with **borderWidth** in pairs.
+ *
**NOTE**:
+ * For bottom sheets, the bottom border color setting is ineffective.
+ *
+ *
* @type { ?(ResourceColor | EdgeColors | LocalizedEdgeColors) }
+ * @default Color.Black
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -14401,7 +15380,8 @@ declare interface SheetOptions extends BindOptions {
borderStyle?: BorderStyle | EdgeStyles;
/**
- * Defines the sheet's shadow.
+ * Shadow of the sheet.
+ * Default value for 2-in-1 devices: **ShadowStyle.OUTER_FLOATING_SM**.
*
* @type { ?(ShadowOptions | ShadowStyle) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14412,7 +15392,14 @@ declare interface SheetOptions extends BindOptions {
shadow?: ShadowOptions | ShadowStyle;
/**
- * Called when height of the sheet is changed
+ * 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.
+ *
*
* @type { ?Callback }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -14423,7 +15410,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
@@ -14435,7 +15422,7 @@ declare interface SheetOptions extends BindOptions {
mode?: SheetMode;
/**
- * Determine sheet scroll size mode.
+ * Content update mode of the sheet when it is scrolled.
*
* @type { ?ScrollSizeMode }
* @default ScrollSizeMode.FELLOW_DETEND
@@ -14447,8 +15434,11 @@ declare interface SheetOptions extends BindOptions {
scrollSizeMode?: ScrollSizeMode;
/**
- * Called when detents of the sheet changed
- *
+ * 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.
+ *
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.
+ *
*
* @type { CustomBuilder }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -16160,9 +17332,11 @@ declare interface CustomPopupOptions {
* @since 10
*/
/**
- * placement of popup
+ * Preferred position of the popup. If the set position is insufficient for holding the popup,
+ * it will be automatically adjusted.
*
* @type { ?Placement }
+ * @default Placement.Bottom
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16192,14 +17366,16 @@ declare interface CustomPopupOptions {
* background color of popup
*
* @type { ?(Color | string | Resource | number) }
+ * @default '#4d4d4d'
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @since 10
*/
/**
- * background color of popup
+ * Color of the popup. To remove the background blur, set backgroundBlurStyle to BlurStyle.NONE.
*
* @type { ?(Color | string | Resource | number) }
+ * @default TRANSPARENT plus COMPONENT_ULTRA_THICK
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16226,6 +17402,7 @@ declare interface CustomPopupOptions {
* whether show arrow
*
* @type { ?boolean }
+ * @default true
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16249,9 +17426,15 @@ declare interface CustomPopupOptions {
* @since 10
*/
/**
- * whether hide popup when click mask
+ * 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.
+ *
*
* @type { ?boolean }
+ * @default true
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16275,7 +17458,7 @@ declare interface CustomPopupOptions {
* @since 10
*/
/**
- * on State Change
+ * Callback for the popup status change event.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -16322,6 +17505,13 @@ 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
@@ -16349,6 +17539,7 @@ declare interface CustomPopupOptions {
* Whether to display in the sub window.
*
* @type { ?boolean }
+ * @default false
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16367,9 +17558,9 @@ declare interface CustomPopupOptions {
* @since 10
*/
/**
- * 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.
+ * 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.
*
* @type { ?(boolean | { color: ResourceColor }) }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -16426,7 +17617,7 @@ declare interface CustomPopupOptions {
* @since 11
*/
/**
- * Set the width of the popup.
+ * Width of the popup.
*
* @type { ?Dimension }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -16445,7 +17636,8 @@ declare interface CustomPopupOptions {
* @since 11
*/
/**
- * The position of the sharp corner of popup.
+ * 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.
*
* @type { ?ArrowPointPosition }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -16465,10 +17657,15 @@ declare interface CustomPopupOptions {
* @since 11
*/
/**
- * The width of the arrow.
+ * 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.
*
* @type { ?Dimension }
* @default 16.0_vp.
+ *
NOTE:
+ * This parameter cannot be set in percentage.
+ *
NOTE:
+ * This parameter cannot be set in percentage.
+ *
+ *
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16507,7 +17708,7 @@ declare interface CustomPopupOptions {
* @since 11
*/
/**
- * The round corners of the popup.
+ * Rounded corner radius of the popup.
*
* @type { ?Dimension }
* @default 20.0_vp.
@@ -16528,7 +17729,7 @@ declare interface CustomPopupOptions {
* @since 11
*/
/**
- * The style of popup Shadow.
+ * Popup shadow.
*
* @type { ?(ShadowOptions | ShadowStyle) }
* @default ShadowStyle.OUTER_DEFAULT_MD.
@@ -16549,7 +17750,7 @@ declare interface CustomPopupOptions {
* @since 11
*/
/**
- * Defines popup background blur Style
+ * Background blur style of the popup.
*
* @type { ?BlurStyle }
* @default BlurStyle.COMPONENT_ULTRA_THICK
@@ -16593,9 +17794,19 @@ declare interface CustomPopupOptions {
transition?: TransitionEffect;
/**
- * Callback function when the popup interactive dismiss
+ * 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.
+ *
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.
+ *
*
* @type { ?Position }
- * @default -
+ * @default {x:0,y:0} - Percentage values are not supported.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16871,10 +18239,15 @@ declare interface ContextMenuOptions {
* @since 10
*/
/**
- * Sets the placement of the context menu window.
+ * 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.
+ *
*
* @type { ?Placement }
- * @default -
+ * @default Placement.BottomLeft
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16883,7 +18256,7 @@ declare interface ContextMenuOptions {
placement?: Placement;
/**
- * whether show arrow belong to the menu, default: false, not show arrow
+ * whether show arrow belong to the menu.
*
* @type { ?boolean }
* @default false
@@ -16891,7 +18264,14 @@ declare interface ContextMenuOptions {
* @since 10
*/
/**
- * whether show arrow belong to the menu, default: false, not show arrow
+ * 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.
+ *
*
* @type { ?boolean }
* @default false
@@ -16906,15 +18286,36 @@ declare interface ContextMenuOptions {
* The horizontal offset to the left of menu or vertical offset to the top of menu
*
* @type { ?Length }
- * @default 0
- * @syscap SystemCapability.ArkUI.ArkUI.Full
- * @since 10
- */
- /**
- * The horizontal offset to the left of menu or vertical offset to the top of menu
+ * @default 0vp
+ * @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.
+ *
*
* @type { ?Length }
- * @default 0
+ * @default 0vp
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16932,8 +18333,15 @@ declare interface ContextMenuOptions {
* @since 11
*/
/**
- * The preview content of context menu.
- *
+ * 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.
+ *
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.
+ *
*
* @type { ?(Length | BorderRadiuses | LocalizedBorderRadiuses) }
+ * @default 8vp for 2-in-1 devices and 20vp for other devices
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -16974,7 +18389,7 @@ declare interface ContextMenuOptions {
* @since 10
*/
/**
- * Callback function when the context menu appears.
+ * Callback triggered when the menu is displayed.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -16985,7 +18400,7 @@ declare interface ContextMenuOptions {
onAppear?: () => void;
/**
- * Callback function when the context menu disappear.
+ * Callback triggered when the menu is hidden.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -17012,7 +18427,7 @@ declare interface ContextMenuOptions {
* @since 11
*/
/**
- * Callback function before the context menu animation starts.
+ * Callback triggered when the menu is about to appear.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -17031,7 +18446,7 @@ declare interface ContextMenuOptions {
* @since 11
*/
/**
- * Callback function before the context menu popAnimation starts.
+ * Callback triggered when the menu is about to disappear.
*
* @type { ?function }
* @syscap SystemCapability.ArkUI.ArkUI.Full
@@ -17081,7 +18496,7 @@ declare interface ContextMenuOptions {
* @since 11
*/
/**
- * Defines the menu's background color
+ * Background color of the menu.
*
* @type { ?ResourceColor }
* @default Color.Transparent
@@ -17102,7 +18517,7 @@ declare interface ContextMenuOptions {
* @since 11
*/
/**
- * Defines menu background blur Style
+ * Background blur style of the menu.
*
* @type { ?BlurStyle }
* @default BlurStyle.COMPONENT_ULTRA_THICK
@@ -17165,7 +18580,7 @@ declare interface ContextMenuOptions {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 20
*/
outlineColor?: ResourceColor | EdgeColors;
@@ -17176,7 +18591,7 @@ declare interface ContextMenuOptions {
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 20
*/
outlineWidth?: Dimension | EdgeOutlineWidths;
@@ -17191,6 +18606,85 @@ declare interface ContextMenuOptions {
* @since 18
*/
hapticFeedbackMode?: HapticFeedbackMode;
+
+ /**
+ * Whether it is a menu without mask.
+ *
+ * @type { ?(boolean | MenuMaskType) }
+ * @default true
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ mask?: boolean | MenuMaskType;
+
+ /**
+ * Defines modal mode of menu.
+ *
+ * @type { ?ModalMode }
+ * @default ModalMode.AUTO
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ modalMode?: ModalMode;
+
+ /**
+ * Defines the menu position.
+ *
+ * @type { ?Position }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ anchorPosition?: Position;
+
+ /**
+ * Callback function when the menu appears.
+ *
+ * @type { ?Callback }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ onDidAppear?: Callback;
+
+ /**
+ * Callback function when the menu disappears.
+ *
+ * @type { ?Callback }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ onDidDisappear?: Callback;
+
+ /**
+ * Callback function before the menu openAnimation starts.
+ *
+ * @type { ?Callback }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ onWillAppear?: Callback;
+
+ /**
+ * Callback function before the menu closeAnimation starts.
+ *
+ * @type { ?Callback }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+ onWillDisappear?: Callback;
}
/**
@@ -17244,6 +18738,7 @@ 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
@@ -17260,7 +18755,7 @@ declare interface MenuOptions extends ContextMenuOptions {
* @since 10
*/
/**
- * Defines the ProgressMask class.
+ * Implements a ProgressMask object to set the progress, maximum value, and color of the mask.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -17281,9 +18776,9 @@ declare class ProgressMask {
/**
* constructor.
*
- * @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.
+ * @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.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -17300,9 +18795,9 @@ declare class ProgressMask {
* @since 10
*/
/**
- * Update the current value of the progress.
+ * Updates the progress value of the progress mask.
*
- * @param { number } value - indicates the current value of the progress.
+ * @param { number } value - Current value of the progress mask.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -17321,7 +18816,7 @@ declare class ProgressMask {
/**
* Update the color of the mask.
*
- * @param { ResourceColor } value - indicates the color of the mask.
+ * @param { ResourceColor } value - Color of the progress mask.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -17726,7 +19221,14 @@ 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
@@ -17889,6 +19391,15 @@ declare interface MenuElement {
* @atomicservice
* @since 12
*/
+ /**
+ * Sets the symbol of the menu element.
+ *
+ * @type { ?SymbolGlyphModifier }
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
symbolIcon?: SymbolGlyphModifier;
/**
@@ -18071,6 +19582,9 @@ 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
@@ -18135,7 +19649,7 @@ declare interface CommonConfiguration {
*/
declare enum OutlineStyle {
/**
- * Shows as a solid line.
+ * Solid border.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -18143,7 +19657,7 @@ declare enum OutlineStyle {
* @since 11
*/
/**
- * Shows as a solid line.
+ * Solid border.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -18154,7 +19668,7 @@ declare enum OutlineStyle {
SOLID = 0,
/**
- * Shows as a series of short square dashed lines.
+ * Dashed border.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -18162,7 +19676,7 @@ declare enum OutlineStyle {
* @since 11
*/
/**
- * Shows as a series of short square dashed lines.
+ * Dashed border.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -18181,7 +19695,7 @@ declare enum OutlineStyle {
* @since 11
*/
/**
- * Displays as a series of dots with a radius of half the borderWidth.
+ * Dotted border. The radius of a dot is half of **outlineWidth**.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -18314,7 +19828,7 @@ declare enum DragPreviewMode {
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 19
*/
ENABLE_TOUCH_POINT_CALCULATION_BASED_ON_FINAL_PREVIEW = 7,
}
@@ -18325,7 +19839,7 @@ declare enum DragPreviewMode {
* @enum { number }
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 19
*/
declare enum DraggingSizeChangeEffect {
/**
@@ -18333,7 +19847,7 @@ declare enum DraggingSizeChangeEffect {
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 19
*/
DEFAULT = 0,
@@ -18342,7 +19856,7 @@ declare enum DraggingSizeChangeEffect {
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 19
*/
SIZE_TRANSITION = 1,
@@ -18351,7 +19865,7 @@ declare enum DraggingSizeChangeEffect {
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 19
*/
SIZE_CONTENT_TRANSITION = 2,
}
@@ -18377,7 +19891,7 @@ declare enum MenuPolicy {
DEFAULT = 0,
/**
- * Hide pop up menu.
+ * The menu is always hidden.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -18387,7 +19901,7 @@ declare enum MenuPolicy {
HIDE = 1,
/**
- * Show pop up menu.
+ * The menu is always displayed.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
@@ -18416,6 +19930,15 @@ declare type ImageModifier = import('../api/arkui/ImageModifier').ImageModifier;
* @atomicservice
* @since 12
*/
+/**
+ * SymbolGlyphModifier
+ *
+ * @typedef {import('../api/arkui/SymbolGlyphModifier').SymbolGlyphModifier} SymbolGlyphModifier
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
declare type SymbolGlyphModifier = import('../api/arkui/SymbolGlyphModifier').SymbolGlyphModifier;
/**
@@ -18462,6 +19985,7 @@ declare interface DragPreviewOptions {
* Drag preview mode.
*
* @type { ?(DragPreviewMode | Array) }
+ * @default DragPreviewMode.AUTO
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -18500,6 +20024,7 @@ declare interface DragPreviewOptions {
* The flag for number showing.
*
* @type { ?(boolean | number) }
+ * @default true
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
@@ -18511,9 +20036,10 @@ declare interface DragPreviewOptions {
* Drag start animation effect from drag preview to the handle drag image.
*
* @type { ?DraggingSizeChangeEffect }
+ * @default DraggingSizeChangeEffect.DEFAULT
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
- * @since 18
+ * @since 19
*/
sizeChangeEffect?: DraggingSizeChangeEffect;
}
@@ -18531,6 +20057,7 @@ 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
@@ -18541,6 +20068,7 @@ declare interface DragInteractionOptions {
* Define whether to execute animation before preview floating.
*
* @type { ?boolean }
+ * @default false
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 12
@@ -18551,6 +20079,7 @@ declare interface DragInteractionOptions {
* 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
@@ -18561,6 +20090,7 @@ declare interface DragInteractionOptions {
* 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
@@ -18772,10 +20302,21 @@ declare type Optional = T | undefined;
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @crossplatform
* @atomicservice
- * @since 18
+ * @since 19
*/
declare type TipsMessageType = ResourceStr | StyledString;
+/**
+ * Import the Matrix4Transit type object for common method.
+ *
+ * @typedef { import('../api/@ohos.matrix4').default.Matrix4Transit } Matrix4Transit
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+declare type Matrix4Transit = import('../api/@ohos.matrix4').default.Matrix4Transit;
+
/**
* Define the options for background image.
*
@@ -18814,6 +20355,56 @@ interface BackgroundImageOptions {
repeat?: ImageRepeat;
}
+/**
+ * Defines background options.
+ *
+ * @interface BackgroundOptions
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ */
+declare interface BackgroundOptions {
+ /**
+ * Set the alignment of the custom background and component.
+ *
+ * @type { ?Alignment} align
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @since 10
+ */
+ /**
+ * Set the alignment of the custom background and component.
+ *
+ * @type { ?Alignment} align
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @since 11
+ */
+ /**
+ * Set the alignment of the custom background and component.
+ *
+ * Anonymous Object Rectification.
+ * @type { ?Alignment }
+ * @default Alignment.Center
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @crossplatform
+ * @atomicservice
+ * @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.
+ * @type { ?Array }
+ * @default LayoutSafeAreaEdge.ALL
+ * @syscap SystemCapability.ArkUI.ArkUI.Full
+ * @atomicservice
+ * @since 20
+ */
+ ignoresLayoutSafeAreaEdges?: Array;
+}
+
/**
* CommonMethod.
*
@@ -18890,7 +20481,9 @@ declare class CommonMethod {
* @since 10
*/
/**
- * Sets the width of the current component.
+ * 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.
*
* @param { Length } value
* @returns { T }
@@ -18902,7 +20495,10 @@ declare class CommonMethod {
*/
width(value: Length): T;
/**
- * Sets the width of the current component.
+ * 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.
*
* @param { Length | LayoutPolicy } widthValue
* @returns { T }
@@ -18942,7 +20538,9 @@ declare class CommonMethod {
* @since 10
*/
/**
- * Sets the height of the current component.
+ * 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.
*
* @param { Length } value
* @returns { T }
@@ -18954,7 +20552,10 @@ declare class CommonMethod {
*/
height(value: Length): T;
/**
- * Sets the height of the current component.
+ * 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.
*
* @param { Length | LayoutPolicy } heightValue
* @returns { T }
@@ -18970,6 +20571,8 @@ declare class CommonMethod {
* 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
@@ -18980,6 +20583,7 @@ 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