Compare commits
3 Commits
576a01512b
...
ff3f2008de
Author | SHA1 | Date | |
---|---|---|---|
ff3f2008de | |||
0b27a62669 | |||
6c9b6e239b |
@ -18,11 +18,11 @@ import 'package:flutter/material.dart';
|
||||
import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart';
|
||||
import 'package:wyatt_ui_components/wyatt_wyatt_ui_components.dart';
|
||||
|
||||
// part 'custom_app_bar_example.g.dart';
|
||||
part 'custom_app_bar_example.g.dart';
|
||||
|
||||
@ComponentCopyWithExtension()
|
||||
class CustomAppBarExample extends AppBarComponent
|
||||
with $CustomAppBarExampleCWProxyImpl {
|
||||
with $CustomAppBarExampleCWMixin {
|
||||
const CustomAppBarExample({super.title, super.key});
|
||||
|
||||
@override
|
||||
|
@ -17,7 +17,6 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:analyzer/dart/element/element.dart';
|
||||
import 'package:analyzer/dart/element/nullability_suffix.dart';
|
||||
import 'package:build/build.dart';
|
||||
import 'package:source_gen/source_gen.dart';
|
||||
import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart';
|
||||
@ -61,11 +60,9 @@ class ComponentProxyGenerator
|
||||
generatedCode.write('${element.displayName} call({');
|
||||
|
||||
for (final field in element.constructors.first.parameters) {
|
||||
if (field.type.nullabilitySuffix == NullabilitySuffix.question) {
|
||||
generatedCode.write('${field.type.getDisplayString(
|
||||
withNullability: false,
|
||||
)}? ${field.displayName}, ');
|
||||
}
|
||||
generatedCode.write('${field.type.getDisplayString(
|
||||
withNullability: false,
|
||||
)}? ${field.displayName}, ');
|
||||
}
|
||||
|
||||
generatedCode.write('});}');
|
||||
|
@ -12,10 +12,10 @@ dependencies:
|
||||
source_gen: ^1.2.7
|
||||
analyzer: ^5.4.0
|
||||
|
||||
wyatt_component_copy_with_extension:
|
||||
git:
|
||||
url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git
|
||||
path: packages/wyatt_component_copy_with_extension
|
||||
wyatt_component_copy_with_extension:
|
||||
git:
|
||||
url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git
|
||||
path: packages/wyatt_component_copy_with_extension
|
||||
|
||||
dev_dependencies:
|
||||
test: ^1.21.0
|
||||
|
@ -12,6 +12,7 @@ abstract class $BottomNavigationBarComponentCWProxy {
|
||||
BottomNavigationBarComponent key(Key? key);
|
||||
BottomNavigationBarComponent call({
|
||||
void Function(BuildContext, int)? onTap,
|
||||
int? currentIndex,
|
||||
Key? key,
|
||||
});
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user