diff --git a/api/@ohos.arkui.advanced.ComposeListItem.static.d.ets b/api/@ohos.arkui.advanced.ComposeListItem.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..6dd6a33c4c45760b22178218b7afb102b93d47c2 --- /dev/null +++ b/api/@ohos.arkui.advanced.ComposeListItem.static.d.ets @@ -0,0 +1,419 @@ +"use static" +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +import { Component } from './arkui/component/customComponent'; +import { ResourceStr } from './arkui/component/units'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { SymbolGlyphModifier } from './arkui/SymbolGlyphModifier'; +import { Builder } from './arkui/component/builder'; +/** + * Declare enum IconType + * + * @enum { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare enum IconType { + /** + * Badge type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + BADGE = 1, + /** + * Normal icon type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + NORMAL_ICON = 2, + /** + * System icon type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + SYSTEM_ICON = 3, + /** + * HeadSculpture type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + HEAD_SCULPTURE = 4, + /** + * App icon type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + APP_ICON = 5, + /** + * Preview type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + PREVIEW = 6, + /** + * Longitudinal type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + LONGITUDINAL = 7, + /** + * Vertical type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + VERTICAL = 8 +} +/** + * Declare type OperateIcon + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class OperateIcon { + /** + * The content of text or the address of icon. + * + * @type { ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + value: ResourceStr; + /** + * The content of text or the address of symbol. + * + * @type { ?SymbolGlyphModifier }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolStyle?: SymbolGlyphModifier; + + /** + * Callback function when operate the icon. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + action?: () => void; + /** + * The accessibilityText of the icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 20 + */ + accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of the icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of the icon. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityLevel?: string; +} +/** + * Declare type OperateCheck + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class OperateCheck { + /** + * Whether is checked on default. + * + * @type { ?boolean }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + isCheck?: boolean; + /** + * Callback function when operate the checkbox/switch/radio. + * + * @type { ?function } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onChange?: (value: boolean) => void; + /** + * The accessibilityText of the checkbox/switch/radio. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @atomicservice + * @since 20 + */ + accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of the checkbox/switch/radio. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of the checkbox/switch/radio. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityLevel?: string; +} +/** + * Declare type OperateButton + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class OperateButton { + /** + * The text on the button. + * + * @type { ?ResourceStr }. + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + text?: ResourceStr; + /** + * The accessibilityText of the button. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityText?: ResourceStr; + /** + * The accessibilityDescription of the button. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityDescription?: ResourceStr; + /** + * The accessibilityLevel of the button. + * + * @type { ?string } + * @default "auto" + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + accessibilityLevel?: string; +} +/** + * Declare ContentItem + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class ContentItem { + /** + * The type of icon. + * + * @type { ?IconType } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + iconStyle?: IconType; + /** + * Sets the icon. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + icon?: ResourceStr; + /** + * Sets the symbol. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolStyle?: SymbolGlyphModifier; + /** + * Sets the primaryText. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + primaryText?: ResourceStr; + /** + * Sets the secondaryText. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + secondaryText?: ResourceStr; + /** + * Sets the description. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + description?: ResourceStr; +} +/** + * Declare OperateItem + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare class OperateItem { + /** + * Sets the icon. + * + * @type { ?OperateIcon } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + icon?: OperateIcon; + /** + * Sets the subIcon. + * + * @type { ?OperateIcon } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + subIcon?: OperateIcon; + /** + * Sets the button. + * + * @type { ?OperateButton } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + button?: OperateButton; + /** + * Sets the toggle. + * + * @type { ?OperateCheck } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + toggle?: OperateCheck; + /** + * Sets the checkBox. + * + * @type { ?OperateCheck } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + checkbox?: OperateCheck; + /** + * Sets the radio. + * + * @type { ?OperateCheck } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + radio?: OperateCheck; + /** + * Sets the image. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + image?: ResourceStr; + /** + * Sets the symbolStyle. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolStyle?: SymbolGlyphModifier; + /** + * Sets the text. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + text?: ResourceStr; + /** + * Sets the arrow. + * + * @type { ?OperateIcon } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + arrow?: OperateIcon; +} +/** + * Declare ComposeListItem + * + * @struct { ComposeListItem } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +@Component +export declare struct ComposeListItem { + /** + * The ContentItem. + * + * @type { ?ContentItem } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef contentItem?: ContentItem; + /** + * The OperateItem. + * + * @type { ?OperateItem } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef operateItem?: OperateItem; + /** + * The method to build component. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @Builder build(): void; +} \ No newline at end of file diff --git a/api/@ohos.arkui.advanced.GridObjectSortComponent.static.d.ets b/api/@ohos.arkui.advanced.GridObjectSortComponent.static.d.ets new file mode 100644 index 0000000000000000000000000000000000000000..33b7b3fd47037a82cf90efcd1cde32f1f05b85af --- /dev/null +++ b/api/@ohos.arkui.advanced.GridObjectSortComponent.static.d.ets @@ -0,0 +1,214 @@ +"use static" +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +import { Resource, ResourceStr, ResourceColor, LocalizedMargin } from './arkui/component/units'; +import { PropRef } from './arkui/stateManagement/decorator'; +import { Component } from './arkui/component/customComponent'; +import { Builder } from './arkui/component/builder'; +/** + * Controls the style types of GridObjectSortComponent. + * + * @enum { string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export declare enum GridObjectSortComponentType { + /** + * The GridObjectSortComponent image text type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + IMAGE_TEXT = "image_text", + /** + * The GridObjectSortComponent text type. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + TEXT = "text" +} +/** + * Declaration of the GridObjectSortComponent item. + * + * @interface GridObjectSortComponentIteml + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface GridObjectSortComponentItem { + /** + * id of GridObjectSortComponent item. + * + * @type { number | string } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + id: number | string; + /** + * GridObjectSortComponent item text. + * + * @type { ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + text: ResourceStr; + /** + * selected of GridObjectSortComponent item, true is show area, false is add area. + * + * @type { boolean } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + selected: boolean; + /** + * order of GridObjectSortComponentItem, Used for sorting dataList. + * + * @type { number } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + order: number; + /** + * image resource path of the GridObjectSortComponent item. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + url?: ResourceStr; + /** + * symbol of the GridObjectSortComponent item. + * + * @type { ?SymbolGlyphModifier } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + symbolStyle?: SymbolGlyphModifier; +} +/** + * GridObjectSortComponentOptions of GridObjectSortComponent. + * + * @interface GridEditOptions + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export interface GridObjectSortComponentOptions { + /** + * Configuration GridObjectSortComponent type. + * + * @type { GridObjectSortComponentType } + * @default GridObjectSortComponentType.TEXT + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + type?: GridObjectSortComponentType; + /** + * The size of the GridObjectSortComponent image. + * + * @type { ?number | ?Resource } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + imageSize?: number | Resource; + /** + * The title displayed in the unedited state of the GridObjectSortComponent. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + normalTitle?: ResourceStr; + /** + * The title displayed in the GridObjectSortComponent edit state. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + editTitle?: ResourceStr; + /** + * Display Area Title, First subtitle of the GridObjectSortComponent. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + showAreaTitle?: ResourceStr; + /** + * Add Zone Title, second subtitle of the GridObjectSortComponent. + * + * @type { ?ResourceStr } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @crossplatform + * @since 20 + */ + addAreaTitle?: ResourceStr; +} +/** + * Declare struct GridObjectSortComponent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +@Component +export declare struct GridObjectSortComponent { + /** + * Component types and parameters of the GridObjectSortComponent. + * + * @type { GridObjectSortComponentOptions } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + @PropRef + options: GridObjectSortComponentOptions; + /** + * Data list of GridObjectSortComponent. + * + * @type { Array } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + dataList: Array; + /** + * Callback when Obtain edited data. + * + * @type { (select: Array, unselect: Array) => void } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onSave: (select: Array, unselect: Array) => void; + /** + * Cancel callback for saving data. + * + * @type { () => void } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ + onCancel: () => void; + /** + * Build function of GridObjectSortComponent. + * + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since20 + */ + @Builder build(): void; +} \ No newline at end of file