Compare commits
No commits in common. "ff3f2008de902f0f52ff0ec4e7671fe2d45ebed3" and "576a01512b39bf3c52d48751c571c46abab2cd9d" have entirely different histories.
ff3f2008de
...
576a01512b
@ -18,11 +18,11 @@ import 'package:flutter/material.dart';
|
|||||||
import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart';
|
import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart';
|
||||||
import 'package:wyatt_ui_components/wyatt_wyatt_ui_components.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()
|
@ComponentCopyWithExtension()
|
||||||
class CustomAppBarExample extends AppBarComponent
|
class CustomAppBarExample extends AppBarComponent
|
||||||
with $CustomAppBarExampleCWMixin {
|
with $CustomAppBarExampleCWProxyImpl {
|
||||||
const CustomAppBarExample({super.title, super.key});
|
const CustomAppBarExample({super.title, super.key});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
|
@ -17,6 +17,7 @@
|
|||||||
import 'dart:async';
|
import 'dart:async';
|
||||||
|
|
||||||
import 'package:analyzer/dart/element/element.dart';
|
import 'package:analyzer/dart/element/element.dart';
|
||||||
|
import 'package:analyzer/dart/element/nullability_suffix.dart';
|
||||||
import 'package:build/build.dart';
|
import 'package:build/build.dart';
|
||||||
import 'package:source_gen/source_gen.dart';
|
import 'package:source_gen/source_gen.dart';
|
||||||
import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart';
|
import 'package:wyatt_component_copy_with_extension/component_copy_with_extension.dart';
|
||||||
@ -60,10 +61,12 @@ class ComponentProxyGenerator
|
|||||||
generatedCode.write('${element.displayName} call({');
|
generatedCode.write('${element.displayName} call({');
|
||||||
|
|
||||||
for (final field in element.constructors.first.parameters) {
|
for (final field in element.constructors.first.parameters) {
|
||||||
|
if (field.type.nullabilitySuffix == NullabilitySuffix.question) {
|
||||||
generatedCode.write('${field.type.getDisplayString(
|
generatedCode.write('${field.type.getDisplayString(
|
||||||
withNullability: false,
|
withNullability: false,
|
||||||
)}? ${field.displayName}, ');
|
)}? ${field.displayName}, ');
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
generatedCode.write('});}');
|
generatedCode.write('});}');
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ dependencies:
|
|||||||
source_gen: ^1.2.7
|
source_gen: ^1.2.7
|
||||||
analyzer: ^5.4.0
|
analyzer: ^5.4.0
|
||||||
|
|
||||||
wyatt_component_copy_with_extension:
|
wyatt_component_copy_with_extension:
|
||||||
git:
|
git:
|
||||||
url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git
|
url: ssh://git@git.wyatt-studio.fr:993/Wyatt-FOSS/wyatt-packages.git
|
||||||
path: packages/wyatt_component_copy_with_extension
|
path: packages/wyatt_component_copy_with_extension
|
||||||
|
@ -12,7 +12,6 @@ abstract class $BottomNavigationBarComponentCWProxy {
|
|||||||
BottomNavigationBarComponent key(Key? key);
|
BottomNavigationBarComponent key(Key? key);
|
||||||
BottomNavigationBarComponent call({
|
BottomNavigationBarComponent call({
|
||||||
void Function(BuildContext, int)? onTap,
|
void Function(BuildContext, int)? onTap,
|
||||||
int? currentIndex,
|
|
||||||
Key? key,
|
Key? key,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user