• 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 * Provides an interface for generating QR codes.
23 *
24 * @interface QRCodeInterface
25 * @syscap SystemCapability.ArkUI.ArkUI.Full
26 * @since 7
27 */
28/**
29 * Provides an interface for generating QR codes.
30 *
31 * @interface QRCodeInterface
32 * @syscap SystemCapability.ArkUI.ArkUI.Full
33 * @form
34 * @since 9
35 */
36/**
37 * Provides an interface for generating QR codes.
38 *
39 * @interface QRCodeInterface
40 * @syscap SystemCapability.ArkUI.ArkUI.Full
41 * @crossplatform
42 * @form
43 * @since 10
44 */
45/**
46 * Provides an interface for generating QR codes.
47 *
48 * @interface QRCodeInterface
49 * @syscap SystemCapability.ArkUI.ArkUI.Full
50 * @crossplatform
51 * @form
52 * @atomicservice
53 * @since 11
54 */
55interface QRCodeInterface {
56  /**
57   * Called when a QR code is set.
58   *
59   * @param { string } value
60   * @returns { QRCodeAttribute }
61   * @syscap SystemCapability.ArkUI.ArkUI.Full
62   * @since 7
63   */
64  /**
65   * Called when a QR code is set.
66   *
67   * @param { string } value
68   * @returns { QRCodeAttribute }
69   * @syscap SystemCapability.ArkUI.ArkUI.Full
70   * @form
71   * @since 9
72   */
73  /**
74   * Called when a QR code is set.
75   *
76   * @param { string } value
77   * @returns { QRCodeAttribute }
78   * @syscap SystemCapability.ArkUI.ArkUI.Full
79   * @crossplatform
80   * @form
81   * @since 10
82   */
83  /**
84   * Called when a QR code is set.
85   *
86   * @param { string } value
87   * @returns { QRCodeAttribute }
88   * @syscap SystemCapability.ArkUI.ArkUI.Full
89   * @crossplatform
90   * @form
91   * @atomicservice
92   * @since 11
93   */
94  (value: string): QRCodeAttribute;
95}
96
97/**
98 * Defines the qrcode attribute functions.
99 *
100 * @extends CommonMethod<QRCodeAttribute>
101 * @syscap SystemCapability.ArkUI.ArkUI.Full
102 * @since 7
103 */
104/**
105 * Defines the qrcode attribute functions.
106 *
107 * @extends CommonMethod<QRCodeAttribute>
108 * @syscap SystemCapability.ArkUI.ArkUI.Full
109 * @form
110 * @since 9
111 */
112/**
113 * Defines the qrcode attribute functions.
114 *
115 * @extends CommonMethod<QRCodeAttribute>
116 * @syscap SystemCapability.ArkUI.ArkUI.Full
117 * @crossplatform
118 * @form
119 * @since 10
120 */
121/**
122 * Defines the qrcode attribute functions.
123 *
124 * @extends CommonMethod<QRCodeAttribute>
125 * @syscap SystemCapability.ArkUI.ArkUI.Full
126 * @crossplatform
127 * @form
128 * @atomicservice
129 * @since 11
130 */
131declare class QRCodeAttribute extends CommonMethod<QRCodeAttribute> {
132  /**
133   * Called when the QR code color is set.
134   *
135   * @param { ResourceColor } value
136   * @returns { QRCodeAttribute }
137   * @syscap SystemCapability.ArkUI.ArkUI.Full
138   * @since 7
139   */
140  /**
141   * Called when the QR code color is set.
142   *
143   * @param { ResourceColor } value
144   * @returns { QRCodeAttribute }
145   * @syscap SystemCapability.ArkUI.ArkUI.Full
146   * @form
147   * @since 9
148   */
149  /**
150   * Called when the QR code color is set.
151   *
152   * @param { ResourceColor } value
153   * @returns { QRCodeAttribute }
154   * @syscap SystemCapability.ArkUI.ArkUI.Full
155   * @crossplatform
156   * @form
157   * @since 10
158   */
159  /**
160   * Called when the QR code color is set.
161   *
162   * @param { ResourceColor } value
163   * @returns { QRCodeAttribute }
164   * @syscap SystemCapability.ArkUI.ArkUI.Full
165   * @crossplatform
166   * @form
167   * @atomicservice
168   * @since 11
169   */
170  color(value: ResourceColor): QRCodeAttribute;
171
172  /**
173   * Called when setting the QR code background color.
174   *
175   * @param { ResourceColor } value
176   * @returns { QRCodeAttribute }
177   * @syscap SystemCapability.ArkUI.ArkUI.Full
178   * @since 7
179   */
180  /**
181   * Called when setting the QR code background color.
182   *
183   * @param { ResourceColor } value
184   * @returns { QRCodeAttribute }
185   * @syscap SystemCapability.ArkUI.ArkUI.Full
186   * @form
187   * @since 9
188   */
189  /**
190   * Called when setting the QR code background color.
191   *
192   * @param { ResourceColor } value
193   * @returns { QRCodeAttribute }
194   * @syscap SystemCapability.ArkUI.ArkUI.Full
195   * @crossplatform
196   * @form
197   * @since 10
198   */
199  /**
200   * Called when setting the QR code background color.
201   *
202   * @param { ResourceColor } value
203   * @returns { QRCodeAttribute }
204   * @syscap SystemCapability.ArkUI.ArkUI.Full
205   * @crossplatform
206   * @form
207   * @atomicservice
208   * @since 11
209   */
210  backgroundColor(value: ResourceColor): QRCodeAttribute;
211
212  /**
213   * Set the opacity of the QR code content color.
214   * @param { number | Resource } value - indicates the opacity of the QR code content color. The value is between 0 and 1, with a default value of 1.
215   * @returns { QRCodeAttribute } the attribute of the QR code
216   * @syscap SystemCapability.ArkUI.ArkUI.Full
217   * @crossplatform
218   * @since 11
219   */
220  /**
221   * Set the opacity of the QR code content color.
222   * @param { number | Resource } value - indicates the opacity of the QR code content color. The value is between 0 and 1, with a default value of 1.
223   * @returns { QRCodeAttribute } the attribute of the QR code
224   * @syscap SystemCapability.ArkUI.ArkUI.Full
225   * @crossplatform
226   * @atomicservice
227   * @since 12
228   */
229  contentOpacity(value: number | Resource): QRCodeAttribute;
230}
231
232/**
233 * Defines QRCode Component.
234 *
235 * @syscap SystemCapability.ArkUI.ArkUI.Full
236 * @since 7
237 */
238/**
239 * Defines QRCode Component.
240 *
241 * @syscap SystemCapability.ArkUI.ArkUI.Full
242 * @form
243 * @since 9
244 */
245/**
246 * Defines QRCode Component.
247 *
248 * @syscap SystemCapability.ArkUI.ArkUI.Full
249 * @crossplatform
250 * @form
251 * @since 10
252 */
253/**
254 * Defines QRCode Component.
255 *
256 * @syscap SystemCapability.ArkUI.ArkUI.Full
257 * @crossplatform
258 * @form
259 * @atomicservice
260 * @since 11
261 */
262declare const QRCode: QRCodeInterface;
263
264/**
265 * Defines QRCode Component instance.
266 *
267 * @syscap SystemCapability.ArkUI.ArkUI.Full
268 * @since 7
269 */
270/**
271 * Defines QRCode Component instance.
272 *
273 * @syscap SystemCapability.ArkUI.ArkUI.Full
274 * @form
275 * @since 9
276 */
277/**
278 * Defines QRCode Component instance.
279 *
280 * @syscap SystemCapability.ArkUI.ArkUI.Full
281 * @crossplatform
282 * @form
283 * @since 10
284 */
285/**
286 * Defines QRCode Component instance.
287 *
288 * @syscap SystemCapability.ArkUI.ArkUI.Full
289 * @crossplatform
290 * @form
291 * @atomicservice
292 * @since 11
293 */
294declare const QRCodeInstance: QRCodeAttribute;
295