!13514 需求接口提交

Merge pull request !13514 from 邹林肯/dw
This commit is contained in:
openharmony_ci 2024-08-29 06:59:56 +00:00 committed by Gitee
commit 865580c91c
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 112 additions and 0 deletions

View File

@ -9728,3 +9728,95 @@ declare enum AccessibilityHoverType {
*/
HOVER_CANCEL = 3,
}
/**
* Type of window width breakpoint.
*
* @enum {number}
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
declare enum WidthBreakpoint {
/**
* Window width < 320vp type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
WIDTH_XS = 0,
/**
* Window width >= 320vp and < 600vp type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
WIDTH_SM = 1,
/**
* Window width >= 600vp and < 840vp type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
WIDTH_MD = 2,
/**
* Window width >= 840vp and < 1440vp type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
WIDTH_LG = 3,
/**
* Window width >= 1440vp type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
WIDTH_XL = 4,
}
/**
* Type of window height breakpoint.
*
* @enum {number}
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
declare enum HeightBreakpoint {
/**
* Window aspectRatio < 0.8 type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
HEIGHT_SM = 0,
/**
* Window aspectRatio >= 0.8 and < 1.2 type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
HEIGHT_MD = 1,
/**
* Window aspectRatio >= 1.2 type.
*
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
HEIGHT_LG = 2,
}

View File

@ -3130,6 +3130,26 @@ export class UIContext {
* @since 12
*/
getWindowName(): string | undefined;
/**
* Get the width breakpoint of current window.
*
* @returns { WidthBreakpoint } The width breakpoint of current window.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
getWindowWidthBreakpoint(): WidthBreakpoint;
/**
* Get the height breakpoint of current window.
*
* @returns { HeightBreakpoint } The height breakpoint of current window.
* @syscap SystemCapability.ArkUI.ArkUI.Full
* @atomicservice
* @since 13
*/
getWindowHeightBreakpoint(): HeightBreakpoint;
/**
* Open the BindSheet.