copyWith method
Hero
copyWith({
- String? id,
- String? classes,
- Styles? css,
- Map<
String, String> ? attributes, - Map<
String, List< ? eventHandlers,UiEventHandler> > - Key? key,
override
An abstract method that concrete components must implement to create a copy of themselves with new values.
Implementation
@override
Hero copyWith({
String? id,
String? classes,
Styles? css,
Map<String, String>? attributes,
Map<String, List<UiEventHandler>>? eventHandlers,
Key? key,
}) {
return Hero(
children,
tag: tag,
style: style as List<HeroStyling>?,
id: id ?? this.id,
classes: mergeClasses(this.classes, classes),
css: css ?? this.css,
attributes: attributes ?? userProvidedAttributes,
eventHandlers: eventHandlers ?? this.eventHandlers,
key: key ?? this.key,
);
}