1/* 2 * Copyright (c) 2023 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16/** 17 * @file 18 * @kit ArkUI 19 */ 20 21/** 22 * Import the WindowStatusType type object for onHoverStatusChange. 23 * 24 * @typedef {import('../api/@ohos.window').default.WindowStatusType} WindowStatusType 25 * @syscap SystemCapability.ArkUI.ArkUI.Full 26 * @atomicservice 27 * @since 12 28 */ 29declare type WindowStatusType = import('../api/@ohos.window').default.WindowStatusType; 30 31/** 32 * Provides ports for stacking containers. 33 * 34 * @interface FolderStackInterface 35 * @syscap SystemCapability.ArkUI.ArkUI.Full 36 * @crossplatform 37 * @since 11 38 */ 39/** 40 * Provides ports for stacking containers. 41 * 42 * @interface FolderStackInterface 43 * @syscap SystemCapability.ArkUI.ArkUI.Full 44 * @crossplatform 45 * @atomicservice 46 * @since 12 47 */ 48 49interface FolderStackInterface { 50 /** 51 * Defines the constructor of folderStack. 52 * 53 * @param { object } value - id of children need to be show in upperItem 54 * @returns { FolderStackAttribute } 55 * @syscap SystemCapability.ArkUI.ArkUI.Full 56 * @crossplatform 57 * @since 11 58 */ 59 /** 60 * Defines the constructor of folderStack. 61 * 62 * @param { object } value - id of children need to be show in upperItem 63 * @returns { FolderStackAttribute } 64 * @syscap SystemCapability.ArkUI.ArkUI.Full 65 * @crossplatform 66 * @atomicservice 67 * @since 12 68 */ 69 (value?: { upperItems?: Array<string> }): FolderStackAttribute; 70} 71 72/** 73/** 74 * @extends CommonMethod<FolderStackAttribute> 75 * @syscap SystemCapability.ArkUI.ArkUI.Full 76 * @crossplatform 77 * @since 11 78 */ 79/** 80 * @extends CommonMethod<FolderStackAttribute> 81 * @syscap SystemCapability.ArkUI.ArkUI.Full 82 * @crossplatform 83 * @atomicservice 84 * @since 12 85 */ 86declare class FolderStackAttribute extends CommonMethod<FolderStackAttribute> { 87 /** 88 * Set the alignment of folderStack. 89 * 90 * @param { Alignment } value - align of children 91 * @returns { FolderStackAttribute } 92 * @syscap SystemCapability.ArkUI.ArkUI.Full 93 * @crossplatform 94 * @since 11 95 */ 96 /** 97 * Set the alignment of folderStack. 98 * 99 * @param { Alignment } value - align of children 100 * @returns { FolderStackAttribute } 101 * @syscap SystemCapability.ArkUI.ArkUI.Full 102 * @crossplatform 103 * @atomicservice 104 * @since 12 105 */ 106 alignContent(value: Alignment): FolderStackAttribute; 107 108 /** 109* Callback folderState when the folderState changes 110* 111* @param { function } callback - executed when folderStatus changed 112* @returns { FolderStackAttribute } 113* @syscap SystemCapability.ArkUI.ArkUI.Full 114* @crossplatform 115* @since 11 116*/ 117/** 118* Callback folderState when the folderState changes 119* 120* @param { function } callback - executed when folderStatus changed 121* @returns { FolderStackAttribute } 122* @syscap SystemCapability.ArkUI.ArkUI.Full 123* @crossplatform 124* @atomicservice 125* @since 12 126*/ 127 onFolderStateChange(callback: (event: { 128 /** 129 * folder state. 130 * 131 * @type { FoldStatus } 132 * @syscap SystemCapability.ArkUI.ArkUI.Full 133 * @crossplatform 134 * @since 11 135 */ 136 /** 137 * folder state. 138 * 139 * @type { FoldStatus } 140 * @syscap SystemCapability.ArkUI.ArkUI.Full 141 * @crossplatform 142 * @atomicservice 143 * @since 12 144 */ 145 foldStatus: FoldStatus 146 }) => void): FolderStackAttribute; 147 148 149 /** 150 * Callback hoverStatus|folderStatus|rotation|windowMode when the hoverStatus changes 151 * 152 * @param { function } handler - executed when hoverStatus changed 153 * @returns { FolderStackAttribute } 154 * @syscap SystemCapability.ArkUI.ArkUI.Full 155 * @atomicservice 156 * @since 12 157 */ 158 onHoverStatusChange(handler: (param: HoverEventParam) => void): FolderStackAttribute; 159 160 /** 161 * Enable the animation of folderStack. 162 * 163 * @param { boolean } value - enable the animation of folderStatus changed 164 * @returns { FolderStackAttribute } 165 * @syscap SystemCapability.ArkUI.ArkUI.Full 166 * @crossplatform 167 * @since 11 168 */ 169 /** 170 * Enable the animation of folderStack. 171 * 172 * @param { boolean } value - enable the animation of folderStatus changed 173 * @returns { FolderStackAttribute } 174 * @syscap SystemCapability.ArkUI.ArkUI.Full 175 * @crossplatform 176 * @atomicservice 177 * @since 12 178 */ 179 enableAnimation(value: boolean): FolderStackAttribute; 180 181 /** 182 * Enable auto halfFolder when orientation. 183 * 184 * @param { boolean } value - enable auto halfFold 185 * @returns { FolderStackAttribute } 186 * @syscap SystemCapability.ArkUI.ArkUI.Full 187 * @crossplatform 188 * @since 11 189 */ 190 /** 191 * Enable auto halfFolder when orientation. 192 * 193 * @param { boolean } value - enable auto halfFold 194 * @returns { FolderStackAttribute } 195 * @syscap SystemCapability.ArkUI.ArkUI.Full 196 * @crossplatform 197 * @atomicservice 198 * @since 12 199 */ 200 autoHalfFold(value: boolean): FolderStackAttribute; 201} 202 203/** 204 * Defines the Embed Data info. 205 * 206 * @interface HoverEventParam 207 * @syscap SystemCapability.ArkUI.ArkUI.Full 208 * @atomicservice 209 * @since 12 210 */ 211declare interface HoverEventParam { 212 /** 213 * Folder state. 214 * 215 * @type { FoldStatus } 216 * @syscap SystemCapability.ArkUI.ArkUI.Full 217 * @atomicservice 218 * @since 12 219 */ 220 foldStatus: FoldStatus 221 222 /** 223 * Is hover mode 224 * 225 * @type { boolean } 226 * @syscap SystemCapability.ArkUI.ArkUI.Full 227 * @atomicservice 228 * @since 12 229 */ 230 isHoverMode: boolean 231 232 /** 233 * App rotation 234 * 235 * @type { AppRotation } 236 * @syscap SystemCapability.ArkUI.ArkUI.Full 237 * @atomicservice 238 * @since 12 239 */ 240 appRotation: AppRotation 241 242 /** 243 * Window status type 244 * 245 * @type { WindowStatusType } 246 * @syscap SystemCapability.ArkUI.ArkUI.Full 247 * @atomicservice 248 * @since 12 249 */ 250 windowStatusType: WindowStatusType 251} 252/** 253 * Defines FolderStack Component. 254 * 255 * @syscap SystemCapability.ArkUI.ArkUI.Full 256 * @crossplatform 257 * @since 11 258 */ 259/** 260 * Defines FolderStack Component. 261 * 262 * @syscap SystemCapability.ArkUI.ArkUI.Full 263 * @crossplatform 264 * @atomicservice 265 * @since 12 266 */ 267declare const FolderStack: FolderStackInterface; 268 269/** 270 * Defines FolderStack Component instance. 271 * 272 * @syscap SystemCapability.ArkUI.ArkUI.Full 273 * @crossplatform 274 * @since 11 275 */ 276/** 277 * Defines FolderStack Component instance. 278 * 279 * @syscap SystemCapability.ArkUI.ArkUI.Full 280 * @crossplatform 281 * @atomicservice 282 * @since 12 283 */ 284declare const FolderStackInstance: FolderStackAttribute; 285