• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (c) 2021-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 the stepper.
23 *
24 * @interface StepperInterface
25 * @syscap SystemCapability.ArkUI.ArkUI.Full
26 * @since 8
27 */
28/**
29 * Declare the stepper.
30 *
31 * @interface StepperInterface
32 * @syscap SystemCapability.ArkUI.ArkUI.Full
33 * @crossplatform
34 * @since 10
35 */
36/**
37 * Declare the stepper.
38 *
39 * @interface StepperInterface
40 * @syscap SystemCapability.ArkUI.ArkUI.Full
41 * @crossplatform
42 * @atomicservice
43 * @since 11
44 */
45interface StepperInterface {
46  /**
47   * Called when the stepper component is used.
48   *
49   * @param { object } value
50   * @returns { StepperAttribute }
51   * @syscap SystemCapability.ArkUI.ArkUI.Full
52   * @since 8
53   */
54  /**
55   * Called when the stepper component is used.
56   *
57   * @param { object } value
58   * @returns { StepperAttribute }
59   * @syscap SystemCapability.ArkUI.ArkUI.Full
60   * @crossplatform
61   * @since 10
62   */
63  /**
64   * Called when the stepper component is used.
65   *
66   * @param { object } value
67   * @returns { StepperAttribute }
68   * @syscap SystemCapability.ArkUI.ArkUI.Full
69   * @crossplatform
70   * @atomicservice
71   * @since 11
72   */
73  (value?: { index?: number }): StepperAttribute;
74}
75
76/**
77 * Defines the stepper attribute functions
78 *
79 * @extends CommonMethod<StepperAttribute>
80 * @syscap SystemCapability.ArkUI.ArkUI.Full
81 * @since 8
82 */
83/**
84 * Defines the stepper attribute functions
85 *
86 * @extends CommonMethod<StepperAttribute>
87 * @syscap SystemCapability.ArkUI.ArkUI.Full
88 * @crossplatform
89 * @since 10
90 */
91/**
92 * Defines the stepper attribute functions
93 *
94 * @extends CommonMethod<StepperAttribute>
95 * @syscap SystemCapability.ArkUI.ArkUI.Full
96 * @crossplatform
97 * @atomicservice
98 * @since 11
99 */
100declare class StepperAttribute extends CommonMethod<StepperAttribute> {
101  /**
102   * Callback when the finish label is clicked.
103   *
104   * @param { function } callback
105   * @returns { StepperAttribute }
106   * @syscap SystemCapability.ArkUI.ArkUI.Full
107   * @since 8
108   */
109  /**
110   * Callback when the finish label is clicked.
111   *
112   * @param { function } callback
113   * @returns { StepperAttribute }
114   * @syscap SystemCapability.ArkUI.ArkUI.Full
115   * @crossplatform
116   * @since 10
117   */
118  /**
119   * Callback when the finish label is clicked.
120   *
121   * @param { function } callback
122   * @returns { StepperAttribute }
123   * @syscap SystemCapability.ArkUI.ArkUI.Full
124   * @crossplatform
125   * @atomicservice
126   * @since 11
127   */
128  onFinish(callback: () => void): StepperAttribute;
129
130  /**
131   * Callback when the skip label is clicked.
132   *
133   * @param { function } callback
134   * @returns { StepperAttribute }
135   * @syscap SystemCapability.ArkUI.ArkUI.Full
136   * @since 8
137   */
138  /**
139   * Callback when the skip label is clicked.
140   *
141   * @param { function } callback
142   * @returns { StepperAttribute }
143   * @syscap SystemCapability.ArkUI.ArkUI.Full
144   * @crossplatform
145   * @since 10
146   */
147  /**
148   * Callback when the skip label is clicked.
149   *
150   * @param { function } callback
151   * @returns { StepperAttribute }
152   * @syscap SystemCapability.ArkUI.ArkUI.Full
153   * @crossplatform
154   * @atomicservice
155   * @since 11
156   */
157  onSkip(callback: () => void): StepperAttribute;
158
159  /**
160   * Callback when the change label is clicked.
161   *
162   * @param { function } callback
163   * @returns { StepperAttribute }
164   * @syscap SystemCapability.ArkUI.ArkUI.Full
165   * @since 8
166   */
167  /**
168   * Callback when the change label is clicked.
169   *
170   * @param { function } callback
171   * @returns { StepperAttribute }
172   * @syscap SystemCapability.ArkUI.ArkUI.Full
173   * @crossplatform
174   * @since 10
175   */
176  /**
177   * Callback when the change label is clicked.
178   *
179   * @param { function } callback
180   * @returns { StepperAttribute }
181   * @syscap SystemCapability.ArkUI.ArkUI.Full
182   * @crossplatform
183   * @atomicservice
184   * @since 11
185   */
186  onChange(callback: (prevIndex: number, index: number) => void): StepperAttribute;
187
188  /**
189   * Callback when the next label is clicked.
190   *
191   * @param { function } callback
192   * @returns { StepperAttribute }
193   * @syscap SystemCapability.ArkUI.ArkUI.Full
194   * @since 8
195   */
196  /**
197   * Callback when the next label is clicked.
198   *
199   * @param { function } callback
200   * @returns { StepperAttribute }
201   * @syscap SystemCapability.ArkUI.ArkUI.Full
202   * @crossplatform
203   * @since 10
204   */
205  /**
206   * Callback when the next label is clicked.
207   *
208   * @param { function } callback
209   * @returns { StepperAttribute }
210   * @syscap SystemCapability.ArkUI.ArkUI.Full
211   * @crossplatform
212   * @atomicservice
213   * @since 11
214   */
215  onNext(callback: (index: number, pendingIndex: number) => void): StepperAttribute;
216
217  /**
218   * Callback when the previous label is clicked.
219   *
220   * @param { function } callback
221   * @returns { StepperAttribute }
222   * @syscap SystemCapability.ArkUI.ArkUI.Full
223   * @since 8
224   */
225  /**
226   * Callback when the previous label is clicked.
227   *
228   * @param { function } callback
229   * @returns { StepperAttribute }
230   * @syscap SystemCapability.ArkUI.ArkUI.Full
231   * @crossplatform
232   * @since 10
233   */
234  /**
235   * Callback when the previous label is clicked.
236   *
237   * @param { function } callback
238   * @returns { StepperAttribute }
239   * @syscap SystemCapability.ArkUI.ArkUI.Full
240   * @crossplatform
241   * @atomicservice
242   * @since 11
243   */
244  onPrevious(callback: (index: number, pendingIndex: number) => void): StepperAttribute;
245}
246
247/**
248 * Defines Stepper Component.
249 *
250 * @syscap SystemCapability.ArkUI.ArkUI.Full
251 * @since 8
252 */
253/**
254 * Defines Stepper Component.
255 *
256 * @syscap SystemCapability.ArkUI.ArkUI.Full
257 * @crossplatform
258 * @since 10
259 */
260/**
261 * Defines Stepper Component.
262 *
263 * @syscap SystemCapability.ArkUI.ArkUI.Full
264 * @crossplatform
265 * @atomicservice
266 * @since 11
267 */
268declare const Stepper: StepperInterface;
269
270/**
271 * Defines Stepper Component instance.
272 *
273 * @syscap SystemCapability.ArkUI.ArkUI.Full
274 * @since 8
275 */
276/**
277 * Defines Stepper Component instance.
278 *
279 * @syscap SystemCapability.ArkUI.ArkUI.Full
280 * @crossplatform
281 * @since 10
282 */
283/**
284 * Defines Stepper Component instance.
285 *
286 * @syscap SystemCapability.ArkUI.ArkUI.Full
287 * @crossplatform
288 * @atomicservice
289 * @since 11
290 */
291declare const StepperInstance: StepperAttribute;
292