copyWith method
Creates a copy of this NavigationTheme with specified properties replaced.
This method facilitates theme updates without full recreation, supporting reactive UIs in ArcaneTheme. It preserves performance by avoiding unnecessary widget rebuilds during navigation state changes.
Implementation
NavigationTheme copyWith({
NavigationType? type,
double? sidebarSpacing,
double? railRightPadding,
double? railTopPadding,
bool? endSide,
bool? drawerTransformsBackdrop,
}) =>
NavigationTheme(
type: type ?? this.type,
sidebarSpacing: sidebarSpacing ?? this.sidebarSpacing,
railRightPadding: railRightPadding ?? this.railRightPadding,
railTopPadding: railTopPadding ?? this.railTopPadding,
endSide: endSide ?? this.endSide,
drawerTransformsBackdrop:
drawerTransformsBackdrop ?? this.drawerTransformsBackdrop,
);