1/* 2 * Copyright (c) 2024-2025 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 * @file 17 * @kit ArkUI 18 * @arkts 1.2 19 */ 20 21 22// WARNING! THIS FILE IS AUTO-GENERATED, DO NOT MAKE CHANGES, THEY WILL BE LOST ON NEXT GENERATION! 23 24import { memo, ComponentBuilder, __memo_context_type, __memo_id_type } from './../stateManagement/runtime' 25import { Length, PX, VP, LPX, ResourceColor, Font, VisualEffect, Filter, UniformDataType, Blender, SizeOptions, ConstraintSizeOptions, ChainWeightOptions, Padding, LocalizedPadding, Margin, LocalizedMargin, Position, BorderOptions, EdgeStyles, EdgeWidths, LocalizedEdgeWidths, EdgeColors, LocalizedEdgeColors, BorderRadiuses, LocalizedBorderRadiuses, OutlineOptions, EdgeOutlineStyles, Dimension, EdgeOutlineWidths, OutlineRadiuses, Area, Edges, LocalizedEdges, LocalizedPosition, ResourceStr, AccessibilityOptions, PixelMap } from './units' 26import { Resource } from './../../../api/global/resource' 27import { CommonMethod, DrawModifier, Rectangle, Callback_Array_TouchTestInfo_TouchResult, TouchTestInfo, TouchResult, PixelRoundPolicy, BackgroundEffectOptions, ForegroundEffectOptions, BorderImageOption, OutlineStyle, Callback_ClickEvent_Void, ClickEvent, Callback_Boolean_HoverEvent_Void, HoverEvent, AccessibilityCallback, Callback_MouseEvent_Void, MouseEvent, Callback_TouchEvent_Void, TouchEvent, Callback_KeyEvent_Void, KeyEvent, Callback_KeyEvent_Boolean, AnimateParam, TransitionOptions, TransitionEffect, MotionBlurOptions, InvertOptions, TranslateOptions, ScaleOptions, RotateOptions, Callback_Area_Area_Void, Literal_Union_Number_Literal_Number_offset_span_lg_md_sm_xs, Literal_Number_offset_span, AlignRuleOption, LocalizedAlignRuleOptions, ClickEffect, Callback_DragEvent_String_Union_CustomBuilder_DragItemInfo, DragEvent, CustomBuilder, DragItemInfo, Callback_DragEvent_String_Void, Callback_PreDragStatus_Void, PreDragStatus, Type_CommonMethod_linearGradient_value, Tuple_ResourceColor_Number, Type_CommonMethod_sweepGradient_value, Tuple_Length_Length, Type_CommonMethod_radialGradient_value, MotionPathOptions, ShadowOptions, ShadowStyle, ProgressMask, StateStyles, PixelStretchEffectOptions, AttributeModifier, GestureModifier, BackgroundBrightnessOptions, Callback_GestureInfo_BaseGestureEvent_GestureJudgeResult, GestureRecognizerJudgeBeginCallback, ShouldBuiltInRecognizerParallelWithCallback, Callback_TouchEvent_HitTestMode, SizeChangeCallback, SafeAreaType, SafeAreaEdge, Literal_Alignment_align, BlurStyle, BackgroundBlurStyleOptions, ForegroundBlurStyleOptions, TransitionFinishCallback, BlurOptions, LinearGradientBlurOptions, EffectType, sharedTransitionOptions, ChainStyle, DragPreviewOptions, DragInteractionOptions, OverlayOptions, BlendMode, BlendApplyType, GeometryTransitionOptions, PopupOptions, CustomPopupOptions, MenuElement, MenuOptions, ContextMenuOptions, ModalTransition, ContentCoverOptions, SheetOptions, VisibleAreaChangeCallback, ContentModifier, CommonConfiguration } from './common' 28 29export interface ProgressOptions { 30 value: number; 31 total?: number; 32 style?: ProgressStyle; 33 type?: ProgressType; 34} 35export enum ProgressType { 36 LINEAR = 0, 37 Linear = 0, 38 RING = 1, 39 Ring = 1, 40 ECLIPSE = 2, 41 Eclipse = 2, 42 SCALE_RING = 3, 43 ScaleRing = 3, 44 CAPSULE = 4, 45 Capsule = 4 46} 47export enum ProgressStatus { 48 LOADING = 0, 49 PROGRESSING = 1 50} 51export interface ProgressStyleOptions extends CommonProgressStyleOptions { 52 strokeWidth?: Length; 53 scaleCount?: number; 54 scaleWidth?: Length; 55} 56export interface CommonProgressStyleOptions { 57 enableSmoothEffect?: boolean; 58} 59export interface ScanEffectOptions { 60 enableScanEffect?: boolean; 61} 62export interface EclipseStyleOptions extends CommonProgressStyleOptions { 63} 64export interface ScaleRingStyleOptions extends CommonProgressStyleOptions { 65 strokeWidth?: Length; 66 scaleWidth?: Length; 67 scaleCount?: number; 68} 69export interface RingStyleOptions extends ScanEffectOptions { 70 strokeWidth?: Length; 71 shadow?: boolean; 72 status?: ProgressStatus; 73} 74export interface LinearStyleOptions extends ScanEffectOptions { 75 strokeWidth?: Length; 76 strokeRadius?: PX | VP | LPX | Resource; 77} 78export interface CapsuleStyleOptions extends ScanEffectOptions { 79 borderColor?: ResourceColor; 80 borderWidth?: Length; 81 content?: string; 82 font?: Font; 83 fontColor?: ResourceColor; 84 showDefaultPercentage?: boolean; 85} 86export enum ProgressStyle { 87 LINEAR = 0, 88 Linear = 0, 89 RING = 1, 90 Ring = 1, 91 ECLIPSE = 2, 92 Eclipse = 2, 93 SCALE_RING = 3, 94 ScaleRing = 3, 95 CAPSULE = 4, 96 Capsule = 4 97} 98export interface ProgressStyleMap { 99} 100export type ProgressInterface = (options: ProgressOptions) => ProgressAttribute; 101export interface ProgressAttribute extends CommonMethod { 102 @memo 103 value(value: number): this; 104 @memo 105 color(value: ResourceColor): this; 106 @memo 107 style(value: LinearStyleOptions | RingStyleOptions | CapsuleStyleOptions | ProgressStyleOptions): this; 108 @memo 109 privacySensitive(value: boolean | undefined): this; 110 @memo 111 contentModifier(value: ContentModifier<ProgressConfiguration>): this; 112} 113export interface ProgressConfiguration extends CommonConfiguration<ProgressConfiguration> { 114 value: number; 115 total: number; 116} 117@memo 118@ComponentBuilder 119export declare function Progress( 120 options: ProgressOptions, 121 @memo 122 content_?: () => void, 123): ProgressAttribute 124