-
-
Notifications
You must be signed in to change notification settings - Fork 162
/
Copy pathassets.gen.dart
508 lines (423 loc) · 13.5 KB
/
assets.gen.dart
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
/// GENERATED CODE - DO NOT MODIFY BY HAND
/// *****************************************************
/// FlutterGen
/// *****************************************************
// coverage:ignore-file
// ignore_for_file: type=lint
// ignore_for_file: directives_ordering,unnecessary_import,implicit_dynamic_list_literal,deprecated_member_use
import 'package:flutter/services.dart';
import 'package:flutter/widgets.dart';
import 'package:flutter_svg/flutter_svg.dart' as _svg;
import 'package:lottie/lottie.dart' as _lottie;
import 'package:rive/rive.dart' as _rive;
import 'package:vector_graphics/vector_graphics.dart' as _vg;
class $AssetsFlareGen {
const $AssetsFlareGen();
/// File path: assets/flare/Penguin.flr
String get penguin => 'assets/flare/Penguin.flr';
/// List of all assets
List<String> get values => [penguin];
}
class $AssetsImagesGen {
const $AssetsImagesGen();
/// File path: assets/images/chip1.jpg
AssetGenImage get chip1 => const AssetGenImage('assets/images/chip1.jpg');
/// File path: assets/images/chip2.jpg
AssetGenImage get chip2 => const AssetGenImage('assets/images/chip2.jpg');
/// Directory path: assets/images/chip3
$AssetsImagesChip3Gen get chip3 => const $AssetsImagesChip3Gen();
/// Directory path: assets/images/chip4
$AssetsImagesChip4Gen get chip4 => const $AssetsImagesChip4Gen();
/// Directory path: assets/images/icons
$AssetsImagesIconsGen get icons => const $AssetsImagesIconsGen();
/// File path: assets/images/logo.png
AssetGenImage get logo => const AssetGenImage('assets/images/logo.png');
/// File path: assets/images/profile.jpg
AssetGenImage get profileJpg =>
const AssetGenImage('assets/images/profile.jpg');
/// File path: assets/images/profile.png
AssetGenImage get profilePng =>
const AssetGenImage('assets/images/profile.png');
/// List of all assets
List<AssetGenImage> get values =>
[chip1, chip2, logo, profileJpg, profilePng];
}
class $AssetsJsonGen {
const $AssetsJsonGen();
/// File path: assets/json/list.json
String get list => 'assets/json/list.json';
/// File path: assets/json/map.json
String get map => 'assets/json/map.json';
/// List of all assets
List<String> get values => [list, map];
}
class $AssetsLottieGen {
const $AssetsLottieGen();
/// File path: assets/lottie/XuiIZ9X1Rf.lottie
LottieGenImage get xuiIZ9X1Rf =>
const LottieGenImage('assets/lottie/XuiIZ9X1Rf.lottie');
/// File path: assets/lottie/alarm-clock-lottie-v440.json
LottieGenImage get alarmClockLottieV440 =>
const LottieGenImage('assets/lottie/alarm-clock-lottie-v440.json');
/// File path: assets/lottie/cat.tgs
LottieGenImage get cat => const LottieGenImage('assets/lottie/cat.tgs');
/// File path: assets/lottie/geometrical-animation.json
LottieGenImage get geometricalAnimation =>
const LottieGenImage('assets/lottie/geometrical-animation.json');
/// File path: assets/lottie/hamburger_arrow.json
LottieGenImage get hamburgerArrow =>
const LottieGenImage('assets/lottie/hamburger_arrow.json');
/// File path: assets/lottie/spinning_carrousel.zip
LottieGenImage get spinningCarrousel =>
const LottieGenImage('assets/lottie/spinning_carrousel.zip');
/// Directory path: assets/lottie/wrong
$AssetsLottieWrongGen get wrong => const $AssetsLottieWrongGen();
/// List of all assets
List<LottieGenImage> get values => [
xuiIZ9X1Rf,
alarmClockLottieV440,
cat,
geometricalAnimation,
hamburgerArrow,
spinningCarrousel
];
}
class $AssetsMixGen {
const $AssetsMixGen();
/// File path: assets/mix/aaa.jpg
AssetGenImage get aaa => const AssetGenImage('assets/mix/aaa.jpg');
/// File path: assets/mix/unknown_mime_type.bk
String get unknownMimeType => 'assets/mix/unknown_mime_type.bk';
/// List of all assets
List<dynamic> get values => [aaa, unknownMimeType];
}
class $AssetsMovieGen {
const $AssetsMovieGen();
/// File path: assets/movie/the_earth.mp4
String get theEarth => 'assets/movie/the_earth.mp4';
/// List of all assets
List<String> get values => [theEarth];
}
class $AssetsRiveGen {
const $AssetsRiveGen();
/// File path: assets/rive/vehicles.riv
RiveGenImage get vehicles => const RiveGenImage('assets/rive/vehicles.riv');
/// List of all assets
List<RiveGenImage> get values => [vehicles];
}
class $AssetsUnknownGen {
const $AssetsUnknownGen();
/// File path: assets/unknown/CHANGELOG.md
String get changelog => 'assets/unknown/CHANGELOG.md';
/// File path: assets/unknown/README.md
String get readme => 'assets/unknown/README.md';
/// File path: assets/unknown/unknown_mime_type.bk
String get unknownMimeType => 'assets/unknown/unknown_mime_type.bk';
/// List of all assets
List<String> get values => [changelog, readme, unknownMimeType];
}
class $AssetsImagesChip3Gen {
const $AssetsImagesChip3Gen();
/// File path: assets/images/chip3/chip3.jpg
AssetGenImage get chip3 =>
const AssetGenImage('assets/images/chip3/chip3.jpg');
/// List of all assets
List<AssetGenImage> get values => [chip3];
}
class $AssetsImagesChip4Gen {
const $AssetsImagesChip4Gen();
/// File path: assets/images/chip4/chip4.jpg
AssetGenImage get chip4 => const AssetGenImage(
'assets/images/chip4/chip4.jpg',
flavors: {'extern'},
);
/// List of all assets
List<AssetGenImage> get values => [chip4];
}
class $AssetsImagesIconsGen {
const $AssetsImagesIconsGen();
/// File path: assets/images/icons/[email protected]
SvgGenImage get dartTest =>
const SvgGenImage('assets/images/icons/[email protected]');
/// File path: assets/images/icons/fuchsia.svg
SvgGenImage get fuchsia =>
const SvgGenImage('assets/images/icons/fuchsia.svg');
/// File path: assets/images/icons/kmm.svg
SvgGenImage get kmm => const SvgGenImage('assets/images/icons/kmm.svg');
/// File path: assets/images/icons/paint.svg
SvgGenImage get paint => const SvgGenImage('assets/images/icons/paint.svg');
/// List of all assets
List<SvgGenImage> get values => [dartTest, fuchsia, kmm, paint];
}
class $AssetsLottieWrongGen {
const $AssetsLottieWrongGen();
/// File path: assets/lottie/wrong/dummy.zip
String get dummy => 'assets/lottie/wrong/dummy.zip';
/// File path: assets/lottie/wrong/rocket-lottie-v439.json
String get rocketLottieV439 => 'assets/lottie/wrong/rocket-lottie-v439.json';
/// List of all assets
List<String> get values => [dummy, rocketLottieV439];
}
class MyAssets {
const MyAssets._();
static const String readme = 'README.md';
static const $AssetsFlareGen flare = $AssetsFlareGen();
static const $AssetsImagesGen images = $AssetsImagesGen();
static const $AssetsJsonGen json = $AssetsJsonGen();
static const $AssetsLottieGen lottie = $AssetsLottieGen();
static const $AssetsMixGen mix = $AssetsMixGen();
static const $AssetsMovieGen movie = $AssetsMovieGen();
static const $AssetsRiveGen rive = $AssetsRiveGen();
static const $AssetsUnknownGen unknown = $AssetsUnknownGen();
/// List of all assets
static List<String> get values => [readme];
}
class AssetGenImage {
const AssetGenImage(
this._assetName, {
this.size,
this.flavors = const {},
});
final String _assetName;
final Size? size;
final Set<String> flavors;
Image image({
Key? key,
AssetBundle? bundle,
ImageFrameBuilder? frameBuilder,
ImageErrorWidgetBuilder? errorBuilder,
String? semanticLabel,
bool excludeFromSemantics = false,
double? scale,
double? width,
double? height,
Color? color,
Animation<double>? opacity,
BlendMode? colorBlendMode,
BoxFit? fit,
AlignmentGeometry alignment = Alignment.center,
ImageRepeat repeat = ImageRepeat.noRepeat,
Rect? centerSlice,
bool matchTextDirection = false,
bool gaplessPlayback = true,
bool isAntiAlias = false,
String? package,
FilterQuality filterQuality = FilterQuality.medium,
int? cacheWidth,
int? cacheHeight,
}) {
return Image.asset(
_assetName,
key: key,
bundle: bundle,
frameBuilder: frameBuilder,
errorBuilder: errorBuilder,
semanticLabel: semanticLabel,
excludeFromSemantics: excludeFromSemantics,
scale: scale,
width: width,
height: height,
color: color,
opacity: opacity,
colorBlendMode: colorBlendMode,
fit: fit,
alignment: alignment,
repeat: repeat,
centerSlice: centerSlice,
matchTextDirection: matchTextDirection,
gaplessPlayback: gaplessPlayback,
isAntiAlias: isAntiAlias,
package: package,
filterQuality: filterQuality,
cacheWidth: cacheWidth,
cacheHeight: cacheHeight,
);
}
ImageProvider provider({
AssetBundle? bundle,
String? package,
}) {
return AssetImage(
_assetName,
bundle: bundle,
package: package,
);
}
String get path => _assetName;
String get keyName => _assetName;
}
class SvgGenImage {
const SvgGenImage(
this._assetName, {
this.size,
this.flavors = const {},
}) : _isVecFormat = false;
const SvgGenImage.vec(
this._assetName, {
this.size,
this.flavors = const {},
}) : _isVecFormat = true;
final String _assetName;
final Size? size;
final Set<String> flavors;
final bool _isVecFormat;
_svg.SvgPicture svg({
Key? key,
bool matchTextDirection = false,
AssetBundle? bundle,
String? package,
double? width,
double? height,
BoxFit fit = BoxFit.contain,
AlignmentGeometry alignment = Alignment.center,
bool allowDrawingOutsideViewBox = false,
WidgetBuilder? placeholderBuilder,
String? semanticsLabel,
bool excludeFromSemantics = false,
_svg.SvgTheme? theme,
ColorFilter? colorFilter,
Clip clipBehavior = Clip.hardEdge,
@deprecated Color? color,
@deprecated BlendMode colorBlendMode = BlendMode.srcIn,
@deprecated bool cacheColorFilter = false,
}) {
final _svg.BytesLoader loader;
if (_isVecFormat) {
loader = _vg.AssetBytesLoader(
_assetName,
assetBundle: bundle,
packageName: package,
);
} else {
loader = _svg.SvgAssetLoader(
_assetName,
assetBundle: bundle,
packageName: package,
theme: theme,
);
}
return _svg.SvgPicture(
loader,
key: key,
matchTextDirection: matchTextDirection,
width: width,
height: height,
fit: fit,
alignment: alignment,
allowDrawingOutsideViewBox: allowDrawingOutsideViewBox,
placeholderBuilder: placeholderBuilder,
semanticsLabel: semanticsLabel,
excludeFromSemantics: excludeFromSemantics,
colorFilter: colorFilter ??
(color == null ? null : ColorFilter.mode(color, colorBlendMode)),
clipBehavior: clipBehavior,
cacheColorFilter: cacheColorFilter,
);
}
String get path => _assetName;
String get keyName => _assetName;
}
class RiveGenImage {
const RiveGenImage(
this._assetName, {
this.flavors = const {},
});
final String _assetName;
final Set<String> flavors;
_rive.RiveAnimation rive({
String? artboard,
List<String> animations = const [],
List<String> stateMachines = const [],
BoxFit? fit,
Alignment? alignment,
Widget? placeHolder,
bool antialiasing = true,
bool useArtboardSize = false,
List<_rive.RiveAnimationController> controllers = const [],
_rive.OnInitCallback? onInit,
}) {
return _rive.RiveAnimation.asset(
_assetName,
artboard: artboard,
animations: animations,
stateMachines: stateMachines,
fit: fit,
alignment: alignment,
placeHolder: placeHolder,
antialiasing: antialiasing,
useArtboardSize: useArtboardSize,
controllers: controllers,
onInit: onInit,
);
}
String get path => _assetName;
String get keyName => _assetName;
}
class LottieGenImage {
const LottieGenImage(
this._assetName, {
this.flavors = const {},
});
final String _assetName;
final Set<String> flavors;
_lottie.LottieBuilder lottie({
Animation<double>? controller,
bool? animate,
_lottie.FrameRate? frameRate,
bool? repeat,
bool? reverse,
_lottie.LottieDelegates? delegates,
_lottie.LottieOptions? options,
void Function(_lottie.LottieComposition)? onLoaded,
_lottie.LottieImageProviderFactory? imageProviderFactory,
Key? key,
AssetBundle? bundle,
Widget Function(
BuildContext,
Widget,
_lottie.LottieComposition?,
)? frameBuilder,
ImageErrorWidgetBuilder? errorBuilder,
double? width,
double? height,
BoxFit? fit,
AlignmentGeometry? alignment,
String? package,
bool? addRepaintBoundary,
FilterQuality? filterQuality,
void Function(String)? onWarning,
_lottie.LottieDecoder? decoder,
_lottie.RenderCache? renderCache,
bool? backgroundLoading,
}) {
return _lottie.Lottie.asset(
_assetName,
controller: controller,
animate: animate,
frameRate: frameRate,
repeat: repeat,
reverse: reverse,
delegates: delegates,
options: options,
onLoaded: onLoaded,
imageProviderFactory: imageProviderFactory,
key: key,
bundle: bundle,
frameBuilder: frameBuilder,
errorBuilder: errorBuilder,
width: width,
height: height,
fit: fit,
alignment: alignment,
package: package,
addRepaintBoundary: addRepaintBoundary,
filterQuality: filterQuality,
onWarning: onWarning,
decoder: decoder,
renderCache: renderCache,
backgroundLoading: backgroundLoading,
);
}
String get path => _assetName;
String get keyName => _assetName;
}