master #81
@ -9,6 +9,6 @@ class CustomAppBar extends AppBarComponent with $CustomAppBarCWMixin {
 | 
				
			|||||||
  const CustomAppBar({super.title});
 | 
					  const CustomAppBar({super.title});
 | 
				
			||||||
  @override
 | 
					  @override
 | 
				
			||||||
  Widget build(BuildContext context) => AppBar(
 | 
					  Widget build(BuildContext context) => AppBar(
 | 
				
			||||||
        title: Text(title ?? 'Title'),
 | 
					        title: Text(title?.text ?? 'Title'),
 | 
				
			||||||
      );
 | 
					      );
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
@ -10,7 +10,7 @@ class $CustomAppBarCWProxyImpl implements $AppBarComponentCWProxy {
 | 
				
			|||||||
  const $CustomAppBarCWProxyImpl(this._value);
 | 
					  const $CustomAppBarCWProxyImpl(this._value);
 | 
				
			||||||
  final CustomAppBar _value;
 | 
					  final CustomAppBar _value;
 | 
				
			||||||
  @override
 | 
					  @override
 | 
				
			||||||
  CustomAppBar title(String? title) => this(title: title);
 | 
					  CustomAppBar title(TextWrapper? title) => this(title: title);
 | 
				
			||||||
  @override
 | 
					  @override
 | 
				
			||||||
  CustomAppBar leading(Widget? leading) => this(leading: leading);
 | 
					  CustomAppBar leading(Widget? leading) => this(leading: leading);
 | 
				
			||||||
  @override
 | 
					  @override
 | 
				
			||||||
@ -19,7 +19,7 @@ class $CustomAppBarCWProxyImpl implements $AppBarComponentCWProxy {
 | 
				
			|||||||
  CustomAppBar key(Key? key) => this(key: key);
 | 
					  CustomAppBar key(Key? key) => this(key: key);
 | 
				
			||||||
  @override
 | 
					  @override
 | 
				
			||||||
  CustomAppBar call({
 | 
					  CustomAppBar call({
 | 
				
			||||||
    String? title,
 | 
					    TextWrapper? title,
 | 
				
			||||||
    Widget? leading,
 | 
					    Widget? leading,
 | 
				
			||||||
    List<Widget>? actions,
 | 
					    List<Widget>? actions,
 | 
				
			||||||
    Key? key,
 | 
					    Key? key,
 | 
				
			||||||
 | 
				
			|||||||
@ -12,6 +12,6 @@ class CustomErrorWidget extends ErrorWidgetComponent
 | 
				
			|||||||
  @override
 | 
					  @override
 | 
				
			||||||
  Widget build(BuildContext context) => ColoredBox(
 | 
					  Widget build(BuildContext context) => ColoredBox(
 | 
				
			||||||
        color: Colors.red,
 | 
					        color: Colors.red,
 | 
				
			||||||
        child: Center(child: Text(error ?? 'Error')),
 | 
					        child: Center(child: Text(error?.text ?? 'Error')),
 | 
				
			||||||
      );
 | 
					      );
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
@ -10,12 +10,12 @@ class $CustomErrorWidgetCWProxyImpl implements $ErrorWidgetComponentCWProxy {
 | 
				
			|||||||
  const $CustomErrorWidgetCWProxyImpl(this._value);
 | 
					  const $CustomErrorWidgetCWProxyImpl(this._value);
 | 
				
			||||||
  final CustomErrorWidget _value;
 | 
					  final CustomErrorWidget _value;
 | 
				
			||||||
  @override
 | 
					  @override
 | 
				
			||||||
  CustomErrorWidget error(String? error) => this(error: error);
 | 
					  CustomErrorWidget error(TextWrapper? error) => this(error: error);
 | 
				
			||||||
  @override
 | 
					  @override
 | 
				
			||||||
  CustomErrorWidget key(Key? key) => this(key: key);
 | 
					  CustomErrorWidget key(Key? key) => this(key: key);
 | 
				
			||||||
  @override
 | 
					  @override
 | 
				
			||||||
  CustomErrorWidget call({
 | 
					  CustomErrorWidget call({
 | 
				
			||||||
    String? error,
 | 
					    TextWrapper? error,
 | 
				
			||||||
    Key? key,
 | 
					    Key? key,
 | 
				
			||||||
  }) =>
 | 
					  }) =>
 | 
				
			||||||
      CustomErrorWidget(
 | 
					      CustomErrorWidget(
 | 
				
			||||||
 | 
				
			|||||||
@ -23,7 +23,7 @@ import 'package:wyatt_ui_components/wyatt_wyatt_ui_components.dart';
 | 
				
			|||||||
mixin CrudMixin<Cubit extends bloc_base.Cubit,
 | 
					mixin CrudMixin<Cubit extends bloc_base.Cubit,
 | 
				
			||||||
    SuccessState extends CrudSuccess> {
 | 
					    SuccessState extends CrudSuccess> {
 | 
				
			||||||
  Widget errorBuilder(BuildContext context, CrudError state) =>
 | 
					  Widget errorBuilder(BuildContext context, CrudError state) =>
 | 
				
			||||||
      context.components.errorWidget?.copyWith(error: state.message) ??
 | 
					      context.components.errorWidget?.copyWith(error: state.message.wrap()) ??
 | 
				
			||||||
      const SizedBox.shrink();
 | 
					      const SizedBox.shrink();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  Widget loadingBuilder(BuildContext context, CrudLoading state) =>
 | 
					  Widget loadingBuilder(BuildContext context, CrudLoading state) =>
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user