1/* 2 * Copyright (c) 2023-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 * Declare Component ProgressButton 23 * @syscap SystemCapability.ArkUI.ArkUI.Full 24 * @since 10 25 */ 26/** 27 * Declare Component ProgressButton 28 * @syscap SystemCapability.ArkUI.ArkUI.Full 29 * @atomicservice 30 * @since 11 31 */ 32@Component 33export declare struct ProgressButton { 34 /** 35 * Sets the ProgressButton progress. 36 * @type { number }. 37 * @syscap SystemCapability.ArkUI.ArkUI.Full 38 * @since 10 39 */ 40 /** 41 * Sets the ProgressButton progress. 42 * @type { number }. 43 * @syscap SystemCapability.ArkUI.ArkUI.Full 44 * @atomicservice 45 * @since 11 46 */ 47 @Prop progress: number; 48 49 /** 50 * Sets the ProgressButton content. 51 * @type { string }. 52 * @syscap SystemCapability.ArkUI.ArkUI.Full 53 * @since 10 54 */ 55 /** 56 * Sets the ProgressButton content. 57 * @type { string }. 58 * @syscap SystemCapability.ArkUI.ArkUI.Full 59 * @atomicservice 60 * @since 11 61 */ 62 @Prop content: string; 63 64 /** 65 * Sets the ProgressButton progressButtonWidth. 66 * @type { ?Length }. 67 * @syscap SystemCapability.ArkUI.ArkUI.Full 68 * @since 10 69 */ 70 /** 71 * Sets the ProgressButton progressButtonWidth. 72 * @type { ?Length }. 73 * @syscap SystemCapability.ArkUI.ArkUI.Full 74 * @atomicservice 75 * @since 11 76 */ 77 progressButtonWidth?: Length; 78 79 /** 80 * Sets the ProgressButton clickCallback. 81 * @type { () => void }. 82 * @syscap SystemCapability.ArkUI.ArkUI.Full 83 * @since 10 84 */ 85 /** 86 * Sets the ProgressButton clickCallback. 87 * @type { () => void }. 88 * @syscap SystemCapability.ArkUI.ArkUI.Full 89 * @atomicservice 90 * @since 11 91 */ 92 clickCallback: () => void; 93 94 /** 95 * Sets the ProgressButton enable state. 96 * @type { boolean }. 97 * @syscap SystemCapability.ArkUI.ArkUI.Full 98 * @since 10 99 */ 100 /** 101 * Sets the ProgressButton enable state. 102 * @type { boolean }. 103 * @syscap SystemCapability.ArkUI.ArkUI.Full 104 * @atomicservice 105 * @since 11 106 */ 107 @Prop enable: boolean; 108 109 /** 110 * Set Color options of the ProgressButton. 111 * 112 * @type { ?ProgressButtonColorOptions } 113 * @syscap SystemCapability.ArkUI.ArkUI.Full 114 * @atomicservice 115 * @since 18 116 */ 117 @Prop colorOptions?: ProgressButtonColorOptions; 118 119 /** 120 * Set border rounded corner radius of progress. 121 * 122 * @type { ?LengthMetrics } 123 * @syscap SystemCapability.ArkUI.ArkUI.Full 124 * @crossplatform 125 * @atomicservice 126 * @since 18 127 */ 128 @Prop progressButtonRadius?: LengthMetrics; 129} 130 131/** 132 * Declare Color options of the ProgressButton. 133 * 134 * @interface ProgressButtonColorOptions 135 * @syscap SystemCapability.ArkUI.ArkUI.Full 136 * @atomicservice 137 * @since 18 138 */ 139export declare interface ProgressButtonColorOptions { 140 141 /** 142 * Set progress color of the ProgressButton. 143 * 144 * @type { ?ResourceColor }. 145 * @syscap SystemCapability.ArkUI.ArkUI.Full 146 * @atomicservice 147 * @since 18 148 */ 149 progressColor?: ResourceColor; 150 151 /** 152 * Set border color of the ProgressButton. 153 * 154 * @type { ?ResourceColor }. 155 * @syscap SystemCapability.ArkUI.ArkUI.Full 156 * @atomicservice 157 * @since 18 158 */ 159 borderColor?: ResourceColor; 160 161 /** 162 * Set text color of the ProgressButton. 163 * 164 * @type { ?ResourceColor }. 165 * @syscap SystemCapability.ArkUI.ArkUI.Full 166 * @atomicservice 167 * @since 18 168 */ 169 textColor?: ResourceColor; 170 171 /** 172 * Set background color of the ProgressButton. 173 * 174 * @type { ?ResourceColor }. 175 * @syscap SystemCapability.ArkUI.ArkUI.Full 176 * @atomicservice 177 * @since 18 178 */ 179 backgroundColor?: ResourceColor; 180}