copyWith method

PageState copyWith({
  1. int? loop,
  2. bool? isVertical,
  3. bool? isPage,
  4. Nodes? nodes,
  5. List<int>? xLines,
  6. List<int>? yLines,
  7. ComponentFit? fit,
  8. NodeID? nodeComponentID,
  9. bool? isDeviceCurrentlyFocused,
  10. bool? isDeviceCurrentlyHovered,
  11. Map<ID, CubitEntity>? cubits,
  12. Map<ID, ControllerVariable>? controllers,
  13. Map<ID, Parameter>? parameters,
  14. Map<ID, ComponentParameterField>? passedParameterFromTopComponent,
  15. SupabaseClient createCMSClient()?,
  16. SupabaseClient createSupabaseClient()?,
  17. SupabaseClient? cmsClient,
  18. SupabaseClient? supabaseClient,
})

Implementation

PageState copyWith({
  final int? loop,
  final bool? isVertical,
  final bool? isPage,
  final Nodes? nodes,
  final List<int>? xLines,
  final List<int>? yLines,
  final ComponentFit? fit,
  final NodeID? nodeComponentID,
  final bool? isDeviceCurrentlyFocused,
  final bool? isDeviceCurrentlyHovered,
  final Map<ID, CubitEntity>? cubits,
  final Map<ID, ControllerVariable>? controllers,
  final Map<ID, Parameter>? parameters,
  final Map<ID, ComponentParameterField>? passedParameterFromTopComponent,
  final SupabaseClient Function()? createCMSClient,
  final SupabaseClient Function()? createSupabaseClient,
  final SupabaseClient? cmsClient,
  final SupabaseClient? supabaseClient,
}) {
  return PageState(
    isPage: isPage ?? this.isPage,
    nodes: nodes ?? this.nodes,
    fit: fit ?? this.fit,
    nodeComponentID: nodeComponentID ?? this.nodeComponentID,
    isDeviceCurrentlyFocused:
        isDeviceCurrentlyFocused ?? this.isDeviceCurrentlyFocused,
    isDeviceCurrentlyHovered:
        isDeviceCurrentlyHovered ?? this.isDeviceCurrentlyHovered,
    cubits: cubits ?? this.cubits,
    controllers: controllers ?? this.controllers,
    parameters: parameters ?? this.parameters,
    passedParameterFromTopComponent: passedParameterFromTopComponent ??
        this.passedParameterFromTopComponent,
    createCMSClient: createCMSClient ?? this.createCMSClient,
    createSupabaseClient: createSupabaseClient ?? this.createSupabaseClient,
    internalCmsClient: cmsClient ?? _getCmsClient,
    internalSupabaseClient: supabaseClient ?? _getSupabaseClient,
  );
}