mirror of
https://gitee.com/openharmony/interface_sdk-js
synced 2024-11-30 10:53:31 +00:00
7f7ac990e0
Signed-off-by: zhangzuhui <zhangzuhui1@h-partners.com>
527 lines
10 KiB
Plaintext
527 lines
10 KiB
Plaintext
/*
|
|
* Copyright (C) 2023-2023 Huawei Device Co., Ltd.
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
* you may not use this file except in compliance with the License.
|
|
* You may obtain a copy of the License at
|
|
*
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
*
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
* See the License for the specific language governing permissions and
|
|
* limitations under the License.
|
|
*/
|
|
|
|
/**
|
|
* @file
|
|
* @kit ArkUI
|
|
*/
|
|
|
|
/**
|
|
* Declare enum IconType
|
|
* @enum { IconType }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
|
|
|
|
/**
|
|
* Declare enum IconType
|
|
* @enum { IconType }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
export declare enum IconType {
|
|
/**
|
|
* Badge type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Badge type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
BADGE = 1,
|
|
/**
|
|
* Normal icon type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Normal icon type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
NORMAL_ICON = 2,
|
|
/**
|
|
* System icon type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* System icon type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
SYSTEM_ICON = 3,
|
|
/**
|
|
* HeadSculpture type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* HeadSculpture type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
HEAD_SCULPTURE = 4,
|
|
/**
|
|
* App icon type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* App icon type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
APP_ICON = 5,
|
|
/**
|
|
* Preview type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Preview type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
PREVIEW = 6,
|
|
/**
|
|
* Longitudinal type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Longitudinal type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
LONGITUDINAL = 7,
|
|
/**
|
|
* Vertical type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Vertical type.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
VERTICAL = 8
|
|
}
|
|
|
|
/**
|
|
* Declare type OperateIcon
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Declare type OperateIcon
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
export declare class OperateIcon {
|
|
/**
|
|
* The content of text or the address of icon.
|
|
* @type { ResourceStr }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* The content of text or the address of icon.
|
|
* @type { ResourceStr }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
value: ResourceStr;
|
|
|
|
/**
|
|
* Callback function when operate the icon.
|
|
* @type { ?() => void }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Callback function when operate the icon.
|
|
* @type { ?() => void }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
action?: () => void;
|
|
}
|
|
|
|
/**
|
|
* Declare type OperateCheck
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Declare type OperateCheck
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
export declare class OperateCheck {
|
|
/**
|
|
* Whether is checked on default.
|
|
* @type { ?boolean }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Whether is checked on default.
|
|
* @type { ?boolean }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
isCheck?: boolean;
|
|
|
|
/**
|
|
* Callback function when operate the checkbox/switch/radio.
|
|
* @type { ?() => void }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Callback function when operate the checkbox/switch/radio.
|
|
* @type { ?() => void }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
onChange?: (value: boolean) => void;
|
|
}
|
|
|
|
/**
|
|
* Declare type OperateButton
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Declare type OperateButton
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
export declare class OperateButton {
|
|
/**
|
|
* The text on the button.
|
|
* @type { ?ResourceStr }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* The text on the button.
|
|
* @type { ?ResourceStr }.
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
text?: ResourceStr;
|
|
}
|
|
|
|
/**
|
|
* Declare ContentItem
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Declare ContentItem
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
export declare class ContentItem {
|
|
/**
|
|
* The type of icon.
|
|
* @type { ?IconType }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* The type of icon.
|
|
* @type { ?IconType }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
iconStyle?: IconType;
|
|
|
|
/**
|
|
* Sets the icon.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the icon.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
icon?: ResourceStr;
|
|
|
|
/**
|
|
* Sets the primaryText.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the primaryText.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
primaryText?: ResourceStr;
|
|
|
|
/**
|
|
* Sets the secondaryText.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the secondaryText.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
secondaryText?: ResourceStr;
|
|
|
|
/**
|
|
* Sets the description.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the description.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
description?: ResourceStr;
|
|
}
|
|
|
|
/**
|
|
* Declare OperateItem
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Declare OperateItem
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
export declare class OperateItem {
|
|
/**
|
|
* Sets the icon.
|
|
* @type { ?OperateIcon }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the icon.
|
|
* @type { ?OperateIcon }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
icon?: OperateIcon;
|
|
|
|
/**
|
|
* Sets the subIcon.
|
|
* @type { ?OperateIcon }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the subIcon.
|
|
* @type { ?OperateIcon }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
subIcon?: OperateIcon;
|
|
|
|
/**
|
|
* Sets the button.
|
|
* @type { ?OperateButton }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the button.
|
|
* @type { ?OperateButton }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
button?: OperateButton;
|
|
|
|
/**
|
|
* Sets the switch.
|
|
* @type { ?OperateCheck }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the switch.
|
|
* @type { ?OperateCheck }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
switch?: OperateCheck;
|
|
|
|
/**
|
|
* Sets the checkBox.
|
|
* @type { ?OperateCheck }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the checkBox.
|
|
* @type { ?OperateCheck }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
checkbox?: OperateCheck;
|
|
|
|
/**
|
|
* Sets the radio.
|
|
* @type { ?OperateCheck }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the radio.
|
|
* @type { ?OperateCheck }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
radio?: OperateCheck;
|
|
|
|
/**
|
|
* Sets the image.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the image.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
image?: ResourceStr;
|
|
|
|
/**
|
|
* Sets the text.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the text.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
text?: ResourceStr;
|
|
|
|
/**
|
|
* Sets the arrow.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Sets the arrow.
|
|
* @type { ?ResourceStr }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
arrow?: OperateIcon;
|
|
}
|
|
|
|
/**
|
|
* Declare ComposeListItem
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* Declare ComposeListItem
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
@Component
|
|
export declare struct ComposeListItem {
|
|
/**
|
|
* The ContentItem.
|
|
* @type { ?ContentItem }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* The ContentItem.
|
|
* @type { ?ContentItem }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
@Prop contentItem?: ContentItem;
|
|
|
|
/**
|
|
* The OperateItem.
|
|
* @type { ?OperateItem }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @since 10
|
|
*/
|
|
/**
|
|
* The OperateItem.
|
|
* @type { ?OperateItem }
|
|
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
|
* @atomicservice
|
|
* @since 11
|
|
*/
|
|
@Prop operateItem?: OperateItem;
|
|
} |