@progress/kendo-angular-barcodes 1.0.0-next.202203230834 → 2.0.0-dev.202204131407

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,292 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { ElementRef, NgZone, Renderer2 } from '@angular/core';
6
+ import { QRCode, QRCodeOptions } from '@progress/kendo-charts';
7
+ import { BaseComponent } from './base.component';
8
+ import { Border, QRCodeEncoding, QRCodeErrorCorrection, QRCodeOverlay, RenderMode } from './chart-types';
9
+ import * as i0 from "@angular/core";
10
+ /**
11
+ * Represents the Kendo UI QR Code component for Angular.
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * import { Component } from '@angular/core';
16
+ *
17
+ * _@Component({
18
+ * selector: 'my-app',
19
+ * template: `
20
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui">
21
+ * </kendo-qrcode>
22
+ * `
23
+ * })
24
+ * export class AppComponent {
25
+ * }
26
+ * ```
27
+ */
28
+ export declare class QRCodeComponent extends BaseComponent {
29
+ protected element: ElementRef;
30
+ protected renderer: Renderer2;
31
+ protected ngZone: NgZone;
32
+ /**
33
+ * The background color of the QR Code. Accepts a valid CSS color string, including hex and rgb.
34
+ *
35
+ * @default "white"
36
+ *
37
+ * @example
38
+ * ```ts-preview
39
+ * import { Component } from '@angular/core';
40
+ *
41
+ * _@Component({
42
+ * selector: 'my-app',
43
+ * template: `
44
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
45
+ * background="#fc0">
46
+ * </kendo-qrcode>
47
+ * `
48
+ * })
49
+ * export class AppComponent {
50
+ * }
51
+ * ```
52
+ */
53
+ background?: string;
54
+ /**
55
+ * The border of the QR Code.
56
+ *
57
+ * @example
58
+ * ```ts-preview
59
+ * import { Component } from '@angular/core';
60
+ * import { Border } from '@progress/kendo-angular-barcodes';
61
+ *
62
+ * _@Component({
63
+ * selector: 'my-app',
64
+ * template: `
65
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
66
+ * [border]="qrcodeBorder" [padding]="5">
67
+ * </kendo-qrcode>
68
+ * `
69
+ * })
70
+ * export class AppComponent {
71
+ * qrcodeBorder: Border = {
72
+ * color: '#fc0',
73
+ * width: 2
74
+ * };
75
+ * }
76
+ * ```
77
+ */
78
+ border?: Border;
79
+ /**
80
+ * The color of the QR Code. Accepts a valid CSS color string, including hex and rgb.
81
+ *
82
+ * @default "black"
83
+ *
84
+ * @example
85
+ * ```ts-preview
86
+ * _@Component({
87
+ * selector: 'my-app',
88
+ * template: `
89
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
90
+ * color="#fc0">
91
+ * </kendo-qrcode>
92
+ * `
93
+ * })
94
+ * export class AppComponent {
95
+ * }
96
+ * ```
97
+ */
98
+ color?: string;
99
+ /**
100
+ * The encoding mode used to encode the value.
101
+ *
102
+ * > **Important** The UTF-8 encoding is not included in the specifications and is not supported by all readers.
103
+ *
104
+ * The possible values are:
105
+ * * `"ISO_8859_1"`&mdash;Supports all characters from the [ISO/IEC 8859-1](https://en.wikipedia.org/wiki/ISO/IEC_8859-1) character set.
106
+ * * `"UTF_8"`&mdash;Supports all [Unicode](https://en.wikipedia.org/wiki/List_of_Unicode_characters) characters.
107
+ *
108
+ * @default "ISO_8859_1"
109
+ *
110
+ * @example
111
+ * ```ts-preview
112
+ * _@Component({
113
+ * selector: 'my-app',
114
+ * template: `
115
+ * <kendo-qrcode value="АБВ" encoding="UTF_8">
116
+ * </kendo-qrcode>
117
+ * `
118
+ * })
119
+ * export class AppComponent {
120
+ * }
121
+ * ```
122
+ */
123
+ encoding?: QRCodeEncoding;
124
+ /**
125
+ * The error correction level to use.
126
+ *
127
+ * The possible values are:
128
+ * * `"L"`&mdash;Approximately 7% of the codewords can be restored.
129
+ * * `"M"`&mdash;Approximately 15% of the codewords can be restored.
130
+ * * `"Q"`&mdash;Approximately 25% of the codewords can be restored.
131
+ * * `"H"`&mdash;Approximately 30% of the codewords can be restored.
132
+ *
133
+ * @default "L"
134
+ *
135
+ * @example
136
+ * ```ts-preview
137
+ * _@Component({
138
+ * selector: 'my-app',
139
+ * template: `
140
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
141
+ * errorCorrection="Q">
142
+ * </kendo-qrcode>
143
+ * `
144
+ * })
145
+ * export class AppComponent {
146
+ * }
147
+ * ```
148
+ */
149
+ errorCorrection?: QRCodeErrorCorrection;
150
+ /**
151
+ * An optional image overlay that will placed over the QR Code.
152
+ *
153
+ * > **Note** Always test if the code reads correctly with the applied overlay.
154
+ * > Depending on the length of the value and the size of the overlay, you might need to raise the `errorCorrection` level to `"M"` or `"H"`.
155
+ *
156
+ * @example
157
+ * ```ts-preview
158
+ * import { QRCodeOverlay } from '@progress/kendo-angular-barcodes';
159
+ *
160
+ * _@Component({
161
+ * selector: 'my-app',
162
+ * template: `
163
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
164
+ * [overlay]="qrcodeOverlay">
165
+ * </kendo-qrcode>
166
+ * `
167
+ * })
168
+ * export class AppComponent {
169
+ * qrcodeOverlay: QRCodeOverlay = {
170
+ * type: 'swiss'
171
+ * };
172
+ * }
173
+ * ```
174
+ */
175
+ overlay?: QRCodeOverlay;
176
+ /**
177
+ * The padding of the QR Code. The value sets all paddings in pixels.
178
+ *
179
+ * @default 0
180
+ *
181
+ * @example
182
+ * ```ts-preview
183
+ * import { Component } from '@angular/core';
184
+ *
185
+ * _@Component({
186
+ * selector: 'my-app',
187
+ * template: `
188
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
189
+ * [padding]="10" background="#fc0">
190
+ * </kendo-qrcode>
191
+ * `
192
+ * })
193
+ * export class AppComponent {
194
+ * }
195
+ * ```
196
+ */
197
+ padding?: number;
198
+ /**
199
+ * Sets the preferred rendering mode of the QR Code.
200
+ *
201
+ * The supported values are:
202
+ * * `"canvas"`&mdash;Renders the component as a Canvas element.
203
+ * * `"svg"`&mdash;Renders the component as an inline SVG document.
204
+ *
205
+ * @default "svg"
206
+ *
207
+ * @example
208
+ * ```ts-preview
209
+ * _@Component({
210
+ * selector: 'my-app',
211
+ * template: `
212
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
213
+ * renderAs="canvas">
214
+ * </kendo-qrcode>
215
+ * `
216
+ * })
217
+ * export class AppComponent {
218
+ * }
219
+ * ```
220
+ */
221
+ renderAs?: RenderMode;
222
+ /**
223
+ * Specifies the size of a QR Code. Numeric values are treated as pixels.
224
+ *
225
+ * If no size is specified, the size will be determined from the element width and height.
226
+ * If the element has width or height of zero, a default value of 200 pixels will be used.
227
+ *
228
+ * @default "200px"
229
+ *
230
+ * @example
231
+ * ```ts-preview
232
+ * _@Component({
233
+ * selector: 'my-app',
234
+ * template: `
235
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
236
+ * [size]="200">
237
+ * </kendo-qrcode>
238
+ *
239
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
240
+ * style="width: 200px; height: 200px;">
241
+ * </kendo-qrcode>
242
+ * `
243
+ * })
244
+ * export class AppComponent {
245
+ * }
246
+ * ```
247
+ */
248
+ size?: number | string;
249
+ /**
250
+ * The value of the QR Code.
251
+ *
252
+ * @example
253
+ * ```ts-preview
254
+ * _@Component({
255
+ * selector: 'my-app',
256
+ * template: `
257
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui">
258
+ * </kendo-qrcode>
259
+ * `
260
+ * })
261
+ * export class AppComponent {
262
+ * }
263
+ * ```
264
+ */
265
+ value: number | string;
266
+ /**
267
+ * Limits the automatic resizing of the QR Code. Sets the maximum number of times per second
268
+ * that the component redraws its content when the size of its container changes.
269
+ * Defaults to `10`. To disable the automatic resizing, set it to `0`.
270
+ *
271
+ * @example
272
+ * ```ts
273
+ * _@Component({
274
+ * selector: 'my-app',
275
+ * template: `
276
+ * <kendo-qrcode value="https://www.telerik.com/kendo-angular-ui"
277
+ * [resizeRateLimit]="2">
278
+ * </kendo-qrcode>
279
+ * `
280
+ * })
281
+ * export class AppComponent {
282
+ * }
283
+ * ```
284
+ */
285
+ resizeRateLimit: number;
286
+ protected get options(): QRCodeOptions;
287
+ constructor(element: ElementRef, renderer: Renderer2, ngZone: NgZone);
288
+ protected createInstance(element: any, options: any): QRCode;
289
+ protected onError(error: Error): void;
290
+ static ɵfac: i0.ɵɵFactoryDeclaration<QRCodeComponent, never>;
291
+ static ɵcmp: i0.ɵɵComponentDeclaration<QRCodeComponent, "kendo-qrcode", ["kendoQRCode"], { "background": "background"; "border": "border"; "color": "color"; "encoding": "encoding"; "errorCorrection": "errorCorrection"; "overlay": "overlay"; "padding": "padding"; "renderAs": "renderAs"; "size": "size"; "value": "value"; "resizeRateLimit": "resizeRateLimit"; }, {}, never, never>;
292
+ }
@@ -0,0 +1,43 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import * as i0 from "@angular/core";
6
+ import * as i1 from "./qrcode.component";
7
+ import * as i2 from "@progress/kendo-angular-common";
8
+ /**
9
+ * Represents the [NgModule]({{ site.data.urls.angular['ngmoduleapi'] }})
10
+ * definition for the QR Code component.
11
+ *
12
+ * @example
13
+ *
14
+ * ```ts-no-run
15
+ * // Import the QR Code module
16
+ * import { QRCodeModule } from '@progress/kendo-angular-barcodes';
17
+ *
18
+ * // The browser platform with a compiler
19
+ * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
20
+ *
21
+ * import { NgModule } from '@angular/core';
22
+ *
23
+ * // Import the app component
24
+ * import { AppComponent } from './app.component';
25
+ *
26
+ * // Define the app module
27
+ * _@NgModule({
28
+ * declarations: [AppComponent], // declare app component
29
+ * imports: [BrowserModule, QRCodeModule], // import QRCodeModule module
30
+ * bootstrap: [AppComponent]
31
+ * })
32
+ * export class AppModule {}
33
+ *
34
+ * // Compile and launch the module
35
+ * platformBrowserDynamic().bootstrapModule(AppModule);
36
+ *
37
+ * ```
38
+ */
39
+ export declare class QRCodeModule {
40
+ static ɵfac: i0.ɵɵFactoryDeclaration<QRCodeModule, never>;
41
+ static ɵmod: i0.ɵɵNgModuleDeclaration<QRCodeModule, [typeof i1.QRCodeComponent], [typeof i2.ResizeSensorModule], [typeof i1.QRCodeComponent]>;
42
+ static ɵinj: i0.ɵɵInjectorDeclaration<QRCodeModule>;
43
+ }