diff --git a/.editorconfig b/.editorconfig index 80a3e35b..206f5ceb 100644 --- a/.editorconfig +++ b/.editorconfig @@ -14,3 +14,6 @@ max_line_length = 150 [*.md] trim_trailing_whitespace = false + +[*.json] +indent_size = 4 diff --git a/analysis_options.yaml b/analysis_options.yaml index 72343f80..ff0f9356 100644 --- a/analysis_options.yaml +++ b/analysis_options.yaml @@ -29,16 +29,16 @@ linter: # producing the lint. rules: avoid_print: false # Uncomment to disable the `avoid_print` rule - prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule - always_use_package_imports: true - no_adjacent_strings_in_list: true - unnecessary_statements: true always_declare_return_types: true - always_put_required_named_parameters_first: true always_put_control_body_on_new_line: true + always_put_required_named_parameters_first: true + always_use_package_imports: true avoid_escaping_inner_quotes: true avoid_setters_without_getters: true + collection_methods_unrelated_type: true + combinators_ordering: true eol_at_end_of_file: true + no_adjacent_strings_in_list: true prefer_constructors_over_static_methods: true prefer_expression_function_bodies: true prefer_final_in_for_each: true @@ -48,12 +48,18 @@ linter: prefer_if_elements_to_conditional_expressions: true prefer_mixin: true prefer_null_aware_method_calls: true + prefer_single_quotes: true require_trailing_commas: true sized_box_shrink_expand: true sort_constructors_first: true + unawaited_futures: true unnecessary_await_in_return: true + unnecessary_null_aware_operator_on_extension_on_nullable: true unnecessary_null_checks: true unnecessary_parenthesis: true + unnecessary_statements: true + unnecessary_to_list_in_spreads: true + unreachable_from_main: true use_enums: true use_if_null_to_convert_nulls_to_bools: true use_is_even_rather_than_modulo: true @@ -61,6 +67,7 @@ linter: use_named_constants: true use_setters_to_change_properties: true use_string_buffers: true + use_string_in_part_of_directives: true use_super_parameters: true use_to_and_as_if_applicable: true diff --git a/assets/translations/en.json b/assets/translations/en.json index c849e266..0d825bff 100644 --- a/assets/translations/en.json +++ b/assets/translations/en.json @@ -2,6 +2,7 @@ "test": "en-test", "locale": "en", "basis": { + "app_name": "SelfPrivacy", "providers": "Providers", "providers_title": "Your Data Center", "select": "Select", @@ -46,7 +47,8 @@ }, "console_page": { "title": "Console", - "waiting": "Waiting for initialization…" + "waiting": "Waiting for initialization…", + "copy": "Copy" }, "about_us_page": { "title": "About us" @@ -59,8 +61,11 @@ }, "application_settings": { "title": "Application settings", + "system_dark_theme_title": "System default theme", + "system_dark_theme_description": "Use light or dark theme depending on system settings", "dark_theme_title": "Dark theme", "dark_theme_description": "Switch your application theme", + "dangerous_settings": "Dangerous settings", "reset_config_title": "Reset application config", "reset_config_description": "Reset api keys and root user", "delete_server_title": "Delete server", @@ -251,6 +256,7 @@ "subtitle": "Private VPN server" }, "users": { + "details_title": "User details", "add_new_user": "Add a first user", "new_user": "New user", "delete_user": "Delete user", @@ -329,7 +335,20 @@ "create_master_account": "Create master account", "enter_username_and_password": "Enter username and strong password", "finish": "Everything is initialized", - "checks": "Checks have been completed \n{} out of {}" + "checks": "Checks have been completed \n{} out of {}", + "steps": { + "hosting": "Hosting", + "server_type": "Server type", + "dns_provider": "DNS provider", + "backups_provider": "Backups", + "domain": "Domain", + "master_account": "Master account", + "server": "Server", + "dns_setup": "DNS setup", + "nixos_installation": "NixOS installation", + "server_reboot": "Server reboot", + "final_checks": "Final checks" + } }, "recovering": { "generic_error": "Operation failed, please try again.", @@ -472,5 +491,19 @@ "root_name": "Cannot be 'root'", "length_not_equal": "Length is [], should be {}", "length_longer": "Length is [], should be shorter than or equal to {}" + }, + "support": { + "title": "SelfPrivacy Support" + }, + "developer_settings": { + "title": "Developer settings", + "subtitle": "These settings are for debugging only. Don't change them unless you know what you're doing.", + "server_setup": "Server setup", + "use_staging_acme": "Use staging ACME server", + "use_staging_acme_description": "Rebuild your app to change this value.", + "routing": "App routing", + "reset_onboarding": "Reset onboarding switch", + "reset_onboarding_description": "Reset onboarding switch to show onboarding screen again", + "cubit_statuses": "Cubit loading statuses" } } diff --git a/lib/config/bloc_config.dart b/lib/config/bloc_config.dart index 6c870f9e..381261fe 100644 --- a/lib/config/bloc_config.dart +++ b/lib/config/bloc_config.dart @@ -12,6 +12,7 @@ import 'package:selfprivacy/logic/cubit/providers/providers_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_jobs/server_jobs_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_volumes/server_volume_cubit.dart'; import 'package:selfprivacy/logic/cubit/services/services_cubit.dart'; +import 'package:selfprivacy/logic/cubit/support_system/support_system_cubit.dart'; import 'package:selfprivacy/logic/cubit/users/users_cubit.dart'; import 'package:selfprivacy/logic/cubit/provider_volumes/provider_volume_cubit.dart'; @@ -23,7 +24,9 @@ class BlocAndProviderConfig extends StatelessWidget { @override Widget build(final BuildContext context) { const isDark = false; + const isAutoDark = true; final serverInstallationCubit = ServerInstallationCubit()..load(); + final supportSystemCubit = SupportSystemCubit(); final usersCubit = UsersCubit(serverInstallationCubit); final servicesCubit = ServicesCubit(serverInstallationCubit); final backupsCubit = BackupsCubit(serverInstallationCubit); @@ -41,9 +44,13 @@ class BlocAndProviderConfig extends StatelessWidget { BlocProvider( create: (final _) => AppSettingsCubit( isDarkModeOn: isDark, + isAutoDarkModeOn: isAutoDark, isOnboardingShowing: true, )..load(), ), + BlocProvider( + create: (final _) => supportSystemCubit, + ), BlocProvider( create: (final _) => serverInstallationCubit, lazy: false, diff --git a/lib/config/brand_colors.dart b/lib/config/brand_colors.dart index 15d1433a..335e652e 100644 --- a/lib/config/brand_colors.dart +++ b/lib/config/brand_colors.dart @@ -2,53 +2,16 @@ import 'package:flutter/material.dart'; class BrandColors { static const Color blue = Color(0xFF093CEF); - static const Color white = Colors.white; - static const Color black = Colors.black; - - static const Color gray1 = Color(0xFF555555); - static const Color gray2 = Color(0xFF7C7C7C); - static const Color gray3 = Color(0xFFFAFAFA); - static const Color gray4 = Color(0xFFDDDDDD); - static const Color gray5 = Color(0xFFEDEEF1); - static Color gray6 = const Color(0xFF181818).withOpacity(0.7); - static const Color grey7 = Color(0xFFABABAB); - - static const Color red1 = Color(0xFFFA0E0E); - static const Color red2 = Color(0xFFE65527); - - static const Color green1 = Color(0xFF00AF54); - - static const Color green2 = Color(0xFF0F8849); - - static Color get navBackgroundLight => white.withOpacity(0.8); - static Color get navBackgroundDark => black.withOpacity(0.8); static const List uninitializedGradientColors = [ Color(0xFF555555), Color(0xFFABABAB), ]; - static const List stableGradientColors = [ - Color(0xFF093CEF), - Color(0xFF14A1CB), - ]; - static const List progressGradientColors = [ - Color(0xFF093CEF), - Color(0xFF14A1CB), - ]; static const List warningGradientColors = [ Color(0xFFEF4E09), Color(0xFFEFD135), ]; static const Color primary = blue; - static const Color headlineColor = black; - static const Color inactive = gray2; - static const Color scaffoldBackground = gray3; - static const Color inputInactive = gray4; - - static const Color textColor1 = black; - static const Color textColor2 = gray1; - static const Color dividerColor = gray5; - static const Color warning = red1; } diff --git a/lib/config/hive_config.dart b/lib/config/hive_config.dart index 93bce6ee..b6ba018c 100644 --- a/lib/config/hive_config.dart +++ b/lib/config/hive_config.dart @@ -63,6 +63,9 @@ class BNames { /// A boolean field of [appSettingsBox] box. static String isDarkModeOn = 'isDarkModeOn'; + /// A boolean field of [appSettingsBox] box. + static String isAutoDarkModeOn = 'isAutoDarkModeOn'; + /// A boolean field of [appSettingsBox] box. static String isOnboardingShowing = 'isOnboardingShowing'; diff --git a/lib/config/text_themes.dart b/lib/config/text_themes.dart deleted file mode 100644 index 63b4b99c..00000000 --- a/lib/config/text_themes.dart +++ /dev/null @@ -1,80 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:selfprivacy/utils/named_font_weight.dart'; - -import 'package:selfprivacy/config/brand_colors.dart'; - -const TextStyle defaultTextStyle = TextStyle( - fontSize: 15, - color: BrandColors.textColor1, -); - -final TextStyle headline1Style = defaultTextStyle.copyWith( - fontSize: 40, - fontWeight: NamedFontWeight.extraBold, - color: BrandColors.headlineColor, -); - -final TextStyle headline2Style = defaultTextStyle.copyWith( - fontSize: 24, - fontWeight: NamedFontWeight.extraBold, - color: BrandColors.headlineColor, -); - -final TextStyle onboardingTitle = defaultTextStyle.copyWith( - fontSize: 30, - fontWeight: NamedFontWeight.extraBold, - color: BrandColors.headlineColor, -); - -final TextStyle headline3Style = defaultTextStyle.copyWith( - fontSize: 20, - fontWeight: NamedFontWeight.extraBold, - color: BrandColors.headlineColor, -); - -final TextStyle headline4Style = defaultTextStyle.copyWith( - fontSize: 18, - fontWeight: NamedFontWeight.medium, - color: BrandColors.headlineColor, -); - -final TextStyle headline4UnderlinedStyle = defaultTextStyle.copyWith( - fontSize: 18, - fontWeight: NamedFontWeight.medium, - color: BrandColors.headlineColor, - decoration: TextDecoration.underline, -); - -final TextStyle headline5Style = defaultTextStyle.copyWith( - fontSize: 15, - fontWeight: NamedFontWeight.medium, - color: BrandColors.headlineColor.withOpacity(0.8), -); - -const TextStyle body1Style = defaultTextStyle; -final TextStyle body2Style = defaultTextStyle.copyWith( - color: BrandColors.textColor2, -); - -final TextStyle buttonTitleText = defaultTextStyle.copyWith( - color: BrandColors.white, - fontSize: 16, - fontWeight: FontWeight.bold, - height: 1, -); - -final TextStyle mediumStyle = - defaultTextStyle.copyWith(fontSize: 13, height: 1.53); - -final TextStyle smallStyle = - defaultTextStyle.copyWith(fontSize: 11, height: 1.45); - -const TextStyle progressTextStyleLight = TextStyle( - fontSize: 11, - color: BrandColors.textColor1, - height: 1.7, -); - -final TextStyle progressTextStyleDark = progressTextStyleLight.copyWith( - color: BrandColors.white, -); diff --git a/lib/logic/api_maps/graphql_maps/api_map.dart b/lib/logic/api_maps/graphql_maps/api_map.dart index 02b9bc04..a633866e 100644 --- a/lib/logic/api_maps/graphql_maps/api_map.dart +++ b/lib/logic/api_maps/graphql_maps/api_map.dart @@ -20,7 +20,13 @@ class RequestLoggingLink extends Link { final Request request, [ final NextLink? forward, ]) async* { - _logToAppConsole(request); + getIt.get().addMessage( + GraphQlRequestMessage( + operation: request.operation, + variables: request.variables, + context: request.context, + ), + ); yield* forward!(request); } } @@ -29,7 +35,13 @@ class ResponseLoggingParser extends ResponseParser { @override Response parseResponse(final Map body) { final response = super.parseResponse(body); - _logToAppConsole(response); + getIt.get().addMessage( + GraphQlResponseMessage( + data: response.data, + errors: response.errors, + context: response.context, + ), + ); return response; } diff --git a/lib/logic/api_maps/graphql_maps/schema/disk_volumes.graphql.dart b/lib/logic/api_maps/graphql_maps/schema/disk_volumes.graphql.dart index 359a7a27..22409ef9 100644 --- a/lib/logic/api_maps/graphql_maps/schema/disk_volumes.graphql.dart +++ b/lib/logic/api_maps/graphql_maps/schema/disk_volumes.graphql.dart @@ -1,24 +1,69 @@ import 'dart:async'; import 'package:gql/ast.dart'; import 'package:graphql/client.dart' as graphql; -import 'package:json_annotation/json_annotation.dart'; import 'package:selfprivacy/utils/scalars.dart'; import 'schema.graphql.dart'; -import 'server_api.graphql.dart'; -part 'disk_volumes.graphql.g.dart'; -@JsonSerializable(explicitToJson: true) class Fragment$basicMutationReturnFields { - Fragment$basicMutationReturnFields( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + Fragment$basicMutationReturnFields({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Fragment$basicMutationReturnFields.fromJson( - Map json) => - _$Fragment$basicMutationReturnFieldsFromJson(json); + Map json) { + switch (json["__typename"] as String) { + case "ApiKeyMutationReturn": + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + .fromJson(json); + + case "AutoUpgradeSettingsMutationReturn": + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + .fromJson(json); + + case "DeviceApiTokenMutationReturn": + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + .fromJson(json); + + case "GenericJobButationReturn": + return Fragment$basicMutationReturnFields$$GenericJobButationReturn + .fromJson(json); + + case "GenericMutationReturn": + return Fragment$basicMutationReturnFields$$GenericMutationReturn + .fromJson(json); + + case "ServiceJobMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + .fromJson(json); + + case "ServiceMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceMutationReturn + .fromJson(json); + + case "TimezoneMutationReturn": + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn + .fromJson(json); + + case "UserMutationReturn": + return Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + json); + + default: + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + } final int code; @@ -26,36 +71,64 @@ class Fragment$basicMutationReturnFields { final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Fragment$basicMutationReturnFieldsToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Fragment$basicMutationReturnFields) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -64,25 +137,35 @@ extension UtilityExtension$Fragment$basicMutationReturnFields on Fragment$basicMutationReturnFields { CopyWith$Fragment$basicMutationReturnFields< Fragment$basicMutationReturnFields> - get copyWith => - CopyWith$Fragment$basicMutationReturnFields(this, (i) => i); + get copyWith => CopyWith$Fragment$basicMutationReturnFields( + this, + (i) => i, + ); } abstract class CopyWith$Fragment$basicMutationReturnFields { factory CopyWith$Fragment$basicMutationReturnFields( - Fragment$basicMutationReturnFields instance, - TRes Function(Fragment$basicMutationReturnFields) then) = - _CopyWithImpl$Fragment$basicMutationReturnFields; + Fragment$basicMutationReturnFields instance, + TRes Function(Fragment$basicMutationReturnFields) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields; factory CopyWith$Fragment$basicMutationReturnFields.stub(TRes res) = _CopyWithStubImpl$Fragment$basicMutationReturnFields; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Fragment$basicMutationReturnFields implements CopyWith$Fragment$basicMutationReturnFields { - _CopyWithImpl$Fragment$basicMutationReturnFields(this._instance, this._then); + _CopyWithImpl$Fragment$basicMutationReturnFields( + this._instance, + this._then, + ); final Fragment$basicMutationReturnFields _instance; @@ -90,24 +173,25 @@ class _CopyWithImpl$Fragment$basicMutationReturnFields static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Fragment$basicMutationReturnFields( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Fragment$basicMutationReturnFields @@ -116,43 +200,54 @@ class _CopyWithStubImpl$Fragment$basicMutationReturnFields TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } const fragmentDefinitionbasicMutationReturnFields = FragmentDefinitionNode( - name: NameNode(value: 'basicMutationReturnFields'), - typeCondition: TypeConditionNode( - on: NamedTypeNode( - name: NameNode(value: 'MutationReturnInterface'), - isNonNull: false)), - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'code'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'message'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'success'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])); + name: NameNode(value: 'basicMutationReturnFields'), + typeCondition: TypeConditionNode( + on: NamedTypeNode( + name: NameNode(value: 'MutationReturnInterface'), + isNonNull: false, + )), + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'code'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'message'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'success'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), +); const documentNodeFragmentbasicMutationReturnFields = DocumentNode(definitions: [ fragmentDefinitionbasicMutationReturnFields, @@ -160,65 +255,1719 @@ const documentNodeFragmentbasicMutationReturnFields = extension ClientExtension$Fragment$basicMutationReturnFields on graphql.GraphQLClient { - void writeFragment$basicMutationReturnFields( - {required Fragment$basicMutationReturnFields data, - required Map idFields, - bool broadcast = true}) => + void writeFragment$basicMutationReturnFields({ + required Fragment$basicMutationReturnFields data, + required Map idFields, + bool broadcast = true, + }) => this.writeFragment( - graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - data: data.toJson(), - broadcast: broadcast); - Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields( - {required Map idFields, bool optimistic = true}) { - final result = this.readFragment( graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - optimistic: optimistic); + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + data: data.toJson(), + broadcast: broadcast, + ); + Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields({ + required Map idFields, + bool optimistic = true, + }) { + final result = this.readFragment( + graphql.FragmentRequest( + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + optimistic: optimistic, + ); return result == null ? null : Fragment$basicMutationReturnFields.fromJson(result); } } -@JsonSerializable(explicitToJson: true) -class Query$GetServerDiskVolumes { - Query$GetServerDiskVolumes( - {required this.storage, required this.$__typename}); +class Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override - factory Query$GetServerDiskVolumes.fromJson(Map json) => - _$Query$GetServerDiskVolumesFromJson(json); + factory Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } - final Query$GetServerDiskVolumes$storage storage; + final int code; + + final String message; + + final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetServerDiskVolumesToJson(this); - int get hashCode { - final l$storage = storage; + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; final l$$__typename = $__typename; - return Object.hashAll([l$storage, l$$__typename]); + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetServerDiskVolumes) || - runtimeType != other.runtimeType) return false; - final l$storage = storage; - final lOther$storage = other.storage; - if (l$storage != lOther$storage) return false; + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + on Fragment$basicMutationReturnFields$$ApiKeyMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ApiKeyMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + on Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + instance, + TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + on Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn instance, + TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericJobButationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericJobButationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericJobButationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$GenericJobButationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericJobButationReturn + on Fragment$basicMutationReturnFields$$GenericJobButationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + Fragment$basicMutationReturnFields$$GenericJobButationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + Fragment$basicMutationReturnFields$$GenericJobButationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericJobButationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericJobButationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$GenericJobButationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$GenericMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericMutationReturn + on Fragment$basicMutationReturnFields$$GenericMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + Fragment$basicMutationReturnFields$$GenericMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + Fragment$basicMutationReturnFields$$GenericMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + on Fragment$basicMutationReturnFields$$ServiceJobMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceJobMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ServiceMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceMutationReturn + on Fragment$basicMutationReturnFields$$ServiceMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + Fragment$basicMutationReturnFields$$ServiceMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + Fragment$basicMutationReturnFields$$ServiceMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$TimezoneMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$TimezoneMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$TimezoneMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$TimezoneMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$TimezoneMutationReturn + on Fragment$basicMutationReturnFields$$TimezoneMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + Fragment$basicMutationReturnFields$$TimezoneMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$TimezoneMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$TimezoneMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$UserMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$UserMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$UserMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$UserMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$UserMutationReturn + on Fragment$basicMutationReturnFields$$UserMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + Fragment$basicMutationReturnFields$$UserMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + Fragment$basicMutationReturnFields$$UserMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$UserMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$UserMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Query$GetServerDiskVolumes { + Query$GetServerDiskVolumes({ + required this.storage, + required this.$__typename, + }); + + factory Query$GetServerDiskVolumes.fromJson(Map json) { + final l$storage = json['storage']; + final l$$__typename = json['__typename']; + return Query$GetServerDiskVolumes( + storage: Query$GetServerDiskVolumes$storage.fromJson( + (l$storage as Map)), + $__typename: (l$$__typename as String), + ); + } + + final Query$GetServerDiskVolumes$storage storage; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$storage = storage; + _resultData['storage'] = l$storage.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$storage = storage; + final l$$__typename = $__typename; + return Object.hashAll([ + l$storage, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetServerDiskVolumes) || + runtimeType != other.runtimeType) { + return false; + } + final l$storage = storage; + final lOther$storage = other.storage; + if (l$storage != lOther$storage) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -226,25 +1975,34 @@ class Query$GetServerDiskVolumes { extension UtilityExtension$Query$GetServerDiskVolumes on Query$GetServerDiskVolumes { CopyWith$Query$GetServerDiskVolumes - get copyWith => CopyWith$Query$GetServerDiskVolumes(this, (i) => i); + get copyWith => CopyWith$Query$GetServerDiskVolumes( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetServerDiskVolumes { factory CopyWith$Query$GetServerDiskVolumes( - Query$GetServerDiskVolumes instance, - TRes Function(Query$GetServerDiskVolumes) then) = - _CopyWithImpl$Query$GetServerDiskVolumes; + Query$GetServerDiskVolumes instance, + TRes Function(Query$GetServerDiskVolumes) then, + ) = _CopyWithImpl$Query$GetServerDiskVolumes; factory CopyWith$Query$GetServerDiskVolumes.stub(TRes res) = _CopyWithStubImpl$Query$GetServerDiskVolumes; - TRes call({Query$GetServerDiskVolumes$storage? storage, String? $__typename}); + TRes call({ + Query$GetServerDiskVolumes$storage? storage, + String? $__typename, + }); CopyWith$Query$GetServerDiskVolumes$storage get storage; } class _CopyWithImpl$Query$GetServerDiskVolumes implements CopyWith$Query$GetServerDiskVolumes { - _CopyWithImpl$Query$GetServerDiskVolumes(this._instance, this._then); + _CopyWithImpl$Query$GetServerDiskVolumes( + this._instance, + this._then, + ); final Query$GetServerDiskVolumes _instance; @@ -252,14 +2010,18 @@ class _CopyWithImpl$Query$GetServerDiskVolumes static const _undefined = {}; - TRes call({Object? storage = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? storage = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetServerDiskVolumes( - storage: storage == _undefined || storage == null - ? _instance.storage - : (storage as Query$GetServerDiskVolumes$storage), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + storage: storage == _undefined || storage == null + ? _instance.storage + : (storage as Query$GetServerDiskVolumes$storage), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$GetServerDiskVolumes$storage get storage { final local$storage = _instance.storage; return CopyWith$Query$GetServerDiskVolumes$storage( @@ -273,7 +2035,10 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes TRes _res; - call({Query$GetServerDiskVolumes$storage? storage, String? $__typename}) => + call({ + Query$GetServerDiskVolumes$storage? storage, + String? $__typename, + }) => _res; CopyWith$Query$GetServerDiskVolumes$storage get storage => CopyWith$Query$GetServerDiskVolumes$storage.stub(_res); @@ -281,163 +2046,188 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes const documentNodeQueryGetServerDiskVolumes = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'GetServerDiskVolumes'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'storage'), + type: OperationType.query, + name: NameNode(value: 'GetServerDiskVolumes'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'storage'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'volumes'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'volumes'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'freeSpace'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'model'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'name'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'root'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'serial'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'totalSpace'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'type'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'usages'), + name: NameNode(value: 'freeSpace'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'model'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'name'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'root'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'serial'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'totalSpace'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'type'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'usages'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'title'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'usedSpace'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + InlineFragmentNode( + typeCondition: TypeConditionNode( + on: NamedTypeNode( + name: NameNode(value: 'ServiceStorageUsage'), + isNonNull: false, + )), + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'service'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'title'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), + name: NameNode(value: 'id'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: 'usedSpace'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), + name: NameNode(value: 'isMovable'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - InlineFragmentNode( - typeCondition: TypeConditionNode( - on: NamedTypeNode( - name: NameNode( - value: 'ServiceStorageUsage'), - isNonNull: false)), - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'service'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'id'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'isMovable'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'displayName'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])) - ])), - FieldNode( - name: NameNode(value: 'usedSpace'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( + name: NameNode(value: 'displayName'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + ]), + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'usedSpace'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), ]); Query$GetServerDiskVolumes _parserFn$Query$GetServerDiskVolumes( Map data) => @@ -445,52 +2235,54 @@ Query$GetServerDiskVolumes _parserFn$Query$GetServerDiskVolumes( class Options$Query$GetServerDiskVolumes extends graphql.QueryOptions { - Options$Query$GetServerDiskVolumes( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryGetServerDiskVolumes, - parserFn: _parserFn$Query$GetServerDiskVolumes); + Options$Query$GetServerDiskVolumes({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryGetServerDiskVolumes, + parserFn: _parserFn$Query$GetServerDiskVolumes, + ); } class WatchOptions$Query$GetServerDiskVolumes extends graphql.WatchQueryOptions { - WatchOptions$Query$GetServerDiskVolumes( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryGetServerDiskVolumes, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$GetServerDiskVolumes); + WatchOptions$Query$GetServerDiskVolumes({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryGetServerDiskVolumes, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$GetServerDiskVolumes, + ); } class FetchMoreOptions$Query$GetServerDiskVolumes @@ -498,8 +2290,9 @@ class FetchMoreOptions$Query$GetServerDiskVolumes FetchMoreOptions$Query$GetServerDiskVolumes( {required graphql.UpdateQuery updateQuery}) : super( - updateQuery: updateQuery, - document: documentNodeQueryGetServerDiskVolumes); + updateQuery: updateQuery, + document: documentNodeQueryGetServerDiskVolumes, + ); } extension ClientExtension$Query$GetServerDiskVolumes on graphql.GraphQLClient { @@ -511,66 +2304,97 @@ extension ClientExtension$Query$GetServerDiskVolumes on graphql.GraphQLClient { watchQuery$GetServerDiskVolumes( [WatchOptions$Query$GetServerDiskVolumes? options]) => this.watchQuery(options ?? WatchOptions$Query$GetServerDiskVolumes()); - void writeQuery$GetServerDiskVolumes( - {required Query$GetServerDiskVolumes data, bool broadcast = true}) => + void writeQuery$GetServerDiskVolumes({ + required Query$GetServerDiskVolumes data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: graphql.Operation( - document: documentNodeQueryGetServerDiskVolumes)), - data: data.toJson(), - broadcast: broadcast); - Query$GetServerDiskVolumes? readQuery$GetServerDiskVolumes( - {bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation( document: documentNodeQueryGetServerDiskVolumes)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$GetServerDiskVolumes? readQuery$GetServerDiskVolumes( + {bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: graphql.Operation( + document: documentNodeQueryGetServerDiskVolumes)), + optimistic: optimistic, + ); return result == null ? null : Query$GetServerDiskVolumes.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$GetServerDiskVolumes$storage { - Query$GetServerDiskVolumes$storage( - {required this.volumes, required this.$__typename}); + Query$GetServerDiskVolumes$storage({ + required this.volumes, + required this.$__typename, + }); - @override factory Query$GetServerDiskVolumes$storage.fromJson( - Map json) => - _$Query$GetServerDiskVolumes$storageFromJson(json); + Map json) { + final l$volumes = json['volumes']; + final l$$__typename = json['__typename']; + return Query$GetServerDiskVolumes$storage( + volumes: (l$volumes as List) + .map((e) => Query$GetServerDiskVolumes$storage$volumes.fromJson( + (e as Map))) + .toList(), + $__typename: (l$$__typename as String), + ); + } final List volumes; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$GetServerDiskVolumes$storageToJson(this); + Map toJson() { + final _resultData = {}; + final l$volumes = volumes; + _resultData['volumes'] = l$volumes.map((e) => e.toJson()).toList(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$volumes = volumes; final l$$__typename = $__typename; - return Object.hashAll( - [Object.hashAll(l$volumes.map((v) => v)), l$$__typename]); + return Object.hashAll([ + Object.hashAll(l$volumes.map((v) => v)), + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$GetServerDiskVolumes$storage) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$volumes = volumes; final lOther$volumes = other.volumes; - if (l$volumes.length != lOther$volumes.length) return false; + if (l$volumes.length != lOther$volumes.length) { + return false; + } for (int i = 0; i < l$volumes.length; i++) { final l$volumes$entry = l$volumes[i]; final lOther$volumes$entry = lOther$volumes[i]; - if (l$volumes$entry != lOther$volumes$entry) return false; + if (l$volumes$entry != lOther$volumes$entry) { + return false; + } } - final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -579,22 +2403,25 @@ extension UtilityExtension$Query$GetServerDiskVolumes$storage on Query$GetServerDiskVolumes$storage { CopyWith$Query$GetServerDiskVolumes$storage< Query$GetServerDiskVolumes$storage> - get copyWith => - CopyWith$Query$GetServerDiskVolumes$storage(this, (i) => i); + get copyWith => CopyWith$Query$GetServerDiskVolumes$storage( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetServerDiskVolumes$storage { factory CopyWith$Query$GetServerDiskVolumes$storage( - Query$GetServerDiskVolumes$storage instance, - TRes Function(Query$GetServerDiskVolumes$storage) then) = - _CopyWithImpl$Query$GetServerDiskVolumes$storage; + Query$GetServerDiskVolumes$storage instance, + TRes Function(Query$GetServerDiskVolumes$storage) then, + ) = _CopyWithImpl$Query$GetServerDiskVolumes$storage; factory CopyWith$Query$GetServerDiskVolumes$storage.stub(TRes res) = _CopyWithStubImpl$Query$GetServerDiskVolumes$storage; - TRes call( - {List? volumes, - String? $__typename}); + TRes call({ + List? volumes, + String? $__typename, + }); TRes volumes( Iterable Function( Iterable< @@ -605,7 +2432,10 @@ abstract class CopyWith$Query$GetServerDiskVolumes$storage { class _CopyWithImpl$Query$GetServerDiskVolumes$storage implements CopyWith$Query$GetServerDiskVolumes$storage { - _CopyWithImpl$Query$GetServerDiskVolumes$storage(this._instance, this._then); + _CopyWithImpl$Query$GetServerDiskVolumes$storage( + this._instance, + this._then, + ); final Query$GetServerDiskVolumes$storage _instance; @@ -613,14 +2443,18 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage static const _undefined = {}; - TRes call({Object? volumes = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? volumes = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetServerDiskVolumes$storage( - volumes: volumes == _undefined || volumes == null - ? _instance.volumes - : (volumes as List), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + volumes: volumes == _undefined || volumes == null + ? _instance.volumes + : (volumes as List), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); TRes volumes( Iterable Function( Iterable< @@ -628,9 +2462,11 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage Query$GetServerDiskVolumes$storage$volumes>>) _fn) => call( - volumes: _fn(_instance.volumes.map((e) => - CopyWith$Query$GetServerDiskVolumes$storage$volumes( - e, (i) => i))).toList()); + volumes: _fn(_instance.volumes + .map((e) => CopyWith$Query$GetServerDiskVolumes$storage$volumes( + e, + (i) => i, + ))).toList()); } class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage @@ -639,31 +2475,57 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage TRes _res; - call( - {List? volumes, - String? $__typename}) => + call({ + List? volumes, + String? $__typename, + }) => _res; volumes(_fn) => _res; } -@JsonSerializable(explicitToJson: true) class Query$GetServerDiskVolumes$storage$volumes { - Query$GetServerDiskVolumes$storage$volumes( - {required this.freeSpace, - this.model, - required this.name, - required this.root, - this.serial, - required this.totalSpace, - required this.type, - required this.usages, - required this.usedSpace, - required this.$__typename}); + Query$GetServerDiskVolumes$storage$volumes({ + required this.freeSpace, + this.model, + required this.name, + required this.root, + this.serial, + required this.totalSpace, + required this.type, + required this.usages, + required this.usedSpace, + required this.$__typename, + }); - @override factory Query$GetServerDiskVolumes$storage$volumes.fromJson( - Map json) => - _$Query$GetServerDiskVolumes$storage$volumesFromJson(json); + Map json) { + final l$freeSpace = json['freeSpace']; + final l$model = json['model']; + final l$name = json['name']; + final l$root = json['root']; + final l$serial = json['serial']; + final l$totalSpace = json['totalSpace']; + final l$type = json['type']; + final l$usages = json['usages']; + final l$usedSpace = json['usedSpace']; + final l$$__typename = json['__typename']; + return Query$GetServerDiskVolumes$storage$volumes( + freeSpace: (l$freeSpace as String), + model: (l$model as String?), + name: (l$name as String), + root: (l$root as bool), + serial: (l$serial as String?), + totalSpace: (l$totalSpace as String), + type: (l$type as String), + usages: (l$usages as List) + .map((e) => + Query$GetServerDiskVolumes$storage$volumes$usages.fromJson( + (e as Map))) + .toList(), + usedSpace: (l$usedSpace as String), + $__typename: (l$$__typename as String), + ); + } final String freeSpace; @@ -683,11 +2545,34 @@ class Query$GetServerDiskVolumes$storage$volumes { final String usedSpace; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$GetServerDiskVolumes$storage$volumesToJson(this); + Map toJson() { + final _resultData = {}; + final l$freeSpace = freeSpace; + _resultData['freeSpace'] = l$freeSpace; + final l$model = model; + _resultData['model'] = l$model; + final l$name = name; + _resultData['name'] = l$name; + final l$root = root; + _resultData['root'] = l$root; + final l$serial = serial; + _resultData['serial'] = l$serial; + final l$totalSpace = totalSpace; + _resultData['totalSpace'] = l$totalSpace; + final l$type = type; + _resultData['type'] = l$type; + final l$usages = usages; + _resultData['usages'] = l$usages.map((e) => e.toJson()).toList(); + final l$usedSpace = usedSpace; + _resultData['usedSpace'] = l$usedSpace; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$freeSpace = freeSpace; final l$model = model; @@ -709,51 +2594,76 @@ class Query$GetServerDiskVolumes$storage$volumes { l$type, Object.hashAll(l$usages.map((v) => v)), l$usedSpace, - l$$__typename + l$$__typename, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$GetServerDiskVolumes$storage$volumes) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$freeSpace = freeSpace; final lOther$freeSpace = other.freeSpace; - if (l$freeSpace != lOther$freeSpace) return false; + if (l$freeSpace != lOther$freeSpace) { + return false; + } final l$model = model; final lOther$model = other.model; - if (l$model != lOther$model) return false; + if (l$model != lOther$model) { + return false; + } final l$name = name; final lOther$name = other.name; - if (l$name != lOther$name) return false; + if (l$name != lOther$name) { + return false; + } final l$root = root; final lOther$root = other.root; - if (l$root != lOther$root) return false; + if (l$root != lOther$root) { + return false; + } final l$serial = serial; final lOther$serial = other.serial; - if (l$serial != lOther$serial) return false; + if (l$serial != lOther$serial) { + return false; + } final l$totalSpace = totalSpace; final lOther$totalSpace = other.totalSpace; - if (l$totalSpace != lOther$totalSpace) return false; + if (l$totalSpace != lOther$totalSpace) { + return false; + } final l$type = type; final lOther$type = other.type; - if (l$type != lOther$type) return false; + if (l$type != lOther$type) { + return false; + } final l$usages = usages; final lOther$usages = other.usages; - if (l$usages.length != lOther$usages.length) return false; + if (l$usages.length != lOther$usages.length) { + return false; + } for (int i = 0; i < l$usages.length; i++) { final l$usages$entry = l$usages[i]; final lOther$usages$entry = lOther$usages[i]; - if (l$usages$entry != lOther$usages$entry) return false; + if (l$usages$entry != lOther$usages$entry) { + return false; + } } - final l$usedSpace = usedSpace; final lOther$usedSpace = other.usedSpace; - if (l$usedSpace != lOther$usedSpace) return false; + if (l$usedSpace != lOther$usedSpace) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -762,30 +2672,33 @@ extension UtilityExtension$Query$GetServerDiskVolumes$storage$volumes on Query$GetServerDiskVolumes$storage$volumes { CopyWith$Query$GetServerDiskVolumes$storage$volumes< Query$GetServerDiskVolumes$storage$volumes> - get copyWith => - CopyWith$Query$GetServerDiskVolumes$storage$volumes(this, (i) => i); + get copyWith => CopyWith$Query$GetServerDiskVolumes$storage$volumes( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetServerDiskVolumes$storage$volumes { factory CopyWith$Query$GetServerDiskVolumes$storage$volumes( - Query$GetServerDiskVolumes$storage$volumes instance, - TRes Function(Query$GetServerDiskVolumes$storage$volumes) then) = - _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes; + Query$GetServerDiskVolumes$storage$volumes instance, + TRes Function(Query$GetServerDiskVolumes$storage$volumes) then, + ) = _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes; factory CopyWith$Query$GetServerDiskVolumes$storage$volumes.stub(TRes res) = _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes; - TRes call( - {String? freeSpace, - String? model, - String? name, - bool? root, - String? serial, - String? totalSpace, - String? type, - List? usages, - String? usedSpace, - String? $__typename}); + TRes call({ + String? freeSpace, + String? model, + String? name, + bool? root, + String? serial, + String? totalSpace, + String? type, + List? usages, + String? usedSpace, + String? $__typename, + }); TRes usages( Iterable Function( Iterable< @@ -797,7 +2710,9 @@ abstract class CopyWith$Query$GetServerDiskVolumes$storage$volumes { class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes implements CopyWith$Query$GetServerDiskVolumes$storage$volumes { _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes( - this._instance, this._then); + this._instance, + this._then, + ); final Query$GetServerDiskVolumes$storage$volumes _instance; @@ -805,45 +2720,47 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes static const _undefined = {}; - TRes call( - {Object? freeSpace = _undefined, - Object? model = _undefined, - Object? name = _undefined, - Object? root = _undefined, - Object? serial = _undefined, - Object? totalSpace = _undefined, - Object? type = _undefined, - Object? usages = _undefined, - Object? usedSpace = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? freeSpace = _undefined, + Object? model = _undefined, + Object? name = _undefined, + Object? root = _undefined, + Object? serial = _undefined, + Object? totalSpace = _undefined, + Object? type = _undefined, + Object? usages = _undefined, + Object? usedSpace = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetServerDiskVolumes$storage$volumes( - freeSpace: freeSpace == _undefined || freeSpace == null - ? _instance.freeSpace - : (freeSpace as String), - model: model == _undefined ? _instance.model : (model as String?), - name: name == _undefined || name == null - ? _instance.name - : (name as String), - root: root == _undefined || root == null - ? _instance.root - : (root as bool), - serial: serial == _undefined ? _instance.serial : (serial as String?), - totalSpace: totalSpace == _undefined || totalSpace == null - ? _instance.totalSpace - : (totalSpace as String), - type: type == _undefined || type == null - ? _instance.type - : (type as String), - usages: usages == _undefined || usages == null - ? _instance.usages - : (usages - as List), - usedSpace: usedSpace == _undefined || usedSpace == null - ? _instance.usedSpace - : (usedSpace as String), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + freeSpace: freeSpace == _undefined || freeSpace == null + ? _instance.freeSpace + : (freeSpace as String), + model: model == _undefined ? _instance.model : (model as String?), + name: name == _undefined || name == null + ? _instance.name + : (name as String), + root: root == _undefined || root == null + ? _instance.root + : (root as bool), + serial: serial == _undefined ? _instance.serial : (serial as String?), + totalSpace: totalSpace == _undefined || totalSpace == null + ? _instance.totalSpace + : (totalSpace as String), + type: type == _undefined || type == null + ? _instance.type + : (type as String), + usages: usages == _undefined || usages == null + ? _instance.usages + : (usages + as List), + usedSpace: usedSpace == _undefined || usedSpace == null + ? _instance.usedSpace + : (usedSpace as String), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); TRes usages( Iterable Function( Iterable< @@ -851,9 +2768,11 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes Query$GetServerDiskVolumes$storage$volumes$usages>>) _fn) => call( - usages: _fn(_instance.usages.map((e) => - CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages( - e, (i) => i))).toList()); + usages: _fn(_instance.usages.map( + (e) => CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages( + e, + (i) => i, + ))).toList()); } class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes @@ -862,38 +2781,45 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes TRes _res; - call( - {String? freeSpace, - String? model, - String? name, - bool? root, - String? serial, - String? totalSpace, - String? type, - List? usages, - String? usedSpace, - String? $__typename}) => + call({ + String? freeSpace, + String? model, + String? name, + bool? root, + String? serial, + String? totalSpace, + String? type, + List? usages, + String? usedSpace, + String? $__typename, + }) => _res; usages(_fn) => _res; } -@JsonSerializable(explicitToJson: true) class Query$GetServerDiskVolumes$storage$volumes$usages { - Query$GetServerDiskVolumes$storage$volumes$usages( - {required this.title, - required this.usedSpace, - required this.$__typename}); + Query$GetServerDiskVolumes$storage$volumes$usages({ + required this.title, + required this.usedSpace, + required this.$__typename, + }); - @override factory Query$GetServerDiskVolumes$storage$volumes$usages.fromJson( Map json) { switch (json["__typename"] as String) { case "ServiceStorageUsage": return Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage .fromJson(json); + default: - return _$Query$GetServerDiskVolumes$storage$volumes$usagesFromJson( - json); + final l$title = json['title']; + final l$usedSpace = json['usedSpace']; + final l$$__typename = json['__typename']; + return Query$GetServerDiskVolumes$storage$volumes$usages( + title: (l$title as String), + usedSpace: (l$usedSpace as String), + $__typename: (l$$__typename as String), + ); } } @@ -901,32 +2827,55 @@ class Query$GetServerDiskVolumes$storage$volumes$usages { final String usedSpace; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$GetServerDiskVolumes$storage$volumes$usagesToJson(this); + Map toJson() { + final _resultData = {}; + final l$title = title; + _resultData['title'] = l$title; + final l$usedSpace = usedSpace; + _resultData['usedSpace'] = l$usedSpace; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$title = title; final l$usedSpace = usedSpace; final l$$__typename = $__typename; - return Object.hashAll([l$title, l$usedSpace, l$$__typename]); + return Object.hashAll([ + l$title, + l$usedSpace, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$GetServerDiskVolumes$storage$volumes$usages) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$title = title; final lOther$title = other.title; - if (l$title != lOther$title) return false; + if (l$title != lOther$title) { + return false; + } final l$usedSpace = usedSpace; final lOther$usedSpace = other.usedSpace; - if (l$usedSpace != lOther$usedSpace) return false; + if (l$usedSpace != lOther$usedSpace) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -937,29 +2886,36 @@ extension UtilityExtension$Query$GetServerDiskVolumes$storage$volumes$usages Query$GetServerDiskVolumes$storage$volumes$usages> get copyWith => CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages< TRes> { factory CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages( - Query$GetServerDiskVolumes$storage$volumes$usages instance, - TRes Function(Query$GetServerDiskVolumes$storage$volumes$usages) - then) = - _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages; + Query$GetServerDiskVolumes$storage$volumes$usages instance, + TRes Function(Query$GetServerDiskVolumes$storage$volumes$usages) then, + ) = _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages; factory CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages.stub( TRes res) = _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages; - TRes call({String? title, String? usedSpace, String? $__typename}); + TRes call({ + String? title, + String? usedSpace, + String? $__typename, + }); } class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages implements CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages { _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages( - this._instance, this._then); + this._instance, + this._then, + ); final Query$GetServerDiskVolumes$storage$volumes$usages _instance; @@ -967,20 +2923,22 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages static const _undefined = {}; - TRes call( - {Object? title = _undefined, - Object? usedSpace = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? title = _undefined, + Object? usedSpace = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetServerDiskVolumes$storage$volumes$usages( - title: title == _undefined || title == null - ? _instance.title - : (title as String), - usedSpace: usedSpace == _undefined || usedSpace == null - ? _instance.usedSpace - : (usedSpace as String), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + title: title == _undefined || title == null + ? _instance.title + : (title as String), + usedSpace: usedSpace == _undefined || usedSpace == null + ? _instance.usedSpace + : (usedSpace as String), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages @@ -991,63 +2949,106 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages TRes _res; - call({String? title, String? usedSpace, String? $__typename}) => _res; + call({ + String? title, + String? usedSpace, + String? $__typename, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage implements Query$GetServerDiskVolumes$storage$volumes$usages { - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage( - {required this.title, - required this.usedSpace, - required this.$__typename, - this.service}); + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage({ + this.service, + required this.$__typename, + required this.title, + required this.usedSpace, + }); - @override factory Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage.fromJson( - Map json) => - _$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsageFromJson( - json); + Map json) { + final l$service = json['service']; + final l$$__typename = json['__typename']; + final l$title = json['title']; + final l$usedSpace = json['usedSpace']; + return Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage( + service: l$service == null + ? null + : Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service + .fromJson((l$service as Map)), + $__typename: (l$$__typename as String), + title: (l$title as String), + usedSpace: (l$usedSpace as String), + ); + } + + final Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service? + service; + + final String $__typename; final String title; final String usedSpace; - @JsonKey(name: '__typename') - final String $__typename; + Map toJson() { + final _resultData = {}; + final l$service = service; + _resultData['service'] = l$service?.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$title = title; + _resultData['title'] = l$title; + final l$usedSpace = usedSpace; + _resultData['usedSpace'] = l$usedSpace; + return _resultData; + } - final Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service? - service; - - Map toJson() => - _$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsageToJson( - this); + @override int get hashCode { + final l$service = service; + final l$$__typename = $__typename; final l$title = title; final l$usedSpace = usedSpace; - final l$$__typename = $__typename; - final l$service = service; - return Object.hashAll([l$title, l$usedSpace, l$$__typename, l$service]); + return Object.hashAll([ + l$service, + l$$__typename, + l$title, + l$usedSpace, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage) || - runtimeType != other.runtimeType) return false; - final l$title = title; - final lOther$title = other.title; - if (l$title != lOther$title) return false; - final l$usedSpace = usedSpace; - final lOther$usedSpace = other.usedSpace; - if (l$usedSpace != lOther$usedSpace) return false; - final l$$__typename = $__typename; - final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + runtimeType != other.runtimeType) { + return false; + } final l$service = service; final lOther$service = other.service; - if (l$service != lOther$service) return false; + if (l$service != lOther$service) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + final l$title = title; + final lOther$title = other.title; + if (l$title != lOther$title) { + return false; + } + final l$usedSpace = usedSpace; + final lOther$usedSpace = other.usedSpace; + if (l$usedSpace != lOther$usedSpace) { + return false; + } return true; } } @@ -1058,29 +3059,32 @@ extension UtilityExtension$Query$GetServerDiskVolumes$storage$volumes$usages$$Se Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage> get copyWith => CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage< TRes> { factory CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage( - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage - instance, - TRes Function( - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage) - then) = - _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage; + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage + instance, + TRes Function( + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage) + then, + ) = _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage; factory CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage.stub( TRes res) = _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage; - TRes call( - {String? title, - String? usedSpace, - String? $__typename, - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service? - service}); + TRes call({ + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service? + service, + String? $__typename, + String? title, + String? usedSpace, + }); CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service< TRes> get service; } @@ -1091,7 +3095,9 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceSt CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage< TRes> { _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage( - this._instance, this._then); + this._instance, + this._then, + ); final Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage _instance; @@ -1102,25 +3108,28 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceSt static const _undefined = {}; - TRes call( - {Object? title = _undefined, - Object? usedSpace = _undefined, - Object? $__typename = _undefined, - Object? service = _undefined}) => - _then(Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage( - title: title == _undefined || title == null - ? _instance.title - : (title as String), - usedSpace: usedSpace == _undefined || usedSpace == null - ? _instance.usedSpace - : (usedSpace as String), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - service: service == _undefined - ? _instance.service - : (service - as Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service?))); + TRes call({ + Object? service = _undefined, + Object? $__typename = _undefined, + Object? title = _undefined, + Object? usedSpace = _undefined, + }) => + _then( + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage( + service: service == _undefined + ? _instance.service + : (service + as Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service?), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + title: title == _undefined || title == null + ? _instance.title + : (title as String), + usedSpace: usedSpace == _undefined || usedSpace == null + ? _instance.usedSpace + : (usedSpace as String), + )); CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service< TRes> get service { final local$service = _instance.service; @@ -1142,12 +3151,13 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$Servi TRes _res; - call( - {String? title, - String? usedSpace, - String? $__typename, - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service? - service}) => + call({ + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service? + service, + String? $__typename, + String? title, + String? usedSpace, + }) => _res; CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service< TRes> @@ -1156,19 +3166,27 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$Servi .stub(_res); } -@JsonSerializable(explicitToJson: true) class Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service { - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service( - {required this.id, - required this.isMovable, - required this.displayName, - required this.$__typename}); + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service({ + required this.id, + required this.isMovable, + required this.displayName, + required this.$__typename, + }); - @override factory Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service.fromJson( - Map json) => - _$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$serviceFromJson( - json); + Map json) { + final l$id = json['id']; + final l$isMovable = json['isMovable']; + final l$displayName = json['displayName']; + final l$$__typename = json['__typename']; + return Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service( + id: (l$id as String), + isMovable: (l$isMovable as bool), + displayName: (l$displayName as String), + $__typename: (l$$__typename as String), + ); + } final String id; @@ -1176,38 +3194,65 @@ class Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$ser final String displayName; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$serviceToJson( - this); + Map toJson() { + final _resultData = {}; + final l$id = id; + _resultData['id'] = l$id; + final l$isMovable = isMovable; + _resultData['isMovable'] = l$isMovable; + final l$displayName = displayName; + _resultData['displayName'] = l$displayName; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$id = id; final l$isMovable = isMovable; final l$displayName = displayName; final l$$__typename = $__typename; - return Object.hashAll([l$id, l$isMovable, l$displayName, l$$__typename]); + return Object.hashAll([ + l$id, + l$isMovable, + l$displayName, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$id = id; final lOther$id = other.id; - if (l$id != lOther$id) return false; + if (l$id != lOther$id) { + return false; + } final l$isMovable = isMovable; final lOther$isMovable = other.isMovable; - if (l$isMovable != lOther$isMovable) return false; + if (l$isMovable != lOther$isMovable) { + return false; + } final l$displayName = displayName; final lOther$displayName = other.displayName; - if (l$displayName != lOther$displayName) return false; + if (l$displayName != lOther$displayName) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1218,25 +3263,31 @@ extension UtilityExtension$Query$GetServerDiskVolumes$storage$volumes$usages$$Se Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service> get copyWith => CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service< TRes> { factory CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service( - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service - instance, - TRes Function( - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service) - then) = - _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service; + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service + instance, + TRes Function( + Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service) + then, + ) = _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service; factory CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service.stub( TRes res) = _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service; - TRes call( - {String? id, bool? isMovable, String? displayName, String? $__typename}); + TRes call({ + String? id, + bool? isMovable, + String? displayName, + String? $__typename, + }); } class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service< @@ -1245,7 +3296,9 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceSt CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service< TRes> { _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service( - this._instance, this._then); + this._instance, + this._then, + ); final Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service _instance; @@ -1256,25 +3309,25 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceSt static const _undefined = {}; - TRes call( - {Object? id = _undefined, - Object? isMovable = _undefined, - Object? displayName = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? id = _undefined, + Object? isMovable = _undefined, + Object? displayName = _undefined, + Object? $__typename = _undefined, + }) => _then( Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service( - id: id == _undefined || id == null - ? _instance.id - : (id as String), - isMovable: isMovable == _undefined || isMovable == null - ? _instance.isMovable - : (isMovable as bool), - displayName: displayName == _undefined || displayName == null - ? _instance.displayName - : (displayName as String), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + id: id == _undefined || id == null ? _instance.id : (id as String), + isMovable: isMovable == _undefined || isMovable == null + ? _instance.isMovable + : (isMovable as bool), + displayName: displayName == _undefined || displayName == null + ? _instance.displayName + : (displayName as String), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service< @@ -1287,50 +3340,74 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$Servi TRes _res; - call( - {String? id, - bool? isMovable, - String? displayName, - String? $__typename}) => + call({ + String? id, + bool? isMovable, + String? displayName, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$MountVolume { - Variables$Mutation$MountVolume({required this.name}); + factory Variables$Mutation$MountVolume({required String name}) => + Variables$Mutation$MountVolume._({ + r'name': name, + }); + + Variables$Mutation$MountVolume._(this._$data); + + factory Variables$Mutation$MountVolume.fromJson(Map data) { + final result$data = {}; + final l$name = data['name']; + result$data['name'] = (l$name as String); + return Variables$Mutation$MountVolume._(result$data); + } + + Map _$data; + + String get name => (_$data['name'] as String); + Map toJson() { + final result$data = {}; + final l$name = name; + result$data['name'] = l$name; + return result$data; + } + + CopyWith$Variables$Mutation$MountVolume + get copyWith => CopyWith$Variables$Mutation$MountVolume( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$MountVolume) || + runtimeType != other.runtimeType) { + return false; + } + final l$name = name; + final lOther$name = other.name; + if (l$name != lOther$name) { + return false; + } + return true; + } @override - factory Variables$Mutation$MountVolume.fromJson(Map json) => - _$Variables$Mutation$MountVolumeFromJson(json); - - final String name; - - Map toJson() => _$Variables$Mutation$MountVolumeToJson(this); int get hashCode { final l$name = name; return Object.hashAll([l$name]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$MountVolume) || - runtimeType != other.runtimeType) return false; - final l$name = name; - final lOther$name = other.name; - if (l$name != lOther$name) return false; - return true; - } - - CopyWith$Variables$Mutation$MountVolume - get copyWith => CopyWith$Variables$Mutation$MountVolume(this, (i) => i); } abstract class CopyWith$Variables$Mutation$MountVolume { factory CopyWith$Variables$Mutation$MountVolume( - Variables$Mutation$MountVolume instance, - TRes Function(Variables$Mutation$MountVolume) then) = - _CopyWithImpl$Variables$Mutation$MountVolume; + Variables$Mutation$MountVolume instance, + TRes Function(Variables$Mutation$MountVolume) then, + ) = _CopyWithImpl$Variables$Mutation$MountVolume; factory CopyWith$Variables$Mutation$MountVolume.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$MountVolume; @@ -1340,7 +3417,10 @@ abstract class CopyWith$Variables$Mutation$MountVolume { class _CopyWithImpl$Variables$Mutation$MountVolume implements CopyWith$Variables$Mutation$MountVolume { - _CopyWithImpl$Variables$Mutation$MountVolume(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$MountVolume( + this._instance, + this._then, + ); final Variables$Mutation$MountVolume _instance; @@ -1349,10 +3429,10 @@ class _CopyWithImpl$Variables$Mutation$MountVolume static const _undefined = {}; TRes call({Object? name = _undefined}) => - _then(Variables$Mutation$MountVolume( - name: name == _undefined || name == null - ? _instance.name - : (name as String))); + _then(Variables$Mutation$MountVolume._({ + ..._instance._$data, + if (name != _undefined && name != null) 'name': (name as String), + })); } class _CopyWithStubImpl$Variables$Mutation$MountVolume @@ -1364,62 +3444,97 @@ class _CopyWithStubImpl$Variables$Mutation$MountVolume call({String? name}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$MountVolume { - Mutation$MountVolume({required this.mountVolume, required this.$__typename}); + Mutation$MountVolume({ + required this.mountVolume, + required this.$__typename, + }); - @override - factory Mutation$MountVolume.fromJson(Map json) => - _$Mutation$MountVolumeFromJson(json); + factory Mutation$MountVolume.fromJson(Map json) { + final l$mountVolume = json['mountVolume']; + final l$$__typename = json['__typename']; + return Mutation$MountVolume( + mountVolume: Mutation$MountVolume$mountVolume.fromJson( + (l$mountVolume as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$MountVolume$mountVolume mountVolume; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$MountVolumeToJson(this); + Map toJson() { + final _resultData = {}; + final l$mountVolume = mountVolume; + _resultData['mountVolume'] = l$mountVolume.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$mountVolume = mountVolume; final l$$__typename = $__typename; - return Object.hashAll([l$mountVolume, l$$__typename]); + return Object.hashAll([ + l$mountVolume, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$MountVolume) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$MountVolume) || runtimeType != other.runtimeType) { return false; + } final l$mountVolume = mountVolume; final lOther$mountVolume = other.mountVolume; - if (l$mountVolume != lOther$mountVolume) return false; + if (l$mountVolume != lOther$mountVolume) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$MountVolume on Mutation$MountVolume { CopyWith$Mutation$MountVolume get copyWith => - CopyWith$Mutation$MountVolume(this, (i) => i); + CopyWith$Mutation$MountVolume( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$MountVolume { - factory CopyWith$Mutation$MountVolume(Mutation$MountVolume instance, - TRes Function(Mutation$MountVolume) then) = - _CopyWithImpl$Mutation$MountVolume; + factory CopyWith$Mutation$MountVolume( + Mutation$MountVolume instance, + TRes Function(Mutation$MountVolume) then, + ) = _CopyWithImpl$Mutation$MountVolume; factory CopyWith$Mutation$MountVolume.stub(TRes res) = _CopyWithStubImpl$Mutation$MountVolume; - TRes call( - {Mutation$MountVolume$mountVolume? mountVolume, String? $__typename}); + TRes call({ + Mutation$MountVolume$mountVolume? mountVolume, + String? $__typename, + }); CopyWith$Mutation$MountVolume$mountVolume get mountVolume; } class _CopyWithImpl$Mutation$MountVolume implements CopyWith$Mutation$MountVolume { - _CopyWithImpl$Mutation$MountVolume(this._instance, this._then); + _CopyWithImpl$Mutation$MountVolume( + this._instance, + this._then, + ); final Mutation$MountVolume _instance; @@ -1427,16 +3542,18 @@ class _CopyWithImpl$Mutation$MountVolume static const _undefined = {}; - TRes call( - {Object? mountVolume = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? mountVolume = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$MountVolume( - mountVolume: mountVolume == _undefined || mountVolume == null - ? _instance.mountVolume - : (mountVolume as Mutation$MountVolume$mountVolume), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + mountVolume: mountVolume == _undefined || mountVolume == null + ? _instance.mountVolume + : (mountVolume as Mutation$MountVolume$mountVolume), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$MountVolume$mountVolume get mountVolume { final local$mountVolume = _instance.mountVolume; return CopyWith$Mutation$MountVolume$mountVolume( @@ -1450,7 +3567,10 @@ class _CopyWithStubImpl$Mutation$MountVolume TRes _res; - call({Mutation$MountVolume$mountVolume? mountVolume, String? $__typename}) => + call({ + Mutation$MountVolume$mountVolume? mountVolume, + String? $__typename, + }) => _res; CopyWith$Mutation$MountVolume$mountVolume get mountVolume => CopyWith$Mutation$MountVolume$mountVolume.stub(_res); @@ -1458,83 +3578,97 @@ class _CopyWithStubImpl$Mutation$MountVolume const documentNodeMutationMountVolume = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'MountVolume'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'name')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'mountVolume'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'name'), - value: VariableNode(name: NameNode(value: 'name'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'MountVolume'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'name')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'mountVolume'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'name'), + value: VariableNode(name: NameNode(value: 'name')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$MountVolume _parserFn$Mutation$MountVolume( Map data) => Mutation$MountVolume.fromJson(data); typedef OnMutationCompleted$Mutation$MountVolume = FutureOr Function( - dynamic, Mutation$MountVolume?); + dynamic, + Mutation$MountVolume?, +); class Options$Mutation$MountVolume extends graphql.MutationOptions { - Options$Mutation$MountVolume( - {String? operationName, - required Variables$Mutation$MountVolume variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$MountVolume? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$MountVolume({ + String? operationName, + required Variables$Mutation$MountVolume variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$MountVolume? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted(data, - data == null ? null : _parserFn$Mutation$MountVolume(data)), - update: update, - onError: onError, - document: documentNodeMutationMountVolume, - parserFn: _parserFn$Mutation$MountVolume); + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( + data, + data == null ? null : _parserFn$Mutation$MountVolume(data), + ), + update: update, + onError: onError, + document: documentNodeMutationMountVolume, + parserFn: _parserFn$Mutation$MountVolume, + ); final OnMutationCompleted$Mutation$MountVolume? onCompletedWithParsed; @@ -1543,38 +3677,39 @@ class Options$Mutation$MountVolume ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$MountVolume extends graphql.WatchQueryOptions { - WatchOptions$Mutation$MountVolume( - {String? operationName, - required Variables$Mutation$MountVolume variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationMountVolume, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$MountVolume); + WatchOptions$Mutation$MountVolume({ + String? operationName, + required Variables$Mutation$MountVolume variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationMountVolume, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$MountVolume, + ); } extension ClientExtension$Mutation$MountVolume on graphql.GraphQLClient { @@ -1586,19 +3721,27 @@ extension ClientExtension$Mutation$MountVolume on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$MountVolume$mountVolume - implements Fragment$basicMutationReturnFields { - Mutation$MountVolume$mountVolume( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$MountVolume$mountVolume({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override - factory Mutation$MountVolume$mountVolume.fromJson( - Map json) => - _$Mutation$MountVolume$mountVolumeFromJson(json); + factory Mutation$MountVolume$mountVolume.fromJson(Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$MountVolume$mountVolume( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -1606,36 +3749,64 @@ class Mutation$MountVolume$mountVolume final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$MountVolume$mountVolumeToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$MountVolume$mountVolume) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1643,24 +3814,35 @@ class Mutation$MountVolume$mountVolume extension UtilityExtension$Mutation$MountVolume$mountVolume on Mutation$MountVolume$mountVolume { CopyWith$Mutation$MountVolume$mountVolume - get copyWith => CopyWith$Mutation$MountVolume$mountVolume(this, (i) => i); + get copyWith => CopyWith$Mutation$MountVolume$mountVolume( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$MountVolume$mountVolume { factory CopyWith$Mutation$MountVolume$mountVolume( - Mutation$MountVolume$mountVolume instance, - TRes Function(Mutation$MountVolume$mountVolume) then) = - _CopyWithImpl$Mutation$MountVolume$mountVolume; + Mutation$MountVolume$mountVolume instance, + TRes Function(Mutation$MountVolume$mountVolume) then, + ) = _CopyWithImpl$Mutation$MountVolume$mountVolume; factory CopyWith$Mutation$MountVolume$mountVolume.stub(TRes res) = _CopyWithStubImpl$Mutation$MountVolume$mountVolume; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$MountVolume$mountVolume implements CopyWith$Mutation$MountVolume$mountVolume { - _CopyWithImpl$Mutation$MountVolume$mountVolume(this._instance, this._then); + _CopyWithImpl$Mutation$MountVolume$mountVolume( + this._instance, + this._then, + ); final Mutation$MountVolume$mountVolume _instance; @@ -1668,24 +3850,25 @@ class _CopyWithImpl$Mutation$MountVolume$mountVolume static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$MountVolume$mountVolume( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$MountVolume$mountVolume @@ -1694,47 +3877,74 @@ class _CopyWithStubImpl$Mutation$MountVolume$mountVolume TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$ResizeVolume { - Variables$Mutation$ResizeVolume({required this.name}); + factory Variables$Mutation$ResizeVolume({required String name}) => + Variables$Mutation$ResizeVolume._({ + r'name': name, + }); + + Variables$Mutation$ResizeVolume._(this._$data); + + factory Variables$Mutation$ResizeVolume.fromJson(Map data) { + final result$data = {}; + final l$name = data['name']; + result$data['name'] = (l$name as String); + return Variables$Mutation$ResizeVolume._(result$data); + } + + Map _$data; + + String get name => (_$data['name'] as String); + Map toJson() { + final result$data = {}; + final l$name = name; + result$data['name'] = l$name; + return result$data; + } + + CopyWith$Variables$Mutation$ResizeVolume + get copyWith => CopyWith$Variables$Mutation$ResizeVolume( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$ResizeVolume) || + runtimeType != other.runtimeType) { + return false; + } + final l$name = name; + final lOther$name = other.name; + if (l$name != lOther$name) { + return false; + } + return true; + } @override - factory Variables$Mutation$ResizeVolume.fromJson(Map json) => - _$Variables$Mutation$ResizeVolumeFromJson(json); - - final String name; - - Map toJson() => - _$Variables$Mutation$ResizeVolumeToJson(this); int get hashCode { final l$name = name; return Object.hashAll([l$name]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$ResizeVolume) || - runtimeType != other.runtimeType) return false; - final l$name = name; - final lOther$name = other.name; - if (l$name != lOther$name) return false; - return true; - } - - CopyWith$Variables$Mutation$ResizeVolume - get copyWith => CopyWith$Variables$Mutation$ResizeVolume(this, (i) => i); } abstract class CopyWith$Variables$Mutation$ResizeVolume { factory CopyWith$Variables$Mutation$ResizeVolume( - Variables$Mutation$ResizeVolume instance, - TRes Function(Variables$Mutation$ResizeVolume) then) = - _CopyWithImpl$Variables$Mutation$ResizeVolume; + Variables$Mutation$ResizeVolume instance, + TRes Function(Variables$Mutation$ResizeVolume) then, + ) = _CopyWithImpl$Variables$Mutation$ResizeVolume; factory CopyWith$Variables$Mutation$ResizeVolume.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$ResizeVolume; @@ -1744,7 +3954,10 @@ abstract class CopyWith$Variables$Mutation$ResizeVolume { class _CopyWithImpl$Variables$Mutation$ResizeVolume implements CopyWith$Variables$Mutation$ResizeVolume { - _CopyWithImpl$Variables$Mutation$ResizeVolume(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$ResizeVolume( + this._instance, + this._then, + ); final Variables$Mutation$ResizeVolume _instance; @@ -1753,10 +3966,10 @@ class _CopyWithImpl$Variables$Mutation$ResizeVolume static const _undefined = {}; TRes call({Object? name = _undefined}) => - _then(Variables$Mutation$ResizeVolume( - name: name == _undefined || name == null - ? _instance.name - : (name as String))); + _then(Variables$Mutation$ResizeVolume._({ + ..._instance._$data, + if (name != _undefined && name != null) 'name': (name as String), + })); } class _CopyWithStubImpl$Variables$Mutation$ResizeVolume @@ -1768,63 +3981,97 @@ class _CopyWithStubImpl$Variables$Mutation$ResizeVolume call({String? name}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$ResizeVolume { - Mutation$ResizeVolume( - {required this.resizeVolume, required this.$__typename}); + Mutation$ResizeVolume({ + required this.resizeVolume, + required this.$__typename, + }); - @override - factory Mutation$ResizeVolume.fromJson(Map json) => - _$Mutation$ResizeVolumeFromJson(json); + factory Mutation$ResizeVolume.fromJson(Map json) { + final l$resizeVolume = json['resizeVolume']; + final l$$__typename = json['__typename']; + return Mutation$ResizeVolume( + resizeVolume: Mutation$ResizeVolume$resizeVolume.fromJson( + (l$resizeVolume as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$ResizeVolume$resizeVolume resizeVolume; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$ResizeVolumeToJson(this); + Map toJson() { + final _resultData = {}; + final l$resizeVolume = resizeVolume; + _resultData['resizeVolume'] = l$resizeVolume.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$resizeVolume = resizeVolume; final l$$__typename = $__typename; - return Object.hashAll([l$resizeVolume, l$$__typename]); + return Object.hashAll([ + l$resizeVolume, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$ResizeVolume) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$ResizeVolume) || runtimeType != other.runtimeType) { return false; + } final l$resizeVolume = resizeVolume; final lOther$resizeVolume = other.resizeVolume; - if (l$resizeVolume != lOther$resizeVolume) return false; + if (l$resizeVolume != lOther$resizeVolume) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$ResizeVolume on Mutation$ResizeVolume { CopyWith$Mutation$ResizeVolume get copyWith => - CopyWith$Mutation$ResizeVolume(this, (i) => i); + CopyWith$Mutation$ResizeVolume( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$ResizeVolume { - factory CopyWith$Mutation$ResizeVolume(Mutation$ResizeVolume instance, - TRes Function(Mutation$ResizeVolume) then) = - _CopyWithImpl$Mutation$ResizeVolume; + factory CopyWith$Mutation$ResizeVolume( + Mutation$ResizeVolume instance, + TRes Function(Mutation$ResizeVolume) then, + ) = _CopyWithImpl$Mutation$ResizeVolume; factory CopyWith$Mutation$ResizeVolume.stub(TRes res) = _CopyWithStubImpl$Mutation$ResizeVolume; - TRes call( - {Mutation$ResizeVolume$resizeVolume? resizeVolume, String? $__typename}); + TRes call({ + Mutation$ResizeVolume$resizeVolume? resizeVolume, + String? $__typename, + }); CopyWith$Mutation$ResizeVolume$resizeVolume get resizeVolume; } class _CopyWithImpl$Mutation$ResizeVolume implements CopyWith$Mutation$ResizeVolume { - _CopyWithImpl$Mutation$ResizeVolume(this._instance, this._then); + _CopyWithImpl$Mutation$ResizeVolume( + this._instance, + this._then, + ); final Mutation$ResizeVolume _instance; @@ -1832,16 +4079,18 @@ class _CopyWithImpl$Mutation$ResizeVolume static const _undefined = {}; - TRes call( - {Object? resizeVolume = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? resizeVolume = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$ResizeVolume( - resizeVolume: resizeVolume == _undefined || resizeVolume == null - ? _instance.resizeVolume - : (resizeVolume as Mutation$ResizeVolume$resizeVolume), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + resizeVolume: resizeVolume == _undefined || resizeVolume == null + ? _instance.resizeVolume + : (resizeVolume as Mutation$ResizeVolume$resizeVolume), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$ResizeVolume$resizeVolume get resizeVolume { final local$resizeVolume = _instance.resizeVolume; return CopyWith$Mutation$ResizeVolume$resizeVolume( @@ -1855,9 +4104,10 @@ class _CopyWithStubImpl$Mutation$ResizeVolume TRes _res; - call( - {Mutation$ResizeVolume$resizeVolume? resizeVolume, - String? $__typename}) => + call({ + Mutation$ResizeVolume$resizeVolume? resizeVolume, + String? $__typename, + }) => _res; CopyWith$Mutation$ResizeVolume$resizeVolume get resizeVolume => CopyWith$Mutation$ResizeVolume$resizeVolume.stub(_res); @@ -1865,86 +4115,97 @@ class _CopyWithStubImpl$Mutation$ResizeVolume const documentNodeMutationResizeVolume = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'ResizeVolume'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'name')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'resizeVolume'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'name'), - value: VariableNode(name: NameNode(value: 'name'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'ResizeVolume'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'name')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'resizeVolume'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'name'), + value: VariableNode(name: NameNode(value: 'name')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$ResizeVolume _parserFn$Mutation$ResizeVolume( Map data) => Mutation$ResizeVolume.fromJson(data); typedef OnMutationCompleted$Mutation$ResizeVolume = FutureOr Function( - dynamic, Mutation$ResizeVolume?); + dynamic, + Mutation$ResizeVolume?, +); class Options$Mutation$ResizeVolume extends graphql.MutationOptions { - Options$Mutation$ResizeVolume( - {String? operationName, - required Variables$Mutation$ResizeVolume variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$ResizeVolume? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$ResizeVolume({ + String? operationName, + required Variables$Mutation$ResizeVolume variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$ResizeVolume? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, - data == null - ? null - : _parserFn$Mutation$ResizeVolume(data)), - update: update, - onError: onError, - document: documentNodeMutationResizeVolume, - parserFn: _parserFn$Mutation$ResizeVolume); + data == null ? null : _parserFn$Mutation$ResizeVolume(data), + ), + update: update, + onError: onError, + document: documentNodeMutationResizeVolume, + parserFn: _parserFn$Mutation$ResizeVolume, + ); final OnMutationCompleted$Mutation$ResizeVolume? onCompletedWithParsed; @@ -1953,38 +4214,39 @@ class Options$Mutation$ResizeVolume ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$ResizeVolume extends graphql.WatchQueryOptions { - WatchOptions$Mutation$ResizeVolume( - {String? operationName, - required Variables$Mutation$ResizeVolume variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationResizeVolume, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$ResizeVolume); + WatchOptions$Mutation$ResizeVolume({ + String? operationName, + required Variables$Mutation$ResizeVolume variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationResizeVolume, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$ResizeVolume, + ); } extension ClientExtension$Mutation$ResizeVolume on graphql.GraphQLClient { @@ -1996,19 +4258,28 @@ extension ClientExtension$Mutation$ResizeVolume on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$ResizeVolume$resizeVolume - implements Fragment$basicMutationReturnFields { - Mutation$ResizeVolume$resizeVolume( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$ResizeVolume$resizeVolume({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$ResizeVolume$resizeVolume.fromJson( - Map json) => - _$Mutation$ResizeVolume$resizeVolumeFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$ResizeVolume$resizeVolume( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -2016,36 +4287,64 @@ class Mutation$ResizeVolume$resizeVolume final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$ResizeVolume$resizeVolumeToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$ResizeVolume$resizeVolume) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2054,25 +4353,35 @@ extension UtilityExtension$Mutation$ResizeVolume$resizeVolume on Mutation$ResizeVolume$resizeVolume { CopyWith$Mutation$ResizeVolume$resizeVolume< Mutation$ResizeVolume$resizeVolume> - get copyWith => - CopyWith$Mutation$ResizeVolume$resizeVolume(this, (i) => i); + get copyWith => CopyWith$Mutation$ResizeVolume$resizeVolume( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$ResizeVolume$resizeVolume { factory CopyWith$Mutation$ResizeVolume$resizeVolume( - Mutation$ResizeVolume$resizeVolume instance, - TRes Function(Mutation$ResizeVolume$resizeVolume) then) = - _CopyWithImpl$Mutation$ResizeVolume$resizeVolume; + Mutation$ResizeVolume$resizeVolume instance, + TRes Function(Mutation$ResizeVolume$resizeVolume) then, + ) = _CopyWithImpl$Mutation$ResizeVolume$resizeVolume; factory CopyWith$Mutation$ResizeVolume$resizeVolume.stub(TRes res) = _CopyWithStubImpl$Mutation$ResizeVolume$resizeVolume; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$ResizeVolume$resizeVolume implements CopyWith$Mutation$ResizeVolume$resizeVolume { - _CopyWithImpl$Mutation$ResizeVolume$resizeVolume(this._instance, this._then); + _CopyWithImpl$Mutation$ResizeVolume$resizeVolume( + this._instance, + this._then, + ); final Mutation$ResizeVolume$resizeVolume _instance; @@ -2080,24 +4389,25 @@ class _CopyWithImpl$Mutation$ResizeVolume$resizeVolume static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$ResizeVolume$resizeVolume( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$ResizeVolume$resizeVolume @@ -2106,48 +4416,74 @@ class _CopyWithStubImpl$Mutation$ResizeVolume$resizeVolume TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$UnmountVolume { - Variables$Mutation$UnmountVolume({required this.name}); + factory Variables$Mutation$UnmountVolume({required String name}) => + Variables$Mutation$UnmountVolume._({ + r'name': name, + }); + + Variables$Mutation$UnmountVolume._(this._$data); + + factory Variables$Mutation$UnmountVolume.fromJson(Map data) { + final result$data = {}; + final l$name = data['name']; + result$data['name'] = (l$name as String); + return Variables$Mutation$UnmountVolume._(result$data); + } + + Map _$data; + + String get name => (_$data['name'] as String); + Map toJson() { + final result$data = {}; + final l$name = name; + result$data['name'] = l$name; + return result$data; + } + + CopyWith$Variables$Mutation$UnmountVolume + get copyWith => CopyWith$Variables$Mutation$UnmountVolume( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$UnmountVolume) || + runtimeType != other.runtimeType) { + return false; + } + final l$name = name; + final lOther$name = other.name; + if (l$name != lOther$name) { + return false; + } + return true; + } @override - factory Variables$Mutation$UnmountVolume.fromJson( - Map json) => - _$Variables$Mutation$UnmountVolumeFromJson(json); - - final String name; - - Map toJson() => - _$Variables$Mutation$UnmountVolumeToJson(this); int get hashCode { final l$name = name; return Object.hashAll([l$name]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$UnmountVolume) || - runtimeType != other.runtimeType) return false; - final l$name = name; - final lOther$name = other.name; - if (l$name != lOther$name) return false; - return true; - } - - CopyWith$Variables$Mutation$UnmountVolume - get copyWith => CopyWith$Variables$Mutation$UnmountVolume(this, (i) => i); } abstract class CopyWith$Variables$Mutation$UnmountVolume { factory CopyWith$Variables$Mutation$UnmountVolume( - Variables$Mutation$UnmountVolume instance, - TRes Function(Variables$Mutation$UnmountVolume) then) = - _CopyWithImpl$Variables$Mutation$UnmountVolume; + Variables$Mutation$UnmountVolume instance, + TRes Function(Variables$Mutation$UnmountVolume) then, + ) = _CopyWithImpl$Variables$Mutation$UnmountVolume; factory CopyWith$Variables$Mutation$UnmountVolume.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$UnmountVolume; @@ -2157,7 +4493,10 @@ abstract class CopyWith$Variables$Mutation$UnmountVolume { class _CopyWithImpl$Variables$Mutation$UnmountVolume implements CopyWith$Variables$Mutation$UnmountVolume { - _CopyWithImpl$Variables$Mutation$UnmountVolume(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$UnmountVolume( + this._instance, + this._then, + ); final Variables$Mutation$UnmountVolume _instance; @@ -2166,10 +4505,10 @@ class _CopyWithImpl$Variables$Mutation$UnmountVolume static const _undefined = {}; TRes call({Object? name = _undefined}) => - _then(Variables$Mutation$UnmountVolume( - name: name == _undefined || name == null - ? _instance.name - : (name as String))); + _then(Variables$Mutation$UnmountVolume._({ + ..._instance._$data, + if (name != _undefined && name != null) 'name': (name as String), + })); } class _CopyWithStubImpl$Variables$Mutation$UnmountVolume @@ -2181,64 +4520,98 @@ class _CopyWithStubImpl$Variables$Mutation$UnmountVolume call({String? name}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$UnmountVolume { - Mutation$UnmountVolume( - {required this.unmountVolume, required this.$__typename}); + Mutation$UnmountVolume({ + required this.unmountVolume, + required this.$__typename, + }); - @override - factory Mutation$UnmountVolume.fromJson(Map json) => - _$Mutation$UnmountVolumeFromJson(json); + factory Mutation$UnmountVolume.fromJson(Map json) { + final l$unmountVolume = json['unmountVolume']; + final l$$__typename = json['__typename']; + return Mutation$UnmountVolume( + unmountVolume: Mutation$UnmountVolume$unmountVolume.fromJson( + (l$unmountVolume as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$UnmountVolume$unmountVolume unmountVolume; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$UnmountVolumeToJson(this); + Map toJson() { + final _resultData = {}; + final l$unmountVolume = unmountVolume; + _resultData['unmountVolume'] = l$unmountVolume.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$unmountVolume = unmountVolume; final l$$__typename = $__typename; - return Object.hashAll([l$unmountVolume, l$$__typename]); + return Object.hashAll([ + l$unmountVolume, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$UnmountVolume) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$UnmountVolume) || + runtimeType != other.runtimeType) { return false; + } final l$unmountVolume = unmountVolume; final lOther$unmountVolume = other.unmountVolume; - if (l$unmountVolume != lOther$unmountVolume) return false; + if (l$unmountVolume != lOther$unmountVolume) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$UnmountVolume on Mutation$UnmountVolume { CopyWith$Mutation$UnmountVolume get copyWith => - CopyWith$Mutation$UnmountVolume(this, (i) => i); + CopyWith$Mutation$UnmountVolume( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$UnmountVolume { - factory CopyWith$Mutation$UnmountVolume(Mutation$UnmountVolume instance, - TRes Function(Mutation$UnmountVolume) then) = - _CopyWithImpl$Mutation$UnmountVolume; + factory CopyWith$Mutation$UnmountVolume( + Mutation$UnmountVolume instance, + TRes Function(Mutation$UnmountVolume) then, + ) = _CopyWithImpl$Mutation$UnmountVolume; factory CopyWith$Mutation$UnmountVolume.stub(TRes res) = _CopyWithStubImpl$Mutation$UnmountVolume; - TRes call( - {Mutation$UnmountVolume$unmountVolume? unmountVolume, - String? $__typename}); + TRes call({ + Mutation$UnmountVolume$unmountVolume? unmountVolume, + String? $__typename, + }); CopyWith$Mutation$UnmountVolume$unmountVolume get unmountVolume; } class _CopyWithImpl$Mutation$UnmountVolume implements CopyWith$Mutation$UnmountVolume { - _CopyWithImpl$Mutation$UnmountVolume(this._instance, this._then); + _CopyWithImpl$Mutation$UnmountVolume( + this._instance, + this._then, + ); final Mutation$UnmountVolume _instance; @@ -2246,16 +4619,18 @@ class _CopyWithImpl$Mutation$UnmountVolume static const _undefined = {}; - TRes call( - {Object? unmountVolume = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? unmountVolume = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$UnmountVolume( - unmountVolume: unmountVolume == _undefined || unmountVolume == null - ? _instance.unmountVolume - : (unmountVolume as Mutation$UnmountVolume$unmountVolume), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + unmountVolume: unmountVolume == _undefined || unmountVolume == null + ? _instance.unmountVolume + : (unmountVolume as Mutation$UnmountVolume$unmountVolume), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$UnmountVolume$unmountVolume get unmountVolume { final local$unmountVolume = _instance.unmountVolume; return CopyWith$Mutation$UnmountVolume$unmountVolume( @@ -2269,9 +4644,10 @@ class _CopyWithStubImpl$Mutation$UnmountVolume TRes _res; - call( - {Mutation$UnmountVolume$unmountVolume? unmountVolume, - String? $__typename}) => + call({ + Mutation$UnmountVolume$unmountVolume? unmountVolume, + String? $__typename, + }) => _res; CopyWith$Mutation$UnmountVolume$unmountVolume get unmountVolume => CopyWith$Mutation$UnmountVolume$unmountVolume.stub(_res); @@ -2279,86 +4655,99 @@ class _CopyWithStubImpl$Mutation$UnmountVolume const documentNodeMutationUnmountVolume = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'UnmountVolume'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'name')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'unmountVolume'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'name'), - value: VariableNode(name: NameNode(value: 'name'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'UnmountVolume'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'name')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'unmountVolume'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'name'), + value: VariableNode(name: NameNode(value: 'name')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$UnmountVolume _parserFn$Mutation$UnmountVolume( Map data) => Mutation$UnmountVolume.fromJson(data); typedef OnMutationCompleted$Mutation$UnmountVolume = FutureOr Function( - dynamic, Mutation$UnmountVolume?); + dynamic, + Mutation$UnmountVolume?, +); class Options$Mutation$UnmountVolume extends graphql.MutationOptions { - Options$Mutation$UnmountVolume( - {String? operationName, - required Variables$Mutation$UnmountVolume variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$UnmountVolume? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$UnmountVolume({ + String? operationName, + required Variables$Mutation$UnmountVolume variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$UnmountVolume? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$UnmountVolume(data)), - update: update, - onError: onError, - document: documentNodeMutationUnmountVolume, - parserFn: _parserFn$Mutation$UnmountVolume); + : _parserFn$Mutation$UnmountVolume(data), + ), + update: update, + onError: onError, + document: documentNodeMutationUnmountVolume, + parserFn: _parserFn$Mutation$UnmountVolume, + ); final OnMutationCompleted$Mutation$UnmountVolume? onCompletedWithParsed; @@ -2367,38 +4756,39 @@ class Options$Mutation$UnmountVolume ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$UnmountVolume extends graphql.WatchQueryOptions { - WatchOptions$Mutation$UnmountVolume( - {String? operationName, - required Variables$Mutation$UnmountVolume variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationUnmountVolume, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$UnmountVolume); + WatchOptions$Mutation$UnmountVolume({ + String? operationName, + required Variables$Mutation$UnmountVolume variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationUnmountVolume, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$UnmountVolume, + ); } extension ClientExtension$Mutation$UnmountVolume on graphql.GraphQLClient { @@ -2410,19 +4800,28 @@ extension ClientExtension$Mutation$UnmountVolume on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$UnmountVolume$unmountVolume - implements Fragment$basicMutationReturnFields { - Mutation$UnmountVolume$unmountVolume( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$UnmountVolume$unmountVolume({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$UnmountVolume$unmountVolume.fromJson( - Map json) => - _$Mutation$UnmountVolume$unmountVolumeFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$UnmountVolume$unmountVolume( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -2430,36 +4829,64 @@ class Mutation$UnmountVolume$unmountVolume final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$UnmountVolume$unmountVolumeToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$UnmountVolume$unmountVolume) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2468,26 +4895,35 @@ extension UtilityExtension$Mutation$UnmountVolume$unmountVolume on Mutation$UnmountVolume$unmountVolume { CopyWith$Mutation$UnmountVolume$unmountVolume< Mutation$UnmountVolume$unmountVolume> - get copyWith => - CopyWith$Mutation$UnmountVolume$unmountVolume(this, (i) => i); + get copyWith => CopyWith$Mutation$UnmountVolume$unmountVolume( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$UnmountVolume$unmountVolume { factory CopyWith$Mutation$UnmountVolume$unmountVolume( - Mutation$UnmountVolume$unmountVolume instance, - TRes Function(Mutation$UnmountVolume$unmountVolume) then) = - _CopyWithImpl$Mutation$UnmountVolume$unmountVolume; + Mutation$UnmountVolume$unmountVolume instance, + TRes Function(Mutation$UnmountVolume$unmountVolume) then, + ) = _CopyWithImpl$Mutation$UnmountVolume$unmountVolume; factory CopyWith$Mutation$UnmountVolume$unmountVolume.stub(TRes res) = _CopyWithStubImpl$Mutation$UnmountVolume$unmountVolume; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$UnmountVolume$unmountVolume implements CopyWith$Mutation$UnmountVolume$unmountVolume { _CopyWithImpl$Mutation$UnmountVolume$unmountVolume( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$UnmountVolume$unmountVolume _instance; @@ -2495,24 +4931,25 @@ class _CopyWithImpl$Mutation$UnmountVolume$unmountVolume static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$UnmountVolume$unmountVolume( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$UnmountVolume$unmountVolume @@ -2521,49 +4958,78 @@ class _CopyWithStubImpl$Mutation$UnmountVolume$unmountVolume TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$MigrateToBinds { - Variables$Mutation$MigrateToBinds({required this.input}); + factory Variables$Mutation$MigrateToBinds( + {required Input$MigrateToBindsInput input}) => + Variables$Mutation$MigrateToBinds._({ + r'input': input, + }); + + Variables$Mutation$MigrateToBinds._(this._$data); + + factory Variables$Mutation$MigrateToBinds.fromJson( + Map data) { + final result$data = {}; + final l$input = data['input']; + result$data['input'] = + Input$MigrateToBindsInput.fromJson((l$input as Map)); + return Variables$Mutation$MigrateToBinds._(result$data); + } + + Map _$data; + + Input$MigrateToBindsInput get input => + (_$data['input'] as Input$MigrateToBindsInput); + Map toJson() { + final result$data = {}; + final l$input = input; + result$data['input'] = l$input.toJson(); + return result$data; + } + + CopyWith$Variables$Mutation$MigrateToBinds + get copyWith => CopyWith$Variables$Mutation$MigrateToBinds( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$MigrateToBinds) || + runtimeType != other.runtimeType) { + return false; + } + final l$input = input; + final lOther$input = other.input; + if (l$input != lOther$input) { + return false; + } + return true; + } @override - factory Variables$Mutation$MigrateToBinds.fromJson( - Map json) => - _$Variables$Mutation$MigrateToBindsFromJson(json); - - final Input$MigrateToBindsInput input; - - Map toJson() => - _$Variables$Mutation$MigrateToBindsToJson(this); int get hashCode { final l$input = input; return Object.hashAll([l$input]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$MigrateToBinds) || - runtimeType != other.runtimeType) return false; - final l$input = input; - final lOther$input = other.input; - if (l$input != lOther$input) return false; - return true; - } - - CopyWith$Variables$Mutation$MigrateToBinds - get copyWith => - CopyWith$Variables$Mutation$MigrateToBinds(this, (i) => i); } abstract class CopyWith$Variables$Mutation$MigrateToBinds { factory CopyWith$Variables$Mutation$MigrateToBinds( - Variables$Mutation$MigrateToBinds instance, - TRes Function(Variables$Mutation$MigrateToBinds) then) = - _CopyWithImpl$Variables$Mutation$MigrateToBinds; + Variables$Mutation$MigrateToBinds instance, + TRes Function(Variables$Mutation$MigrateToBinds) then, + ) = _CopyWithImpl$Variables$Mutation$MigrateToBinds; factory CopyWith$Variables$Mutation$MigrateToBinds.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$MigrateToBinds; @@ -2573,7 +5039,10 @@ abstract class CopyWith$Variables$Mutation$MigrateToBinds { class _CopyWithImpl$Variables$Mutation$MigrateToBinds implements CopyWith$Variables$Mutation$MigrateToBinds { - _CopyWithImpl$Variables$Mutation$MigrateToBinds(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$MigrateToBinds( + this._instance, + this._then, + ); final Variables$Mutation$MigrateToBinds _instance; @@ -2582,10 +5051,11 @@ class _CopyWithImpl$Variables$Mutation$MigrateToBinds static const _undefined = {}; TRes call({Object? input = _undefined}) => - _then(Variables$Mutation$MigrateToBinds( - input: input == _undefined || input == null - ? _instance.input - : (input as Input$MigrateToBindsInput))); + _then(Variables$Mutation$MigrateToBinds._({ + ..._instance._$data, + if (input != _undefined && input != null) + 'input': (input as Input$MigrateToBindsInput), + })); } class _CopyWithStubImpl$Variables$Mutation$MigrateToBinds @@ -2597,64 +5067,98 @@ class _CopyWithStubImpl$Variables$Mutation$MigrateToBinds call({Input$MigrateToBindsInput? input}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$MigrateToBinds { - Mutation$MigrateToBinds( - {required this.migrateToBinds, required this.$__typename}); + Mutation$MigrateToBinds({ + required this.migrateToBinds, + required this.$__typename, + }); - @override - factory Mutation$MigrateToBinds.fromJson(Map json) => - _$Mutation$MigrateToBindsFromJson(json); + factory Mutation$MigrateToBinds.fromJson(Map json) { + final l$migrateToBinds = json['migrateToBinds']; + final l$$__typename = json['__typename']; + return Mutation$MigrateToBinds( + migrateToBinds: Mutation$MigrateToBinds$migrateToBinds.fromJson( + (l$migrateToBinds as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$MigrateToBinds$migrateToBinds migrateToBinds; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$MigrateToBindsToJson(this); + Map toJson() { + final _resultData = {}; + final l$migrateToBinds = migrateToBinds; + _resultData['migrateToBinds'] = l$migrateToBinds.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$migrateToBinds = migrateToBinds; final l$$__typename = $__typename; - return Object.hashAll([l$migrateToBinds, l$$__typename]); + return Object.hashAll([ + l$migrateToBinds, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$MigrateToBinds) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$MigrateToBinds) || + runtimeType != other.runtimeType) { return false; + } final l$migrateToBinds = migrateToBinds; final lOther$migrateToBinds = other.migrateToBinds; - if (l$migrateToBinds != lOther$migrateToBinds) return false; + if (l$migrateToBinds != lOther$migrateToBinds) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$MigrateToBinds on Mutation$MigrateToBinds { CopyWith$Mutation$MigrateToBinds get copyWith => - CopyWith$Mutation$MigrateToBinds(this, (i) => i); + CopyWith$Mutation$MigrateToBinds( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$MigrateToBinds { - factory CopyWith$Mutation$MigrateToBinds(Mutation$MigrateToBinds instance, - TRes Function(Mutation$MigrateToBinds) then) = - _CopyWithImpl$Mutation$MigrateToBinds; + factory CopyWith$Mutation$MigrateToBinds( + Mutation$MigrateToBinds instance, + TRes Function(Mutation$MigrateToBinds) then, + ) = _CopyWithImpl$Mutation$MigrateToBinds; factory CopyWith$Mutation$MigrateToBinds.stub(TRes res) = _CopyWithStubImpl$Mutation$MigrateToBinds; - TRes call( - {Mutation$MigrateToBinds$migrateToBinds? migrateToBinds, - String? $__typename}); + TRes call({ + Mutation$MigrateToBinds$migrateToBinds? migrateToBinds, + String? $__typename, + }); CopyWith$Mutation$MigrateToBinds$migrateToBinds get migrateToBinds; } class _CopyWithImpl$Mutation$MigrateToBinds implements CopyWith$Mutation$MigrateToBinds { - _CopyWithImpl$Mutation$MigrateToBinds(this._instance, this._then); + _CopyWithImpl$Mutation$MigrateToBinds( + this._instance, + this._then, + ); final Mutation$MigrateToBinds _instance; @@ -2662,16 +5166,18 @@ class _CopyWithImpl$Mutation$MigrateToBinds static const _undefined = {}; - TRes call( - {Object? migrateToBinds = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? migrateToBinds = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$MigrateToBinds( - migrateToBinds: migrateToBinds == _undefined || migrateToBinds == null - ? _instance.migrateToBinds - : (migrateToBinds as Mutation$MigrateToBinds$migrateToBinds), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + migrateToBinds: migrateToBinds == _undefined || migrateToBinds == null + ? _instance.migrateToBinds + : (migrateToBinds as Mutation$MigrateToBinds$migrateToBinds), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$MigrateToBinds$migrateToBinds get migrateToBinds { final local$migrateToBinds = _instance.migrateToBinds; return CopyWith$Mutation$MigrateToBinds$migrateToBinds( @@ -2685,9 +5191,10 @@ class _CopyWithStubImpl$Mutation$MigrateToBinds TRes _res; - call( - {Mutation$MigrateToBinds$migrateToBinds? migrateToBinds, - String? $__typename}) => + call({ + Mutation$MigrateToBinds$migrateToBinds? migrateToBinds, + String? $__typename, + }) => _res; CopyWith$Mutation$MigrateToBinds$migrateToBinds get migrateToBinds => CopyWith$Mutation$MigrateToBinds$migrateToBinds.stub(_res); @@ -2695,165 +5202,191 @@ class _CopyWithStubImpl$Mutation$MigrateToBinds const documentNodeMutationMigrateToBinds = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'MigrateToBinds'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'input')), - type: NamedTypeNode( - name: NameNode(value: 'MigrateToBindsInput'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'migrateToBinds'), + type: OperationType.mutation, + name: NameNode(value: 'MigrateToBinds'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'input')), + type: NamedTypeNode( + name: NameNode(value: 'MigrateToBindsInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'migrateToBinds'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'input'), + value: VariableNode(name: NameNode(value: 'input')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: 'job'), alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'input'), - value: VariableNode(name: NameNode(value: 'input'))) - ], + arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), FieldNode( - name: NameNode(value: 'job'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'createdAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'description'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'error'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'finishedAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'name'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'progress'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'result'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'status'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'statusText'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'uid'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'updatedAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'createdAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'description'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'error'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'finishedAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'name'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'progress'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'result'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'status'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'statusText'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'uid'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'updatedAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$MigrateToBinds _parserFn$Mutation$MigrateToBinds( Map data) => Mutation$MigrateToBinds.fromJson(data); typedef OnMutationCompleted$Mutation$MigrateToBinds = FutureOr Function( - dynamic, Mutation$MigrateToBinds?); + dynamic, + Mutation$MigrateToBinds?, +); class Options$Mutation$MigrateToBinds extends graphql.MutationOptions { - Options$Mutation$MigrateToBinds( - {String? operationName, - required Variables$Mutation$MigrateToBinds variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$MigrateToBinds? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$MigrateToBinds({ + String? operationName, + required Variables$Mutation$MigrateToBinds variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$MigrateToBinds? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$MigrateToBinds(data)), - update: update, - onError: onError, - document: documentNodeMutationMigrateToBinds, - parserFn: _parserFn$Mutation$MigrateToBinds); + : _parserFn$Mutation$MigrateToBinds(data), + ), + update: update, + onError: onError, + document: documentNodeMutationMigrateToBinds, + parserFn: _parserFn$Mutation$MigrateToBinds, + ); final OnMutationCompleted$Mutation$MigrateToBinds? onCompletedWithParsed; @@ -2862,38 +5395,39 @@ class Options$Mutation$MigrateToBinds ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$MigrateToBinds extends graphql.WatchQueryOptions { - WatchOptions$Mutation$MigrateToBinds( - {String? operationName, - required Variables$Mutation$MigrateToBinds variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationMigrateToBinds, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$MigrateToBinds); + WatchOptions$Mutation$MigrateToBinds({ + String? operationName, + required Variables$Mutation$MigrateToBinds variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationMigrateToBinds, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$MigrateToBinds, + ); } extension ClientExtension$Mutation$MigrateToBinds on graphql.GraphQLClient { @@ -2905,20 +5439,34 @@ extension ClientExtension$Mutation$MigrateToBinds on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$MigrateToBinds$migrateToBinds - implements Fragment$basicMutationReturnFields { - Mutation$MigrateToBinds$migrateToBinds( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.job}); + implements Fragment$basicMutationReturnFields$$GenericJobButationReturn { + Mutation$MigrateToBinds$migrateToBinds({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.job, + }); - @override factory Mutation$MigrateToBinds$migrateToBinds.fromJson( - Map json) => - _$Mutation$MigrateToBinds$migrateToBindsFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$job = json['job']; + return Mutation$MigrateToBinds$migrateToBinds( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + job: l$job == null + ? null + : Mutation$MigrateToBinds$migrateToBinds$job.fromJson( + (l$job as Map)), + ); + } final int code; @@ -2926,42 +5474,75 @@ class Mutation$MigrateToBinds$migrateToBinds final bool success; - @JsonKey(name: '__typename') final String $__typename; final Mutation$MigrateToBinds$migrateToBinds$job? job; - Map toJson() => - _$Mutation$MigrateToBinds$migrateToBindsToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$job = job; + _resultData['job'] = l$job?.toJson(); + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$job = job; - return Object.hashAll([l$code, l$message, l$success, l$$__typename, l$job]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$job, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$MigrateToBinds$migrateToBinds) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$job = job; final lOther$job = other.job; - if (l$job != lOther$job) return false; + if (l$job != lOther$job) { + return false; + } return true; } } @@ -2970,32 +5551,37 @@ extension UtilityExtension$Mutation$MigrateToBinds$migrateToBinds on Mutation$MigrateToBinds$migrateToBinds { CopyWith$Mutation$MigrateToBinds$migrateToBinds< Mutation$MigrateToBinds$migrateToBinds> - get copyWith => - CopyWith$Mutation$MigrateToBinds$migrateToBinds(this, (i) => i); + get copyWith => CopyWith$Mutation$MigrateToBinds$migrateToBinds( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$MigrateToBinds$migrateToBinds { factory CopyWith$Mutation$MigrateToBinds$migrateToBinds( - Mutation$MigrateToBinds$migrateToBinds instance, - TRes Function(Mutation$MigrateToBinds$migrateToBinds) then) = - _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds; + Mutation$MigrateToBinds$migrateToBinds instance, + TRes Function(Mutation$MigrateToBinds$migrateToBinds) then, + ) = _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds; factory CopyWith$Mutation$MigrateToBinds$migrateToBinds.stub(TRes res) = _CopyWithStubImpl$Mutation$MigrateToBinds$migrateToBinds; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - Mutation$MigrateToBinds$migrateToBinds$job? job}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + Mutation$MigrateToBinds$migrateToBinds$job? job, + }); CopyWith$Mutation$MigrateToBinds$migrateToBinds$job get job; } class _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds implements CopyWith$Mutation$MigrateToBinds$migrateToBinds { _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$MigrateToBinds$migrateToBinds _instance; @@ -3003,28 +5589,29 @@ class _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? job = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? job = _undefined, + }) => _then(Mutation$MigrateToBinds$migrateToBinds( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - job: job == _undefined - ? _instance.job - : (job as Mutation$MigrateToBinds$migrateToBinds$job?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + job: job == _undefined + ? _instance.job + : (job as Mutation$MigrateToBinds$migrateToBinds$job?), + )); CopyWith$Mutation$MigrateToBinds$migrateToBinds$job get job { final local$job = _instance.job; return local$job == null @@ -3041,47 +5628,70 @@ class _CopyWithStubImpl$Mutation$MigrateToBinds$migrateToBinds TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - Mutation$MigrateToBinds$migrateToBinds$job? job}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + Mutation$MigrateToBinds$migrateToBinds$job? job, + }) => _res; CopyWith$Mutation$MigrateToBinds$migrateToBinds$job get job => CopyWith$Mutation$MigrateToBinds$migrateToBinds$job.stub(_res); } -@JsonSerializable(explicitToJson: true) class Mutation$MigrateToBinds$migrateToBinds$job { - Mutation$MigrateToBinds$migrateToBinds$job( - {required this.createdAt, - required this.description, - this.error, - this.finishedAt, - required this.name, - this.progress, - this.result, - required this.status, - this.statusText, - required this.uid, - required this.updatedAt, - required this.$__typename}); + Mutation$MigrateToBinds$migrateToBinds$job({ + required this.createdAt, + required this.description, + this.error, + this.finishedAt, + required this.name, + this.progress, + this.result, + required this.status, + this.statusText, + required this.uid, + required this.updatedAt, + required this.$__typename, + }); - @override factory Mutation$MigrateToBinds$migrateToBinds$job.fromJson( - Map json) => - _$Mutation$MigrateToBinds$migrateToBinds$jobFromJson(json); + Map json) { + final l$createdAt = json['createdAt']; + final l$description = json['description']; + final l$error = json['error']; + final l$finishedAt = json['finishedAt']; + final l$name = json['name']; + final l$progress = json['progress']; + final l$result = json['result']; + final l$status = json['status']; + final l$statusText = json['statusText']; + final l$uid = json['uid']; + final l$updatedAt = json['updatedAt']; + final l$$__typename = json['__typename']; + return Mutation$MigrateToBinds$migrateToBinds$job( + createdAt: dateTimeFromJson(l$createdAt), + description: (l$description as String), + error: (l$error as String?), + finishedAt: l$finishedAt == null ? null : dateTimeFromJson(l$finishedAt), + name: (l$name as String), + progress: (l$progress as int?), + result: (l$result as String?), + status: (l$status as String), + statusText: (l$statusText as String?), + uid: (l$uid as String), + updatedAt: dateTimeFromJson(l$updatedAt), + $__typename: (l$$__typename as String), + ); + } - @JsonKey(fromJson: dateTimeFromJson, toJson: dateTimeToJson) final DateTime createdAt; final String description; final String? error; - @JsonKey( - fromJson: _nullable$dateTimeFromJson, toJson: _nullable$dateTimeToJson) final DateTime? finishedAt; final String name; @@ -3096,14 +5706,41 @@ class Mutation$MigrateToBinds$migrateToBinds$job { final String uid; - @JsonKey(fromJson: dateTimeFromJson, toJson: dateTimeToJson) final DateTime updatedAt; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$MigrateToBinds$migrateToBinds$jobToJson(this); + Map toJson() { + final _resultData = {}; + final l$createdAt = createdAt; + _resultData['createdAt'] = dateTimeToJson(l$createdAt); + final l$description = description; + _resultData['description'] = l$description; + final l$error = error; + _resultData['error'] = l$error; + final l$finishedAt = finishedAt; + _resultData['finishedAt'] = + l$finishedAt == null ? null : dateTimeToJson(l$finishedAt); + final l$name = name; + _resultData['name'] = l$name; + final l$progress = progress; + _resultData['progress'] = l$progress; + final l$result = result; + _resultData['result'] = l$result; + final l$status = status; + _resultData['status'] = l$status; + final l$statusText = statusText; + _resultData['statusText'] = l$statusText; + final l$uid = uid; + _resultData['uid'] = l$uid; + final l$updatedAt = updatedAt; + _resultData['updatedAt'] = dateTimeToJson(l$updatedAt); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$createdAt = createdAt; final l$description = description; @@ -3129,51 +5766,79 @@ class Mutation$MigrateToBinds$migrateToBinds$job { l$statusText, l$uid, l$updatedAt, - l$$__typename + l$$__typename, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$MigrateToBinds$migrateToBinds$job) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$createdAt = createdAt; final lOther$createdAt = other.createdAt; - if (l$createdAt != lOther$createdAt) return false; + if (l$createdAt != lOther$createdAt) { + return false; + } final l$description = description; final lOther$description = other.description; - if (l$description != lOther$description) return false; + if (l$description != lOther$description) { + return false; + } final l$error = error; final lOther$error = other.error; - if (l$error != lOther$error) return false; + if (l$error != lOther$error) { + return false; + } final l$finishedAt = finishedAt; final lOther$finishedAt = other.finishedAt; - if (l$finishedAt != lOther$finishedAt) return false; + if (l$finishedAt != lOther$finishedAt) { + return false; + } final l$name = name; final lOther$name = other.name; - if (l$name != lOther$name) return false; + if (l$name != lOther$name) { + return false; + } final l$progress = progress; final lOther$progress = other.progress; - if (l$progress != lOther$progress) return false; + if (l$progress != lOther$progress) { + return false; + } final l$result = result; final lOther$result = other.result; - if (l$result != lOther$result) return false; + if (l$result != lOther$result) { + return false; + } final l$status = status; final lOther$status = other.status; - if (l$status != lOther$status) return false; + if (l$status != lOther$status) { + return false; + } final l$statusText = statusText; final lOther$statusText = other.statusText; - if (l$statusText != lOther$statusText) return false; + if (l$statusText != lOther$statusText) { + return false; + } final l$uid = uid; final lOther$uid = other.uid; - if (l$uid != lOther$uid) return false; + if (l$uid != lOther$uid) { + return false; + } final l$updatedAt = updatedAt; final lOther$updatedAt = other.updatedAt; - if (l$updatedAt != lOther$updatedAt) return false; + if (l$updatedAt != lOther$updatedAt) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -3182,38 +5847,43 @@ extension UtilityExtension$Mutation$MigrateToBinds$migrateToBinds$job on Mutation$MigrateToBinds$migrateToBinds$job { CopyWith$Mutation$MigrateToBinds$migrateToBinds$job< Mutation$MigrateToBinds$migrateToBinds$job> - get copyWith => - CopyWith$Mutation$MigrateToBinds$migrateToBinds$job(this, (i) => i); + get copyWith => CopyWith$Mutation$MigrateToBinds$migrateToBinds$job( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$MigrateToBinds$migrateToBinds$job { factory CopyWith$Mutation$MigrateToBinds$migrateToBinds$job( - Mutation$MigrateToBinds$migrateToBinds$job instance, - TRes Function(Mutation$MigrateToBinds$migrateToBinds$job) then) = - _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds$job; + Mutation$MigrateToBinds$migrateToBinds$job instance, + TRes Function(Mutation$MigrateToBinds$migrateToBinds$job) then, + ) = _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds$job; factory CopyWith$Mutation$MigrateToBinds$migrateToBinds$job.stub(TRes res) = _CopyWithStubImpl$Mutation$MigrateToBinds$migrateToBinds$job; - TRes call( - {DateTime? createdAt, - String? description, - String? error, - DateTime? finishedAt, - String? name, - int? progress, - String? result, - String? status, - String? statusText, - String? uid, - DateTime? updatedAt, - String? $__typename}); + TRes call({ + DateTime? createdAt, + String? description, + String? error, + DateTime? finishedAt, + String? name, + int? progress, + String? result, + String? status, + String? statusText, + String? uid, + DateTime? updatedAt, + String? $__typename, + }); } class _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds$job implements CopyWith$Mutation$MigrateToBinds$migrateToBinds$job { _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds$job( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$MigrateToBinds$migrateToBinds$job _instance; @@ -3221,51 +5891,51 @@ class _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds$job static const _undefined = {}; - TRes call( - {Object? createdAt = _undefined, - Object? description = _undefined, - Object? error = _undefined, - Object? finishedAt = _undefined, - Object? name = _undefined, - Object? progress = _undefined, - Object? result = _undefined, - Object? status = _undefined, - Object? statusText = _undefined, - Object? uid = _undefined, - Object? updatedAt = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? createdAt = _undefined, + Object? description = _undefined, + Object? error = _undefined, + Object? finishedAt = _undefined, + Object? name = _undefined, + Object? progress = _undefined, + Object? result = _undefined, + Object? status = _undefined, + Object? statusText = _undefined, + Object? uid = _undefined, + Object? updatedAt = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$MigrateToBinds$migrateToBinds$job( - createdAt: createdAt == _undefined || createdAt == null - ? _instance.createdAt - : (createdAt as DateTime), - description: description == _undefined || description == null - ? _instance.description - : (description as String), - error: error == _undefined ? _instance.error : (error as String?), - finishedAt: finishedAt == _undefined - ? _instance.finishedAt - : (finishedAt as DateTime?), - name: name == _undefined || name == null - ? _instance.name - : (name as String), - progress: - progress == _undefined ? _instance.progress : (progress as int?), - result: result == _undefined ? _instance.result : (result as String?), - status: status == _undefined || status == null - ? _instance.status - : (status as String), - statusText: statusText == _undefined - ? _instance.statusText - : (statusText as String?), - uid: uid == _undefined || uid == null - ? _instance.uid - : (uid as String), - updatedAt: updatedAt == _undefined || updatedAt == null - ? _instance.updatedAt - : (updatedAt as DateTime), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + createdAt: createdAt == _undefined || createdAt == null + ? _instance.createdAt + : (createdAt as DateTime), + description: description == _undefined || description == null + ? _instance.description + : (description as String), + error: error == _undefined ? _instance.error : (error as String?), + finishedAt: finishedAt == _undefined + ? _instance.finishedAt + : (finishedAt as DateTime?), + name: name == _undefined || name == null + ? _instance.name + : (name as String), + progress: + progress == _undefined ? _instance.progress : (progress as int?), + result: result == _undefined ? _instance.result : (result as String?), + status: status == _undefined || status == null + ? _instance.status + : (status as String), + statusText: statusText == _undefined + ? _instance.statusText + : (statusText as String?), + uid: uid == _undefined || uid == null ? _instance.uid : (uid as String), + updatedAt: updatedAt == _undefined || updatedAt == null + ? _instance.updatedAt + : (updatedAt as DateTime), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$MigrateToBinds$migrateToBinds$job @@ -3274,23 +5944,19 @@ class _CopyWithStubImpl$Mutation$MigrateToBinds$migrateToBinds$job TRes _res; - call( - {DateTime? createdAt, - String? description, - String? error, - DateTime? finishedAt, - String? name, - int? progress, - String? result, - String? status, - String? statusText, - String? uid, - DateTime? updatedAt, - String? $__typename}) => + call({ + DateTime? createdAt, + String? description, + String? error, + DateTime? finishedAt, + String? name, + int? progress, + String? result, + String? status, + String? statusText, + String? uid, + DateTime? updatedAt, + String? $__typename, + }) => _res; } - -DateTime? _nullable$dateTimeFromJson(dynamic data) => - data == null ? null : dateTimeFromJson(data); -dynamic _nullable$dateTimeToJson(DateTime? data) => - data == null ? null : dateTimeToJson(data); diff --git a/lib/logic/api_maps/graphql_maps/schema/disk_volumes.graphql.g.dart b/lib/logic/api_maps/graphql_maps/schema/disk_volumes.graphql.g.dart deleted file mode 100644 index c1ab4fba..00000000 --- a/lib/logic/api_maps/graphql_maps/schema/disk_volumes.graphql.g.dart +++ /dev/null @@ -1,376 +0,0 @@ -// GENERATED CODE - DO NOT MODIFY BY HAND - -part of 'disk_volumes.graphql.dart'; - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -Fragment$basicMutationReturnFields _$Fragment$basicMutationReturnFieldsFromJson( - Map json) => - Fragment$basicMutationReturnFields( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Fragment$basicMutationReturnFieldsToJson( - Fragment$basicMutationReturnFields instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Query$GetServerDiskVolumes _$Query$GetServerDiskVolumesFromJson( - Map json) => - Query$GetServerDiskVolumes( - storage: Query$GetServerDiskVolumes$storage.fromJson( - json['storage'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetServerDiskVolumesToJson( - Query$GetServerDiskVolumes instance) => - { - 'storage': instance.storage.toJson(), - '__typename': instance.$__typename, - }; - -Query$GetServerDiskVolumes$storage _$Query$GetServerDiskVolumes$storageFromJson( - Map json) => - Query$GetServerDiskVolumes$storage( - volumes: (json['volumes'] as List) - .map((e) => Query$GetServerDiskVolumes$storage$volumes.fromJson( - e as Map)) - .toList(), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetServerDiskVolumes$storageToJson( - Query$GetServerDiskVolumes$storage instance) => - { - 'volumes': instance.volumes.map((e) => e.toJson()).toList(), - '__typename': instance.$__typename, - }; - -Query$GetServerDiskVolumes$storage$volumes - _$Query$GetServerDiskVolumes$storage$volumesFromJson( - Map json) => - Query$GetServerDiskVolumes$storage$volumes( - freeSpace: json['freeSpace'] as String, - model: json['model'] as String?, - name: json['name'] as String, - root: json['root'] as bool, - serial: json['serial'] as String?, - totalSpace: json['totalSpace'] as String, - type: json['type'] as String, - usages: (json['usages'] as List) - .map((e) => - Query$GetServerDiskVolumes$storage$volumes$usages.fromJson( - e as Map)) - .toList(), - usedSpace: json['usedSpace'] as String, - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetServerDiskVolumes$storage$volumesToJson( - Query$GetServerDiskVolumes$storage$volumes instance) => - { - 'freeSpace': instance.freeSpace, - 'model': instance.model, - 'name': instance.name, - 'root': instance.root, - 'serial': instance.serial, - 'totalSpace': instance.totalSpace, - 'type': instance.type, - 'usages': instance.usages.map((e) => e.toJson()).toList(), - 'usedSpace': instance.usedSpace, - '__typename': instance.$__typename, - }; - -Query$GetServerDiskVolumes$storage$volumes$usages - _$Query$GetServerDiskVolumes$storage$volumes$usagesFromJson( - Map json) => - Query$GetServerDiskVolumes$storage$volumes$usages( - title: json['title'] as String, - usedSpace: json['usedSpace'] as String, - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetServerDiskVolumes$storage$volumes$usagesToJson( - Query$GetServerDiskVolumes$storage$volumes$usages instance) => - { - 'title': instance.title, - 'usedSpace': instance.usedSpace, - '__typename': instance.$__typename, - }; - -Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage - _$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsageFromJson( - Map json) => - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage( - title: json['title'] as String, - usedSpace: json['usedSpace'] as String, - $__typename: json['__typename'] as String, - service: json['service'] == null - ? null - : Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service - .fromJson(json['service'] as Map), - ); - -Map - _$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsageToJson( - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage - instance) => - { - 'title': instance.title, - 'usedSpace': instance.usedSpace, - '__typename': instance.$__typename, - 'service': instance.service?.toJson(), - }; - -Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service - _$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$serviceFromJson( - Map json) => - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service( - id: json['id'] as String, - isMovable: json['isMovable'] as bool, - displayName: json['displayName'] as String, - $__typename: json['__typename'] as String, - ); - -Map - _$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$serviceToJson( - Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service - instance) => - { - 'id': instance.id, - 'isMovable': instance.isMovable, - 'displayName': instance.displayName, - '__typename': instance.$__typename, - }; - -Variables$Mutation$MountVolume _$Variables$Mutation$MountVolumeFromJson( - Map json) => - Variables$Mutation$MountVolume( - name: json['name'] as String, - ); - -Map _$Variables$Mutation$MountVolumeToJson( - Variables$Mutation$MountVolume instance) => - { - 'name': instance.name, - }; - -Mutation$MountVolume _$Mutation$MountVolumeFromJson( - Map json) => - Mutation$MountVolume( - mountVolume: Mutation$MountVolume$mountVolume.fromJson( - json['mountVolume'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$MountVolumeToJson( - Mutation$MountVolume instance) => - { - 'mountVolume': instance.mountVolume.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$MountVolume$mountVolume _$Mutation$MountVolume$mountVolumeFromJson( - Map json) => - Mutation$MountVolume$mountVolume( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$MountVolume$mountVolumeToJson( - Mutation$MountVolume$mountVolume instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$ResizeVolume _$Variables$Mutation$ResizeVolumeFromJson( - Map json) => - Variables$Mutation$ResizeVolume( - name: json['name'] as String, - ); - -Map _$Variables$Mutation$ResizeVolumeToJson( - Variables$Mutation$ResizeVolume instance) => - { - 'name': instance.name, - }; - -Mutation$ResizeVolume _$Mutation$ResizeVolumeFromJson( - Map json) => - Mutation$ResizeVolume( - resizeVolume: Mutation$ResizeVolume$resizeVolume.fromJson( - json['resizeVolume'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$ResizeVolumeToJson( - Mutation$ResizeVolume instance) => - { - 'resizeVolume': instance.resizeVolume.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$ResizeVolume$resizeVolume _$Mutation$ResizeVolume$resizeVolumeFromJson( - Map json) => - Mutation$ResizeVolume$resizeVolume( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$ResizeVolume$resizeVolumeToJson( - Mutation$ResizeVolume$resizeVolume instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$UnmountVolume _$Variables$Mutation$UnmountVolumeFromJson( - Map json) => - Variables$Mutation$UnmountVolume( - name: json['name'] as String, - ); - -Map _$Variables$Mutation$UnmountVolumeToJson( - Variables$Mutation$UnmountVolume instance) => - { - 'name': instance.name, - }; - -Mutation$UnmountVolume _$Mutation$UnmountVolumeFromJson( - Map json) => - Mutation$UnmountVolume( - unmountVolume: Mutation$UnmountVolume$unmountVolume.fromJson( - json['unmountVolume'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$UnmountVolumeToJson( - Mutation$UnmountVolume instance) => - { - 'unmountVolume': instance.unmountVolume.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$UnmountVolume$unmountVolume - _$Mutation$UnmountVolume$unmountVolumeFromJson(Map json) => - Mutation$UnmountVolume$unmountVolume( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$UnmountVolume$unmountVolumeToJson( - Mutation$UnmountVolume$unmountVolume instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$MigrateToBinds _$Variables$Mutation$MigrateToBindsFromJson( - Map json) => - Variables$Mutation$MigrateToBinds( - input: Input$MigrateToBindsInput.fromJson( - json['input'] as Map), - ); - -Map _$Variables$Mutation$MigrateToBindsToJson( - Variables$Mutation$MigrateToBinds instance) => - { - 'input': instance.input.toJson(), - }; - -Mutation$MigrateToBinds _$Mutation$MigrateToBindsFromJson( - Map json) => - Mutation$MigrateToBinds( - migrateToBinds: Mutation$MigrateToBinds$migrateToBinds.fromJson( - json['migrateToBinds'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$MigrateToBindsToJson( - Mutation$MigrateToBinds instance) => - { - 'migrateToBinds': instance.migrateToBinds.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$MigrateToBinds$migrateToBinds - _$Mutation$MigrateToBinds$migrateToBindsFromJson( - Map json) => - Mutation$MigrateToBinds$migrateToBinds( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - job: json['job'] == null - ? null - : Mutation$MigrateToBinds$migrateToBinds$job.fromJson( - json['job'] as Map), - ); - -Map _$Mutation$MigrateToBinds$migrateToBindsToJson( - Mutation$MigrateToBinds$migrateToBinds instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'job': instance.job?.toJson(), - }; - -Mutation$MigrateToBinds$migrateToBinds$job - _$Mutation$MigrateToBinds$migrateToBinds$jobFromJson( - Map json) => - Mutation$MigrateToBinds$migrateToBinds$job( - createdAt: dateTimeFromJson(json['createdAt']), - description: json['description'] as String, - error: json['error'] as String?, - finishedAt: _nullable$dateTimeFromJson(json['finishedAt']), - name: json['name'] as String, - progress: json['progress'] as int?, - result: json['result'] as String?, - status: json['status'] as String, - statusText: json['statusText'] as String?, - uid: json['uid'] as String, - updatedAt: dateTimeFromJson(json['updatedAt']), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$MigrateToBinds$migrateToBinds$jobToJson( - Mutation$MigrateToBinds$migrateToBinds$job instance) => - { - 'createdAt': dateTimeToJson(instance.createdAt), - 'description': instance.description, - 'error': instance.error, - 'finishedAt': _nullable$dateTimeToJson(instance.finishedAt), - 'name': instance.name, - 'progress': instance.progress, - 'result': instance.result, - 'status': instance.status, - 'statusText': instance.statusText, - 'uid': instance.uid, - 'updatedAt': dateTimeToJson(instance.updatedAt), - '__typename': instance.$__typename, - }; diff --git a/lib/logic/api_maps/graphql_maps/schema/schema.graphql.dart b/lib/logic/api_maps/graphql_maps/schema/schema.graphql.dart index 11d49a43..1b92ccad 100644 --- a/lib/logic/api_maps/graphql_maps/schema/schema.graphql.dart +++ b/lib/logic/api_maps/graphql_maps/schema/schema.graphql.dart @@ -1,61 +1,116 @@ import 'package:gql/ast.dart'; import 'package:graphql/client.dart' as graphql; -import 'package:json_annotation/json_annotation.dart'; import 'package:selfprivacy/utils/scalars.dart'; -part 'schema.graphql.g.dart'; -@JsonSerializable(explicitToJson: true) class Input$AutoUpgradeSettingsInput { - Input$AutoUpgradeSettingsInput({this.enableAutoUpgrade, this.allowReboot}); + factory Input$AutoUpgradeSettingsInput({ + bool? enableAutoUpgrade, + bool? allowReboot, + }) => + Input$AutoUpgradeSettingsInput._({ + if (enableAutoUpgrade != null) r'enableAutoUpgrade': enableAutoUpgrade, + if (allowReboot != null) r'allowReboot': allowReboot, + }); - @override - factory Input$AutoUpgradeSettingsInput.fromJson(Map json) => - _$Input$AutoUpgradeSettingsInputFromJson(json); + Input$AutoUpgradeSettingsInput._(this._$data); - final bool? enableAutoUpgrade; - - final bool? allowReboot; - - Map toJson() => _$Input$AutoUpgradeSettingsInputToJson(this); - int get hashCode { - final l$enableAutoUpgrade = enableAutoUpgrade; - final l$allowReboot = allowReboot; - return Object.hashAll([l$enableAutoUpgrade, l$allowReboot]); + factory Input$AutoUpgradeSettingsInput.fromJson(Map data) { + final result$data = {}; + if (data.containsKey('enableAutoUpgrade')) { + final l$enableAutoUpgrade = data['enableAutoUpgrade']; + result$data['enableAutoUpgrade'] = (l$enableAutoUpgrade as bool?); + } + if (data.containsKey('allowReboot')) { + final l$allowReboot = data['allowReboot']; + result$data['allowReboot'] = (l$allowReboot as bool?); + } + return Input$AutoUpgradeSettingsInput._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Input$AutoUpgradeSettingsInput) || - runtimeType != other.runtimeType) return false; - final l$enableAutoUpgrade = enableAutoUpgrade; - final lOther$enableAutoUpgrade = other.enableAutoUpgrade; - if (l$enableAutoUpgrade != lOther$enableAutoUpgrade) return false; - final l$allowReboot = allowReboot; - final lOther$allowReboot = other.allowReboot; - if (l$allowReboot != lOther$allowReboot) return false; - return true; + Map _$data; + + bool? get enableAutoUpgrade => (_$data['enableAutoUpgrade'] as bool?); + bool? get allowReboot => (_$data['allowReboot'] as bool?); + Map toJson() { + final result$data = {}; + if (_$data.containsKey('enableAutoUpgrade')) { + final l$enableAutoUpgrade = enableAutoUpgrade; + result$data['enableAutoUpgrade'] = l$enableAutoUpgrade; + } + if (_$data.containsKey('allowReboot')) { + final l$allowReboot = allowReboot; + result$data['allowReboot'] = l$allowReboot; + } + return result$data; } CopyWith$Input$AutoUpgradeSettingsInput - get copyWith => CopyWith$Input$AutoUpgradeSettingsInput(this, (i) => i); + get copyWith => CopyWith$Input$AutoUpgradeSettingsInput( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Input$AutoUpgradeSettingsInput) || + runtimeType != other.runtimeType) { + return false; + } + final l$enableAutoUpgrade = enableAutoUpgrade; + final lOther$enableAutoUpgrade = other.enableAutoUpgrade; + if (_$data.containsKey('enableAutoUpgrade') != + other._$data.containsKey('enableAutoUpgrade')) { + return false; + } + if (l$enableAutoUpgrade != lOther$enableAutoUpgrade) { + return false; + } + final l$allowReboot = allowReboot; + final lOther$allowReboot = other.allowReboot; + if (_$data.containsKey('allowReboot') != + other._$data.containsKey('allowReboot')) { + return false; + } + if (l$allowReboot != lOther$allowReboot) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$enableAutoUpgrade = enableAutoUpgrade; + final l$allowReboot = allowReboot; + return Object.hashAll([ + _$data.containsKey('enableAutoUpgrade') ? l$enableAutoUpgrade : const {}, + _$data.containsKey('allowReboot') ? l$allowReboot : const {}, + ]); + } } abstract class CopyWith$Input$AutoUpgradeSettingsInput { factory CopyWith$Input$AutoUpgradeSettingsInput( - Input$AutoUpgradeSettingsInput instance, - TRes Function(Input$AutoUpgradeSettingsInput) then) = - _CopyWithImpl$Input$AutoUpgradeSettingsInput; + Input$AutoUpgradeSettingsInput instance, + TRes Function(Input$AutoUpgradeSettingsInput) then, + ) = _CopyWithImpl$Input$AutoUpgradeSettingsInput; factory CopyWith$Input$AutoUpgradeSettingsInput.stub(TRes res) = _CopyWithStubImpl$Input$AutoUpgradeSettingsInput; - TRes call({bool? enableAutoUpgrade, bool? allowReboot}); + TRes call({ + bool? enableAutoUpgrade, + bool? allowReboot, + }); } class _CopyWithImpl$Input$AutoUpgradeSettingsInput implements CopyWith$Input$AutoUpgradeSettingsInput { - _CopyWithImpl$Input$AutoUpgradeSettingsInput(this._instance, this._then); + _CopyWithImpl$Input$AutoUpgradeSettingsInput( + this._instance, + this._then, + ); final Input$AutoUpgradeSettingsInput _instance; @@ -63,16 +118,16 @@ class _CopyWithImpl$Input$AutoUpgradeSettingsInput static const _undefined = {}; - TRes call( - {Object? enableAutoUpgrade = _undefined, - Object? allowReboot = _undefined}) => - _then(Input$AutoUpgradeSettingsInput( - enableAutoUpgrade: enableAutoUpgrade == _undefined - ? _instance.enableAutoUpgrade - : (enableAutoUpgrade as bool?), - allowReboot: allowReboot == _undefined - ? _instance.allowReboot - : (allowReboot as bool?))); + TRes call({ + Object? enableAutoUpgrade = _undefined, + Object? allowReboot = _undefined, + }) => + _then(Input$AutoUpgradeSettingsInput._({ + ..._instance._$data, + if (enableAutoUpgrade != _undefined) + 'enableAutoUpgrade': (enableAutoUpgrade as bool?), + if (allowReboot != _undefined) 'allowReboot': (allowReboot as bool?), + })); } class _CopyWithStubImpl$Input$AutoUpgradeSettingsInput @@ -81,33 +136,111 @@ class _CopyWithStubImpl$Input$AutoUpgradeSettingsInput TRes _res; - call({bool? enableAutoUpgrade, bool? allowReboot}) => _res; + call({ + bool? enableAutoUpgrade, + bool? allowReboot, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Input$MigrateToBindsInput { - Input$MigrateToBindsInput( - {required this.emailBlockDevice, - required this.bitwardenBlockDevice, - required this.giteaBlockDevice, - required this.nextcloudBlockDevice, - required this.pleromaBlockDevice}); + factory Input$MigrateToBindsInput({ + required String emailBlockDevice, + required String bitwardenBlockDevice, + required String giteaBlockDevice, + required String nextcloudBlockDevice, + required String pleromaBlockDevice, + }) => + Input$MigrateToBindsInput._({ + r'emailBlockDevice': emailBlockDevice, + r'bitwardenBlockDevice': bitwardenBlockDevice, + r'giteaBlockDevice': giteaBlockDevice, + r'nextcloudBlockDevice': nextcloudBlockDevice, + r'pleromaBlockDevice': pleromaBlockDevice, + }); + + Input$MigrateToBindsInput._(this._$data); + + factory Input$MigrateToBindsInput.fromJson(Map data) { + final result$data = {}; + final l$emailBlockDevice = data['emailBlockDevice']; + result$data['emailBlockDevice'] = (l$emailBlockDevice as String); + final l$bitwardenBlockDevice = data['bitwardenBlockDevice']; + result$data['bitwardenBlockDevice'] = (l$bitwardenBlockDevice as String); + final l$giteaBlockDevice = data['giteaBlockDevice']; + result$data['giteaBlockDevice'] = (l$giteaBlockDevice as String); + final l$nextcloudBlockDevice = data['nextcloudBlockDevice']; + result$data['nextcloudBlockDevice'] = (l$nextcloudBlockDevice as String); + final l$pleromaBlockDevice = data['pleromaBlockDevice']; + result$data['pleromaBlockDevice'] = (l$pleromaBlockDevice as String); + return Input$MigrateToBindsInput._(result$data); + } + + Map _$data; + + String get emailBlockDevice => (_$data['emailBlockDevice'] as String); + String get bitwardenBlockDevice => (_$data['bitwardenBlockDevice'] as String); + String get giteaBlockDevice => (_$data['giteaBlockDevice'] as String); + String get nextcloudBlockDevice => (_$data['nextcloudBlockDevice'] as String); + String get pleromaBlockDevice => (_$data['pleromaBlockDevice'] as String); + Map toJson() { + final result$data = {}; + final l$emailBlockDevice = emailBlockDevice; + result$data['emailBlockDevice'] = l$emailBlockDevice; + final l$bitwardenBlockDevice = bitwardenBlockDevice; + result$data['bitwardenBlockDevice'] = l$bitwardenBlockDevice; + final l$giteaBlockDevice = giteaBlockDevice; + result$data['giteaBlockDevice'] = l$giteaBlockDevice; + final l$nextcloudBlockDevice = nextcloudBlockDevice; + result$data['nextcloudBlockDevice'] = l$nextcloudBlockDevice; + final l$pleromaBlockDevice = pleromaBlockDevice; + result$data['pleromaBlockDevice'] = l$pleromaBlockDevice; + return result$data; + } + + CopyWith$Input$MigrateToBindsInput get copyWith => + CopyWith$Input$MigrateToBindsInput( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Input$MigrateToBindsInput) || + runtimeType != other.runtimeType) { + return false; + } + final l$emailBlockDevice = emailBlockDevice; + final lOther$emailBlockDevice = other.emailBlockDevice; + if (l$emailBlockDevice != lOther$emailBlockDevice) { + return false; + } + final l$bitwardenBlockDevice = bitwardenBlockDevice; + final lOther$bitwardenBlockDevice = other.bitwardenBlockDevice; + if (l$bitwardenBlockDevice != lOther$bitwardenBlockDevice) { + return false; + } + final l$giteaBlockDevice = giteaBlockDevice; + final lOther$giteaBlockDevice = other.giteaBlockDevice; + if (l$giteaBlockDevice != lOther$giteaBlockDevice) { + return false; + } + final l$nextcloudBlockDevice = nextcloudBlockDevice; + final lOther$nextcloudBlockDevice = other.nextcloudBlockDevice; + if (l$nextcloudBlockDevice != lOther$nextcloudBlockDevice) { + return false; + } + final l$pleromaBlockDevice = pleromaBlockDevice; + final lOther$pleromaBlockDevice = other.pleromaBlockDevice; + if (l$pleromaBlockDevice != lOther$pleromaBlockDevice) { + return false; + } + return true; + } @override - factory Input$MigrateToBindsInput.fromJson(Map json) => - _$Input$MigrateToBindsInputFromJson(json); - - final String emailBlockDevice; - - final String bitwardenBlockDevice; - - final String giteaBlockDevice; - - final String nextcloudBlockDevice; - - final String pleromaBlockDevice; - - Map toJson() => _$Input$MigrateToBindsInputToJson(this); int get hashCode { final l$emailBlockDevice = emailBlockDevice; final l$bitwardenBlockDevice = bitwardenBlockDevice; @@ -119,56 +252,35 @@ class Input$MigrateToBindsInput { l$bitwardenBlockDevice, l$giteaBlockDevice, l$nextcloudBlockDevice, - l$pleromaBlockDevice + l$pleromaBlockDevice, ]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Input$MigrateToBindsInput) || - runtimeType != other.runtimeType) return false; - final l$emailBlockDevice = emailBlockDevice; - final lOther$emailBlockDevice = other.emailBlockDevice; - if (l$emailBlockDevice != lOther$emailBlockDevice) return false; - final l$bitwardenBlockDevice = bitwardenBlockDevice; - final lOther$bitwardenBlockDevice = other.bitwardenBlockDevice; - if (l$bitwardenBlockDevice != lOther$bitwardenBlockDevice) return false; - final l$giteaBlockDevice = giteaBlockDevice; - final lOther$giteaBlockDevice = other.giteaBlockDevice; - if (l$giteaBlockDevice != lOther$giteaBlockDevice) return false; - final l$nextcloudBlockDevice = nextcloudBlockDevice; - final lOther$nextcloudBlockDevice = other.nextcloudBlockDevice; - if (l$nextcloudBlockDevice != lOther$nextcloudBlockDevice) return false; - final l$pleromaBlockDevice = pleromaBlockDevice; - final lOther$pleromaBlockDevice = other.pleromaBlockDevice; - if (l$pleromaBlockDevice != lOther$pleromaBlockDevice) return false; - return true; - } - - CopyWith$Input$MigrateToBindsInput get copyWith => - CopyWith$Input$MigrateToBindsInput(this, (i) => i); } abstract class CopyWith$Input$MigrateToBindsInput { - factory CopyWith$Input$MigrateToBindsInput(Input$MigrateToBindsInput instance, - TRes Function(Input$MigrateToBindsInput) then) = - _CopyWithImpl$Input$MigrateToBindsInput; + factory CopyWith$Input$MigrateToBindsInput( + Input$MigrateToBindsInput instance, + TRes Function(Input$MigrateToBindsInput) then, + ) = _CopyWithImpl$Input$MigrateToBindsInput; factory CopyWith$Input$MigrateToBindsInput.stub(TRes res) = _CopyWithStubImpl$Input$MigrateToBindsInput; - TRes call( - {String? emailBlockDevice, - String? bitwardenBlockDevice, - String? giteaBlockDevice, - String? nextcloudBlockDevice, - String? pleromaBlockDevice}); + TRes call({ + String? emailBlockDevice, + String? bitwardenBlockDevice, + String? giteaBlockDevice, + String? nextcloudBlockDevice, + String? pleromaBlockDevice, + }); } class _CopyWithImpl$Input$MigrateToBindsInput implements CopyWith$Input$MigrateToBindsInput { - _CopyWithImpl$Input$MigrateToBindsInput(this._instance, this._then); + _CopyWithImpl$Input$MigrateToBindsInput( + this._instance, + this._then, + ); final Input$MigrateToBindsInput _instance; @@ -176,33 +288,26 @@ class _CopyWithImpl$Input$MigrateToBindsInput static const _undefined = {}; - TRes call( - {Object? emailBlockDevice = _undefined, - Object? bitwardenBlockDevice = _undefined, - Object? giteaBlockDevice = _undefined, - Object? nextcloudBlockDevice = _undefined, - Object? pleromaBlockDevice = _undefined}) => - _then(Input$MigrateToBindsInput( - emailBlockDevice: - emailBlockDevice == _undefined || emailBlockDevice == null - ? _instance.emailBlockDevice - : (emailBlockDevice as String), - bitwardenBlockDevice: - bitwardenBlockDevice == _undefined || bitwardenBlockDevice == null - ? _instance.bitwardenBlockDevice - : (bitwardenBlockDevice as String), - giteaBlockDevice: - giteaBlockDevice == _undefined || giteaBlockDevice == null - ? _instance.giteaBlockDevice - : (giteaBlockDevice as String), - nextcloudBlockDevice: - nextcloudBlockDevice == _undefined || nextcloudBlockDevice == null - ? _instance.nextcloudBlockDevice - : (nextcloudBlockDevice as String), - pleromaBlockDevice: - pleromaBlockDevice == _undefined || pleromaBlockDevice == null - ? _instance.pleromaBlockDevice - : (pleromaBlockDevice as String))); + TRes call({ + Object? emailBlockDevice = _undefined, + Object? bitwardenBlockDevice = _undefined, + Object? giteaBlockDevice = _undefined, + Object? nextcloudBlockDevice = _undefined, + Object? pleromaBlockDevice = _undefined, + }) => + _then(Input$MigrateToBindsInput._({ + ..._instance._$data, + if (emailBlockDevice != _undefined && emailBlockDevice != null) + 'emailBlockDevice': (emailBlockDevice as String), + if (bitwardenBlockDevice != _undefined && bitwardenBlockDevice != null) + 'bitwardenBlockDevice': (bitwardenBlockDevice as String), + if (giteaBlockDevice != _undefined && giteaBlockDevice != null) + 'giteaBlockDevice': (giteaBlockDevice as String), + if (nextcloudBlockDevice != _undefined && nextcloudBlockDevice != null) + 'nextcloudBlockDevice': (nextcloudBlockDevice as String), + if (pleromaBlockDevice != _undefined && pleromaBlockDevice != null) + 'pleromaBlockDevice': (pleromaBlockDevice as String), + })); } class _CopyWithStubImpl$Input$MigrateToBindsInput @@ -211,66 +316,109 @@ class _CopyWithStubImpl$Input$MigrateToBindsInput TRes _res; - call( - {String? emailBlockDevice, - String? bitwardenBlockDevice, - String? giteaBlockDevice, - String? nextcloudBlockDevice, - String? pleromaBlockDevice}) => + call({ + String? emailBlockDevice, + String? bitwardenBlockDevice, + String? giteaBlockDevice, + String? nextcloudBlockDevice, + String? pleromaBlockDevice, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Input$MoveServiceInput { - Input$MoveServiceInput({required this.serviceId, required this.location}); + factory Input$MoveServiceInput({ + required String serviceId, + required String location, + }) => + Input$MoveServiceInput._({ + r'serviceId': serviceId, + r'location': location, + }); - @override - factory Input$MoveServiceInput.fromJson(Map json) => - _$Input$MoveServiceInputFromJson(json); + Input$MoveServiceInput._(this._$data); - final String serviceId; - - final String location; - - Map toJson() => _$Input$MoveServiceInputToJson(this); - int get hashCode { - final l$serviceId = serviceId; - final l$location = location; - return Object.hashAll([l$serviceId, l$location]); + factory Input$MoveServiceInput.fromJson(Map data) { + final result$data = {}; + final l$serviceId = data['serviceId']; + result$data['serviceId'] = (l$serviceId as String); + final l$location = data['location']; + result$data['location'] = (l$location as String); + return Input$MoveServiceInput._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Input$MoveServiceInput) || runtimeType != other.runtimeType) - return false; + Map _$data; + + String get serviceId => (_$data['serviceId'] as String); + String get location => (_$data['location'] as String); + Map toJson() { + final result$data = {}; final l$serviceId = serviceId; - final lOther$serviceId = other.serviceId; - if (l$serviceId != lOther$serviceId) return false; + result$data['serviceId'] = l$serviceId; final l$location = location; - final lOther$location = other.location; - if (l$location != lOther$location) return false; - return true; + result$data['location'] = l$location; + return result$data; } CopyWith$Input$MoveServiceInput get copyWith => - CopyWith$Input$MoveServiceInput(this, (i) => i); + CopyWith$Input$MoveServiceInput( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Input$MoveServiceInput) || + runtimeType != other.runtimeType) { + return false; + } + final l$serviceId = serviceId; + final lOther$serviceId = other.serviceId; + if (l$serviceId != lOther$serviceId) { + return false; + } + final l$location = location; + final lOther$location = other.location; + if (l$location != lOther$location) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$serviceId = serviceId; + final l$location = location; + return Object.hashAll([ + l$serviceId, + l$location, + ]); + } } abstract class CopyWith$Input$MoveServiceInput { - factory CopyWith$Input$MoveServiceInput(Input$MoveServiceInput instance, - TRes Function(Input$MoveServiceInput) then) = - _CopyWithImpl$Input$MoveServiceInput; + factory CopyWith$Input$MoveServiceInput( + Input$MoveServiceInput instance, + TRes Function(Input$MoveServiceInput) then, + ) = _CopyWithImpl$Input$MoveServiceInput; factory CopyWith$Input$MoveServiceInput.stub(TRes res) = _CopyWithStubImpl$Input$MoveServiceInput; - TRes call({String? serviceId, String? location}); + TRes call({ + String? serviceId, + String? location, + }); } class _CopyWithImpl$Input$MoveServiceInput implements CopyWith$Input$MoveServiceInput { - _CopyWithImpl$Input$MoveServiceInput(this._instance, this._then); + _CopyWithImpl$Input$MoveServiceInput( + this._instance, + this._then, + ); final Input$MoveServiceInput _instance; @@ -278,14 +426,17 @@ class _CopyWithImpl$Input$MoveServiceInput static const _undefined = {}; - TRes call({Object? serviceId = _undefined, Object? location = _undefined}) => - _then(Input$MoveServiceInput( - serviceId: serviceId == _undefined || serviceId == null - ? _instance.serviceId - : (serviceId as String), - location: location == _undefined || location == null - ? _instance.location - : (location as String))); + TRes call({ + Object? serviceId = _undefined, + Object? location = _undefined, + }) => + _then(Input$MoveServiceInput._({ + ..._instance._$data, + if (serviceId != _undefined && serviceId != null) + 'serviceId': (serviceId as String), + if (location != _undefined && location != null) + 'location': (location as String), + })); } class _CopyWithStubImpl$Input$MoveServiceInput @@ -294,63 +445,123 @@ class _CopyWithStubImpl$Input$MoveServiceInput TRes _res; - call({String? serviceId, String? location}) => _res; + call({ + String? serviceId, + String? location, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Input$RecoveryKeyLimitsInput { - Input$RecoveryKeyLimitsInput({this.expirationDate, this.uses}); + factory Input$RecoveryKeyLimitsInput({ + DateTime? expirationDate, + int? uses, + }) => + Input$RecoveryKeyLimitsInput._({ + if (expirationDate != null) r'expirationDate': expirationDate, + if (uses != null) r'uses': uses, + }); - @override - factory Input$RecoveryKeyLimitsInput.fromJson(Map json) => - _$Input$RecoveryKeyLimitsInputFromJson(json); + Input$RecoveryKeyLimitsInput._(this._$data); - @JsonKey( - fromJson: _nullable$dateTimeFromJson, toJson: _nullable$dateTimeToJson) - final DateTime? expirationDate; - - final int? uses; - - Map toJson() => _$Input$RecoveryKeyLimitsInputToJson(this); - int get hashCode { - final l$expirationDate = expirationDate; - final l$uses = uses; - return Object.hashAll([l$expirationDate, l$uses]); + factory Input$RecoveryKeyLimitsInput.fromJson(Map data) { + final result$data = {}; + if (data.containsKey('expirationDate')) { + final l$expirationDate = data['expirationDate']; + result$data['expirationDate'] = + l$expirationDate == null ? null : dateTimeFromJson(l$expirationDate); + } + if (data.containsKey('uses')) { + final l$uses = data['uses']; + result$data['uses'] = (l$uses as int?); + } + return Input$RecoveryKeyLimitsInput._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Input$RecoveryKeyLimitsInput) || - runtimeType != other.runtimeType) return false; - final l$expirationDate = expirationDate; - final lOther$expirationDate = other.expirationDate; - if (l$expirationDate != lOther$expirationDate) return false; - final l$uses = uses; - final lOther$uses = other.uses; - if (l$uses != lOther$uses) return false; - return true; + Map _$data; + + DateTime? get expirationDate => (_$data['expirationDate'] as DateTime?); + int? get uses => (_$data['uses'] as int?); + Map toJson() { + final result$data = {}; + if (_$data.containsKey('expirationDate')) { + final l$expirationDate = expirationDate; + result$data['expirationDate'] = + l$expirationDate == null ? null : dateTimeToJson(l$expirationDate); + } + if (_$data.containsKey('uses')) { + final l$uses = uses; + result$data['uses'] = l$uses; + } + return result$data; } CopyWith$Input$RecoveryKeyLimitsInput - get copyWith => CopyWith$Input$RecoveryKeyLimitsInput(this, (i) => i); + get copyWith => CopyWith$Input$RecoveryKeyLimitsInput( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Input$RecoveryKeyLimitsInput) || + runtimeType != other.runtimeType) { + return false; + } + final l$expirationDate = expirationDate; + final lOther$expirationDate = other.expirationDate; + if (_$data.containsKey('expirationDate') != + other._$data.containsKey('expirationDate')) { + return false; + } + if (l$expirationDate != lOther$expirationDate) { + return false; + } + final l$uses = uses; + final lOther$uses = other.uses; + if (_$data.containsKey('uses') != other._$data.containsKey('uses')) { + return false; + } + if (l$uses != lOther$uses) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$expirationDate = expirationDate; + final l$uses = uses; + return Object.hashAll([ + _$data.containsKey('expirationDate') ? l$expirationDate : const {}, + _$data.containsKey('uses') ? l$uses : const {}, + ]); + } } abstract class CopyWith$Input$RecoveryKeyLimitsInput { factory CopyWith$Input$RecoveryKeyLimitsInput( - Input$RecoveryKeyLimitsInput instance, - TRes Function(Input$RecoveryKeyLimitsInput) then) = - _CopyWithImpl$Input$RecoveryKeyLimitsInput; + Input$RecoveryKeyLimitsInput instance, + TRes Function(Input$RecoveryKeyLimitsInput) then, + ) = _CopyWithImpl$Input$RecoveryKeyLimitsInput; factory CopyWith$Input$RecoveryKeyLimitsInput.stub(TRes res) = _CopyWithStubImpl$Input$RecoveryKeyLimitsInput; - TRes call({DateTime? expirationDate, int? uses}); + TRes call({ + DateTime? expirationDate, + int? uses, + }); } class _CopyWithImpl$Input$RecoveryKeyLimitsInput implements CopyWith$Input$RecoveryKeyLimitsInput { - _CopyWithImpl$Input$RecoveryKeyLimitsInput(this._instance, this._then); + _CopyWithImpl$Input$RecoveryKeyLimitsInput( + this._instance, + this._then, + ); final Input$RecoveryKeyLimitsInput _instance; @@ -358,12 +569,16 @@ class _CopyWithImpl$Input$RecoveryKeyLimitsInput static const _undefined = {}; - TRes call({Object? expirationDate = _undefined, Object? uses = _undefined}) => - _then(Input$RecoveryKeyLimitsInput( - expirationDate: expirationDate == _undefined - ? _instance.expirationDate - : (expirationDate as DateTime?), - uses: uses == _undefined ? _instance.uses : (uses as int?))); + TRes call({ + Object? expirationDate = _undefined, + Object? uses = _undefined, + }) => + _then(Input$RecoveryKeyLimitsInput._({ + ..._instance._$data, + if (expirationDate != _undefined) + 'expirationDate': (expirationDate as DateTime?), + if (uses != _undefined) 'uses': (uses as int?), + })); } class _CopyWithStubImpl$Input$RecoveryKeyLimitsInput @@ -372,60 +587,106 @@ class _CopyWithStubImpl$Input$RecoveryKeyLimitsInput TRes _res; - call({DateTime? expirationDate, int? uses}) => _res; + call({ + DateTime? expirationDate, + int? uses, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Input$SshMutationInput { - Input$SshMutationInput({required this.username, required this.sshKey}); + factory Input$SshMutationInput({ + required String username, + required String sshKey, + }) => + Input$SshMutationInput._({ + r'username': username, + r'sshKey': sshKey, + }); - @override - factory Input$SshMutationInput.fromJson(Map json) => - _$Input$SshMutationInputFromJson(json); + Input$SshMutationInput._(this._$data); - final String username; - - final String sshKey; - - Map toJson() => _$Input$SshMutationInputToJson(this); - int get hashCode { - final l$username = username; - final l$sshKey = sshKey; - return Object.hashAll([l$username, l$sshKey]); + factory Input$SshMutationInput.fromJson(Map data) { + final result$data = {}; + final l$username = data['username']; + result$data['username'] = (l$username as String); + final l$sshKey = data['sshKey']; + result$data['sshKey'] = (l$sshKey as String); + return Input$SshMutationInput._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Input$SshMutationInput) || runtimeType != other.runtimeType) - return false; + Map _$data; + + String get username => (_$data['username'] as String); + String get sshKey => (_$data['sshKey'] as String); + Map toJson() { + final result$data = {}; final l$username = username; - final lOther$username = other.username; - if (l$username != lOther$username) return false; + result$data['username'] = l$username; final l$sshKey = sshKey; - final lOther$sshKey = other.sshKey; - if (l$sshKey != lOther$sshKey) return false; - return true; + result$data['sshKey'] = l$sshKey; + return result$data; } CopyWith$Input$SshMutationInput get copyWith => - CopyWith$Input$SshMutationInput(this, (i) => i); + CopyWith$Input$SshMutationInput( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Input$SshMutationInput) || + runtimeType != other.runtimeType) { + return false; + } + final l$username = username; + final lOther$username = other.username; + if (l$username != lOther$username) { + return false; + } + final l$sshKey = sshKey; + final lOther$sshKey = other.sshKey; + if (l$sshKey != lOther$sshKey) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$username = username; + final l$sshKey = sshKey; + return Object.hashAll([ + l$username, + l$sshKey, + ]); + } } abstract class CopyWith$Input$SshMutationInput { - factory CopyWith$Input$SshMutationInput(Input$SshMutationInput instance, - TRes Function(Input$SshMutationInput) then) = - _CopyWithImpl$Input$SshMutationInput; + factory CopyWith$Input$SshMutationInput( + Input$SshMutationInput instance, + TRes Function(Input$SshMutationInput) then, + ) = _CopyWithImpl$Input$SshMutationInput; factory CopyWith$Input$SshMutationInput.stub(TRes res) = _CopyWithStubImpl$Input$SshMutationInput; - TRes call({String? username, String? sshKey}); + TRes call({ + String? username, + String? sshKey, + }); } class _CopyWithImpl$Input$SshMutationInput implements CopyWith$Input$SshMutationInput { - _CopyWithImpl$Input$SshMutationInput(this._instance, this._then); + _CopyWithImpl$Input$SshMutationInput( + this._instance, + this._then, + ); final Input$SshMutationInput _instance; @@ -433,14 +694,17 @@ class _CopyWithImpl$Input$SshMutationInput static const _undefined = {}; - TRes call({Object? username = _undefined, Object? sshKey = _undefined}) => - _then(Input$SshMutationInput( - username: username == _undefined || username == null - ? _instance.username - : (username as String), - sshKey: sshKey == _undefined || sshKey == null - ? _instance.sshKey - : (sshKey as String))); + TRes call({ + Object? username = _undefined, + Object? sshKey = _undefined, + }) => + _then(Input$SshMutationInput._({ + ..._instance._$data, + if (username != _undefined && username != null) + 'username': (username as String), + if (sshKey != _undefined && sshKey != null) + 'sshKey': (sshKey as String), + })); } class _CopyWithStubImpl$Input$SshMutationInput @@ -449,61 +713,106 @@ class _CopyWithStubImpl$Input$SshMutationInput TRes _res; - call({String? username, String? sshKey}) => _res; + call({ + String? username, + String? sshKey, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Input$UseNewDeviceKeyInput { - Input$UseNewDeviceKeyInput({required this.key, required this.deviceName}); + factory Input$UseNewDeviceKeyInput({ + required String key, + required String deviceName, + }) => + Input$UseNewDeviceKeyInput._({ + r'key': key, + r'deviceName': deviceName, + }); - @override - factory Input$UseNewDeviceKeyInput.fromJson(Map json) => - _$Input$UseNewDeviceKeyInputFromJson(json); + Input$UseNewDeviceKeyInput._(this._$data); - final String key; - - final String deviceName; - - Map toJson() => _$Input$UseNewDeviceKeyInputToJson(this); - int get hashCode { - final l$key = key; - final l$deviceName = deviceName; - return Object.hashAll([l$key, l$deviceName]); + factory Input$UseNewDeviceKeyInput.fromJson(Map data) { + final result$data = {}; + final l$key = data['key']; + result$data['key'] = (l$key as String); + final l$deviceName = data['deviceName']; + result$data['deviceName'] = (l$deviceName as String); + return Input$UseNewDeviceKeyInput._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Input$UseNewDeviceKeyInput) || - runtimeType != other.runtimeType) return false; + Map _$data; + + String get key => (_$data['key'] as String); + String get deviceName => (_$data['deviceName'] as String); + Map toJson() { + final result$data = {}; final l$key = key; - final lOther$key = other.key; - if (l$key != lOther$key) return false; + result$data['key'] = l$key; final l$deviceName = deviceName; - final lOther$deviceName = other.deviceName; - if (l$deviceName != lOther$deviceName) return false; - return true; + result$data['deviceName'] = l$deviceName; + return result$data; } CopyWith$Input$UseNewDeviceKeyInput - get copyWith => CopyWith$Input$UseNewDeviceKeyInput(this, (i) => i); + get copyWith => CopyWith$Input$UseNewDeviceKeyInput( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Input$UseNewDeviceKeyInput) || + runtimeType != other.runtimeType) { + return false; + } + final l$key = key; + final lOther$key = other.key; + if (l$key != lOther$key) { + return false; + } + final l$deviceName = deviceName; + final lOther$deviceName = other.deviceName; + if (l$deviceName != lOther$deviceName) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$key = key; + final l$deviceName = deviceName; + return Object.hashAll([ + l$key, + l$deviceName, + ]); + } } abstract class CopyWith$Input$UseNewDeviceKeyInput { factory CopyWith$Input$UseNewDeviceKeyInput( - Input$UseNewDeviceKeyInput instance, - TRes Function(Input$UseNewDeviceKeyInput) then) = - _CopyWithImpl$Input$UseNewDeviceKeyInput; + Input$UseNewDeviceKeyInput instance, + TRes Function(Input$UseNewDeviceKeyInput) then, + ) = _CopyWithImpl$Input$UseNewDeviceKeyInput; factory CopyWith$Input$UseNewDeviceKeyInput.stub(TRes res) = _CopyWithStubImpl$Input$UseNewDeviceKeyInput; - TRes call({String? key, String? deviceName}); + TRes call({ + String? key, + String? deviceName, + }); } class _CopyWithImpl$Input$UseNewDeviceKeyInput implements CopyWith$Input$UseNewDeviceKeyInput { - _CopyWithImpl$Input$UseNewDeviceKeyInput(this._instance, this._then); + _CopyWithImpl$Input$UseNewDeviceKeyInput( + this._instance, + this._then, + ); final Input$UseNewDeviceKeyInput _instance; @@ -511,14 +820,16 @@ class _CopyWithImpl$Input$UseNewDeviceKeyInput static const _undefined = {}; - TRes call({Object? key = _undefined, Object? deviceName = _undefined}) => - _then(Input$UseNewDeviceKeyInput( - key: key == _undefined || key == null - ? _instance.key - : (key as String), - deviceName: deviceName == _undefined || deviceName == null - ? _instance.deviceName - : (deviceName as String))); + TRes call({ + Object? key = _undefined, + Object? deviceName = _undefined, + }) => + _then(Input$UseNewDeviceKeyInput._({ + ..._instance._$data, + if (key != _undefined && key != null) 'key': (key as String), + if (deviceName != _undefined && deviceName != null) + 'deviceName': (deviceName as String), + })); } class _CopyWithStubImpl$Input$UseNewDeviceKeyInput @@ -527,60 +838,106 @@ class _CopyWithStubImpl$Input$UseNewDeviceKeyInput TRes _res; - call({String? key, String? deviceName}) => _res; + call({ + String? key, + String? deviceName, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Input$UseRecoveryKeyInput { - Input$UseRecoveryKeyInput({required this.key, required this.deviceName}); + factory Input$UseRecoveryKeyInput({ + required String key, + required String deviceName, + }) => + Input$UseRecoveryKeyInput._({ + r'key': key, + r'deviceName': deviceName, + }); - @override - factory Input$UseRecoveryKeyInput.fromJson(Map json) => - _$Input$UseRecoveryKeyInputFromJson(json); + Input$UseRecoveryKeyInput._(this._$data); - final String key; - - final String deviceName; - - Map toJson() => _$Input$UseRecoveryKeyInputToJson(this); - int get hashCode { - final l$key = key; - final l$deviceName = deviceName; - return Object.hashAll([l$key, l$deviceName]); + factory Input$UseRecoveryKeyInput.fromJson(Map data) { + final result$data = {}; + final l$key = data['key']; + result$data['key'] = (l$key as String); + final l$deviceName = data['deviceName']; + result$data['deviceName'] = (l$deviceName as String); + return Input$UseRecoveryKeyInput._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Input$UseRecoveryKeyInput) || - runtimeType != other.runtimeType) return false; + Map _$data; + + String get key => (_$data['key'] as String); + String get deviceName => (_$data['deviceName'] as String); + Map toJson() { + final result$data = {}; final l$key = key; - final lOther$key = other.key; - if (l$key != lOther$key) return false; + result$data['key'] = l$key; final l$deviceName = deviceName; - final lOther$deviceName = other.deviceName; - if (l$deviceName != lOther$deviceName) return false; - return true; + result$data['deviceName'] = l$deviceName; + return result$data; } CopyWith$Input$UseRecoveryKeyInput get copyWith => - CopyWith$Input$UseRecoveryKeyInput(this, (i) => i); + CopyWith$Input$UseRecoveryKeyInput( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Input$UseRecoveryKeyInput) || + runtimeType != other.runtimeType) { + return false; + } + final l$key = key; + final lOther$key = other.key; + if (l$key != lOther$key) { + return false; + } + final l$deviceName = deviceName; + final lOther$deviceName = other.deviceName; + if (l$deviceName != lOther$deviceName) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$key = key; + final l$deviceName = deviceName; + return Object.hashAll([ + l$key, + l$deviceName, + ]); + } } abstract class CopyWith$Input$UseRecoveryKeyInput { - factory CopyWith$Input$UseRecoveryKeyInput(Input$UseRecoveryKeyInput instance, - TRes Function(Input$UseRecoveryKeyInput) then) = - _CopyWithImpl$Input$UseRecoveryKeyInput; + factory CopyWith$Input$UseRecoveryKeyInput( + Input$UseRecoveryKeyInput instance, + TRes Function(Input$UseRecoveryKeyInput) then, + ) = _CopyWithImpl$Input$UseRecoveryKeyInput; factory CopyWith$Input$UseRecoveryKeyInput.stub(TRes res) = _CopyWithStubImpl$Input$UseRecoveryKeyInput; - TRes call({String? key, String? deviceName}); + TRes call({ + String? key, + String? deviceName, + }); } class _CopyWithImpl$Input$UseRecoveryKeyInput implements CopyWith$Input$UseRecoveryKeyInput { - _CopyWithImpl$Input$UseRecoveryKeyInput(this._instance, this._then); + _CopyWithImpl$Input$UseRecoveryKeyInput( + this._instance, + this._then, + ); final Input$UseRecoveryKeyInput _instance; @@ -588,14 +945,16 @@ class _CopyWithImpl$Input$UseRecoveryKeyInput static const _undefined = {}; - TRes call({Object? key = _undefined, Object? deviceName = _undefined}) => - _then(Input$UseRecoveryKeyInput( - key: key == _undefined || key == null - ? _instance.key - : (key as String), - deviceName: deviceName == _undefined || deviceName == null - ? _instance.deviceName - : (deviceName as String))); + TRes call({ + Object? key = _undefined, + Object? deviceName = _undefined, + }) => + _then(Input$UseRecoveryKeyInput._({ + ..._instance._$data, + if (key != _undefined && key != null) 'key': (key as String), + if (deviceName != _undefined && deviceName != null) + 'deviceName': (deviceName as String), + })); } class _CopyWithStubImpl$Input$UseRecoveryKeyInput @@ -604,60 +963,106 @@ class _CopyWithStubImpl$Input$UseRecoveryKeyInput TRes _res; - call({String? key, String? deviceName}) => _res; + call({ + String? key, + String? deviceName, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Input$UserMutationInput { - Input$UserMutationInput({required this.username, required this.password}); + factory Input$UserMutationInput({ + required String username, + required String password, + }) => + Input$UserMutationInput._({ + r'username': username, + r'password': password, + }); - @override - factory Input$UserMutationInput.fromJson(Map json) => - _$Input$UserMutationInputFromJson(json); + Input$UserMutationInput._(this._$data); - final String username; - - final String password; - - Map toJson() => _$Input$UserMutationInputToJson(this); - int get hashCode { - final l$username = username; - final l$password = password; - return Object.hashAll([l$username, l$password]); + factory Input$UserMutationInput.fromJson(Map data) { + final result$data = {}; + final l$username = data['username']; + result$data['username'] = (l$username as String); + final l$password = data['password']; + result$data['password'] = (l$password as String); + return Input$UserMutationInput._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Input$UserMutationInput) || runtimeType != other.runtimeType) - return false; + Map _$data; + + String get username => (_$data['username'] as String); + String get password => (_$data['password'] as String); + Map toJson() { + final result$data = {}; final l$username = username; - final lOther$username = other.username; - if (l$username != lOther$username) return false; + result$data['username'] = l$username; final l$password = password; - final lOther$password = other.password; - if (l$password != lOther$password) return false; - return true; + result$data['password'] = l$password; + return result$data; } CopyWith$Input$UserMutationInput get copyWith => - CopyWith$Input$UserMutationInput(this, (i) => i); + CopyWith$Input$UserMutationInput( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Input$UserMutationInput) || + runtimeType != other.runtimeType) { + return false; + } + final l$username = username; + final lOther$username = other.username; + if (l$username != lOther$username) { + return false; + } + final l$password = password; + final lOther$password = other.password; + if (l$password != lOther$password) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$username = username; + final l$password = password; + return Object.hashAll([ + l$username, + l$password, + ]); + } } abstract class CopyWith$Input$UserMutationInput { - factory CopyWith$Input$UserMutationInput(Input$UserMutationInput instance, - TRes Function(Input$UserMutationInput) then) = - _CopyWithImpl$Input$UserMutationInput; + factory CopyWith$Input$UserMutationInput( + Input$UserMutationInput instance, + TRes Function(Input$UserMutationInput) then, + ) = _CopyWithImpl$Input$UserMutationInput; factory CopyWith$Input$UserMutationInput.stub(TRes res) = _CopyWithStubImpl$Input$UserMutationInput; - TRes call({String? username, String? password}); + TRes call({ + String? username, + String? password, + }); } class _CopyWithImpl$Input$UserMutationInput implements CopyWith$Input$UserMutationInput { - _CopyWithImpl$Input$UserMutationInput(this._instance, this._then); + _CopyWithImpl$Input$UserMutationInput( + this._instance, + this._then, + ); final Input$UserMutationInput _instance; @@ -665,14 +1070,17 @@ class _CopyWithImpl$Input$UserMutationInput static const _undefined = {}; - TRes call({Object? username = _undefined, Object? password = _undefined}) => - _then(Input$UserMutationInput( - username: username == _undefined || username == null - ? _instance.username - : (username as String), - password: password == _undefined || password == null - ? _instance.password - : (password as String))); + TRes call({ + Object? username = _undefined, + Object? password = _undefined, + }) => + _then(Input$UserMutationInput._({ + ..._instance._$data, + if (username != _undefined && username != null) + 'username': (username as String), + if (password != _undefined && password != null) + 'password': (password as String), + })); } class _CopyWithStubImpl$Input$UserMutationInput @@ -681,78 +1089,200 @@ class _CopyWithStubImpl$Input$UserMutationInput TRes _res; - call({String? username, String? password}) => _res; + call({ + String? username, + String? password, + }) => + _res; } -enum Enum$DnsProvider { - @JsonValue('CLOUDFLARE') - CLOUDFLARE, - $unknown +enum Enum$DnsProvider { CLOUDFLARE, $unknown } + +String toJson$Enum$DnsProvider(Enum$DnsProvider e) { + switch (e) { + case Enum$DnsProvider.CLOUDFLARE: + return r'CLOUDFLARE'; + case Enum$DnsProvider.$unknown: + return r'$unknown'; + } } -enum Enum$ServerProvider { - @JsonValue('HETZNER') - HETZNER, - @JsonValue('DIGITALOCEAN') - DIGITALOCEAN, - $unknown +Enum$DnsProvider fromJson$Enum$DnsProvider(String value) { + switch (value) { + case r'CLOUDFLARE': + return Enum$DnsProvider.CLOUDFLARE; + default: + return Enum$DnsProvider.$unknown; + } +} + +enum Enum$ServerProvider { HETZNER, DIGITALOCEAN, $unknown } + +String toJson$Enum$ServerProvider(Enum$ServerProvider e) { + switch (e) { + case Enum$ServerProvider.HETZNER: + return r'HETZNER'; + case Enum$ServerProvider.DIGITALOCEAN: + return r'DIGITALOCEAN'; + case Enum$ServerProvider.$unknown: + return r'$unknown'; + } +} + +Enum$ServerProvider fromJson$Enum$ServerProvider(String value) { + switch (value) { + case r'HETZNER': + return Enum$ServerProvider.HETZNER; + case r'DIGITALOCEAN': + return Enum$ServerProvider.DIGITALOCEAN; + default: + return Enum$ServerProvider.$unknown; + } } enum Enum$ServiceStatusEnum { - @JsonValue('ACTIVATING') ACTIVATING, - @JsonValue('ACTIVE') ACTIVE, - @JsonValue('DEACTIVATING') DEACTIVATING, - @JsonValue('FAILED') FAILED, - @JsonValue('INACTIVE') INACTIVE, - @JsonValue('OFF') OFF, - @JsonValue('RELOADING') RELOADING, $unknown } -enum Enum$Severity { - @JsonValue('CRITICAL') - CRITICAL, - @JsonValue('ERROR') - ERROR, - @JsonValue('INFO') - INFO, - @JsonValue('SUCCESS') - SUCCESS, - @JsonValue('WARNING') - WARNING, - $unknown +String toJson$Enum$ServiceStatusEnum(Enum$ServiceStatusEnum e) { + switch (e) { + case Enum$ServiceStatusEnum.ACTIVATING: + return r'ACTIVATING'; + case Enum$ServiceStatusEnum.ACTIVE: + return r'ACTIVE'; + case Enum$ServiceStatusEnum.DEACTIVATING: + return r'DEACTIVATING'; + case Enum$ServiceStatusEnum.FAILED: + return r'FAILED'; + case Enum$ServiceStatusEnum.INACTIVE: + return r'INACTIVE'; + case Enum$ServiceStatusEnum.OFF: + return r'OFF'; + case Enum$ServiceStatusEnum.RELOADING: + return r'RELOADING'; + case Enum$ServiceStatusEnum.$unknown: + return r'$unknown'; + } } -enum Enum$UserType { - @JsonValue('NORMAL') - NORMAL, - @JsonValue('PRIMARY') - PRIMARY, - @JsonValue('ROOT') - ROOT, - $unknown +Enum$ServiceStatusEnum fromJson$Enum$ServiceStatusEnum(String value) { + switch (value) { + case r'ACTIVATING': + return Enum$ServiceStatusEnum.ACTIVATING; + case r'ACTIVE': + return Enum$ServiceStatusEnum.ACTIVE; + case r'DEACTIVATING': + return Enum$ServiceStatusEnum.DEACTIVATING; + case r'FAILED': + return Enum$ServiceStatusEnum.FAILED; + case r'INACTIVE': + return Enum$ServiceStatusEnum.INACTIVE; + case r'OFF': + return Enum$ServiceStatusEnum.OFF; + case r'RELOADING': + return Enum$ServiceStatusEnum.RELOADING; + default: + return Enum$ServiceStatusEnum.$unknown; + } +} + +enum Enum$Severity { CRITICAL, ERROR, INFO, SUCCESS, WARNING, $unknown } + +String toJson$Enum$Severity(Enum$Severity e) { + switch (e) { + case Enum$Severity.CRITICAL: + return r'CRITICAL'; + case Enum$Severity.ERROR: + return r'ERROR'; + case Enum$Severity.INFO: + return r'INFO'; + case Enum$Severity.SUCCESS: + return r'SUCCESS'; + case Enum$Severity.WARNING: + return r'WARNING'; + case Enum$Severity.$unknown: + return r'$unknown'; + } +} + +Enum$Severity fromJson$Enum$Severity(String value) { + switch (value) { + case r'CRITICAL': + return Enum$Severity.CRITICAL; + case r'ERROR': + return Enum$Severity.ERROR; + case r'INFO': + return Enum$Severity.INFO; + case r'SUCCESS': + return Enum$Severity.SUCCESS; + case r'WARNING': + return Enum$Severity.WARNING; + default: + return Enum$Severity.$unknown; + } +} + +enum Enum$UserType { NORMAL, PRIMARY, ROOT, $unknown } + +String toJson$Enum$UserType(Enum$UserType e) { + switch (e) { + case Enum$UserType.NORMAL: + return r'NORMAL'; + case Enum$UserType.PRIMARY: + return r'PRIMARY'; + case Enum$UserType.ROOT: + return r'ROOT'; + case Enum$UserType.$unknown: + return r'$unknown'; + } +} + +Enum$UserType fromJson$Enum$UserType(String value) { + switch (value) { + case r'NORMAL': + return Enum$UserType.NORMAL; + case r'PRIMARY': + return Enum$UserType.PRIMARY; + case r'ROOT': + return Enum$UserType.ROOT; + default: + return Enum$UserType.$unknown; + } } -@JsonSerializable(explicitToJson: true) class Fragment$dnsRecordFields { - Fragment$dnsRecordFields( - {required this.content, - required this.name, - this.priority, - required this.recordType, - required this.ttl, - required this.$__typename}); + Fragment$dnsRecordFields({ + required this.content, + required this.name, + this.priority, + required this.recordType, + required this.ttl, + required this.$__typename, + }); - @override - factory Fragment$dnsRecordFields.fromJson(Map json) => - _$Fragment$dnsRecordFieldsFromJson(json); + factory Fragment$dnsRecordFields.fromJson(Map json) { + final l$content = json['content']; + final l$name = json['name']; + final l$priority = json['priority']; + final l$recordType = json['recordType']; + final l$ttl = json['ttl']; + final l$$__typename = json['__typename']; + return Fragment$dnsRecordFields( + content: (l$content as String), + name: (l$name as String), + priority: (l$priority as int?), + recordType: (l$recordType as String), + ttl: (l$ttl as int), + $__typename: (l$$__typename as String), + ); + } final String content; @@ -764,10 +1294,26 @@ class Fragment$dnsRecordFields { final int ttl; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Fragment$dnsRecordFieldsToJson(this); + Map toJson() { + final _resultData = {}; + final l$content = content; + _resultData['content'] = l$content; + final l$name = name; + _resultData['name'] = l$name; + final l$priority = priority; + _resultData['priority'] = l$priority; + final l$recordType = recordType; + _resultData['recordType'] = l$recordType; + final l$ttl = ttl; + _resultData['ttl'] = l$ttl; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$content = content; final l$name = name; @@ -775,33 +1321,55 @@ class Fragment$dnsRecordFields { final l$recordType = recordType; final l$ttl = ttl; final l$$__typename = $__typename; - return Object.hashAll( - [l$content, l$name, l$priority, l$recordType, l$ttl, l$$__typename]); + return Object.hashAll([ + l$content, + l$name, + l$priority, + l$recordType, + l$ttl, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Fragment$dnsRecordFields) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$content = content; final lOther$content = other.content; - if (l$content != lOther$content) return false; + if (l$content != lOther$content) { + return false; + } final l$name = name; final lOther$name = other.name; - if (l$name != lOther$name) return false; + if (l$name != lOther$name) { + return false; + } final l$priority = priority; final lOther$priority = other.priority; - if (l$priority != lOther$priority) return false; + if (l$priority != lOther$priority) { + return false; + } final l$recordType = recordType; final lOther$recordType = other.recordType; - if (l$recordType != lOther$recordType) return false; + if (l$recordType != lOther$recordType) { + return false; + } final l$ttl = ttl; final lOther$ttl = other.ttl; - if (l$ttl != lOther$ttl) return false; + if (l$ttl != lOther$ttl) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -809,29 +1377,37 @@ class Fragment$dnsRecordFields { extension UtilityExtension$Fragment$dnsRecordFields on Fragment$dnsRecordFields { CopyWith$Fragment$dnsRecordFields get copyWith => - CopyWith$Fragment$dnsRecordFields(this, (i) => i); + CopyWith$Fragment$dnsRecordFields( + this, + (i) => i, + ); } abstract class CopyWith$Fragment$dnsRecordFields { - factory CopyWith$Fragment$dnsRecordFields(Fragment$dnsRecordFields instance, - TRes Function(Fragment$dnsRecordFields) then) = - _CopyWithImpl$Fragment$dnsRecordFields; + factory CopyWith$Fragment$dnsRecordFields( + Fragment$dnsRecordFields instance, + TRes Function(Fragment$dnsRecordFields) then, + ) = _CopyWithImpl$Fragment$dnsRecordFields; factory CopyWith$Fragment$dnsRecordFields.stub(TRes res) = _CopyWithStubImpl$Fragment$dnsRecordFields; - TRes call( - {String? content, - String? name, - int? priority, - String? recordType, - int? ttl, - String? $__typename}); + TRes call({ + String? content, + String? name, + int? priority, + String? recordType, + int? ttl, + String? $__typename, + }); } class _CopyWithImpl$Fragment$dnsRecordFields implements CopyWith$Fragment$dnsRecordFields { - _CopyWithImpl$Fragment$dnsRecordFields(this._instance, this._then); + _CopyWithImpl$Fragment$dnsRecordFields( + this._instance, + this._then, + ); final Fragment$dnsRecordFields _instance; @@ -839,29 +1415,31 @@ class _CopyWithImpl$Fragment$dnsRecordFields static const _undefined = {}; - TRes call( - {Object? content = _undefined, - Object? name = _undefined, - Object? priority = _undefined, - Object? recordType = _undefined, - Object? ttl = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? content = _undefined, + Object? name = _undefined, + Object? priority = _undefined, + Object? recordType = _undefined, + Object? ttl = _undefined, + Object? $__typename = _undefined, + }) => _then(Fragment$dnsRecordFields( - content: content == _undefined || content == null - ? _instance.content - : (content as String), - name: name == _undefined || name == null - ? _instance.name - : (name as String), - priority: - priority == _undefined ? _instance.priority : (priority as int?), - recordType: recordType == _undefined || recordType == null - ? _instance.recordType - : (recordType as String), - ttl: ttl == _undefined || ttl == null ? _instance.ttl : (ttl as int), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + content: content == _undefined || content == null + ? _instance.content + : (content as String), + name: name == _undefined || name == null + ? _instance.name + : (name as String), + priority: + priority == _undefined ? _instance.priority : (priority as int?), + recordType: recordType == _undefined || recordType == null + ? _instance.recordType + : (recordType as String), + ttl: ttl == _undefined || ttl == null ? _instance.ttl : (ttl as int), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Fragment$dnsRecordFields @@ -870,86 +1448,105 @@ class _CopyWithStubImpl$Fragment$dnsRecordFields TRes _res; - call( - {String? content, - String? name, - int? priority, - String? recordType, - int? ttl, - String? $__typename}) => + call({ + String? content, + String? name, + int? priority, + String? recordType, + int? ttl, + String? $__typename, + }) => _res; } const fragmentDefinitiondnsRecordFields = FragmentDefinitionNode( - name: NameNode(value: 'dnsRecordFields'), - typeCondition: TypeConditionNode( - on: NamedTypeNode( - name: NameNode(value: 'DnsRecord'), isNonNull: false)), - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'content'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'name'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'priority'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'recordType'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'ttl'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])); + name: NameNode(value: 'dnsRecordFields'), + typeCondition: TypeConditionNode( + on: NamedTypeNode( + name: NameNode(value: 'DnsRecord'), + isNonNull: false, + )), + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'content'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'name'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'priority'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'recordType'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'ttl'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), +); const documentNodeFragmentdnsRecordFields = DocumentNode(definitions: [ fragmentDefinitiondnsRecordFields, ]); extension ClientExtension$Fragment$dnsRecordFields on graphql.GraphQLClient { - void writeFragment$dnsRecordFields( - {required Fragment$dnsRecordFields data, - required Map idFields, - bool broadcast = true}) => + void writeFragment$dnsRecordFields({ + required Fragment$dnsRecordFields data, + required Map idFields, + bool broadcast = true, + }) => this.writeFragment( - graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'dnsRecordFields', - document: documentNodeFragmentdnsRecordFields)), - data: data.toJson(), - broadcast: broadcast); - Fragment$dnsRecordFields? readFragment$dnsRecordFields( - {required Map idFields, bool optimistic = true}) { - final result = this.readFragment( graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'dnsRecordFields', - document: documentNodeFragmentdnsRecordFields)), - optimistic: optimistic); + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'dnsRecordFields', + document: documentNodeFragmentdnsRecordFields, + ), + ), + data: data.toJson(), + broadcast: broadcast, + ); + Fragment$dnsRecordFields? readFragment$dnsRecordFields({ + required Map idFields, + bool optimistic = true, + }) { + final result = this.readFragment( + graphql.FragmentRequest( + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'dnsRecordFields', + document: documentNodeFragmentdnsRecordFields, + ), + ), + optimistic: optimistic, + ); return result == null ? null : Fragment$dnsRecordFields.fromJson(result); } } @@ -964,11 +1561,7 @@ const possibleTypesMap = { 'ServiceJobMutationReturn', 'ServiceMutationReturn', 'TimezoneMutationReturn', - 'UserMutationReturn' + 'UserMutationReturn', }, - 'StorageUsageInterface': {'ServiceStorageUsage'} + 'StorageUsageInterface': {'ServiceStorageUsage'}, }; -DateTime? _nullable$dateTimeFromJson(dynamic data) => - data == null ? null : dateTimeFromJson(data); -dynamic _nullable$dateTimeToJson(DateTime? data) => - data == null ? null : dateTimeToJson(data); diff --git a/lib/logic/api_maps/graphql_maps/schema/schema.graphql.g.dart b/lib/logic/api_maps/graphql_maps/schema/schema.graphql.g.dart deleted file mode 100644 index 7d1280c8..00000000 --- a/lib/logic/api_maps/graphql_maps/schema/schema.graphql.g.dart +++ /dev/null @@ -1,147 +0,0 @@ -// GENERATED CODE - DO NOT MODIFY BY HAND - -part of 'schema.graphql.dart'; - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -Input$AutoUpgradeSettingsInput _$Input$AutoUpgradeSettingsInputFromJson( - Map json) => - Input$AutoUpgradeSettingsInput( - enableAutoUpgrade: json['enableAutoUpgrade'] as bool?, - allowReboot: json['allowReboot'] as bool?, - ); - -Map _$Input$AutoUpgradeSettingsInputToJson( - Input$AutoUpgradeSettingsInput instance) => - { - 'enableAutoUpgrade': instance.enableAutoUpgrade, - 'allowReboot': instance.allowReboot, - }; - -Input$MigrateToBindsInput _$Input$MigrateToBindsInputFromJson( - Map json) => - Input$MigrateToBindsInput( - emailBlockDevice: json['emailBlockDevice'] as String, - bitwardenBlockDevice: json['bitwardenBlockDevice'] as String, - giteaBlockDevice: json['giteaBlockDevice'] as String, - nextcloudBlockDevice: json['nextcloudBlockDevice'] as String, - pleromaBlockDevice: json['pleromaBlockDevice'] as String, - ); - -Map _$Input$MigrateToBindsInputToJson( - Input$MigrateToBindsInput instance) => - { - 'emailBlockDevice': instance.emailBlockDevice, - 'bitwardenBlockDevice': instance.bitwardenBlockDevice, - 'giteaBlockDevice': instance.giteaBlockDevice, - 'nextcloudBlockDevice': instance.nextcloudBlockDevice, - 'pleromaBlockDevice': instance.pleromaBlockDevice, - }; - -Input$MoveServiceInput _$Input$MoveServiceInputFromJson( - Map json) => - Input$MoveServiceInput( - serviceId: json['serviceId'] as String, - location: json['location'] as String, - ); - -Map _$Input$MoveServiceInputToJson( - Input$MoveServiceInput instance) => - { - 'serviceId': instance.serviceId, - 'location': instance.location, - }; - -Input$RecoveryKeyLimitsInput _$Input$RecoveryKeyLimitsInputFromJson( - Map json) => - Input$RecoveryKeyLimitsInput( - expirationDate: _nullable$dateTimeFromJson(json['expirationDate']), - uses: json['uses'] as int?, - ); - -Map _$Input$RecoveryKeyLimitsInputToJson( - Input$RecoveryKeyLimitsInput instance) => - { - 'expirationDate': _nullable$dateTimeToJson(instance.expirationDate), - 'uses': instance.uses, - }; - -Input$SshMutationInput _$Input$SshMutationInputFromJson( - Map json) => - Input$SshMutationInput( - username: json['username'] as String, - sshKey: json['sshKey'] as String, - ); - -Map _$Input$SshMutationInputToJson( - Input$SshMutationInput instance) => - { - 'username': instance.username, - 'sshKey': instance.sshKey, - }; - -Input$UseNewDeviceKeyInput _$Input$UseNewDeviceKeyInputFromJson( - Map json) => - Input$UseNewDeviceKeyInput( - key: json['key'] as String, - deviceName: json['deviceName'] as String, - ); - -Map _$Input$UseNewDeviceKeyInputToJson( - Input$UseNewDeviceKeyInput instance) => - { - 'key': instance.key, - 'deviceName': instance.deviceName, - }; - -Input$UseRecoveryKeyInput _$Input$UseRecoveryKeyInputFromJson( - Map json) => - Input$UseRecoveryKeyInput( - key: json['key'] as String, - deviceName: json['deviceName'] as String, - ); - -Map _$Input$UseRecoveryKeyInputToJson( - Input$UseRecoveryKeyInput instance) => - { - 'key': instance.key, - 'deviceName': instance.deviceName, - }; - -Input$UserMutationInput _$Input$UserMutationInputFromJson( - Map json) => - Input$UserMutationInput( - username: json['username'] as String, - password: json['password'] as String, - ); - -Map _$Input$UserMutationInputToJson( - Input$UserMutationInput instance) => - { - 'username': instance.username, - 'password': instance.password, - }; - -Fragment$dnsRecordFields _$Fragment$dnsRecordFieldsFromJson( - Map json) => - Fragment$dnsRecordFields( - content: json['content'] as String, - name: json['name'] as String, - priority: json['priority'] as int?, - recordType: json['recordType'] as String, - ttl: json['ttl'] as int, - $__typename: json['__typename'] as String, - ); - -Map _$Fragment$dnsRecordFieldsToJson( - Fragment$dnsRecordFields instance) => - { - 'content': instance.content, - 'name': instance.name, - 'priority': instance.priority, - 'recordType': instance.recordType, - 'ttl': instance.ttl, - '__typename': instance.$__typename, - }; diff --git a/lib/logic/api_maps/graphql_maps/schema/server_api.graphql.dart b/lib/logic/api_maps/graphql_maps/schema/server_api.graphql.dart index 325ee89d..4bb33228 100644 --- a/lib/logic/api_maps/graphql_maps/schema/server_api.graphql.dart +++ b/lib/logic/api_maps/graphql_maps/schema/server_api.graphql.dart @@ -1,23 +1,70 @@ import 'dart:async'; +import 'disk_volumes.graphql.dart'; import 'package:gql/ast.dart'; import 'package:graphql/client.dart' as graphql; -import 'package:json_annotation/json_annotation.dart'; import 'package:selfprivacy/utils/scalars.dart'; import 'schema.graphql.dart'; -part 'server_api.graphql.g.dart'; -@JsonSerializable(explicitToJson: true) class Fragment$basicMutationReturnFields { - Fragment$basicMutationReturnFields( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + Fragment$basicMutationReturnFields({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Fragment$basicMutationReturnFields.fromJson( - Map json) => - _$Fragment$basicMutationReturnFieldsFromJson(json); + Map json) { + switch (json["__typename"] as String) { + case "ApiKeyMutationReturn": + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + .fromJson(json); + + case "AutoUpgradeSettingsMutationReturn": + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + .fromJson(json); + + case "DeviceApiTokenMutationReturn": + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + .fromJson(json); + + case "GenericJobButationReturn": + return Fragment$basicMutationReturnFields$$GenericJobButationReturn + .fromJson(json); + + case "GenericMutationReturn": + return Fragment$basicMutationReturnFields$$GenericMutationReturn + .fromJson(json); + + case "ServiceJobMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + .fromJson(json); + + case "ServiceMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceMutationReturn + .fromJson(json); + + case "TimezoneMutationReturn": + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn + .fromJson(json); + + case "UserMutationReturn": + return Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + json); + + default: + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + } final int code; @@ -25,36 +72,64 @@ class Fragment$basicMutationReturnFields { final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Fragment$basicMutationReturnFieldsToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Fragment$basicMutationReturnFields) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -63,25 +138,35 @@ extension UtilityExtension$Fragment$basicMutationReturnFields on Fragment$basicMutationReturnFields { CopyWith$Fragment$basicMutationReturnFields< Fragment$basicMutationReturnFields> - get copyWith => - CopyWith$Fragment$basicMutationReturnFields(this, (i) => i); + get copyWith => CopyWith$Fragment$basicMutationReturnFields( + this, + (i) => i, + ); } abstract class CopyWith$Fragment$basicMutationReturnFields { factory CopyWith$Fragment$basicMutationReturnFields( - Fragment$basicMutationReturnFields instance, - TRes Function(Fragment$basicMutationReturnFields) then) = - _CopyWithImpl$Fragment$basicMutationReturnFields; + Fragment$basicMutationReturnFields instance, + TRes Function(Fragment$basicMutationReturnFields) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields; factory CopyWith$Fragment$basicMutationReturnFields.stub(TRes res) = _CopyWithStubImpl$Fragment$basicMutationReturnFields; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Fragment$basicMutationReturnFields implements CopyWith$Fragment$basicMutationReturnFields { - _CopyWithImpl$Fragment$basicMutationReturnFields(this._instance, this._then); + _CopyWithImpl$Fragment$basicMutationReturnFields( + this._instance, + this._then, + ); final Fragment$basicMutationReturnFields _instance; @@ -89,24 +174,25 @@ class _CopyWithImpl$Fragment$basicMutationReturnFields static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Fragment$basicMutationReturnFields( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Fragment$basicMutationReturnFields @@ -115,43 +201,54 @@ class _CopyWithStubImpl$Fragment$basicMutationReturnFields TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } const fragmentDefinitionbasicMutationReturnFields = FragmentDefinitionNode( - name: NameNode(value: 'basicMutationReturnFields'), - typeCondition: TypeConditionNode( - on: NamedTypeNode( - name: NameNode(value: 'MutationReturnInterface'), - isNonNull: false)), - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'code'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'message'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'success'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])); + name: NameNode(value: 'basicMutationReturnFields'), + typeCondition: TypeConditionNode( + on: NamedTypeNode( + name: NameNode(value: 'MutationReturnInterface'), + isNonNull: false, + )), + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'code'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'message'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'success'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), +); const documentNodeFragmentbasicMutationReturnFields = DocumentNode(definitions: [ fragmentDefinitionbasicMutationReturnFields, @@ -159,88 +256,1751 @@ const documentNodeFragmentbasicMutationReturnFields = extension ClientExtension$Fragment$basicMutationReturnFields on graphql.GraphQLClient { - void writeFragment$basicMutationReturnFields( - {required Fragment$basicMutationReturnFields data, - required Map idFields, - bool broadcast = true}) => + void writeFragment$basicMutationReturnFields({ + required Fragment$basicMutationReturnFields data, + required Map idFields, + bool broadcast = true, + }) => this.writeFragment( - graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - data: data.toJson(), - broadcast: broadcast); - Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields( - {required Map idFields, bool optimistic = true}) { - final result = this.readFragment( graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - optimistic: optimistic); + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + data: data.toJson(), + broadcast: broadcast, + ); + Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields({ + required Map idFields, + bool optimistic = true, + }) { + final result = this.readFragment( + graphql.FragmentRequest( + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + optimistic: optimistic, + ); return result == null ? null : Fragment$basicMutationReturnFields.fromJson(result); } } -@JsonSerializable(explicitToJson: true) -class Query$GetApiVersion { - Query$GetApiVersion({required this.api, required this.$__typename}); +class Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override - factory Query$GetApiVersion.fromJson(Map json) => - _$Query$GetApiVersionFromJson(json); + factory Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } - final Query$GetApiVersion$api api; + final int code; + + final String message; + + final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetApiVersionToJson(this); - int get hashCode { - final l$api = api; + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; final l$$__typename = $__typename; - return Object.hashAll([l$api, l$$__typename]); + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetApiVersion) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) || + runtimeType != other.runtimeType) { return false; - final l$api = api; - final lOther$api = other.api; - if (l$api != lOther$api) return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + on Fragment$basicMutationReturnFields$$ApiKeyMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ApiKeyMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + on Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + instance, + TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + on Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn instance, + TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericJobButationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericJobButationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericJobButationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$GenericJobButationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericJobButationReturn + on Fragment$basicMutationReturnFields$$GenericJobButationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + Fragment$basicMutationReturnFields$$GenericJobButationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + Fragment$basicMutationReturnFields$$GenericJobButationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericJobButationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericJobButationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$GenericJobButationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$GenericMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericMutationReturn + on Fragment$basicMutationReturnFields$$GenericMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + Fragment$basicMutationReturnFields$$GenericMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + Fragment$basicMutationReturnFields$$GenericMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + on Fragment$basicMutationReturnFields$$ServiceJobMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceJobMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ServiceMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceMutationReturn + on Fragment$basicMutationReturnFields$$ServiceMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + Fragment$basicMutationReturnFields$$ServiceMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + Fragment$basicMutationReturnFields$$ServiceMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$TimezoneMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$TimezoneMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$TimezoneMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$TimezoneMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$TimezoneMutationReturn + on Fragment$basicMutationReturnFields$$TimezoneMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + Fragment$basicMutationReturnFields$$TimezoneMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$TimezoneMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$TimezoneMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$UserMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$UserMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$UserMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$UserMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$UserMutationReturn + on Fragment$basicMutationReturnFields$$UserMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + Fragment$basicMutationReturnFields$$UserMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + Fragment$basicMutationReturnFields$$UserMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$UserMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$UserMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Query$GetApiVersion { + Query$GetApiVersion({ + required this.api, + required this.$__typename, + }); + + factory Query$GetApiVersion.fromJson(Map json) { + final l$api = json['api']; + final l$$__typename = json['__typename']; + return Query$GetApiVersion( + api: Query$GetApiVersion$api.fromJson((l$api as Map)), + $__typename: (l$$__typename as String), + ); + } + + final Query$GetApiVersion$api api; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$api = api; + _resultData['api'] = l$api.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$api = api; + final l$$__typename = $__typename; + return Object.hashAll([ + l$api, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetApiVersion) || runtimeType != other.runtimeType) { + return false; + } + final l$api = api; + final lOther$api = other.api; + if (l$api != lOther$api) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$GetApiVersion on Query$GetApiVersion { CopyWith$Query$GetApiVersion get copyWith => - CopyWith$Query$GetApiVersion(this, (i) => i); + CopyWith$Query$GetApiVersion( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetApiVersion { - factory CopyWith$Query$GetApiVersion(Query$GetApiVersion instance, - TRes Function(Query$GetApiVersion) then) = - _CopyWithImpl$Query$GetApiVersion; + factory CopyWith$Query$GetApiVersion( + Query$GetApiVersion instance, + TRes Function(Query$GetApiVersion) then, + ) = _CopyWithImpl$Query$GetApiVersion; factory CopyWith$Query$GetApiVersion.stub(TRes res) = _CopyWithStubImpl$Query$GetApiVersion; - TRes call({Query$GetApiVersion$api? api, String? $__typename}); + TRes call({ + Query$GetApiVersion$api? api, + String? $__typename, + }); CopyWith$Query$GetApiVersion$api get api; } class _CopyWithImpl$Query$GetApiVersion implements CopyWith$Query$GetApiVersion { - _CopyWithImpl$Query$GetApiVersion(this._instance, this._then); + _CopyWithImpl$Query$GetApiVersion( + this._instance, + this._then, + ); final Query$GetApiVersion _instance; @@ -248,14 +2008,18 @@ class _CopyWithImpl$Query$GetApiVersion static const _undefined = {}; - TRes call({Object? api = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? api = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetApiVersion( - api: api == _undefined || api == null - ? _instance.api - : (api as Query$GetApiVersion$api), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + api: api == _undefined || api == null + ? _instance.api + : (api as Query$GetApiVersion$api), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$GetApiVersion$api get api { final local$api = _instance.api; return CopyWith$Query$GetApiVersion$api(local$api, (e) => call(api: e)); @@ -268,103 +2032,116 @@ class _CopyWithStubImpl$Query$GetApiVersion TRes _res; - call({Query$GetApiVersion$api? api, String? $__typename}) => _res; + call({ + Query$GetApiVersion$api? api, + String? $__typename, + }) => + _res; CopyWith$Query$GetApiVersion$api get api => CopyWith$Query$GetApiVersion$api.stub(_res); } const documentNodeQueryGetApiVersion = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'GetApiVersion'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'api'), + type: OperationType.query, + name: NameNode(value: 'GetApiVersion'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'api'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'version'), alias: null, arguments: [], directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'version'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), ]); Query$GetApiVersion _parserFn$Query$GetApiVersion(Map data) => Query$GetApiVersion.fromJson(data); class Options$Query$GetApiVersion extends graphql.QueryOptions { - Options$Query$GetApiVersion( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryGetApiVersion, - parserFn: _parserFn$Query$GetApiVersion); + Options$Query$GetApiVersion({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryGetApiVersion, + parserFn: _parserFn$Query$GetApiVersion, + ); } class WatchOptions$Query$GetApiVersion extends graphql.WatchQueryOptions { - WatchOptions$Query$GetApiVersion( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryGetApiVersion, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$GetApiVersion); + WatchOptions$Query$GetApiVersion({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryGetApiVersion, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$GetApiVersion, + ); } class FetchMoreOptions$Query$GetApiVersion extends graphql.FetchMoreOptions { FetchMoreOptions$Query$GetApiVersion( {required graphql.UpdateQuery updateQuery}) : super( - updateQuery: updateQuery, document: documentNodeQueryGetApiVersion); + updateQuery: updateQuery, + document: documentNodeQueryGetApiVersion, + ); } extension ClientExtension$Query$GetApiVersion on graphql.GraphQLClient { @@ -374,78 +2151,118 @@ extension ClientExtension$Query$GetApiVersion on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$GetApiVersion( [WatchOptions$Query$GetApiVersion? options]) => this.watchQuery(options ?? WatchOptions$Query$GetApiVersion()); - void writeQuery$GetApiVersion( - {required Query$GetApiVersion data, bool broadcast = true}) => + void writeQuery$GetApiVersion({ + required Query$GetApiVersion data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: - graphql.Operation(document: documentNodeQueryGetApiVersion)), - data: data.toJson(), - broadcast: broadcast); - Query$GetApiVersion? readQuery$GetApiVersion({bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation(document: documentNodeQueryGetApiVersion)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$GetApiVersion? readQuery$GetApiVersion({bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: + graphql.Operation(document: documentNodeQueryGetApiVersion)), + optimistic: optimistic, + ); return result == null ? null : Query$GetApiVersion.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$GetApiVersion$api { - Query$GetApiVersion$api({required this.version, required this.$__typename}); + Query$GetApiVersion$api({ + required this.version, + required this.$__typename, + }); - @override - factory Query$GetApiVersion$api.fromJson(Map json) => - _$Query$GetApiVersion$apiFromJson(json); + factory Query$GetApiVersion$api.fromJson(Map json) { + final l$version = json['version']; + final l$$__typename = json['__typename']; + return Query$GetApiVersion$api( + version: (l$version as String), + $__typename: (l$$__typename as String), + ); + } final String version; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetApiVersion$apiToJson(this); + Map toJson() { + final _resultData = {}; + final l$version = version; + _resultData['version'] = l$version; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$version = version; final l$$__typename = $__typename; - return Object.hashAll([l$version, l$$__typename]); + return Object.hashAll([ + l$version, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetApiVersion$api) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetApiVersion$api) || + runtimeType != other.runtimeType) { return false; + } final l$version = version; final lOther$version = other.version; - if (l$version != lOther$version) return false; + if (l$version != lOther$version) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$GetApiVersion$api on Query$GetApiVersion$api { CopyWith$Query$GetApiVersion$api get copyWith => - CopyWith$Query$GetApiVersion$api(this, (i) => i); + CopyWith$Query$GetApiVersion$api( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetApiVersion$api { - factory CopyWith$Query$GetApiVersion$api(Query$GetApiVersion$api instance, - TRes Function(Query$GetApiVersion$api) then) = - _CopyWithImpl$Query$GetApiVersion$api; + factory CopyWith$Query$GetApiVersion$api( + Query$GetApiVersion$api instance, + TRes Function(Query$GetApiVersion$api) then, + ) = _CopyWithImpl$Query$GetApiVersion$api; factory CopyWith$Query$GetApiVersion$api.stub(TRes res) = _CopyWithStubImpl$Query$GetApiVersion$api; - TRes call({String? version, String? $__typename}); + TRes call({ + String? version, + String? $__typename, + }); } class _CopyWithImpl$Query$GetApiVersion$api implements CopyWith$Query$GetApiVersion$api { - _CopyWithImpl$Query$GetApiVersion$api(this._instance, this._then); + _CopyWithImpl$Query$GetApiVersion$api( + this._instance, + this._then, + ); final Query$GetApiVersion$api _instance; @@ -453,14 +2270,18 @@ class _CopyWithImpl$Query$GetApiVersion$api static const _undefined = {}; - TRes call({Object? version = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? version = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetApiVersion$api( - version: version == _undefined || version == null - ? _instance.version - : (version as String), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + version: version == _undefined || version == null + ? _instance.version + : (version as String), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$GetApiVersion$api @@ -469,64 +2290,103 @@ class _CopyWithStubImpl$Query$GetApiVersion$api TRes _res; - call({String? version, String? $__typename}) => _res; + call({ + String? version, + String? $__typename, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Query$GetApiJobs { - Query$GetApiJobs({required this.jobs, required this.$__typename}); + Query$GetApiJobs({ + required this.jobs, + required this.$__typename, + }); - @override - factory Query$GetApiJobs.fromJson(Map json) => - _$Query$GetApiJobsFromJson(json); + factory Query$GetApiJobs.fromJson(Map json) { + final l$jobs = json['jobs']; + final l$$__typename = json['__typename']; + return Query$GetApiJobs( + jobs: Query$GetApiJobs$jobs.fromJson((l$jobs as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$GetApiJobs$jobs jobs; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetApiJobsToJson(this); + Map toJson() { + final _resultData = {}; + final l$jobs = jobs; + _resultData['jobs'] = l$jobs.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$jobs = jobs; final l$$__typename = $__typename; - return Object.hashAll([l$jobs, l$$__typename]); + return Object.hashAll([ + l$jobs, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetApiJobs) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetApiJobs) || runtimeType != other.runtimeType) { return false; + } final l$jobs = jobs; final lOther$jobs = other.jobs; - if (l$jobs != lOther$jobs) return false; + if (l$jobs != lOther$jobs) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$GetApiJobs on Query$GetApiJobs { CopyWith$Query$GetApiJobs get copyWith => - CopyWith$Query$GetApiJobs(this, (i) => i); + CopyWith$Query$GetApiJobs( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetApiJobs { factory CopyWith$Query$GetApiJobs( - Query$GetApiJobs instance, TRes Function(Query$GetApiJobs) then) = - _CopyWithImpl$Query$GetApiJobs; + Query$GetApiJobs instance, + TRes Function(Query$GetApiJobs) then, + ) = _CopyWithImpl$Query$GetApiJobs; factory CopyWith$Query$GetApiJobs.stub(TRes res) = _CopyWithStubImpl$Query$GetApiJobs; - TRes call({Query$GetApiJobs$jobs? jobs, String? $__typename}); + TRes call({ + Query$GetApiJobs$jobs? jobs, + String? $__typename, + }); CopyWith$Query$GetApiJobs$jobs get jobs; } class _CopyWithImpl$Query$GetApiJobs implements CopyWith$Query$GetApiJobs { - _CopyWithImpl$Query$GetApiJobs(this._instance, this._then); + _CopyWithImpl$Query$GetApiJobs( + this._instance, + this._then, + ); final Query$GetApiJobs _instance; @@ -534,14 +2394,18 @@ class _CopyWithImpl$Query$GetApiJobs static const _undefined = {}; - TRes call({Object? jobs = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? jobs = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetApiJobs( - jobs: jobs == _undefined || jobs == null - ? _instance.jobs - : (jobs as Query$GetApiJobs$jobs), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + jobs: jobs == _undefined || jobs == null + ? _instance.jobs + : (jobs as Query$GetApiJobs$jobs), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$GetApiJobs$jobs get jobs { final local$jobs = _instance.jobs; return CopyWith$Query$GetApiJobs$jobs(local$jobs, (e) => call(jobs: e)); @@ -554,173 +2418,199 @@ class _CopyWithStubImpl$Query$GetApiJobs TRes _res; - call({Query$GetApiJobs$jobs? jobs, String? $__typename}) => _res; + call({ + Query$GetApiJobs$jobs? jobs, + String? $__typename, + }) => + _res; CopyWith$Query$GetApiJobs$jobs get jobs => CopyWith$Query$GetApiJobs$jobs.stub(_res); } const documentNodeQueryGetApiJobs = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'GetApiJobs'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'jobs'), + type: OperationType.query, + name: NameNode(value: 'GetApiJobs'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'jobs'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'getJobs'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'getJobs'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'createdAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'description'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'error'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'finishedAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'name'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'progress'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'result'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'status'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'statusText'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'uid'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'updatedAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'createdAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'description'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'error'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'finishedAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'name'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'progress'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'result'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'status'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'statusText'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'uid'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'updatedAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), ]); Query$GetApiJobs _parserFn$Query$GetApiJobs(Map data) => Query$GetApiJobs.fromJson(data); class Options$Query$GetApiJobs extends graphql.QueryOptions { - Options$Query$GetApiJobs( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryGetApiJobs, - parserFn: _parserFn$Query$GetApiJobs); + Options$Query$GetApiJobs({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryGetApiJobs, + parserFn: _parserFn$Query$GetApiJobs, + ); } class WatchOptions$Query$GetApiJobs extends graphql.WatchQueryOptions { - WatchOptions$Query$GetApiJobs( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryGetApiJobs, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$GetApiJobs); + WatchOptions$Query$GetApiJobs({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryGetApiJobs, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$GetApiJobs, + ); } class FetchMoreOptions$Query$GetApiJobs extends graphql.FetchMoreOptions { FetchMoreOptions$Query$GetApiJobs({required graphql.UpdateQuery updateQuery}) - : super(updateQuery: updateQuery, document: documentNodeQueryGetApiJobs); + : super( + updateQuery: updateQuery, + document: documentNodeQueryGetApiJobs, + ); } extension ClientExtension$Query$GetApiJobs on graphql.GraphQLClient { @@ -730,81 +2620,118 @@ extension ClientExtension$Query$GetApiJobs on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$GetApiJobs( [WatchOptions$Query$GetApiJobs? options]) => this.watchQuery(options ?? WatchOptions$Query$GetApiJobs()); - void writeQuery$GetApiJobs( - {required Query$GetApiJobs data, bool broadcast = true}) => + void writeQuery$GetApiJobs({ + required Query$GetApiJobs data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: - graphql.Operation(document: documentNodeQueryGetApiJobs)), - data: data.toJson(), - broadcast: broadcast); - Query$GetApiJobs? readQuery$GetApiJobs({bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation(document: documentNodeQueryGetApiJobs)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$GetApiJobs? readQuery$GetApiJobs({bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: graphql.Operation(document: documentNodeQueryGetApiJobs)), + optimistic: optimistic, + ); return result == null ? null : Query$GetApiJobs.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$GetApiJobs$jobs { - Query$GetApiJobs$jobs({required this.getJobs, required this.$__typename}); + Query$GetApiJobs$jobs({ + required this.getJobs, + required this.$__typename, + }); - @override - factory Query$GetApiJobs$jobs.fromJson(Map json) => - _$Query$GetApiJobs$jobsFromJson(json); + factory Query$GetApiJobs$jobs.fromJson(Map json) { + final l$getJobs = json['getJobs']; + final l$$__typename = json['__typename']; + return Query$GetApiJobs$jobs( + getJobs: (l$getJobs as List) + .map((e) => Query$GetApiJobs$jobs$getJobs.fromJson( + (e as Map))) + .toList(), + $__typename: (l$$__typename as String), + ); + } final List getJobs; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetApiJobs$jobsToJson(this); + Map toJson() { + final _resultData = {}; + final l$getJobs = getJobs; + _resultData['getJobs'] = l$getJobs.map((e) => e.toJson()).toList(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$getJobs = getJobs; final l$$__typename = $__typename; - return Object.hashAll( - [Object.hashAll(l$getJobs.map((v) => v)), l$$__typename]); + return Object.hashAll([ + Object.hashAll(l$getJobs.map((v) => v)), + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetApiJobs$jobs) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetApiJobs$jobs) || runtimeType != other.runtimeType) { return false; + } final l$getJobs = getJobs; final lOther$getJobs = other.getJobs; - if (l$getJobs.length != lOther$getJobs.length) return false; + if (l$getJobs.length != lOther$getJobs.length) { + return false; + } for (int i = 0; i < l$getJobs.length; i++) { final l$getJobs$entry = l$getJobs[i]; final lOther$getJobs$entry = lOther$getJobs[i]; - if (l$getJobs$entry != lOther$getJobs$entry) return false; + if (l$getJobs$entry != lOther$getJobs$entry) { + return false; + } } - final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$GetApiJobs$jobs on Query$GetApiJobs$jobs { CopyWith$Query$GetApiJobs$jobs get copyWith => - CopyWith$Query$GetApiJobs$jobs(this, (i) => i); + CopyWith$Query$GetApiJobs$jobs( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetApiJobs$jobs { - factory CopyWith$Query$GetApiJobs$jobs(Query$GetApiJobs$jobs instance, - TRes Function(Query$GetApiJobs$jobs) then) = - _CopyWithImpl$Query$GetApiJobs$jobs; + factory CopyWith$Query$GetApiJobs$jobs( + Query$GetApiJobs$jobs instance, + TRes Function(Query$GetApiJobs$jobs) then, + ) = _CopyWithImpl$Query$GetApiJobs$jobs; factory CopyWith$Query$GetApiJobs$jobs.stub(TRes res) = _CopyWithStubImpl$Query$GetApiJobs$jobs; - TRes call( - {List? getJobs, String? $__typename}); + TRes call({ + List? getJobs, + String? $__typename, + }); TRes getJobs( Iterable Function( Iterable< @@ -815,7 +2742,10 @@ abstract class CopyWith$Query$GetApiJobs$jobs { class _CopyWithImpl$Query$GetApiJobs$jobs implements CopyWith$Query$GetApiJobs$jobs { - _CopyWithImpl$Query$GetApiJobs$jobs(this._instance, this._then); + _CopyWithImpl$Query$GetApiJobs$jobs( + this._instance, + this._then, + ); final Query$GetApiJobs$jobs _instance; @@ -823,14 +2753,18 @@ class _CopyWithImpl$Query$GetApiJobs$jobs static const _undefined = {}; - TRes call({Object? getJobs = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? getJobs = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetApiJobs$jobs( - getJobs: getJobs == _undefined || getJobs == null - ? _instance.getJobs - : (getJobs as List), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + getJobs: getJobs == _undefined || getJobs == null + ? _instance.getJobs + : (getJobs as List), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); TRes getJobs( Iterable Function( Iterable< @@ -838,9 +2772,11 @@ class _CopyWithImpl$Query$GetApiJobs$jobs Query$GetApiJobs$jobs$getJobs>>) _fn) => call( - getJobs: _fn(_instance.getJobs.map( - (e) => CopyWith$Query$GetApiJobs$jobs$getJobs(e, (i) => i))) - .toList()); + getJobs: _fn(_instance.getJobs + .map((e) => CopyWith$Query$GetApiJobs$jobs$getJobs( + e, + (i) => i, + ))).toList()); } class _CopyWithStubImpl$Query$GetApiJobs$jobs @@ -849,40 +2785,65 @@ class _CopyWithStubImpl$Query$GetApiJobs$jobs TRes _res; - call({List? getJobs, String? $__typename}) => + call({ + List? getJobs, + String? $__typename, + }) => _res; getJobs(_fn) => _res; } -@JsonSerializable(explicitToJson: true) class Query$GetApiJobs$jobs$getJobs { - Query$GetApiJobs$jobs$getJobs( - {required this.createdAt, - required this.description, - this.error, - this.finishedAt, - required this.name, - this.progress, - this.result, - required this.status, - this.statusText, - required this.uid, - required this.updatedAt, - required this.$__typename}); + Query$GetApiJobs$jobs$getJobs({ + required this.createdAt, + required this.description, + this.error, + this.finishedAt, + required this.name, + this.progress, + this.result, + required this.status, + this.statusText, + required this.uid, + required this.updatedAt, + required this.$__typename, + }); - @override - factory Query$GetApiJobs$jobs$getJobs.fromJson(Map json) => - _$Query$GetApiJobs$jobs$getJobsFromJson(json); + factory Query$GetApiJobs$jobs$getJobs.fromJson(Map json) { + final l$createdAt = json['createdAt']; + final l$description = json['description']; + final l$error = json['error']; + final l$finishedAt = json['finishedAt']; + final l$name = json['name']; + final l$progress = json['progress']; + final l$result = json['result']; + final l$status = json['status']; + final l$statusText = json['statusText']; + final l$uid = json['uid']; + final l$updatedAt = json['updatedAt']; + final l$$__typename = json['__typename']; + return Query$GetApiJobs$jobs$getJobs( + createdAt: dateTimeFromJson(l$createdAt), + description: (l$description as String), + error: (l$error as String?), + finishedAt: l$finishedAt == null ? null : dateTimeFromJson(l$finishedAt), + name: (l$name as String), + progress: (l$progress as int?), + result: (l$result as String?), + status: (l$status as String), + statusText: (l$statusText as String?), + uid: (l$uid as String), + updatedAt: dateTimeFromJson(l$updatedAt), + $__typename: (l$$__typename as String), + ); + } - @JsonKey(fromJson: dateTimeFromJson, toJson: dateTimeToJson) final DateTime createdAt; final String description; final String? error; - @JsonKey( - fromJson: _nullable$dateTimeFromJson, toJson: _nullable$dateTimeToJson) final DateTime? finishedAt; final String name; @@ -897,13 +2858,41 @@ class Query$GetApiJobs$jobs$getJobs { final String uid; - @JsonKey(fromJson: dateTimeFromJson, toJson: dateTimeToJson) final DateTime updatedAt; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetApiJobs$jobs$getJobsToJson(this); + Map toJson() { + final _resultData = {}; + final l$createdAt = createdAt; + _resultData['createdAt'] = dateTimeToJson(l$createdAt); + final l$description = description; + _resultData['description'] = l$description; + final l$error = error; + _resultData['error'] = l$error; + final l$finishedAt = finishedAt; + _resultData['finishedAt'] = + l$finishedAt == null ? null : dateTimeToJson(l$finishedAt); + final l$name = name; + _resultData['name'] = l$name; + final l$progress = progress; + _resultData['progress'] = l$progress; + final l$result = result; + _resultData['result'] = l$result; + final l$status = status; + _resultData['status'] = l$status; + final l$statusText = statusText; + _resultData['statusText'] = l$statusText; + final l$uid = uid; + _resultData['uid'] = l$uid; + final l$updatedAt = updatedAt; + _resultData['updatedAt'] = dateTimeToJson(l$updatedAt); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$createdAt = createdAt; final l$description = description; @@ -929,51 +2918,79 @@ class Query$GetApiJobs$jobs$getJobs { l$statusText, l$uid, l$updatedAt, - l$$__typename + l$$__typename, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$GetApiJobs$jobs$getJobs) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$createdAt = createdAt; final lOther$createdAt = other.createdAt; - if (l$createdAt != lOther$createdAt) return false; + if (l$createdAt != lOther$createdAt) { + return false; + } final l$description = description; final lOther$description = other.description; - if (l$description != lOther$description) return false; + if (l$description != lOther$description) { + return false; + } final l$error = error; final lOther$error = other.error; - if (l$error != lOther$error) return false; + if (l$error != lOther$error) { + return false; + } final l$finishedAt = finishedAt; final lOther$finishedAt = other.finishedAt; - if (l$finishedAt != lOther$finishedAt) return false; + if (l$finishedAt != lOther$finishedAt) { + return false; + } final l$name = name; final lOther$name = other.name; - if (l$name != lOther$name) return false; + if (l$name != lOther$name) { + return false; + } final l$progress = progress; final lOther$progress = other.progress; - if (l$progress != lOther$progress) return false; + if (l$progress != lOther$progress) { + return false; + } final l$result = result; final lOther$result = other.result; - if (l$result != lOther$result) return false; + if (l$result != lOther$result) { + return false; + } final l$status = status; final lOther$status = other.status; - if (l$status != lOther$status) return false; + if (l$status != lOther$status) { + return false; + } final l$statusText = statusText; final lOther$statusText = other.statusText; - if (l$statusText != lOther$statusText) return false; + if (l$statusText != lOther$statusText) { + return false; + } final l$uid = uid; final lOther$uid = other.uid; - if (l$uid != lOther$uid) return false; + if (l$uid != lOther$uid) { + return false; + } final l$updatedAt = updatedAt; final lOther$updatedAt = other.updatedAt; - if (l$updatedAt != lOther$updatedAt) return false; + if (l$updatedAt != lOther$updatedAt) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -981,36 +2998,43 @@ class Query$GetApiJobs$jobs$getJobs { extension UtilityExtension$Query$GetApiJobs$jobs$getJobs on Query$GetApiJobs$jobs$getJobs { CopyWith$Query$GetApiJobs$jobs$getJobs - get copyWith => CopyWith$Query$GetApiJobs$jobs$getJobs(this, (i) => i); + get copyWith => CopyWith$Query$GetApiJobs$jobs$getJobs( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetApiJobs$jobs$getJobs { factory CopyWith$Query$GetApiJobs$jobs$getJobs( - Query$GetApiJobs$jobs$getJobs instance, - TRes Function(Query$GetApiJobs$jobs$getJobs) then) = - _CopyWithImpl$Query$GetApiJobs$jobs$getJobs; + Query$GetApiJobs$jobs$getJobs instance, + TRes Function(Query$GetApiJobs$jobs$getJobs) then, + ) = _CopyWithImpl$Query$GetApiJobs$jobs$getJobs; factory CopyWith$Query$GetApiJobs$jobs$getJobs.stub(TRes res) = _CopyWithStubImpl$Query$GetApiJobs$jobs$getJobs; - TRes call( - {DateTime? createdAt, - String? description, - String? error, - DateTime? finishedAt, - String? name, - int? progress, - String? result, - String? status, - String? statusText, - String? uid, - DateTime? updatedAt, - String? $__typename}); + TRes call({ + DateTime? createdAt, + String? description, + String? error, + DateTime? finishedAt, + String? name, + int? progress, + String? result, + String? status, + String? statusText, + String? uid, + DateTime? updatedAt, + String? $__typename, + }); } class _CopyWithImpl$Query$GetApiJobs$jobs$getJobs implements CopyWith$Query$GetApiJobs$jobs$getJobs { - _CopyWithImpl$Query$GetApiJobs$jobs$getJobs(this._instance, this._then); + _CopyWithImpl$Query$GetApiJobs$jobs$getJobs( + this._instance, + this._then, + ); final Query$GetApiJobs$jobs$getJobs _instance; @@ -1018,51 +3042,51 @@ class _CopyWithImpl$Query$GetApiJobs$jobs$getJobs static const _undefined = {}; - TRes call( - {Object? createdAt = _undefined, - Object? description = _undefined, - Object? error = _undefined, - Object? finishedAt = _undefined, - Object? name = _undefined, - Object? progress = _undefined, - Object? result = _undefined, - Object? status = _undefined, - Object? statusText = _undefined, - Object? uid = _undefined, - Object? updatedAt = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? createdAt = _undefined, + Object? description = _undefined, + Object? error = _undefined, + Object? finishedAt = _undefined, + Object? name = _undefined, + Object? progress = _undefined, + Object? result = _undefined, + Object? status = _undefined, + Object? statusText = _undefined, + Object? uid = _undefined, + Object? updatedAt = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetApiJobs$jobs$getJobs( - createdAt: createdAt == _undefined || createdAt == null - ? _instance.createdAt - : (createdAt as DateTime), - description: description == _undefined || description == null - ? _instance.description - : (description as String), - error: error == _undefined ? _instance.error : (error as String?), - finishedAt: finishedAt == _undefined - ? _instance.finishedAt - : (finishedAt as DateTime?), - name: name == _undefined || name == null - ? _instance.name - : (name as String), - progress: - progress == _undefined ? _instance.progress : (progress as int?), - result: result == _undefined ? _instance.result : (result as String?), - status: status == _undefined || status == null - ? _instance.status - : (status as String), - statusText: statusText == _undefined - ? _instance.statusText - : (statusText as String?), - uid: uid == _undefined || uid == null - ? _instance.uid - : (uid as String), - updatedAt: updatedAt == _undefined || updatedAt == null - ? _instance.updatedAt - : (updatedAt as DateTime), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + createdAt: createdAt == _undefined || createdAt == null + ? _instance.createdAt + : (createdAt as DateTime), + description: description == _undefined || description == null + ? _instance.description + : (description as String), + error: error == _undefined ? _instance.error : (error as String?), + finishedAt: finishedAt == _undefined + ? _instance.finishedAt + : (finishedAt as DateTime?), + name: name == _undefined || name == null + ? _instance.name + : (name as String), + progress: + progress == _undefined ? _instance.progress : (progress as int?), + result: result == _undefined ? _instance.result : (result as String?), + status: status == _undefined || status == null + ? _instance.status + : (status as String), + statusText: statusText == _undefined + ? _instance.statusText + : (statusText as String?), + uid: uid == _undefined || uid == null ? _instance.uid : (uid as String), + updatedAt: updatedAt == _undefined || updatedAt == null + ? _instance.updatedAt + : (updatedAt as DateTime), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$GetApiJobs$jobs$getJobs @@ -1071,58 +3095,82 @@ class _CopyWithStubImpl$Query$GetApiJobs$jobs$getJobs TRes _res; - call( - {DateTime? createdAt, - String? description, - String? error, - DateTime? finishedAt, - String? name, - int? progress, - String? result, - String? status, - String? statusText, - String? uid, - DateTime? updatedAt, - String? $__typename}) => + call({ + DateTime? createdAt, + String? description, + String? error, + DateTime? finishedAt, + String? name, + int? progress, + String? result, + String? status, + String? statusText, + String? uid, + DateTime? updatedAt, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$RemoveJob { - Variables$Mutation$RemoveJob({required this.jobId}); + factory Variables$Mutation$RemoveJob({required String jobId}) => + Variables$Mutation$RemoveJob._({ + r'jobId': jobId, + }); + + Variables$Mutation$RemoveJob._(this._$data); + + factory Variables$Mutation$RemoveJob.fromJson(Map data) { + final result$data = {}; + final l$jobId = data['jobId']; + result$data['jobId'] = (l$jobId as String); + return Variables$Mutation$RemoveJob._(result$data); + } + + Map _$data; + + String get jobId => (_$data['jobId'] as String); + Map toJson() { + final result$data = {}; + final l$jobId = jobId; + result$data['jobId'] = l$jobId; + return result$data; + } + + CopyWith$Variables$Mutation$RemoveJob + get copyWith => CopyWith$Variables$Mutation$RemoveJob( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$RemoveJob) || + runtimeType != other.runtimeType) { + return false; + } + final l$jobId = jobId; + final lOther$jobId = other.jobId; + if (l$jobId != lOther$jobId) { + return false; + } + return true; + } @override - factory Variables$Mutation$RemoveJob.fromJson(Map json) => - _$Variables$Mutation$RemoveJobFromJson(json); - - final String jobId; - - Map toJson() => _$Variables$Mutation$RemoveJobToJson(this); int get hashCode { final l$jobId = jobId; return Object.hashAll([l$jobId]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$RemoveJob) || - runtimeType != other.runtimeType) return false; - final l$jobId = jobId; - final lOther$jobId = other.jobId; - if (l$jobId != lOther$jobId) return false; - return true; - } - - CopyWith$Variables$Mutation$RemoveJob - get copyWith => CopyWith$Variables$Mutation$RemoveJob(this, (i) => i); } abstract class CopyWith$Variables$Mutation$RemoveJob { factory CopyWith$Variables$Mutation$RemoveJob( - Variables$Mutation$RemoveJob instance, - TRes Function(Variables$Mutation$RemoveJob) then) = - _CopyWithImpl$Variables$Mutation$RemoveJob; + Variables$Mutation$RemoveJob instance, + TRes Function(Variables$Mutation$RemoveJob) then, + ) = _CopyWithImpl$Variables$Mutation$RemoveJob; factory CopyWith$Variables$Mutation$RemoveJob.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$RemoveJob; @@ -1132,7 +3180,10 @@ abstract class CopyWith$Variables$Mutation$RemoveJob { class _CopyWithImpl$Variables$Mutation$RemoveJob implements CopyWith$Variables$Mutation$RemoveJob { - _CopyWithImpl$Variables$Mutation$RemoveJob(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$RemoveJob( + this._instance, + this._then, + ); final Variables$Mutation$RemoveJob _instance; @@ -1140,10 +3191,11 @@ class _CopyWithImpl$Variables$Mutation$RemoveJob static const _undefined = {}; - TRes call({Object? jobId = _undefined}) => _then(Variables$Mutation$RemoveJob( - jobId: jobId == _undefined || jobId == null - ? _instance.jobId - : (jobId as String))); + TRes call({Object? jobId = _undefined}) => + _then(Variables$Mutation$RemoveJob._({ + ..._instance._$data, + if (jobId != _undefined && jobId != null) 'jobId': (jobId as String), + })); } class _CopyWithStubImpl$Variables$Mutation$RemoveJob @@ -1155,61 +3207,97 @@ class _CopyWithStubImpl$Variables$Mutation$RemoveJob call({String? jobId}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$RemoveJob { - Mutation$RemoveJob({required this.removeJob, required this.$__typename}); + Mutation$RemoveJob({ + required this.removeJob, + required this.$__typename, + }); - @override - factory Mutation$RemoveJob.fromJson(Map json) => - _$Mutation$RemoveJobFromJson(json); + factory Mutation$RemoveJob.fromJson(Map json) { + final l$removeJob = json['removeJob']; + final l$$__typename = json['__typename']; + return Mutation$RemoveJob( + removeJob: Mutation$RemoveJob$removeJob.fromJson( + (l$removeJob as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$RemoveJob$removeJob removeJob; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RemoveJobToJson(this); + Map toJson() { + final _resultData = {}; + final l$removeJob = removeJob; + _resultData['removeJob'] = l$removeJob.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$removeJob = removeJob; final l$$__typename = $__typename; - return Object.hashAll([l$removeJob, l$$__typename]); + return Object.hashAll([ + l$removeJob, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$RemoveJob) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$RemoveJob) || runtimeType != other.runtimeType) { return false; + } final l$removeJob = removeJob; final lOther$removeJob = other.removeJob; - if (l$removeJob != lOther$removeJob) return false; + if (l$removeJob != lOther$removeJob) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$RemoveJob on Mutation$RemoveJob { CopyWith$Mutation$RemoveJob get copyWith => - CopyWith$Mutation$RemoveJob(this, (i) => i); + CopyWith$Mutation$RemoveJob( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RemoveJob { factory CopyWith$Mutation$RemoveJob( - Mutation$RemoveJob instance, TRes Function(Mutation$RemoveJob) then) = - _CopyWithImpl$Mutation$RemoveJob; + Mutation$RemoveJob instance, + TRes Function(Mutation$RemoveJob) then, + ) = _CopyWithImpl$Mutation$RemoveJob; factory CopyWith$Mutation$RemoveJob.stub(TRes res) = _CopyWithStubImpl$Mutation$RemoveJob; - TRes call({Mutation$RemoveJob$removeJob? removeJob, String? $__typename}); + TRes call({ + Mutation$RemoveJob$removeJob? removeJob, + String? $__typename, + }); CopyWith$Mutation$RemoveJob$removeJob get removeJob; } class _CopyWithImpl$Mutation$RemoveJob implements CopyWith$Mutation$RemoveJob { - _CopyWithImpl$Mutation$RemoveJob(this._instance, this._then); + _CopyWithImpl$Mutation$RemoveJob( + this._instance, + this._then, + ); final Mutation$RemoveJob _instance; @@ -1217,15 +3305,18 @@ class _CopyWithImpl$Mutation$RemoveJob static const _undefined = {}; - TRes call( - {Object? removeJob = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? removeJob = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RemoveJob( - removeJob: removeJob == _undefined || removeJob == null - ? _instance.removeJob - : (removeJob as Mutation$RemoveJob$removeJob), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + removeJob: removeJob == _undefined || removeJob == null + ? _instance.removeJob + : (removeJob as Mutation$RemoveJob$removeJob), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$RemoveJob$removeJob get removeJob { final local$removeJob = _instance.removeJob; return CopyWith$Mutation$RemoveJob$removeJob( @@ -1239,89 +3330,107 @@ class _CopyWithStubImpl$Mutation$RemoveJob TRes _res; - call({Mutation$RemoveJob$removeJob? removeJob, String? $__typename}) => _res; + call({ + Mutation$RemoveJob$removeJob? removeJob, + String? $__typename, + }) => + _res; CopyWith$Mutation$RemoveJob$removeJob get removeJob => CopyWith$Mutation$RemoveJob$removeJob.stub(_res); } const documentNodeMutationRemoveJob = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'RemoveJob'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'jobId')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'removeJob'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'jobId'), - value: VariableNode(name: NameNode(value: 'jobId'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'RemoveJob'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'jobId')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'removeJob'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'jobId'), + value: VariableNode(name: NameNode(value: 'jobId')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$RemoveJob _parserFn$Mutation$RemoveJob(Map data) => Mutation$RemoveJob.fromJson(data); typedef OnMutationCompleted$Mutation$RemoveJob = FutureOr Function( - dynamic, Mutation$RemoveJob?); + dynamic, + Mutation$RemoveJob?, +); class Options$Mutation$RemoveJob extends graphql.MutationOptions { - Options$Mutation$RemoveJob( - {String? operationName, - required Variables$Mutation$RemoveJob variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$RemoveJob? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$RemoveJob({ + String? operationName, + required Variables$Mutation$RemoveJob variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$RemoveJob? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted(data, - data == null ? null : _parserFn$Mutation$RemoveJob(data)), - update: update, - onError: onError, - document: documentNodeMutationRemoveJob, - parserFn: _parserFn$Mutation$RemoveJob); + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( + data, + data == null ? null : _parserFn$Mutation$RemoveJob(data), + ), + update: update, + onError: onError, + document: documentNodeMutationRemoveJob, + parserFn: _parserFn$Mutation$RemoveJob, + ); final OnMutationCompleted$Mutation$RemoveJob? onCompletedWithParsed; @@ -1330,38 +3439,39 @@ class Options$Mutation$RemoveJob ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$RemoveJob extends graphql.WatchQueryOptions { - WatchOptions$Mutation$RemoveJob( - {String? operationName, - required Variables$Mutation$RemoveJob variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationRemoveJob, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$RemoveJob); + WatchOptions$Mutation$RemoveJob({ + String? operationName, + required Variables$Mutation$RemoveJob variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationRemoveJob, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$RemoveJob, + ); } extension ClientExtension$Mutation$RemoveJob on graphql.GraphQLClient { @@ -1373,18 +3483,27 @@ extension ClientExtension$Mutation$RemoveJob on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$RemoveJob$removeJob - implements Fragment$basicMutationReturnFields { - Mutation$RemoveJob$removeJob( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$RemoveJob$removeJob({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override - factory Mutation$RemoveJob$removeJob.fromJson(Map json) => - _$Mutation$RemoveJob$removeJobFromJson(json); + factory Mutation$RemoveJob$removeJob.fromJson(Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$RemoveJob$removeJob( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -1392,35 +3511,64 @@ class Mutation$RemoveJob$removeJob final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RemoveJob$removeJobToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RemoveJob$removeJob) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1428,24 +3576,35 @@ class Mutation$RemoveJob$removeJob extension UtilityExtension$Mutation$RemoveJob$removeJob on Mutation$RemoveJob$removeJob { CopyWith$Mutation$RemoveJob$removeJob - get copyWith => CopyWith$Mutation$RemoveJob$removeJob(this, (i) => i); + get copyWith => CopyWith$Mutation$RemoveJob$removeJob( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RemoveJob$removeJob { factory CopyWith$Mutation$RemoveJob$removeJob( - Mutation$RemoveJob$removeJob instance, - TRes Function(Mutation$RemoveJob$removeJob) then) = - _CopyWithImpl$Mutation$RemoveJob$removeJob; + Mutation$RemoveJob$removeJob instance, + TRes Function(Mutation$RemoveJob$removeJob) then, + ) = _CopyWithImpl$Mutation$RemoveJob$removeJob; factory CopyWith$Mutation$RemoveJob$removeJob.stub(TRes res) = _CopyWithStubImpl$Mutation$RemoveJob$removeJob; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$RemoveJob$removeJob implements CopyWith$Mutation$RemoveJob$removeJob { - _CopyWithImpl$Mutation$RemoveJob$removeJob(this._instance, this._then); + _CopyWithImpl$Mutation$RemoveJob$removeJob( + this._instance, + this._then, + ); final Mutation$RemoveJob$removeJob _instance; @@ -1453,24 +3612,25 @@ class _CopyWithImpl$Mutation$RemoveJob$removeJob static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RemoveJob$removeJob( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$RemoveJob$removeJob @@ -1479,42 +3639,73 @@ class _CopyWithStubImpl$Mutation$RemoveJob$removeJob TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$RunSystemRebuild { - Mutation$RunSystemRebuild( - {required this.runSystemRebuild, required this.$__typename}); + Mutation$RunSystemRebuild({ + required this.runSystemRebuild, + required this.$__typename, + }); - @override - factory Mutation$RunSystemRebuild.fromJson(Map json) => - _$Mutation$RunSystemRebuildFromJson(json); + factory Mutation$RunSystemRebuild.fromJson(Map json) { + final l$runSystemRebuild = json['runSystemRebuild']; + final l$$__typename = json['__typename']; + return Mutation$RunSystemRebuild( + runSystemRebuild: Mutation$RunSystemRebuild$runSystemRebuild.fromJson( + (l$runSystemRebuild as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$RunSystemRebuild$runSystemRebuild runSystemRebuild; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RunSystemRebuildToJson(this); + Map toJson() { + final _resultData = {}; + final l$runSystemRebuild = runSystemRebuild; + _resultData['runSystemRebuild'] = l$runSystemRebuild.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$runSystemRebuild = runSystemRebuild; final l$$__typename = $__typename; - return Object.hashAll([l$runSystemRebuild, l$$__typename]); + return Object.hashAll([ + l$runSystemRebuild, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RunSystemRebuild) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$runSystemRebuild = runSystemRebuild; final lOther$runSystemRebuild = other.runSystemRebuild; - if (l$runSystemRebuild != lOther$runSystemRebuild) return false; + if (l$runSystemRebuild != lOther$runSystemRebuild) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1522,27 +3713,35 @@ class Mutation$RunSystemRebuild { extension UtilityExtension$Mutation$RunSystemRebuild on Mutation$RunSystemRebuild { CopyWith$Mutation$RunSystemRebuild get copyWith => - CopyWith$Mutation$RunSystemRebuild(this, (i) => i); + CopyWith$Mutation$RunSystemRebuild( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RunSystemRebuild { - factory CopyWith$Mutation$RunSystemRebuild(Mutation$RunSystemRebuild instance, - TRes Function(Mutation$RunSystemRebuild) then) = - _CopyWithImpl$Mutation$RunSystemRebuild; + factory CopyWith$Mutation$RunSystemRebuild( + Mutation$RunSystemRebuild instance, + TRes Function(Mutation$RunSystemRebuild) then, + ) = _CopyWithImpl$Mutation$RunSystemRebuild; factory CopyWith$Mutation$RunSystemRebuild.stub(TRes res) = _CopyWithStubImpl$Mutation$RunSystemRebuild; - TRes call( - {Mutation$RunSystemRebuild$runSystemRebuild? runSystemRebuild, - String? $__typename}); + TRes call({ + Mutation$RunSystemRebuild$runSystemRebuild? runSystemRebuild, + String? $__typename, + }); CopyWith$Mutation$RunSystemRebuild$runSystemRebuild get runSystemRebuild; } class _CopyWithImpl$Mutation$RunSystemRebuild implements CopyWith$Mutation$RunSystemRebuild { - _CopyWithImpl$Mutation$RunSystemRebuild(this._instance, this._then); + _CopyWithImpl$Mutation$RunSystemRebuild( + this._instance, + this._then, + ); final Mutation$RunSystemRebuild _instance; @@ -1550,18 +3749,19 @@ class _CopyWithImpl$Mutation$RunSystemRebuild static const _undefined = {}; - TRes call( - {Object? runSystemRebuild = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? runSystemRebuild = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RunSystemRebuild( - runSystemRebuild: - runSystemRebuild == _undefined || runSystemRebuild == null - ? _instance.runSystemRebuild - : (runSystemRebuild - as Mutation$RunSystemRebuild$runSystemRebuild), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + runSystemRebuild: runSystemRebuild == _undefined || + runSystemRebuild == null + ? _instance.runSystemRebuild + : (runSystemRebuild as Mutation$RunSystemRebuild$runSystemRebuild), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$RunSystemRebuild$runSystemRebuild get runSystemRebuild { final local$runSystemRebuild = _instance.runSystemRebuild; @@ -1576,9 +3776,10 @@ class _CopyWithStubImpl$Mutation$RunSystemRebuild TRes _res; - call( - {Mutation$RunSystemRebuild$runSystemRebuild? runSystemRebuild, - String? $__typename}) => + call({ + Mutation$RunSystemRebuild$runSystemRebuild? runSystemRebuild, + String? $__typename, + }) => _res; CopyWith$Mutation$RunSystemRebuild$runSystemRebuild get runSystemRebuild => @@ -1587,73 +3788,82 @@ class _CopyWithStubImpl$Mutation$RunSystemRebuild const documentNodeMutationRunSystemRebuild = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'RunSystemRebuild'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'runSystemRebuild'), - alias: null, - arguments: [], + type: OperationType.mutation, + name: NameNode(value: 'RunSystemRebuild'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'runSystemRebuild'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$RunSystemRebuild _parserFn$Mutation$RunSystemRebuild( Map data) => Mutation$RunSystemRebuild.fromJson(data); typedef OnMutationCompleted$Mutation$RunSystemRebuild = FutureOr Function( - dynamic, Mutation$RunSystemRebuild?); + dynamic, + Mutation$RunSystemRebuild?, +); class Options$Mutation$RunSystemRebuild extends graphql.MutationOptions { - Options$Mutation$RunSystemRebuild( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$RunSystemRebuild? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$RunSystemRebuild({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$RunSystemRebuild? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$RunSystemRebuild(data)), - update: update, - onError: onError, - document: documentNodeMutationRunSystemRebuild, - parserFn: _parserFn$Mutation$RunSystemRebuild); + : _parserFn$Mutation$RunSystemRebuild(data), + ), + update: update, + onError: onError, + document: documentNodeMutationRunSystemRebuild, + parserFn: _parserFn$Mutation$RunSystemRebuild, + ); final OnMutationCompleted$Mutation$RunSystemRebuild? onCompletedWithParsed; @@ -1662,36 +3872,37 @@ class Options$Mutation$RunSystemRebuild ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$RunSystemRebuild extends graphql.WatchQueryOptions { - WatchOptions$Mutation$RunSystemRebuild( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationRunSystemRebuild, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$RunSystemRebuild); + WatchOptions$Mutation$RunSystemRebuild({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationRunSystemRebuild, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$RunSystemRebuild, + ); } extension ClientExtension$Mutation$RunSystemRebuild on graphql.GraphQLClient { @@ -1705,19 +3916,28 @@ extension ClientExtension$Mutation$RunSystemRebuild on graphql.GraphQLClient { this.watchMutation(options ?? WatchOptions$Mutation$RunSystemRebuild()); } -@JsonSerializable(explicitToJson: true) class Mutation$RunSystemRebuild$runSystemRebuild - implements Fragment$basicMutationReturnFields { - Mutation$RunSystemRebuild$runSystemRebuild( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$RunSystemRebuild$runSystemRebuild({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$RunSystemRebuild$runSystemRebuild.fromJson( - Map json) => - _$Mutation$RunSystemRebuild$runSystemRebuildFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$RunSystemRebuild$runSystemRebuild( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -1725,36 +3945,64 @@ class Mutation$RunSystemRebuild$runSystemRebuild final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$RunSystemRebuild$runSystemRebuildToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RunSystemRebuild$runSystemRebuild) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1763,26 +4011,35 @@ extension UtilityExtension$Mutation$RunSystemRebuild$runSystemRebuild on Mutation$RunSystemRebuild$runSystemRebuild { CopyWith$Mutation$RunSystemRebuild$runSystemRebuild< Mutation$RunSystemRebuild$runSystemRebuild> - get copyWith => - CopyWith$Mutation$RunSystemRebuild$runSystemRebuild(this, (i) => i); + get copyWith => CopyWith$Mutation$RunSystemRebuild$runSystemRebuild( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RunSystemRebuild$runSystemRebuild { factory CopyWith$Mutation$RunSystemRebuild$runSystemRebuild( - Mutation$RunSystemRebuild$runSystemRebuild instance, - TRes Function(Mutation$RunSystemRebuild$runSystemRebuild) then) = - _CopyWithImpl$Mutation$RunSystemRebuild$runSystemRebuild; + Mutation$RunSystemRebuild$runSystemRebuild instance, + TRes Function(Mutation$RunSystemRebuild$runSystemRebuild) then, + ) = _CopyWithImpl$Mutation$RunSystemRebuild$runSystemRebuild; factory CopyWith$Mutation$RunSystemRebuild$runSystemRebuild.stub(TRes res) = _CopyWithStubImpl$Mutation$RunSystemRebuild$runSystemRebuild; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$RunSystemRebuild$runSystemRebuild implements CopyWith$Mutation$RunSystemRebuild$runSystemRebuild { _CopyWithImpl$Mutation$RunSystemRebuild$runSystemRebuild( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$RunSystemRebuild$runSystemRebuild _instance; @@ -1790,24 +4047,25 @@ class _CopyWithImpl$Mutation$RunSystemRebuild$runSystemRebuild static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RunSystemRebuild$runSystemRebuild( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$RunSystemRebuild$runSystemRebuild @@ -1816,42 +4074,73 @@ class _CopyWithStubImpl$Mutation$RunSystemRebuild$runSystemRebuild TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$RunSystemRollback { - Mutation$RunSystemRollback( - {required this.runSystemRollback, required this.$__typename}); + Mutation$RunSystemRollback({ + required this.runSystemRollback, + required this.$__typename, + }); - @override - factory Mutation$RunSystemRollback.fromJson(Map json) => - _$Mutation$RunSystemRollbackFromJson(json); + factory Mutation$RunSystemRollback.fromJson(Map json) { + final l$runSystemRollback = json['runSystemRollback']; + final l$$__typename = json['__typename']; + return Mutation$RunSystemRollback( + runSystemRollback: Mutation$RunSystemRollback$runSystemRollback.fromJson( + (l$runSystemRollback as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$RunSystemRollback$runSystemRollback runSystemRollback; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RunSystemRollbackToJson(this); + Map toJson() { + final _resultData = {}; + final l$runSystemRollback = runSystemRollback; + _resultData['runSystemRollback'] = l$runSystemRollback.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$runSystemRollback = runSystemRollback; final l$$__typename = $__typename; - return Object.hashAll([l$runSystemRollback, l$$__typename]); + return Object.hashAll([ + l$runSystemRollback, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RunSystemRollback) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$runSystemRollback = runSystemRollback; final lOther$runSystemRollback = other.runSystemRollback; - if (l$runSystemRollback != lOther$runSystemRollback) return false; + if (l$runSystemRollback != lOther$runSystemRollback) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1859,28 +4148,35 @@ class Mutation$RunSystemRollback { extension UtilityExtension$Mutation$RunSystemRollback on Mutation$RunSystemRollback { CopyWith$Mutation$RunSystemRollback - get copyWith => CopyWith$Mutation$RunSystemRollback(this, (i) => i); + get copyWith => CopyWith$Mutation$RunSystemRollback( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RunSystemRollback { factory CopyWith$Mutation$RunSystemRollback( - Mutation$RunSystemRollback instance, - TRes Function(Mutation$RunSystemRollback) then) = - _CopyWithImpl$Mutation$RunSystemRollback; + Mutation$RunSystemRollback instance, + TRes Function(Mutation$RunSystemRollback) then, + ) = _CopyWithImpl$Mutation$RunSystemRollback; factory CopyWith$Mutation$RunSystemRollback.stub(TRes res) = _CopyWithStubImpl$Mutation$RunSystemRollback; - TRes call( - {Mutation$RunSystemRollback$runSystemRollback? runSystemRollback, - String? $__typename}); + TRes call({ + Mutation$RunSystemRollback$runSystemRollback? runSystemRollback, + String? $__typename, + }); CopyWith$Mutation$RunSystemRollback$runSystemRollback get runSystemRollback; } class _CopyWithImpl$Mutation$RunSystemRollback implements CopyWith$Mutation$RunSystemRollback { - _CopyWithImpl$Mutation$RunSystemRollback(this._instance, this._then); + _CopyWithImpl$Mutation$RunSystemRollback( + this._instance, + this._then, + ); final Mutation$RunSystemRollback _instance; @@ -1888,18 +4184,20 @@ class _CopyWithImpl$Mutation$RunSystemRollback static const _undefined = {}; - TRes call( - {Object? runSystemRollback = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? runSystemRollback = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RunSystemRollback( - runSystemRollback: - runSystemRollback == _undefined || runSystemRollback == null - ? _instance.runSystemRollback - : (runSystemRollback - as Mutation$RunSystemRollback$runSystemRollback), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + runSystemRollback: + runSystemRollback == _undefined || runSystemRollback == null + ? _instance.runSystemRollback + : (runSystemRollback + as Mutation$RunSystemRollback$runSystemRollback), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$RunSystemRollback$runSystemRollback get runSystemRollback { final local$runSystemRollback = _instance.runSystemRollback; @@ -1914,9 +4212,10 @@ class _CopyWithStubImpl$Mutation$RunSystemRollback TRes _res; - call( - {Mutation$RunSystemRollback$runSystemRollback? runSystemRollback, - String? $__typename}) => + call({ + Mutation$RunSystemRollback$runSystemRollback? runSystemRollback, + String? $__typename, + }) => _res; CopyWith$Mutation$RunSystemRollback$runSystemRollback get runSystemRollback => @@ -1925,73 +4224,83 @@ class _CopyWithStubImpl$Mutation$RunSystemRollback const documentNodeMutationRunSystemRollback = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'RunSystemRollback'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'runSystemRollback'), - alias: null, - arguments: [], + type: OperationType.mutation, + name: NameNode(value: 'RunSystemRollback'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'runSystemRollback'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$RunSystemRollback _parserFn$Mutation$RunSystemRollback( Map data) => Mutation$RunSystemRollback.fromJson(data); typedef OnMutationCompleted$Mutation$RunSystemRollback = FutureOr - Function(dynamic, Mutation$RunSystemRollback?); + Function( + dynamic, + Mutation$RunSystemRollback?, +); class Options$Mutation$RunSystemRollback extends graphql.MutationOptions { - Options$Mutation$RunSystemRollback( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$RunSystemRollback? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$RunSystemRollback({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$RunSystemRollback? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$RunSystemRollback(data)), - update: update, - onError: onError, - document: documentNodeMutationRunSystemRollback, - parserFn: _parserFn$Mutation$RunSystemRollback); + : _parserFn$Mutation$RunSystemRollback(data), + ), + update: update, + onError: onError, + document: documentNodeMutationRunSystemRollback, + parserFn: _parserFn$Mutation$RunSystemRollback, + ); final OnMutationCompleted$Mutation$RunSystemRollback? onCompletedWithParsed; @@ -2000,36 +4309,37 @@ class Options$Mutation$RunSystemRollback ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$RunSystemRollback extends graphql.WatchQueryOptions { - WatchOptions$Mutation$RunSystemRollback( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationRunSystemRollback, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$RunSystemRollback); + WatchOptions$Mutation$RunSystemRollback({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationRunSystemRollback, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$RunSystemRollback, + ); } extension ClientExtension$Mutation$RunSystemRollback on graphql.GraphQLClient { @@ -2043,19 +4353,28 @@ extension ClientExtension$Mutation$RunSystemRollback on graphql.GraphQLClient { this.watchMutation(options ?? WatchOptions$Mutation$RunSystemRollback()); } -@JsonSerializable(explicitToJson: true) class Mutation$RunSystemRollback$runSystemRollback - implements Fragment$basicMutationReturnFields { - Mutation$RunSystemRollback$runSystemRollback( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$RunSystemRollback$runSystemRollback({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$RunSystemRollback$runSystemRollback.fromJson( - Map json) => - _$Mutation$RunSystemRollback$runSystemRollbackFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$RunSystemRollback$runSystemRollback( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -2063,36 +4382,64 @@ class Mutation$RunSystemRollback$runSystemRollback final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$RunSystemRollback$runSystemRollbackToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RunSystemRollback$runSystemRollback) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2101,26 +4448,35 @@ extension UtilityExtension$Mutation$RunSystemRollback$runSystemRollback on Mutation$RunSystemRollback$runSystemRollback { CopyWith$Mutation$RunSystemRollback$runSystemRollback< Mutation$RunSystemRollback$runSystemRollback> - get copyWith => - CopyWith$Mutation$RunSystemRollback$runSystemRollback(this, (i) => i); + get copyWith => CopyWith$Mutation$RunSystemRollback$runSystemRollback( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RunSystemRollback$runSystemRollback { factory CopyWith$Mutation$RunSystemRollback$runSystemRollback( - Mutation$RunSystemRollback$runSystemRollback instance, - TRes Function(Mutation$RunSystemRollback$runSystemRollback) then) = - _CopyWithImpl$Mutation$RunSystemRollback$runSystemRollback; + Mutation$RunSystemRollback$runSystemRollback instance, + TRes Function(Mutation$RunSystemRollback$runSystemRollback) then, + ) = _CopyWithImpl$Mutation$RunSystemRollback$runSystemRollback; factory CopyWith$Mutation$RunSystemRollback$runSystemRollback.stub(TRes res) = _CopyWithStubImpl$Mutation$RunSystemRollback$runSystemRollback; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$RunSystemRollback$runSystemRollback implements CopyWith$Mutation$RunSystemRollback$runSystemRollback { _CopyWithImpl$Mutation$RunSystemRollback$runSystemRollback( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$RunSystemRollback$runSystemRollback _instance; @@ -2128,24 +4484,25 @@ class _CopyWithImpl$Mutation$RunSystemRollback$runSystemRollback static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RunSystemRollback$runSystemRollback( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$RunSystemRollback$runSystemRollback @@ -2154,42 +4511,73 @@ class _CopyWithStubImpl$Mutation$RunSystemRollback$runSystemRollback TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$RunSystemUpgrade { - Mutation$RunSystemUpgrade( - {required this.runSystemUpgrade, required this.$__typename}); + Mutation$RunSystemUpgrade({ + required this.runSystemUpgrade, + required this.$__typename, + }); - @override - factory Mutation$RunSystemUpgrade.fromJson(Map json) => - _$Mutation$RunSystemUpgradeFromJson(json); + factory Mutation$RunSystemUpgrade.fromJson(Map json) { + final l$runSystemUpgrade = json['runSystemUpgrade']; + final l$$__typename = json['__typename']; + return Mutation$RunSystemUpgrade( + runSystemUpgrade: Mutation$RunSystemUpgrade$runSystemUpgrade.fromJson( + (l$runSystemUpgrade as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$RunSystemUpgrade$runSystemUpgrade runSystemUpgrade; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RunSystemUpgradeToJson(this); + Map toJson() { + final _resultData = {}; + final l$runSystemUpgrade = runSystemUpgrade; + _resultData['runSystemUpgrade'] = l$runSystemUpgrade.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$runSystemUpgrade = runSystemUpgrade; final l$$__typename = $__typename; - return Object.hashAll([l$runSystemUpgrade, l$$__typename]); + return Object.hashAll([ + l$runSystemUpgrade, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RunSystemUpgrade) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$runSystemUpgrade = runSystemUpgrade; final lOther$runSystemUpgrade = other.runSystemUpgrade; - if (l$runSystemUpgrade != lOther$runSystemUpgrade) return false; + if (l$runSystemUpgrade != lOther$runSystemUpgrade) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2197,27 +4585,35 @@ class Mutation$RunSystemUpgrade { extension UtilityExtension$Mutation$RunSystemUpgrade on Mutation$RunSystemUpgrade { CopyWith$Mutation$RunSystemUpgrade get copyWith => - CopyWith$Mutation$RunSystemUpgrade(this, (i) => i); + CopyWith$Mutation$RunSystemUpgrade( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RunSystemUpgrade { - factory CopyWith$Mutation$RunSystemUpgrade(Mutation$RunSystemUpgrade instance, - TRes Function(Mutation$RunSystemUpgrade) then) = - _CopyWithImpl$Mutation$RunSystemUpgrade; + factory CopyWith$Mutation$RunSystemUpgrade( + Mutation$RunSystemUpgrade instance, + TRes Function(Mutation$RunSystemUpgrade) then, + ) = _CopyWithImpl$Mutation$RunSystemUpgrade; factory CopyWith$Mutation$RunSystemUpgrade.stub(TRes res) = _CopyWithStubImpl$Mutation$RunSystemUpgrade; - TRes call( - {Mutation$RunSystemUpgrade$runSystemUpgrade? runSystemUpgrade, - String? $__typename}); + TRes call({ + Mutation$RunSystemUpgrade$runSystemUpgrade? runSystemUpgrade, + String? $__typename, + }); CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade get runSystemUpgrade; } class _CopyWithImpl$Mutation$RunSystemUpgrade implements CopyWith$Mutation$RunSystemUpgrade { - _CopyWithImpl$Mutation$RunSystemUpgrade(this._instance, this._then); + _CopyWithImpl$Mutation$RunSystemUpgrade( + this._instance, + this._then, + ); final Mutation$RunSystemUpgrade _instance; @@ -2225,18 +4621,19 @@ class _CopyWithImpl$Mutation$RunSystemUpgrade static const _undefined = {}; - TRes call( - {Object? runSystemUpgrade = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? runSystemUpgrade = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RunSystemUpgrade( - runSystemUpgrade: - runSystemUpgrade == _undefined || runSystemUpgrade == null - ? _instance.runSystemUpgrade - : (runSystemUpgrade - as Mutation$RunSystemUpgrade$runSystemUpgrade), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + runSystemUpgrade: runSystemUpgrade == _undefined || + runSystemUpgrade == null + ? _instance.runSystemUpgrade + : (runSystemUpgrade as Mutation$RunSystemUpgrade$runSystemUpgrade), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade get runSystemUpgrade { final local$runSystemUpgrade = _instance.runSystemUpgrade; @@ -2251,9 +4648,10 @@ class _CopyWithStubImpl$Mutation$RunSystemUpgrade TRes _res; - call( - {Mutation$RunSystemUpgrade$runSystemUpgrade? runSystemUpgrade, - String? $__typename}) => + call({ + Mutation$RunSystemUpgrade$runSystemUpgrade? runSystemUpgrade, + String? $__typename, + }) => _res; CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade get runSystemUpgrade => @@ -2262,73 +4660,82 @@ class _CopyWithStubImpl$Mutation$RunSystemUpgrade const documentNodeMutationRunSystemUpgrade = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'RunSystemUpgrade'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'runSystemUpgrade'), - alias: null, - arguments: [], + type: OperationType.mutation, + name: NameNode(value: 'RunSystemUpgrade'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'runSystemUpgrade'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$RunSystemUpgrade _parserFn$Mutation$RunSystemUpgrade( Map data) => Mutation$RunSystemUpgrade.fromJson(data); typedef OnMutationCompleted$Mutation$RunSystemUpgrade = FutureOr Function( - dynamic, Mutation$RunSystemUpgrade?); + dynamic, + Mutation$RunSystemUpgrade?, +); class Options$Mutation$RunSystemUpgrade extends graphql.MutationOptions { - Options$Mutation$RunSystemUpgrade( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$RunSystemUpgrade? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$RunSystemUpgrade({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$RunSystemUpgrade? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$RunSystemUpgrade(data)), - update: update, - onError: onError, - document: documentNodeMutationRunSystemUpgrade, - parserFn: _parserFn$Mutation$RunSystemUpgrade); + : _parserFn$Mutation$RunSystemUpgrade(data), + ), + update: update, + onError: onError, + document: documentNodeMutationRunSystemUpgrade, + parserFn: _parserFn$Mutation$RunSystemUpgrade, + ); final OnMutationCompleted$Mutation$RunSystemUpgrade? onCompletedWithParsed; @@ -2337,36 +4744,37 @@ class Options$Mutation$RunSystemUpgrade ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$RunSystemUpgrade extends graphql.WatchQueryOptions { - WatchOptions$Mutation$RunSystemUpgrade( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationRunSystemUpgrade, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$RunSystemUpgrade); + WatchOptions$Mutation$RunSystemUpgrade({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationRunSystemUpgrade, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$RunSystemUpgrade, + ); } extension ClientExtension$Mutation$RunSystemUpgrade on graphql.GraphQLClient { @@ -2380,19 +4788,28 @@ extension ClientExtension$Mutation$RunSystemUpgrade on graphql.GraphQLClient { this.watchMutation(options ?? WatchOptions$Mutation$RunSystemUpgrade()); } -@JsonSerializable(explicitToJson: true) class Mutation$RunSystemUpgrade$runSystemUpgrade - implements Fragment$basicMutationReturnFields { - Mutation$RunSystemUpgrade$runSystemUpgrade( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$RunSystemUpgrade$runSystemUpgrade({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$RunSystemUpgrade$runSystemUpgrade.fromJson( - Map json) => - _$Mutation$RunSystemUpgrade$runSystemUpgradeFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$RunSystemUpgrade$runSystemUpgrade( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -2400,36 +4817,64 @@ class Mutation$RunSystemUpgrade$runSystemUpgrade final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$RunSystemUpgrade$runSystemUpgradeToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RunSystemUpgrade$runSystemUpgrade) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2438,26 +4883,35 @@ extension UtilityExtension$Mutation$RunSystemUpgrade$runSystemUpgrade on Mutation$RunSystemUpgrade$runSystemUpgrade { CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade< Mutation$RunSystemUpgrade$runSystemUpgrade> - get copyWith => - CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade(this, (i) => i); + get copyWith => CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade { factory CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade( - Mutation$RunSystemUpgrade$runSystemUpgrade instance, - TRes Function(Mutation$RunSystemUpgrade$runSystemUpgrade) then) = - _CopyWithImpl$Mutation$RunSystemUpgrade$runSystemUpgrade; + Mutation$RunSystemUpgrade$runSystemUpgrade instance, + TRes Function(Mutation$RunSystemUpgrade$runSystemUpgrade) then, + ) = _CopyWithImpl$Mutation$RunSystemUpgrade$runSystemUpgrade; factory CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade.stub(TRes res) = _CopyWithStubImpl$Mutation$RunSystemUpgrade$runSystemUpgrade; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$RunSystemUpgrade$runSystemUpgrade implements CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade { _CopyWithImpl$Mutation$RunSystemUpgrade$runSystemUpgrade( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$RunSystemUpgrade$runSystemUpgrade _instance; @@ -2465,24 +4919,25 @@ class _CopyWithImpl$Mutation$RunSystemUpgrade$runSystemUpgrade static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RunSystemUpgrade$runSystemUpgrade( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$RunSystemUpgrade$runSystemUpgrade @@ -2491,43 +4946,75 @@ class _CopyWithStubImpl$Mutation$RunSystemUpgrade$runSystemUpgrade TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$PullRepositoryChanges { - Mutation$PullRepositoryChanges( - {required this.pullRepositoryChanges, required this.$__typename}); + Mutation$PullRepositoryChanges({ + required this.pullRepositoryChanges, + required this.$__typename, + }); - @override - factory Mutation$PullRepositoryChanges.fromJson(Map json) => - _$Mutation$PullRepositoryChangesFromJson(json); + factory Mutation$PullRepositoryChanges.fromJson(Map json) { + final l$pullRepositoryChanges = json['pullRepositoryChanges']; + final l$$__typename = json['__typename']; + return Mutation$PullRepositoryChanges( + pullRepositoryChanges: + Mutation$PullRepositoryChanges$pullRepositoryChanges.fromJson( + (l$pullRepositoryChanges as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$PullRepositoryChanges$pullRepositoryChanges pullRepositoryChanges; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$PullRepositoryChangesToJson(this); + Map toJson() { + final _resultData = {}; + final l$pullRepositoryChanges = pullRepositoryChanges; + _resultData['pullRepositoryChanges'] = l$pullRepositoryChanges.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$pullRepositoryChanges = pullRepositoryChanges; final l$$__typename = $__typename; - return Object.hashAll([l$pullRepositoryChanges, l$$__typename]); + return Object.hashAll([ + l$pullRepositoryChanges, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$PullRepositoryChanges) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$pullRepositoryChanges = pullRepositoryChanges; final lOther$pullRepositoryChanges = other.pullRepositoryChanges; - if (l$pullRepositoryChanges != lOther$pullRepositoryChanges) return false; + if (l$pullRepositoryChanges != lOther$pullRepositoryChanges) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2535,29 +5022,35 @@ class Mutation$PullRepositoryChanges { extension UtilityExtension$Mutation$PullRepositoryChanges on Mutation$PullRepositoryChanges { CopyWith$Mutation$PullRepositoryChanges - get copyWith => CopyWith$Mutation$PullRepositoryChanges(this, (i) => i); + get copyWith => CopyWith$Mutation$PullRepositoryChanges( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$PullRepositoryChanges { factory CopyWith$Mutation$PullRepositoryChanges( - Mutation$PullRepositoryChanges instance, - TRes Function(Mutation$PullRepositoryChanges) then) = - _CopyWithImpl$Mutation$PullRepositoryChanges; + Mutation$PullRepositoryChanges instance, + TRes Function(Mutation$PullRepositoryChanges) then, + ) = _CopyWithImpl$Mutation$PullRepositoryChanges; factory CopyWith$Mutation$PullRepositoryChanges.stub(TRes res) = _CopyWithStubImpl$Mutation$PullRepositoryChanges; - TRes call( - {Mutation$PullRepositoryChanges$pullRepositoryChanges? - pullRepositoryChanges, - String? $__typename}); + TRes call({ + Mutation$PullRepositoryChanges$pullRepositoryChanges? pullRepositoryChanges, + String? $__typename, + }); CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges get pullRepositoryChanges; } class _CopyWithImpl$Mutation$PullRepositoryChanges implements CopyWith$Mutation$PullRepositoryChanges { - _CopyWithImpl$Mutation$PullRepositoryChanges(this._instance, this._then); + _CopyWithImpl$Mutation$PullRepositoryChanges( + this._instance, + this._then, + ); final Mutation$PullRepositoryChanges _instance; @@ -2565,18 +5058,20 @@ class _CopyWithImpl$Mutation$PullRepositoryChanges static const _undefined = {}; - TRes call( - {Object? pullRepositoryChanges = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? pullRepositoryChanges = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$PullRepositoryChanges( - pullRepositoryChanges: pullRepositoryChanges == _undefined || - pullRepositoryChanges == null - ? _instance.pullRepositoryChanges - : (pullRepositoryChanges - as Mutation$PullRepositoryChanges$pullRepositoryChanges), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + pullRepositoryChanges: + pullRepositoryChanges == _undefined || pullRepositoryChanges == null + ? _instance.pullRepositoryChanges + : (pullRepositoryChanges + as Mutation$PullRepositoryChanges$pullRepositoryChanges), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges get pullRepositoryChanges { final local$pullRepositoryChanges = _instance.pullRepositoryChanges; @@ -2591,10 +5086,10 @@ class _CopyWithStubImpl$Mutation$PullRepositoryChanges TRes _res; - call( - {Mutation$PullRepositoryChanges$pullRepositoryChanges? - pullRepositoryChanges, - String? $__typename}) => + call({ + Mutation$PullRepositoryChanges$pullRepositoryChanges? pullRepositoryChanges, + String? $__typename, + }) => _res; CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges get pullRepositoryChanges => @@ -2604,73 +5099,83 @@ class _CopyWithStubImpl$Mutation$PullRepositoryChanges const documentNodeMutationPullRepositoryChanges = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'PullRepositoryChanges'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'pullRepositoryChanges'), - alias: null, - arguments: [], + type: OperationType.mutation, + name: NameNode(value: 'PullRepositoryChanges'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'pullRepositoryChanges'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$PullRepositoryChanges _parserFn$Mutation$PullRepositoryChanges( Map data) => Mutation$PullRepositoryChanges.fromJson(data); typedef OnMutationCompleted$Mutation$PullRepositoryChanges = FutureOr - Function(dynamic, Mutation$PullRepositoryChanges?); + Function( + dynamic, + Mutation$PullRepositoryChanges?, +); class Options$Mutation$PullRepositoryChanges extends graphql.MutationOptions { - Options$Mutation$PullRepositoryChanges( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$PullRepositoryChanges? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$PullRepositoryChanges({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$PullRepositoryChanges? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$PullRepositoryChanges(data)), - update: update, - onError: onError, - document: documentNodeMutationPullRepositoryChanges, - parserFn: _parserFn$Mutation$PullRepositoryChanges); + : _parserFn$Mutation$PullRepositoryChanges(data), + ), + update: update, + onError: onError, + document: documentNodeMutationPullRepositoryChanges, + parserFn: _parserFn$Mutation$PullRepositoryChanges, + ); final OnMutationCompleted$Mutation$PullRepositoryChanges? onCompletedWithParsed; @@ -2680,36 +5185,37 @@ class Options$Mutation$PullRepositoryChanges ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$PullRepositoryChanges extends graphql.WatchQueryOptions { - WatchOptions$Mutation$PullRepositoryChanges( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationPullRepositoryChanges, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$PullRepositoryChanges); + WatchOptions$Mutation$PullRepositoryChanges({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationPullRepositoryChanges, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$PullRepositoryChanges, + ); } extension ClientExtension$Mutation$PullRepositoryChanges @@ -2726,19 +5232,28 @@ extension ClientExtension$Mutation$PullRepositoryChanges options ?? WatchOptions$Mutation$PullRepositoryChanges()); } -@JsonSerializable(explicitToJson: true) class Mutation$PullRepositoryChanges$pullRepositoryChanges - implements Fragment$basicMutationReturnFields { - Mutation$PullRepositoryChanges$pullRepositoryChanges( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$PullRepositoryChanges$pullRepositoryChanges({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$PullRepositoryChanges$pullRepositoryChanges.fromJson( - Map json) => - _$Mutation$PullRepositoryChanges$pullRepositoryChangesFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$PullRepositoryChanges$pullRepositoryChanges( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -2746,36 +5261,64 @@ class Mutation$PullRepositoryChanges$pullRepositoryChanges final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$PullRepositoryChanges$pullRepositoryChangesToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$PullRepositoryChanges$pullRepositoryChanges) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2786,29 +5329,37 @@ extension UtilityExtension$Mutation$PullRepositoryChanges$pullRepositoryChanges Mutation$PullRepositoryChanges$pullRepositoryChanges> get copyWith => CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges< TRes> { factory CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges( - Mutation$PullRepositoryChanges$pullRepositoryChanges instance, - TRes Function(Mutation$PullRepositoryChanges$pullRepositoryChanges) - then) = - _CopyWithImpl$Mutation$PullRepositoryChanges$pullRepositoryChanges; + Mutation$PullRepositoryChanges$pullRepositoryChanges instance, + TRes Function(Mutation$PullRepositoryChanges$pullRepositoryChanges) then, + ) = _CopyWithImpl$Mutation$PullRepositoryChanges$pullRepositoryChanges; factory CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges.stub( TRes res) = _CopyWithStubImpl$Mutation$PullRepositoryChanges$pullRepositoryChanges; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$PullRepositoryChanges$pullRepositoryChanges implements CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges { _CopyWithImpl$Mutation$PullRepositoryChanges$pullRepositoryChanges( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$PullRepositoryChanges$pullRepositoryChanges _instance; @@ -2817,24 +5368,25 @@ class _CopyWithImpl$Mutation$PullRepositoryChanges$pullRepositoryChanges static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$PullRepositoryChanges$pullRepositoryChanges( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$PullRepositoryChanges$pullRepositoryChanges< @@ -2846,67 +5398,106 @@ class _CopyWithStubImpl$Mutation$PullRepositoryChanges$pullRepositoryChanges< TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$RebootSystem { - Mutation$RebootSystem( - {required this.rebootSystem, required this.$__typename}); + Mutation$RebootSystem({ + required this.rebootSystem, + required this.$__typename, + }); - @override - factory Mutation$RebootSystem.fromJson(Map json) => - _$Mutation$RebootSystemFromJson(json); + factory Mutation$RebootSystem.fromJson(Map json) { + final l$rebootSystem = json['rebootSystem']; + final l$$__typename = json['__typename']; + return Mutation$RebootSystem( + rebootSystem: Mutation$RebootSystem$rebootSystem.fromJson( + (l$rebootSystem as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$RebootSystem$rebootSystem rebootSystem; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RebootSystemToJson(this); + Map toJson() { + final _resultData = {}; + final l$rebootSystem = rebootSystem; + _resultData['rebootSystem'] = l$rebootSystem.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$rebootSystem = rebootSystem; final l$$__typename = $__typename; - return Object.hashAll([l$rebootSystem, l$$__typename]); + return Object.hashAll([ + l$rebootSystem, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$RebootSystem) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$RebootSystem) || runtimeType != other.runtimeType) { return false; + } final l$rebootSystem = rebootSystem; final lOther$rebootSystem = other.rebootSystem; - if (l$rebootSystem != lOther$rebootSystem) return false; + if (l$rebootSystem != lOther$rebootSystem) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$RebootSystem on Mutation$RebootSystem { CopyWith$Mutation$RebootSystem get copyWith => - CopyWith$Mutation$RebootSystem(this, (i) => i); + CopyWith$Mutation$RebootSystem( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RebootSystem { - factory CopyWith$Mutation$RebootSystem(Mutation$RebootSystem instance, - TRes Function(Mutation$RebootSystem) then) = - _CopyWithImpl$Mutation$RebootSystem; + factory CopyWith$Mutation$RebootSystem( + Mutation$RebootSystem instance, + TRes Function(Mutation$RebootSystem) then, + ) = _CopyWithImpl$Mutation$RebootSystem; factory CopyWith$Mutation$RebootSystem.stub(TRes res) = _CopyWithStubImpl$Mutation$RebootSystem; - TRes call( - {Mutation$RebootSystem$rebootSystem? rebootSystem, String? $__typename}); + TRes call({ + Mutation$RebootSystem$rebootSystem? rebootSystem, + String? $__typename, + }); CopyWith$Mutation$RebootSystem$rebootSystem get rebootSystem; } class _CopyWithImpl$Mutation$RebootSystem implements CopyWith$Mutation$RebootSystem { - _CopyWithImpl$Mutation$RebootSystem(this._instance, this._then); + _CopyWithImpl$Mutation$RebootSystem( + this._instance, + this._then, + ); final Mutation$RebootSystem _instance; @@ -2914,16 +5505,18 @@ class _CopyWithImpl$Mutation$RebootSystem static const _undefined = {}; - TRes call( - {Object? rebootSystem = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? rebootSystem = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RebootSystem( - rebootSystem: rebootSystem == _undefined || rebootSystem == null - ? _instance.rebootSystem - : (rebootSystem as Mutation$RebootSystem$rebootSystem), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + rebootSystem: rebootSystem == _undefined || rebootSystem == null + ? _instance.rebootSystem + : (rebootSystem as Mutation$RebootSystem$rebootSystem), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$RebootSystem$rebootSystem get rebootSystem { final local$rebootSystem = _instance.rebootSystem; return CopyWith$Mutation$RebootSystem$rebootSystem( @@ -2937,9 +5530,10 @@ class _CopyWithStubImpl$Mutation$RebootSystem TRes _res; - call( - {Mutation$RebootSystem$rebootSystem? rebootSystem, - String? $__typename}) => + call({ + Mutation$RebootSystem$rebootSystem? rebootSystem, + String? $__typename, + }) => _res; CopyWith$Mutation$RebootSystem$rebootSystem get rebootSystem => CopyWith$Mutation$RebootSystem$rebootSystem.stub(_res); @@ -2947,73 +5541,80 @@ class _CopyWithStubImpl$Mutation$RebootSystem const documentNodeMutationRebootSystem = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'RebootSystem'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'rebootSystem'), - alias: null, - arguments: [], + type: OperationType.mutation, + name: NameNode(value: 'RebootSystem'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'rebootSystem'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$RebootSystem _parserFn$Mutation$RebootSystem( Map data) => Mutation$RebootSystem.fromJson(data); typedef OnMutationCompleted$Mutation$RebootSystem = FutureOr Function( - dynamic, Mutation$RebootSystem?); + dynamic, + Mutation$RebootSystem?, +); class Options$Mutation$RebootSystem extends graphql.MutationOptions { - Options$Mutation$RebootSystem( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$RebootSystem? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$RebootSystem({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$RebootSystem? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, - data == null - ? null - : _parserFn$Mutation$RebootSystem(data)), - update: update, - onError: onError, - document: documentNodeMutationRebootSystem, - parserFn: _parserFn$Mutation$RebootSystem); + data == null ? null : _parserFn$Mutation$RebootSystem(data), + ), + update: update, + onError: onError, + document: documentNodeMutationRebootSystem, + parserFn: _parserFn$Mutation$RebootSystem, + ); final OnMutationCompleted$Mutation$RebootSystem? onCompletedWithParsed; @@ -3022,36 +5623,37 @@ class Options$Mutation$RebootSystem ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$RebootSystem extends graphql.WatchQueryOptions { - WatchOptions$Mutation$RebootSystem( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationRebootSystem, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$RebootSystem); + WatchOptions$Mutation$RebootSystem({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationRebootSystem, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$RebootSystem, + ); } extension ClientExtension$Mutation$RebootSystem on graphql.GraphQLClient { @@ -3063,19 +5665,28 @@ extension ClientExtension$Mutation$RebootSystem on graphql.GraphQLClient { this.watchMutation(options ?? WatchOptions$Mutation$RebootSystem()); } -@JsonSerializable(explicitToJson: true) class Mutation$RebootSystem$rebootSystem - implements Fragment$basicMutationReturnFields { - Mutation$RebootSystem$rebootSystem( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$RebootSystem$rebootSystem({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$RebootSystem$rebootSystem.fromJson( - Map json) => - _$Mutation$RebootSystem$rebootSystemFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$RebootSystem$rebootSystem( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -3083,36 +5694,64 @@ class Mutation$RebootSystem$rebootSystem final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$RebootSystem$rebootSystemToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RebootSystem$rebootSystem) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -3121,25 +5760,35 @@ extension UtilityExtension$Mutation$RebootSystem$rebootSystem on Mutation$RebootSystem$rebootSystem { CopyWith$Mutation$RebootSystem$rebootSystem< Mutation$RebootSystem$rebootSystem> - get copyWith => - CopyWith$Mutation$RebootSystem$rebootSystem(this, (i) => i); + get copyWith => CopyWith$Mutation$RebootSystem$rebootSystem( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RebootSystem$rebootSystem { factory CopyWith$Mutation$RebootSystem$rebootSystem( - Mutation$RebootSystem$rebootSystem instance, - TRes Function(Mutation$RebootSystem$rebootSystem) then) = - _CopyWithImpl$Mutation$RebootSystem$rebootSystem; + Mutation$RebootSystem$rebootSystem instance, + TRes Function(Mutation$RebootSystem$rebootSystem) then, + ) = _CopyWithImpl$Mutation$RebootSystem$rebootSystem; factory CopyWith$Mutation$RebootSystem$rebootSystem.stub(TRes res) = _CopyWithStubImpl$Mutation$RebootSystem$rebootSystem; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$RebootSystem$rebootSystem implements CopyWith$Mutation$RebootSystem$rebootSystem { - _CopyWithImpl$Mutation$RebootSystem$rebootSystem(this._instance, this._then); + _CopyWithImpl$Mutation$RebootSystem$rebootSystem( + this._instance, + this._then, + ); final Mutation$RebootSystem$rebootSystem _instance; @@ -3147,24 +5796,25 @@ class _CopyWithImpl$Mutation$RebootSystem$rebootSystem static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RebootSystem$rebootSystem( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$RebootSystem$rebootSystem @@ -3173,41 +5823,73 @@ class _CopyWithStubImpl$Mutation$RebootSystem$rebootSystem TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Query$SystemServerProvider { - Query$SystemServerProvider({required this.system, required this.$__typename}); + Query$SystemServerProvider({ + required this.system, + required this.$__typename, + }); - @override - factory Query$SystemServerProvider.fromJson(Map json) => - _$Query$SystemServerProviderFromJson(json); + factory Query$SystemServerProvider.fromJson(Map json) { + final l$system = json['system']; + final l$$__typename = json['__typename']; + return Query$SystemServerProvider( + system: Query$SystemServerProvider$system.fromJson( + (l$system as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$SystemServerProvider$system system; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$SystemServerProviderToJson(this); + Map toJson() { + final _resultData = {}; + final l$system = system; + _resultData['system'] = l$system.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$system = system; final l$$__typename = $__typename; - return Object.hashAll([l$system, l$$__typename]); + return Object.hashAll([ + l$system, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemServerProvider) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$system = system; final lOther$system = other.system; - if (l$system != lOther$system) return false; + if (l$system != lOther$system) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -3215,25 +5897,34 @@ class Query$SystemServerProvider { extension UtilityExtension$Query$SystemServerProvider on Query$SystemServerProvider { CopyWith$Query$SystemServerProvider - get copyWith => CopyWith$Query$SystemServerProvider(this, (i) => i); + get copyWith => CopyWith$Query$SystemServerProvider( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemServerProvider { factory CopyWith$Query$SystemServerProvider( - Query$SystemServerProvider instance, - TRes Function(Query$SystemServerProvider) then) = - _CopyWithImpl$Query$SystemServerProvider; + Query$SystemServerProvider instance, + TRes Function(Query$SystemServerProvider) then, + ) = _CopyWithImpl$Query$SystemServerProvider; factory CopyWith$Query$SystemServerProvider.stub(TRes res) = _CopyWithStubImpl$Query$SystemServerProvider; - TRes call({Query$SystemServerProvider$system? system, String? $__typename}); + TRes call({ + Query$SystemServerProvider$system? system, + String? $__typename, + }); CopyWith$Query$SystemServerProvider$system get system; } class _CopyWithImpl$Query$SystemServerProvider implements CopyWith$Query$SystemServerProvider { - _CopyWithImpl$Query$SystemServerProvider(this._instance, this._then); + _CopyWithImpl$Query$SystemServerProvider( + this._instance, + this._then, + ); final Query$SystemServerProvider _instance; @@ -3241,14 +5932,18 @@ class _CopyWithImpl$Query$SystemServerProvider static const _undefined = {}; - TRes call({Object? system = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? system = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemServerProvider( - system: system == _undefined || system == null - ? _instance.system - : (system as Query$SystemServerProvider$system), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + system: system == _undefined || system == null + ? _instance.system + : (system as Query$SystemServerProvider$system), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$SystemServerProvider$system get system { final local$system = _instance.system; return CopyWith$Query$SystemServerProvider$system( @@ -3262,7 +5957,10 @@ class _CopyWithStubImpl$Query$SystemServerProvider TRes _res; - call({Query$SystemServerProvider$system? system, String? $__typename}) => + call({ + Query$SystemServerProvider$system? system, + String? $__typename, + }) => _res; CopyWith$Query$SystemServerProvider$system get system => CopyWith$Query$SystemServerProvider$system.stub(_res); @@ -3270,50 +5968,57 @@ class _CopyWithStubImpl$Query$SystemServerProvider const documentNodeQuerySystemServerProvider = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'SystemServerProvider'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'system'), + type: OperationType.query, + name: NameNode(value: 'SystemServerProvider'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'system'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'provider'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'provider'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'provider'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'provider'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), ]); Query$SystemServerProvider _parserFn$Query$SystemServerProvider( Map data) => @@ -3321,52 +6026,54 @@ Query$SystemServerProvider _parserFn$Query$SystemServerProvider( class Options$Query$SystemServerProvider extends graphql.QueryOptions { - Options$Query$SystemServerProvider( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQuerySystemServerProvider, - parserFn: _parserFn$Query$SystemServerProvider); + Options$Query$SystemServerProvider({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQuerySystemServerProvider, + parserFn: _parserFn$Query$SystemServerProvider, + ); } class WatchOptions$Query$SystemServerProvider extends graphql.WatchQueryOptions { - WatchOptions$Query$SystemServerProvider( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQuerySystemServerProvider, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$SystemServerProvider); + WatchOptions$Query$SystemServerProvider({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQuerySystemServerProvider, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$SystemServerProvider, + ); } class FetchMoreOptions$Query$SystemServerProvider @@ -3374,8 +6081,9 @@ class FetchMoreOptions$Query$SystemServerProvider FetchMoreOptions$Query$SystemServerProvider( {required graphql.UpdateQuery updateQuery}) : super( - updateQuery: updateQuery, - document: documentNodeQuerySystemServerProvider); + updateQuery: updateQuery, + document: documentNodeQuerySystemServerProvider, + ); } extension ClientExtension$Query$SystemServerProvider on graphql.GraphQLClient { @@ -3387,59 +6095,88 @@ extension ClientExtension$Query$SystemServerProvider on graphql.GraphQLClient { watchQuery$SystemServerProvider( [WatchOptions$Query$SystemServerProvider? options]) => this.watchQuery(options ?? WatchOptions$Query$SystemServerProvider()); - void writeQuery$SystemServerProvider( - {required Query$SystemServerProvider data, bool broadcast = true}) => + void writeQuery$SystemServerProvider({ + required Query$SystemServerProvider data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: graphql.Operation( - document: documentNodeQuerySystemServerProvider)), - data: data.toJson(), - broadcast: broadcast); - Query$SystemServerProvider? readQuery$SystemServerProvider( - {bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation( document: documentNodeQuerySystemServerProvider)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$SystemServerProvider? readQuery$SystemServerProvider( + {bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: graphql.Operation( + document: documentNodeQuerySystemServerProvider)), + optimistic: optimistic, + ); return result == null ? null : Query$SystemServerProvider.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$SystemServerProvider$system { - Query$SystemServerProvider$system( - {required this.provider, required this.$__typename}); + Query$SystemServerProvider$system({ + required this.provider, + required this.$__typename, + }); - @override factory Query$SystemServerProvider$system.fromJson( - Map json) => - _$Query$SystemServerProvider$systemFromJson(json); + Map json) { + final l$provider = json['provider']; + final l$$__typename = json['__typename']; + return Query$SystemServerProvider$system( + provider: Query$SystemServerProvider$system$provider.fromJson( + (l$provider as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$SystemServerProvider$system$provider provider; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$SystemServerProvider$systemToJson(this); + Map toJson() { + final _resultData = {}; + final l$provider = provider; + _resultData['provider'] = l$provider.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$provider = provider; final l$$__typename = $__typename; - return Object.hashAll([l$provider, l$$__typename]); + return Object.hashAll([ + l$provider, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemServerProvider$system) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$provider = provider; final lOther$provider = other.provider; - if (l$provider != lOther$provider) return false; + if (l$provider != lOther$provider) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -3447,28 +6184,34 @@ class Query$SystemServerProvider$system { extension UtilityExtension$Query$SystemServerProvider$system on Query$SystemServerProvider$system { CopyWith$Query$SystemServerProvider$system - get copyWith => - CopyWith$Query$SystemServerProvider$system(this, (i) => i); + get copyWith => CopyWith$Query$SystemServerProvider$system( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemServerProvider$system { factory CopyWith$Query$SystemServerProvider$system( - Query$SystemServerProvider$system instance, - TRes Function(Query$SystemServerProvider$system) then) = - _CopyWithImpl$Query$SystemServerProvider$system; + Query$SystemServerProvider$system instance, + TRes Function(Query$SystemServerProvider$system) then, + ) = _CopyWithImpl$Query$SystemServerProvider$system; factory CopyWith$Query$SystemServerProvider$system.stub(TRes res) = _CopyWithStubImpl$Query$SystemServerProvider$system; - TRes call( - {Query$SystemServerProvider$system$provider? provider, - String? $__typename}); + TRes call({ + Query$SystemServerProvider$system$provider? provider, + String? $__typename, + }); CopyWith$Query$SystemServerProvider$system$provider get provider; } class _CopyWithImpl$Query$SystemServerProvider$system implements CopyWith$Query$SystemServerProvider$system { - _CopyWithImpl$Query$SystemServerProvider$system(this._instance, this._then); + _CopyWithImpl$Query$SystemServerProvider$system( + this._instance, + this._then, + ); final Query$SystemServerProvider$system _instance; @@ -3476,15 +6219,18 @@ class _CopyWithImpl$Query$SystemServerProvider$system static const _undefined = {}; - TRes call( - {Object? provider = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? provider = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemServerProvider$system( - provider: provider == _undefined || provider == null - ? _instance.provider - : (provider as Query$SystemServerProvider$system$provider), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + provider: provider == _undefined || provider == null + ? _instance.provider + : (provider as Query$SystemServerProvider$system$provider), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$SystemServerProvider$system$provider get provider { final local$provider = _instance.provider; return CopyWith$Query$SystemServerProvider$system$provider( @@ -3498,49 +6244,73 @@ class _CopyWithStubImpl$Query$SystemServerProvider$system TRes _res; - call( - {Query$SystemServerProvider$system$provider? provider, - String? $__typename}) => + call({ + Query$SystemServerProvider$system$provider? provider, + String? $__typename, + }) => _res; CopyWith$Query$SystemServerProvider$system$provider get provider => CopyWith$Query$SystemServerProvider$system$provider.stub(_res); } -@JsonSerializable(explicitToJson: true) class Query$SystemServerProvider$system$provider { - Query$SystemServerProvider$system$provider( - {required this.provider, required this.$__typename}); + Query$SystemServerProvider$system$provider({ + required this.provider, + required this.$__typename, + }); - @override factory Query$SystemServerProvider$system$provider.fromJson( - Map json) => - _$Query$SystemServerProvider$system$providerFromJson(json); + Map json) { + final l$provider = json['provider']; + final l$$__typename = json['__typename']; + return Query$SystemServerProvider$system$provider( + provider: fromJson$Enum$ServerProvider((l$provider as String)), + $__typename: (l$$__typename as String), + ); + } - @JsonKey(unknownEnumValue: Enum$ServerProvider.$unknown) final Enum$ServerProvider provider; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$SystemServerProvider$system$providerToJson(this); + Map toJson() { + final _resultData = {}; + final l$provider = provider; + _resultData['provider'] = toJson$Enum$ServerProvider(l$provider); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$provider = provider; final l$$__typename = $__typename; - return Object.hashAll([l$provider, l$$__typename]); + return Object.hashAll([ + l$provider, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemServerProvider$system$provider) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$provider = provider; final lOther$provider = other.provider; - if (l$provider != lOther$provider) return false; + if (l$provider != lOther$provider) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -3549,26 +6319,33 @@ extension UtilityExtension$Query$SystemServerProvider$system$provider on Query$SystemServerProvider$system$provider { CopyWith$Query$SystemServerProvider$system$provider< Query$SystemServerProvider$system$provider> - get copyWith => - CopyWith$Query$SystemServerProvider$system$provider(this, (i) => i); + get copyWith => CopyWith$Query$SystemServerProvider$system$provider( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemServerProvider$system$provider { factory CopyWith$Query$SystemServerProvider$system$provider( - Query$SystemServerProvider$system$provider instance, - TRes Function(Query$SystemServerProvider$system$provider) then) = - _CopyWithImpl$Query$SystemServerProvider$system$provider; + Query$SystemServerProvider$system$provider instance, + TRes Function(Query$SystemServerProvider$system$provider) then, + ) = _CopyWithImpl$Query$SystemServerProvider$system$provider; factory CopyWith$Query$SystemServerProvider$system$provider.stub(TRes res) = _CopyWithStubImpl$Query$SystemServerProvider$system$provider; - TRes call({Enum$ServerProvider? provider, String? $__typename}); + TRes call({ + Enum$ServerProvider? provider, + String? $__typename, + }); } class _CopyWithImpl$Query$SystemServerProvider$system$provider implements CopyWith$Query$SystemServerProvider$system$provider { _CopyWithImpl$Query$SystemServerProvider$system$provider( - this._instance, this._then); + this._instance, + this._then, + ); final Query$SystemServerProvider$system$provider _instance; @@ -3576,15 +6353,18 @@ class _CopyWithImpl$Query$SystemServerProvider$system$provider static const _undefined = {}; - TRes call( - {Object? provider = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? provider = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemServerProvider$system$provider( - provider: provider == _undefined || provider == null - ? _instance.provider - : (provider as Enum$ServerProvider), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + provider: provider == _undefined || provider == null + ? _instance.provider + : (provider as Enum$ServerProvider), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$SystemServerProvider$system$provider @@ -3593,64 +6373,103 @@ class _CopyWithStubImpl$Query$SystemServerProvider$system$provider TRes _res; - call({Enum$ServerProvider? provider, String? $__typename}) => _res; + call({ + Enum$ServerProvider? provider, + String? $__typename, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Query$GetApiTokens { - Query$GetApiTokens({required this.api, required this.$__typename}); + Query$GetApiTokens({ + required this.api, + required this.$__typename, + }); - @override - factory Query$GetApiTokens.fromJson(Map json) => - _$Query$GetApiTokensFromJson(json); + factory Query$GetApiTokens.fromJson(Map json) { + final l$api = json['api']; + final l$$__typename = json['__typename']; + return Query$GetApiTokens( + api: Query$GetApiTokens$api.fromJson((l$api as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$GetApiTokens$api api; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetApiTokensToJson(this); + Map toJson() { + final _resultData = {}; + final l$api = api; + _resultData['api'] = l$api.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$api = api; final l$$__typename = $__typename; - return Object.hashAll([l$api, l$$__typename]); + return Object.hashAll([ + l$api, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetApiTokens) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetApiTokens) || runtimeType != other.runtimeType) { return false; + } final l$api = api; final lOther$api = other.api; - if (l$api != lOther$api) return false; + if (l$api != lOther$api) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$GetApiTokens on Query$GetApiTokens { CopyWith$Query$GetApiTokens get copyWith => - CopyWith$Query$GetApiTokens(this, (i) => i); + CopyWith$Query$GetApiTokens( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetApiTokens { factory CopyWith$Query$GetApiTokens( - Query$GetApiTokens instance, TRes Function(Query$GetApiTokens) then) = - _CopyWithImpl$Query$GetApiTokens; + Query$GetApiTokens instance, + TRes Function(Query$GetApiTokens) then, + ) = _CopyWithImpl$Query$GetApiTokens; factory CopyWith$Query$GetApiTokens.stub(TRes res) = _CopyWithStubImpl$Query$GetApiTokens; - TRes call({Query$GetApiTokens$api? api, String? $__typename}); + TRes call({ + Query$GetApiTokens$api? api, + String? $__typename, + }); CopyWith$Query$GetApiTokens$api get api; } class _CopyWithImpl$Query$GetApiTokens implements CopyWith$Query$GetApiTokens { - _CopyWithImpl$Query$GetApiTokens(this._instance, this._then); + _CopyWithImpl$Query$GetApiTokens( + this._instance, + this._then, + ); final Query$GetApiTokens _instance; @@ -3658,14 +6477,18 @@ class _CopyWithImpl$Query$GetApiTokens static const _undefined = {}; - TRes call({Object? api = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? api = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetApiTokens( - api: api == _undefined || api == null - ? _instance.api - : (api as Query$GetApiTokens$api), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + api: api == _undefined || api == null + ? _instance.api + : (api as Query$GetApiTokens$api), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$GetApiTokens$api get api { final local$api = _instance.api; return CopyWith$Query$GetApiTokens$api(local$api, (e) => call(api: e)); @@ -3678,128 +6501,145 @@ class _CopyWithStubImpl$Query$GetApiTokens TRes _res; - call({Query$GetApiTokens$api? api, String? $__typename}) => _res; + call({ + Query$GetApiTokens$api? api, + String? $__typename, + }) => + _res; CopyWith$Query$GetApiTokens$api get api => CopyWith$Query$GetApiTokens$api.stub(_res); } const documentNodeQueryGetApiTokens = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'GetApiTokens'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'api'), + type: OperationType.query, + name: NameNode(value: 'GetApiTokens'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'api'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'devices'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'devices'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'creationDate'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'isCaller'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'name'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'creationDate'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'isCaller'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'name'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), ]); Query$GetApiTokens _parserFn$Query$GetApiTokens(Map data) => Query$GetApiTokens.fromJson(data); class Options$Query$GetApiTokens extends graphql.QueryOptions { - Options$Query$GetApiTokens( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryGetApiTokens, - parserFn: _parserFn$Query$GetApiTokens); + Options$Query$GetApiTokens({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryGetApiTokens, + parserFn: _parserFn$Query$GetApiTokens, + ); } class WatchOptions$Query$GetApiTokens extends graphql.WatchQueryOptions { - WatchOptions$Query$GetApiTokens( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryGetApiTokens, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$GetApiTokens); + WatchOptions$Query$GetApiTokens({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryGetApiTokens, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$GetApiTokens, + ); } class FetchMoreOptions$Query$GetApiTokens extends graphql.FetchMoreOptions { FetchMoreOptions$Query$GetApiTokens( {required graphql.UpdateQuery updateQuery}) : super( - updateQuery: updateQuery, document: documentNodeQueryGetApiTokens); + updateQuery: updateQuery, + document: documentNodeQueryGetApiTokens, + ); } extension ClientExtension$Query$GetApiTokens on graphql.GraphQLClient { @@ -3809,81 +6649,120 @@ extension ClientExtension$Query$GetApiTokens on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$GetApiTokens( [WatchOptions$Query$GetApiTokens? options]) => this.watchQuery(options ?? WatchOptions$Query$GetApiTokens()); - void writeQuery$GetApiTokens( - {required Query$GetApiTokens data, bool broadcast = true}) => + void writeQuery$GetApiTokens({ + required Query$GetApiTokens data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: - graphql.Operation(document: documentNodeQueryGetApiTokens)), - data: data.toJson(), - broadcast: broadcast); - Query$GetApiTokens? readQuery$GetApiTokens({bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation(document: documentNodeQueryGetApiTokens)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$GetApiTokens? readQuery$GetApiTokens({bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: + graphql.Operation(document: documentNodeQueryGetApiTokens)), + optimistic: optimistic, + ); return result == null ? null : Query$GetApiTokens.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$GetApiTokens$api { - Query$GetApiTokens$api({required this.devices, required this.$__typename}); + Query$GetApiTokens$api({ + required this.devices, + required this.$__typename, + }); - @override - factory Query$GetApiTokens$api.fromJson(Map json) => - _$Query$GetApiTokens$apiFromJson(json); + factory Query$GetApiTokens$api.fromJson(Map json) { + final l$devices = json['devices']; + final l$$__typename = json['__typename']; + return Query$GetApiTokens$api( + devices: (l$devices as List) + .map((e) => Query$GetApiTokens$api$devices.fromJson( + (e as Map))) + .toList(), + $__typename: (l$$__typename as String), + ); + } final List devices; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetApiTokens$apiToJson(this); + Map toJson() { + final _resultData = {}; + final l$devices = devices; + _resultData['devices'] = l$devices.map((e) => e.toJson()).toList(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$devices = devices; final l$$__typename = $__typename; - return Object.hashAll( - [Object.hashAll(l$devices.map((v) => v)), l$$__typename]); + return Object.hashAll([ + Object.hashAll(l$devices.map((v) => v)), + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetApiTokens$api) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetApiTokens$api) || + runtimeType != other.runtimeType) { return false; + } final l$devices = devices; final lOther$devices = other.devices; - if (l$devices.length != lOther$devices.length) return false; + if (l$devices.length != lOther$devices.length) { + return false; + } for (int i = 0; i < l$devices.length; i++) { final l$devices$entry = l$devices[i]; final lOther$devices$entry = lOther$devices[i]; - if (l$devices$entry != lOther$devices$entry) return false; + if (l$devices$entry != lOther$devices$entry) { + return false; + } } - final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$GetApiTokens$api on Query$GetApiTokens$api { CopyWith$Query$GetApiTokens$api get copyWith => - CopyWith$Query$GetApiTokens$api(this, (i) => i); + CopyWith$Query$GetApiTokens$api( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetApiTokens$api { - factory CopyWith$Query$GetApiTokens$api(Query$GetApiTokens$api instance, - TRes Function(Query$GetApiTokens$api) then) = - _CopyWithImpl$Query$GetApiTokens$api; + factory CopyWith$Query$GetApiTokens$api( + Query$GetApiTokens$api instance, + TRes Function(Query$GetApiTokens$api) then, + ) = _CopyWithImpl$Query$GetApiTokens$api; factory CopyWith$Query$GetApiTokens$api.stub(TRes res) = _CopyWithStubImpl$Query$GetApiTokens$api; - TRes call( - {List? devices, String? $__typename}); + TRes call({ + List? devices, + String? $__typename, + }); TRes devices( Iterable Function( Iterable< @@ -3894,7 +6773,10 @@ abstract class CopyWith$Query$GetApiTokens$api { class _CopyWithImpl$Query$GetApiTokens$api implements CopyWith$Query$GetApiTokens$api { - _CopyWithImpl$Query$GetApiTokens$api(this._instance, this._then); + _CopyWithImpl$Query$GetApiTokens$api( + this._instance, + this._then, + ); final Query$GetApiTokens$api _instance; @@ -3902,14 +6784,18 @@ class _CopyWithImpl$Query$GetApiTokens$api static const _undefined = {}; - TRes call({Object? devices = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? devices = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetApiTokens$api( - devices: devices == _undefined || devices == null - ? _instance.devices - : (devices as List), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + devices: devices == _undefined || devices == null + ? _instance.devices + : (devices as List), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); TRes devices( Iterable Function( Iterable< @@ -3917,9 +6803,11 @@ class _CopyWithImpl$Query$GetApiTokens$api Query$GetApiTokens$api$devices>>) _fn) => call( - devices: _fn(_instance.devices.map( - (e) => CopyWith$Query$GetApiTokens$api$devices(e, (i) => i))) - .toList()); + devices: _fn(_instance.devices + .map((e) => CopyWith$Query$GetApiTokens$api$devices( + e, + (i) => i, + ))).toList()); } class _CopyWithStubImpl$Query$GetApiTokens$api @@ -3928,59 +6816,99 @@ class _CopyWithStubImpl$Query$GetApiTokens$api TRes _res; - call({List? devices, String? $__typename}) => + call({ + List? devices, + String? $__typename, + }) => _res; devices(_fn) => _res; } -@JsonSerializable(explicitToJson: true) class Query$GetApiTokens$api$devices { - Query$GetApiTokens$api$devices( - {required this.creationDate, - required this.isCaller, - required this.name, - required this.$__typename}); + Query$GetApiTokens$api$devices({ + required this.creationDate, + required this.isCaller, + required this.name, + required this.$__typename, + }); - @override - factory Query$GetApiTokens$api$devices.fromJson(Map json) => - _$Query$GetApiTokens$api$devicesFromJson(json); + factory Query$GetApiTokens$api$devices.fromJson(Map json) { + final l$creationDate = json['creationDate']; + final l$isCaller = json['isCaller']; + final l$name = json['name']; + final l$$__typename = json['__typename']; + return Query$GetApiTokens$api$devices( + creationDate: dateTimeFromJson(l$creationDate), + isCaller: (l$isCaller as bool), + name: (l$name as String), + $__typename: (l$$__typename as String), + ); + } - @JsonKey(fromJson: dateTimeFromJson, toJson: dateTimeToJson) final DateTime creationDate; final bool isCaller; final String name; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetApiTokens$api$devicesToJson(this); + Map toJson() { + final _resultData = {}; + final l$creationDate = creationDate; + _resultData['creationDate'] = dateTimeToJson(l$creationDate); + final l$isCaller = isCaller; + _resultData['isCaller'] = l$isCaller; + final l$name = name; + _resultData['name'] = l$name; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$creationDate = creationDate; final l$isCaller = isCaller; final l$name = name; final l$$__typename = $__typename; - return Object.hashAll([l$creationDate, l$isCaller, l$name, l$$__typename]); + return Object.hashAll([ + l$creationDate, + l$isCaller, + l$name, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$GetApiTokens$api$devices) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$creationDate = creationDate; final lOther$creationDate = other.creationDate; - if (l$creationDate != lOther$creationDate) return false; + if (l$creationDate != lOther$creationDate) { + return false; + } final l$isCaller = isCaller; final lOther$isCaller = other.isCaller; - if (l$isCaller != lOther$isCaller) return false; + if (l$isCaller != lOther$isCaller) { + return false; + } final l$name = name; final lOther$name = other.name; - if (l$name != lOther$name) return false; + if (l$name != lOther$name) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -3988,28 +6916,35 @@ class Query$GetApiTokens$api$devices { extension UtilityExtension$Query$GetApiTokens$api$devices on Query$GetApiTokens$api$devices { CopyWith$Query$GetApiTokens$api$devices - get copyWith => CopyWith$Query$GetApiTokens$api$devices(this, (i) => i); + get copyWith => CopyWith$Query$GetApiTokens$api$devices( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetApiTokens$api$devices { factory CopyWith$Query$GetApiTokens$api$devices( - Query$GetApiTokens$api$devices instance, - TRes Function(Query$GetApiTokens$api$devices) then) = - _CopyWithImpl$Query$GetApiTokens$api$devices; + Query$GetApiTokens$api$devices instance, + TRes Function(Query$GetApiTokens$api$devices) then, + ) = _CopyWithImpl$Query$GetApiTokens$api$devices; factory CopyWith$Query$GetApiTokens$api$devices.stub(TRes res) = _CopyWithStubImpl$Query$GetApiTokens$api$devices; - TRes call( - {DateTime? creationDate, - bool? isCaller, - String? name, - String? $__typename}); + TRes call({ + DateTime? creationDate, + bool? isCaller, + String? name, + String? $__typename, + }); } class _CopyWithImpl$Query$GetApiTokens$api$devices implements CopyWith$Query$GetApiTokens$api$devices { - _CopyWithImpl$Query$GetApiTokens$api$devices(this._instance, this._then); + _CopyWithImpl$Query$GetApiTokens$api$devices( + this._instance, + this._then, + ); final Query$GetApiTokens$api$devices _instance; @@ -4017,24 +6952,26 @@ class _CopyWithImpl$Query$GetApiTokens$api$devices static const _undefined = {}; - TRes call( - {Object? creationDate = _undefined, - Object? isCaller = _undefined, - Object? name = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? creationDate = _undefined, + Object? isCaller = _undefined, + Object? name = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetApiTokens$api$devices( - creationDate: creationDate == _undefined || creationDate == null - ? _instance.creationDate - : (creationDate as DateTime), - isCaller: isCaller == _undefined || isCaller == null - ? _instance.isCaller - : (isCaller as bool), - name: name == _undefined || name == null - ? _instance.name - : (name as String), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + creationDate: creationDate == _undefined || creationDate == null + ? _instance.creationDate + : (creationDate as DateTime), + isCaller: isCaller == _undefined || isCaller == null + ? _instance.isCaller + : (isCaller as bool), + name: name == _undefined || name == null + ? _instance.name + : (name as String), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$GetApiTokens$api$devices @@ -4043,69 +6980,105 @@ class _CopyWithStubImpl$Query$GetApiTokens$api$devices TRes _res; - call( - {DateTime? creationDate, - bool? isCaller, - String? name, - String? $__typename}) => + call({ + DateTime? creationDate, + bool? isCaller, + String? name, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Query$RecoveryKey { - Query$RecoveryKey({required this.api, required this.$__typename}); + Query$RecoveryKey({ + required this.api, + required this.$__typename, + }); - @override - factory Query$RecoveryKey.fromJson(Map json) => - _$Query$RecoveryKeyFromJson(json); + factory Query$RecoveryKey.fromJson(Map json) { + final l$api = json['api']; + final l$$__typename = json['__typename']; + return Query$RecoveryKey( + api: Query$RecoveryKey$api.fromJson((l$api as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$RecoveryKey$api api; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$RecoveryKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$api = api; + _resultData['api'] = l$api.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$api = api; final l$$__typename = $__typename; - return Object.hashAll([l$api, l$$__typename]); + return Object.hashAll([ + l$api, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$RecoveryKey) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$RecoveryKey) || runtimeType != other.runtimeType) { return false; + } final l$api = api; final lOther$api = other.api; - if (l$api != lOther$api) return false; + if (l$api != lOther$api) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$RecoveryKey on Query$RecoveryKey { CopyWith$Query$RecoveryKey get copyWith => - CopyWith$Query$RecoveryKey(this, (i) => i); + CopyWith$Query$RecoveryKey( + this, + (i) => i, + ); } abstract class CopyWith$Query$RecoveryKey { factory CopyWith$Query$RecoveryKey( - Query$RecoveryKey instance, TRes Function(Query$RecoveryKey) then) = - _CopyWithImpl$Query$RecoveryKey; + Query$RecoveryKey instance, + TRes Function(Query$RecoveryKey) then, + ) = _CopyWithImpl$Query$RecoveryKey; factory CopyWith$Query$RecoveryKey.stub(TRes res) = _CopyWithStubImpl$Query$RecoveryKey; - TRes call({Query$RecoveryKey$api? api, String? $__typename}); + TRes call({ + Query$RecoveryKey$api? api, + String? $__typename, + }); CopyWith$Query$RecoveryKey$api get api; } class _CopyWithImpl$Query$RecoveryKey implements CopyWith$Query$RecoveryKey { - _CopyWithImpl$Query$RecoveryKey(this._instance, this._then); + _CopyWithImpl$Query$RecoveryKey( + this._instance, + this._then, + ); final Query$RecoveryKey _instance; @@ -4113,14 +7086,18 @@ class _CopyWithImpl$Query$RecoveryKey static const _undefined = {}; - TRes call({Object? api = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? api = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$RecoveryKey( - api: api == _undefined || api == null - ? _instance.api - : (api as Query$RecoveryKey$api), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + api: api == _undefined || api == null + ? _instance.api + : (api as Query$RecoveryKey$api), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$RecoveryKey$api get api { final local$api = _instance.api; return CopyWith$Query$RecoveryKey$api(local$api, (e) => call(api: e)); @@ -4133,138 +7110,158 @@ class _CopyWithStubImpl$Query$RecoveryKey TRes _res; - call({Query$RecoveryKey$api? api, String? $__typename}) => _res; + call({ + Query$RecoveryKey$api? api, + String? $__typename, + }) => + _res; CopyWith$Query$RecoveryKey$api get api => CopyWith$Query$RecoveryKey$api.stub(_res); } const documentNodeQueryRecoveryKey = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'RecoveryKey'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'api'), + type: OperationType.query, + name: NameNode(value: 'RecoveryKey'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'api'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'recoveryKey'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'recoveryKey'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'creationDate'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'exists'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'expirationDate'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'usesLeft'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'valid'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'creationDate'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'exists'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'expirationDate'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'usesLeft'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'valid'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), ]); Query$RecoveryKey _parserFn$Query$RecoveryKey(Map data) => Query$RecoveryKey.fromJson(data); class Options$Query$RecoveryKey extends graphql.QueryOptions { - Options$Query$RecoveryKey( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryRecoveryKey, - parserFn: _parserFn$Query$RecoveryKey); + Options$Query$RecoveryKey({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryRecoveryKey, + parserFn: _parserFn$Query$RecoveryKey, + ); } class WatchOptions$Query$RecoveryKey extends graphql.WatchQueryOptions { - WatchOptions$Query$RecoveryKey( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryRecoveryKey, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$RecoveryKey); + WatchOptions$Query$RecoveryKey({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryRecoveryKey, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$RecoveryKey, + ); } class FetchMoreOptions$Query$RecoveryKey extends graphql.FetchMoreOptions { FetchMoreOptions$Query$RecoveryKey({required graphql.UpdateQuery updateQuery}) - : super(updateQuery: updateQuery, document: documentNodeQueryRecoveryKey); + : super( + updateQuery: updateQuery, + document: documentNodeQueryRecoveryKey, + ); } extension ClientExtension$Query$RecoveryKey on graphql.GraphQLClient { @@ -4274,80 +7271,118 @@ extension ClientExtension$Query$RecoveryKey on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$RecoveryKey( [WatchOptions$Query$RecoveryKey? options]) => this.watchQuery(options ?? WatchOptions$Query$RecoveryKey()); - void writeQuery$RecoveryKey( - {required Query$RecoveryKey data, bool broadcast = true}) => + void writeQuery$RecoveryKey({ + required Query$RecoveryKey data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: - graphql.Operation(document: documentNodeQueryRecoveryKey)), - data: data.toJson(), - broadcast: broadcast); - Query$RecoveryKey? readQuery$RecoveryKey({bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation(document: documentNodeQueryRecoveryKey)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$RecoveryKey? readQuery$RecoveryKey({bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: graphql.Operation(document: documentNodeQueryRecoveryKey)), + optimistic: optimistic, + ); return result == null ? null : Query$RecoveryKey.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$RecoveryKey$api { - Query$RecoveryKey$api({required this.recoveryKey, required this.$__typename}); + Query$RecoveryKey$api({ + required this.recoveryKey, + required this.$__typename, + }); - @override - factory Query$RecoveryKey$api.fromJson(Map json) => - _$Query$RecoveryKey$apiFromJson(json); + factory Query$RecoveryKey$api.fromJson(Map json) { + final l$recoveryKey = json['recoveryKey']; + final l$$__typename = json['__typename']; + return Query$RecoveryKey$api( + recoveryKey: Query$RecoveryKey$api$recoveryKey.fromJson( + (l$recoveryKey as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$RecoveryKey$api$recoveryKey recoveryKey; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$RecoveryKey$apiToJson(this); + Map toJson() { + final _resultData = {}; + final l$recoveryKey = recoveryKey; + _resultData['recoveryKey'] = l$recoveryKey.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$recoveryKey = recoveryKey; final l$$__typename = $__typename; - return Object.hashAll([l$recoveryKey, l$$__typename]); + return Object.hashAll([ + l$recoveryKey, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$RecoveryKey$api) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$RecoveryKey$api) || runtimeType != other.runtimeType) { return false; + } final l$recoveryKey = recoveryKey; final lOther$recoveryKey = other.recoveryKey; - if (l$recoveryKey != lOther$recoveryKey) return false; + if (l$recoveryKey != lOther$recoveryKey) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$RecoveryKey$api on Query$RecoveryKey$api { CopyWith$Query$RecoveryKey$api get copyWith => - CopyWith$Query$RecoveryKey$api(this, (i) => i); + CopyWith$Query$RecoveryKey$api( + this, + (i) => i, + ); } abstract class CopyWith$Query$RecoveryKey$api { - factory CopyWith$Query$RecoveryKey$api(Query$RecoveryKey$api instance, - TRes Function(Query$RecoveryKey$api) then) = - _CopyWithImpl$Query$RecoveryKey$api; + factory CopyWith$Query$RecoveryKey$api( + Query$RecoveryKey$api instance, + TRes Function(Query$RecoveryKey$api) then, + ) = _CopyWithImpl$Query$RecoveryKey$api; factory CopyWith$Query$RecoveryKey$api.stub(TRes res) = _CopyWithStubImpl$Query$RecoveryKey$api; - TRes call( - {Query$RecoveryKey$api$recoveryKey? recoveryKey, String? $__typename}); + TRes call({ + Query$RecoveryKey$api$recoveryKey? recoveryKey, + String? $__typename, + }); CopyWith$Query$RecoveryKey$api$recoveryKey get recoveryKey; } class _CopyWithImpl$Query$RecoveryKey$api implements CopyWith$Query$RecoveryKey$api { - _CopyWithImpl$Query$RecoveryKey$api(this._instance, this._then); + _CopyWithImpl$Query$RecoveryKey$api( + this._instance, + this._then, + ); final Query$RecoveryKey$api _instance; @@ -4355,16 +7390,18 @@ class _CopyWithImpl$Query$RecoveryKey$api static const _undefined = {}; - TRes call( - {Object? recoveryKey = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? recoveryKey = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$RecoveryKey$api( - recoveryKey: recoveryKey == _undefined || recoveryKey == null - ? _instance.recoveryKey - : (recoveryKey as Query$RecoveryKey$api$recoveryKey), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + recoveryKey: recoveryKey == _undefined || recoveryKey == null + ? _instance.recoveryKey + : (recoveryKey as Query$RecoveryKey$api$recoveryKey), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$RecoveryKey$api$recoveryKey get recoveryKey { final local$recoveryKey = _instance.recoveryKey; return CopyWith$Query$RecoveryKey$api$recoveryKey( @@ -4378,46 +7415,77 @@ class _CopyWithStubImpl$Query$RecoveryKey$api TRes _res; - call({Query$RecoveryKey$api$recoveryKey? recoveryKey, String? $__typename}) => + call({ + Query$RecoveryKey$api$recoveryKey? recoveryKey, + String? $__typename, + }) => _res; CopyWith$Query$RecoveryKey$api$recoveryKey get recoveryKey => CopyWith$Query$RecoveryKey$api$recoveryKey.stub(_res); } -@JsonSerializable(explicitToJson: true) class Query$RecoveryKey$api$recoveryKey { - Query$RecoveryKey$api$recoveryKey( - {this.creationDate, - required this.exists, - this.expirationDate, - this.usesLeft, - required this.valid, - required this.$__typename}); + Query$RecoveryKey$api$recoveryKey({ + this.creationDate, + required this.exists, + this.expirationDate, + this.usesLeft, + required this.valid, + required this.$__typename, + }); - @override factory Query$RecoveryKey$api$recoveryKey.fromJson( - Map json) => - _$Query$RecoveryKey$api$recoveryKeyFromJson(json); + Map json) { + final l$creationDate = json['creationDate']; + final l$exists = json['exists']; + final l$expirationDate = json['expirationDate']; + final l$usesLeft = json['usesLeft']; + final l$valid = json['valid']; + final l$$__typename = json['__typename']; + return Query$RecoveryKey$api$recoveryKey( + creationDate: + l$creationDate == null ? null : dateTimeFromJson(l$creationDate), + exists: (l$exists as bool), + expirationDate: + l$expirationDate == null ? null : dateTimeFromJson(l$expirationDate), + usesLeft: (l$usesLeft as int?), + valid: (l$valid as bool), + $__typename: (l$$__typename as String), + ); + } - @JsonKey( - fromJson: _nullable$dateTimeFromJson, toJson: _nullable$dateTimeToJson) final DateTime? creationDate; final bool exists; - @JsonKey( - fromJson: _nullable$dateTimeFromJson, toJson: _nullable$dateTimeToJson) final DateTime? expirationDate; final int? usesLeft; final bool valid; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$RecoveryKey$api$recoveryKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$creationDate = creationDate; + _resultData['creationDate'] = + l$creationDate == null ? null : dateTimeToJson(l$creationDate); + final l$exists = exists; + _resultData['exists'] = l$exists; + final l$expirationDate = expirationDate; + _resultData['expirationDate'] = + l$expirationDate == null ? null : dateTimeToJson(l$expirationDate); + final l$usesLeft = usesLeft; + _resultData['usesLeft'] = l$usesLeft; + final l$valid = valid; + _resultData['valid'] = l$valid; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$creationDate = creationDate; final l$exists = exists; @@ -4431,33 +7499,49 @@ class Query$RecoveryKey$api$recoveryKey { l$expirationDate, l$usesLeft, l$valid, - l$$__typename + l$$__typename, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$RecoveryKey$api$recoveryKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$creationDate = creationDate; final lOther$creationDate = other.creationDate; - if (l$creationDate != lOther$creationDate) return false; + if (l$creationDate != lOther$creationDate) { + return false; + } final l$exists = exists; final lOther$exists = other.exists; - if (l$exists != lOther$exists) return false; + if (l$exists != lOther$exists) { + return false; + } final l$expirationDate = expirationDate; final lOther$expirationDate = other.expirationDate; - if (l$expirationDate != lOther$expirationDate) return false; + if (l$expirationDate != lOther$expirationDate) { + return false; + } final l$usesLeft = usesLeft; final lOther$usesLeft = other.usesLeft; - if (l$usesLeft != lOther$usesLeft) return false; + if (l$usesLeft != lOther$usesLeft) { + return false; + } final l$valid = valid; final lOther$valid = other.valid; - if (l$valid != lOther$valid) return false; + if (l$valid != lOther$valid) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -4465,31 +7549,37 @@ class Query$RecoveryKey$api$recoveryKey { extension UtilityExtension$Query$RecoveryKey$api$recoveryKey on Query$RecoveryKey$api$recoveryKey { CopyWith$Query$RecoveryKey$api$recoveryKey - get copyWith => - CopyWith$Query$RecoveryKey$api$recoveryKey(this, (i) => i); + get copyWith => CopyWith$Query$RecoveryKey$api$recoveryKey( + this, + (i) => i, + ); } abstract class CopyWith$Query$RecoveryKey$api$recoveryKey { factory CopyWith$Query$RecoveryKey$api$recoveryKey( - Query$RecoveryKey$api$recoveryKey instance, - TRes Function(Query$RecoveryKey$api$recoveryKey) then) = - _CopyWithImpl$Query$RecoveryKey$api$recoveryKey; + Query$RecoveryKey$api$recoveryKey instance, + TRes Function(Query$RecoveryKey$api$recoveryKey) then, + ) = _CopyWithImpl$Query$RecoveryKey$api$recoveryKey; factory CopyWith$Query$RecoveryKey$api$recoveryKey.stub(TRes res) = _CopyWithStubImpl$Query$RecoveryKey$api$recoveryKey; - TRes call( - {DateTime? creationDate, - bool? exists, - DateTime? expirationDate, - int? usesLeft, - bool? valid, - String? $__typename}); + TRes call({ + DateTime? creationDate, + bool? exists, + DateTime? expirationDate, + int? usesLeft, + bool? valid, + String? $__typename, + }); } class _CopyWithImpl$Query$RecoveryKey$api$recoveryKey implements CopyWith$Query$RecoveryKey$api$recoveryKey { - _CopyWithImpl$Query$RecoveryKey$api$recoveryKey(this._instance, this._then); + _CopyWithImpl$Query$RecoveryKey$api$recoveryKey( + this._instance, + this._then, + ); final Query$RecoveryKey$api$recoveryKey _instance; @@ -4497,31 +7587,33 @@ class _CopyWithImpl$Query$RecoveryKey$api$recoveryKey static const _undefined = {}; - TRes call( - {Object? creationDate = _undefined, - Object? exists = _undefined, - Object? expirationDate = _undefined, - Object? usesLeft = _undefined, - Object? valid = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? creationDate = _undefined, + Object? exists = _undefined, + Object? expirationDate = _undefined, + Object? usesLeft = _undefined, + Object? valid = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$RecoveryKey$api$recoveryKey( - creationDate: creationDate == _undefined - ? _instance.creationDate - : (creationDate as DateTime?), - exists: exists == _undefined || exists == null - ? _instance.exists - : (exists as bool), - expirationDate: expirationDate == _undefined - ? _instance.expirationDate - : (expirationDate as DateTime?), - usesLeft: - usesLeft == _undefined ? _instance.usesLeft : (usesLeft as int?), - valid: valid == _undefined || valid == null - ? _instance.valid - : (valid as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + creationDate: creationDate == _undefined + ? _instance.creationDate + : (creationDate as DateTime?), + exists: exists == _undefined || exists == null + ? _instance.exists + : (exists as bool), + expirationDate: expirationDate == _undefined + ? _instance.expirationDate + : (expirationDate as DateTime?), + usesLeft: + usesLeft == _undefined ? _instance.usesLeft : (usesLeft as int?), + valid: valid == _undefined || valid == null + ? _instance.valid + : (valid as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$RecoveryKey$api$recoveryKey @@ -4530,56 +7622,90 @@ class _CopyWithStubImpl$Query$RecoveryKey$api$recoveryKey TRes _res; - call( - {DateTime? creationDate, - bool? exists, - DateTime? expirationDate, - int? usesLeft, - bool? valid, - String? $__typename}) => + call({ + DateTime? creationDate, + bool? exists, + DateTime? expirationDate, + int? usesLeft, + bool? valid, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$GetNewRecoveryApiKey { - Variables$Mutation$GetNewRecoveryApiKey({this.limits}); + factory Variables$Mutation$GetNewRecoveryApiKey( + {Input$RecoveryKeyLimitsInput? limits}) => + Variables$Mutation$GetNewRecoveryApiKey._({ + if (limits != null) r'limits': limits, + }); + + Variables$Mutation$GetNewRecoveryApiKey._(this._$data); - @override factory Variables$Mutation$GetNewRecoveryApiKey.fromJson( - Map json) => - _$Variables$Mutation$GetNewRecoveryApiKeyFromJson(json); - - final Input$RecoveryKeyLimitsInput? limits; - - Map toJson() => - _$Variables$Mutation$GetNewRecoveryApiKeyToJson(this); - int get hashCode { - final l$limits = limits; - return Object.hashAll([l$limits]); + Map data) { + final result$data = {}; + if (data.containsKey('limits')) { + final l$limits = data['limits']; + result$data['limits'] = l$limits == null + ? null + : Input$RecoveryKeyLimitsInput.fromJson( + (l$limits as Map)); + } + return Variables$Mutation$GetNewRecoveryApiKey._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$GetNewRecoveryApiKey) || - runtimeType != other.runtimeType) return false; - final l$limits = limits; - final lOther$limits = other.limits; - if (l$limits != lOther$limits) return false; - return true; + Map _$data; + + Input$RecoveryKeyLimitsInput? get limits => + (_$data['limits'] as Input$RecoveryKeyLimitsInput?); + Map toJson() { + final result$data = {}; + if (_$data.containsKey('limits')) { + final l$limits = limits; + result$data['limits'] = l$limits?.toJson(); + } + return result$data; } CopyWith$Variables$Mutation$GetNewRecoveryApiKey< Variables$Mutation$GetNewRecoveryApiKey> - get copyWith => - CopyWith$Variables$Mutation$GetNewRecoveryApiKey(this, (i) => i); + get copyWith => CopyWith$Variables$Mutation$GetNewRecoveryApiKey( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$GetNewRecoveryApiKey) || + runtimeType != other.runtimeType) { + return false; + } + final l$limits = limits; + final lOther$limits = other.limits; + if (_$data.containsKey('limits') != other._$data.containsKey('limits')) { + return false; + } + if (l$limits != lOther$limits) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$limits = limits; + return Object.hashAll([_$data.containsKey('limits') ? l$limits : const {}]); + } } abstract class CopyWith$Variables$Mutation$GetNewRecoveryApiKey { factory CopyWith$Variables$Mutation$GetNewRecoveryApiKey( - Variables$Mutation$GetNewRecoveryApiKey instance, - TRes Function(Variables$Mutation$GetNewRecoveryApiKey) then) = - _CopyWithImpl$Variables$Mutation$GetNewRecoveryApiKey; + Variables$Mutation$GetNewRecoveryApiKey instance, + TRes Function(Variables$Mutation$GetNewRecoveryApiKey) then, + ) = _CopyWithImpl$Variables$Mutation$GetNewRecoveryApiKey; factory CopyWith$Variables$Mutation$GetNewRecoveryApiKey.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$GetNewRecoveryApiKey; @@ -4590,7 +7716,9 @@ abstract class CopyWith$Variables$Mutation$GetNewRecoveryApiKey { class _CopyWithImpl$Variables$Mutation$GetNewRecoveryApiKey implements CopyWith$Variables$Mutation$GetNewRecoveryApiKey { _CopyWithImpl$Variables$Mutation$GetNewRecoveryApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Variables$Mutation$GetNewRecoveryApiKey _instance; @@ -4599,10 +7727,11 @@ class _CopyWithImpl$Variables$Mutation$GetNewRecoveryApiKey static const _undefined = {}; TRes call({Object? limits = _undefined}) => - _then(Variables$Mutation$GetNewRecoveryApiKey( - limits: limits == _undefined - ? _instance.limits - : (limits as Input$RecoveryKeyLimitsInput?))); + _then(Variables$Mutation$GetNewRecoveryApiKey._({ + ..._instance._$data, + if (limits != _undefined) + 'limits': (limits as Input$RecoveryKeyLimitsInput?), + })); } class _CopyWithStubImpl$Variables$Mutation$GetNewRecoveryApiKey @@ -4614,38 +7743,65 @@ class _CopyWithStubImpl$Variables$Mutation$GetNewRecoveryApiKey call({Input$RecoveryKeyLimitsInput? limits}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$GetNewRecoveryApiKey { - Mutation$GetNewRecoveryApiKey( - {required this.getNewRecoveryApiKey, required this.$__typename}); + Mutation$GetNewRecoveryApiKey({ + required this.getNewRecoveryApiKey, + required this.$__typename, + }); - @override - factory Mutation$GetNewRecoveryApiKey.fromJson(Map json) => - _$Mutation$GetNewRecoveryApiKeyFromJson(json); + factory Mutation$GetNewRecoveryApiKey.fromJson(Map json) { + final l$getNewRecoveryApiKey = json['getNewRecoveryApiKey']; + final l$$__typename = json['__typename']; + return Mutation$GetNewRecoveryApiKey( + getNewRecoveryApiKey: + Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey.fromJson( + (l$getNewRecoveryApiKey as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey getNewRecoveryApiKey; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$GetNewRecoveryApiKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$getNewRecoveryApiKey = getNewRecoveryApiKey; + _resultData['getNewRecoveryApiKey'] = l$getNewRecoveryApiKey.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$getNewRecoveryApiKey = getNewRecoveryApiKey; final l$$__typename = $__typename; - return Object.hashAll([l$getNewRecoveryApiKey, l$$__typename]); + return Object.hashAll([ + l$getNewRecoveryApiKey, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$GetNewRecoveryApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$getNewRecoveryApiKey = getNewRecoveryApiKey; final lOther$getNewRecoveryApiKey = other.getNewRecoveryApiKey; - if (l$getNewRecoveryApiKey != lOther$getNewRecoveryApiKey) return false; + if (l$getNewRecoveryApiKey != lOther$getNewRecoveryApiKey) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -4653,28 +7809,35 @@ class Mutation$GetNewRecoveryApiKey { extension UtilityExtension$Mutation$GetNewRecoveryApiKey on Mutation$GetNewRecoveryApiKey { CopyWith$Mutation$GetNewRecoveryApiKey - get copyWith => CopyWith$Mutation$GetNewRecoveryApiKey(this, (i) => i); + get copyWith => CopyWith$Mutation$GetNewRecoveryApiKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$GetNewRecoveryApiKey { factory CopyWith$Mutation$GetNewRecoveryApiKey( - Mutation$GetNewRecoveryApiKey instance, - TRes Function(Mutation$GetNewRecoveryApiKey) then) = - _CopyWithImpl$Mutation$GetNewRecoveryApiKey; + Mutation$GetNewRecoveryApiKey instance, + TRes Function(Mutation$GetNewRecoveryApiKey) then, + ) = _CopyWithImpl$Mutation$GetNewRecoveryApiKey; factory CopyWith$Mutation$GetNewRecoveryApiKey.stub(TRes res) = _CopyWithStubImpl$Mutation$GetNewRecoveryApiKey; - TRes call( - {Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey? getNewRecoveryApiKey, - String? $__typename}); + TRes call({ + Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey? getNewRecoveryApiKey, + String? $__typename, + }); CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey get getNewRecoveryApiKey; } class _CopyWithImpl$Mutation$GetNewRecoveryApiKey implements CopyWith$Mutation$GetNewRecoveryApiKey { - _CopyWithImpl$Mutation$GetNewRecoveryApiKey(this._instance, this._then); + _CopyWithImpl$Mutation$GetNewRecoveryApiKey( + this._instance, + this._then, + ); final Mutation$GetNewRecoveryApiKey _instance; @@ -4682,18 +7845,20 @@ class _CopyWithImpl$Mutation$GetNewRecoveryApiKey static const _undefined = {}; - TRes call( - {Object? getNewRecoveryApiKey = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? getNewRecoveryApiKey = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$GetNewRecoveryApiKey( - getNewRecoveryApiKey: - getNewRecoveryApiKey == _undefined || getNewRecoveryApiKey == null - ? _instance.getNewRecoveryApiKey - : (getNewRecoveryApiKey - as Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + getNewRecoveryApiKey: + getNewRecoveryApiKey == _undefined || getNewRecoveryApiKey == null + ? _instance.getNewRecoveryApiKey + : (getNewRecoveryApiKey + as Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey get getNewRecoveryApiKey { final local$getNewRecoveryApiKey = _instance.getNewRecoveryApiKey; @@ -4708,10 +7873,10 @@ class _CopyWithStubImpl$Mutation$GetNewRecoveryApiKey TRes _res; - call( - {Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey? - getNewRecoveryApiKey, - String? $__typename}) => + call({ + Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey? getNewRecoveryApiKey, + String? $__typename, + }) => _res; CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey get getNewRecoveryApiKey => @@ -4721,93 +7886,107 @@ class _CopyWithStubImpl$Mutation$GetNewRecoveryApiKey const documentNodeMutationGetNewRecoveryApiKey = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'GetNewRecoveryApiKey'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'limits')), - type: NamedTypeNode( - name: NameNode(value: 'RecoveryKeyLimitsInput'), - isNonNull: false), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'getNewRecoveryApiKey'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'limits'), - value: VariableNode(name: NameNode(value: 'limits'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'GetNewRecoveryApiKey'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'limits')), + type: NamedTypeNode( + name: NameNode(value: 'RecoveryKeyLimitsInput'), + isNonNull: false, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'getNewRecoveryApiKey'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'limits'), + value: VariableNode(name: NameNode(value: 'limits')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: 'key'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( + name: NameNode(value: 'key'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$GetNewRecoveryApiKey _parserFn$Mutation$GetNewRecoveryApiKey( Map data) => Mutation$GetNewRecoveryApiKey.fromJson(data); typedef OnMutationCompleted$Mutation$GetNewRecoveryApiKey = FutureOr - Function(dynamic, Mutation$GetNewRecoveryApiKey?); + Function( + dynamic, + Mutation$GetNewRecoveryApiKey?, +); class Options$Mutation$GetNewRecoveryApiKey extends graphql.MutationOptions { - Options$Mutation$GetNewRecoveryApiKey( - {String? operationName, - Variables$Mutation$GetNewRecoveryApiKey? variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$GetNewRecoveryApiKey? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$GetNewRecoveryApiKey({ + String? operationName, + Variables$Mutation$GetNewRecoveryApiKey? variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$GetNewRecoveryApiKey? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables?.toJson() ?? {}, - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables?.toJson() ?? {}, + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$GetNewRecoveryApiKey(data)), - update: update, - onError: onError, - document: documentNodeMutationGetNewRecoveryApiKey, - parserFn: _parserFn$Mutation$GetNewRecoveryApiKey); + : _parserFn$Mutation$GetNewRecoveryApiKey(data), + ), + update: update, + onError: onError, + document: documentNodeMutationGetNewRecoveryApiKey, + parserFn: _parserFn$Mutation$GetNewRecoveryApiKey, + ); final OnMutationCompleted$Mutation$GetNewRecoveryApiKey? onCompletedWithParsed; @@ -4817,38 +7996,39 @@ class Options$Mutation$GetNewRecoveryApiKey ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$GetNewRecoveryApiKey extends graphql.WatchQueryOptions { - WatchOptions$Mutation$GetNewRecoveryApiKey( - {String? operationName, - Variables$Mutation$GetNewRecoveryApiKey? variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables?.toJson() ?? {}, - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationGetNewRecoveryApiKey, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$GetNewRecoveryApiKey); + WatchOptions$Mutation$GetNewRecoveryApiKey({ + String? operationName, + Variables$Mutation$GetNewRecoveryApiKey? variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables?.toJson() ?? {}, + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationGetNewRecoveryApiKey, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$GetNewRecoveryApiKey, + ); } extension ClientExtension$Mutation$GetNewRecoveryApiKey @@ -4864,20 +8044,31 @@ extension ClientExtension$Mutation$GetNewRecoveryApiKey options ?? WatchOptions$Mutation$GetNewRecoveryApiKey()); } -@JsonSerializable(explicitToJson: true) class Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey - implements Fragment$basicMutationReturnFields { - Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.key}); + implements Fragment$basicMutationReturnFields$$ApiKeyMutationReturn { + Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.key, + }); - @override factory Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey.fromJson( - Map json) => - _$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKeyFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$key = json['key']; + return Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + key: (l$key as String?), + ); + } final int code; @@ -4885,42 +8076,75 @@ class Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey final bool success; - @JsonKey(name: '__typename') final String $__typename; final String? key; - Map toJson() => - _$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$key = key; + _resultData['key'] = l$key; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$key = key; - return Object.hashAll([l$code, l$message, l$success, l$$__typename, l$key]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$key, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$key = key; final lOther$key = other.key; - if (l$key != lOther$key) return false; + if (l$key != lOther$key) { + return false; + } return true; } } @@ -4931,34 +8155,38 @@ extension UtilityExtension$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey> get copyWith => CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey< TRes> { factory CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey( - Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey instance, - TRes Function(Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey) - then) = - _CopyWithImpl$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey; + Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey instance, + TRes Function(Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey) then, + ) = _CopyWithImpl$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey; factory CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey.stub( TRes res) = _CopyWithStubImpl$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? key}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? key, + }); } class _CopyWithImpl$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey implements CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey { _CopyWithImpl$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey _instance; @@ -4966,26 +8194,27 @@ class _CopyWithImpl$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? key = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? key = _undefined, + }) => _then(Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - key: key == _undefined ? _instance.key : (key as String?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + key: key == _undefined ? _instance.key : (key as String?), + )); } class _CopyWithStubImpl$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey @@ -4996,55 +8225,80 @@ class _CopyWithStubImpl$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? key}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? key, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$UseRecoveryApiKey { - Variables$Mutation$UseRecoveryApiKey({required this.input}); + factory Variables$Mutation$UseRecoveryApiKey( + {required Input$UseRecoveryKeyInput input}) => + Variables$Mutation$UseRecoveryApiKey._({ + r'input': input, + }); + + Variables$Mutation$UseRecoveryApiKey._(this._$data); - @override factory Variables$Mutation$UseRecoveryApiKey.fromJson( - Map json) => - _$Variables$Mutation$UseRecoveryApiKeyFromJson(json); - - final Input$UseRecoveryKeyInput input; - - Map toJson() => - _$Variables$Mutation$UseRecoveryApiKeyToJson(this); - int get hashCode { - final l$input = input; - return Object.hashAll([l$input]); + Map data) { + final result$data = {}; + final l$input = data['input']; + result$data['input'] = + Input$UseRecoveryKeyInput.fromJson((l$input as Map)); + return Variables$Mutation$UseRecoveryApiKey._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$UseRecoveryApiKey) || - runtimeType != other.runtimeType) return false; + Map _$data; + + Input$UseRecoveryKeyInput get input => + (_$data['input'] as Input$UseRecoveryKeyInput); + Map toJson() { + final result$data = {}; final l$input = input; - final lOther$input = other.input; - if (l$input != lOther$input) return false; - return true; + result$data['input'] = l$input.toJson(); + return result$data; } CopyWith$Variables$Mutation$UseRecoveryApiKey< Variables$Mutation$UseRecoveryApiKey> - get copyWith => - CopyWith$Variables$Mutation$UseRecoveryApiKey(this, (i) => i); + get copyWith => CopyWith$Variables$Mutation$UseRecoveryApiKey( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$UseRecoveryApiKey) || + runtimeType != other.runtimeType) { + return false; + } + final l$input = input; + final lOther$input = other.input; + if (l$input != lOther$input) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$input = input; + return Object.hashAll([l$input]); + } } abstract class CopyWith$Variables$Mutation$UseRecoveryApiKey { factory CopyWith$Variables$Mutation$UseRecoveryApiKey( - Variables$Mutation$UseRecoveryApiKey instance, - TRes Function(Variables$Mutation$UseRecoveryApiKey) then) = - _CopyWithImpl$Variables$Mutation$UseRecoveryApiKey; + Variables$Mutation$UseRecoveryApiKey instance, + TRes Function(Variables$Mutation$UseRecoveryApiKey) then, + ) = _CopyWithImpl$Variables$Mutation$UseRecoveryApiKey; factory CopyWith$Variables$Mutation$UseRecoveryApiKey.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$UseRecoveryApiKey; @@ -5055,7 +8309,9 @@ abstract class CopyWith$Variables$Mutation$UseRecoveryApiKey { class _CopyWithImpl$Variables$Mutation$UseRecoveryApiKey implements CopyWith$Variables$Mutation$UseRecoveryApiKey { _CopyWithImpl$Variables$Mutation$UseRecoveryApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Variables$Mutation$UseRecoveryApiKey _instance; @@ -5064,10 +8320,11 @@ class _CopyWithImpl$Variables$Mutation$UseRecoveryApiKey static const _undefined = {}; TRes call({Object? input = _undefined}) => - _then(Variables$Mutation$UseRecoveryApiKey( - input: input == _undefined || input == null - ? _instance.input - : (input as Input$UseRecoveryKeyInput))); + _then(Variables$Mutation$UseRecoveryApiKey._({ + ..._instance._$data, + if (input != _undefined && input != null) + 'input': (input as Input$UseRecoveryKeyInput), + })); } class _CopyWithStubImpl$Variables$Mutation$UseRecoveryApiKey @@ -5079,38 +8336,64 @@ class _CopyWithStubImpl$Variables$Mutation$UseRecoveryApiKey call({Input$UseRecoveryKeyInput? input}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$UseRecoveryApiKey { - Mutation$UseRecoveryApiKey( - {required this.useRecoveryApiKey, required this.$__typename}); + Mutation$UseRecoveryApiKey({ + required this.useRecoveryApiKey, + required this.$__typename, + }); - @override - factory Mutation$UseRecoveryApiKey.fromJson(Map json) => - _$Mutation$UseRecoveryApiKeyFromJson(json); + factory Mutation$UseRecoveryApiKey.fromJson(Map json) { + final l$useRecoveryApiKey = json['useRecoveryApiKey']; + final l$$__typename = json['__typename']; + return Mutation$UseRecoveryApiKey( + useRecoveryApiKey: Mutation$UseRecoveryApiKey$useRecoveryApiKey.fromJson( + (l$useRecoveryApiKey as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$UseRecoveryApiKey$useRecoveryApiKey useRecoveryApiKey; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$UseRecoveryApiKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$useRecoveryApiKey = useRecoveryApiKey; + _resultData['useRecoveryApiKey'] = l$useRecoveryApiKey.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$useRecoveryApiKey = useRecoveryApiKey; final l$$__typename = $__typename; - return Object.hashAll([l$useRecoveryApiKey, l$$__typename]); + return Object.hashAll([ + l$useRecoveryApiKey, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$UseRecoveryApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$useRecoveryApiKey = useRecoveryApiKey; final lOther$useRecoveryApiKey = other.useRecoveryApiKey; - if (l$useRecoveryApiKey != lOther$useRecoveryApiKey) return false; + if (l$useRecoveryApiKey != lOther$useRecoveryApiKey) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -5118,28 +8401,35 @@ class Mutation$UseRecoveryApiKey { extension UtilityExtension$Mutation$UseRecoveryApiKey on Mutation$UseRecoveryApiKey { CopyWith$Mutation$UseRecoveryApiKey - get copyWith => CopyWith$Mutation$UseRecoveryApiKey(this, (i) => i); + get copyWith => CopyWith$Mutation$UseRecoveryApiKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$UseRecoveryApiKey { factory CopyWith$Mutation$UseRecoveryApiKey( - Mutation$UseRecoveryApiKey instance, - TRes Function(Mutation$UseRecoveryApiKey) then) = - _CopyWithImpl$Mutation$UseRecoveryApiKey; + Mutation$UseRecoveryApiKey instance, + TRes Function(Mutation$UseRecoveryApiKey) then, + ) = _CopyWithImpl$Mutation$UseRecoveryApiKey; factory CopyWith$Mutation$UseRecoveryApiKey.stub(TRes res) = _CopyWithStubImpl$Mutation$UseRecoveryApiKey; - TRes call( - {Mutation$UseRecoveryApiKey$useRecoveryApiKey? useRecoveryApiKey, - String? $__typename}); + TRes call({ + Mutation$UseRecoveryApiKey$useRecoveryApiKey? useRecoveryApiKey, + String? $__typename, + }); CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey get useRecoveryApiKey; } class _CopyWithImpl$Mutation$UseRecoveryApiKey implements CopyWith$Mutation$UseRecoveryApiKey { - _CopyWithImpl$Mutation$UseRecoveryApiKey(this._instance, this._then); + _CopyWithImpl$Mutation$UseRecoveryApiKey( + this._instance, + this._then, + ); final Mutation$UseRecoveryApiKey _instance; @@ -5147,18 +8437,20 @@ class _CopyWithImpl$Mutation$UseRecoveryApiKey static const _undefined = {}; - TRes call( - {Object? useRecoveryApiKey = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? useRecoveryApiKey = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$UseRecoveryApiKey( - useRecoveryApiKey: - useRecoveryApiKey == _undefined || useRecoveryApiKey == null - ? _instance.useRecoveryApiKey - : (useRecoveryApiKey - as Mutation$UseRecoveryApiKey$useRecoveryApiKey), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + useRecoveryApiKey: + useRecoveryApiKey == _undefined || useRecoveryApiKey == null + ? _instance.useRecoveryApiKey + : (useRecoveryApiKey + as Mutation$UseRecoveryApiKey$useRecoveryApiKey), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey get useRecoveryApiKey { final local$useRecoveryApiKey = _instance.useRecoveryApiKey; @@ -5173,9 +8465,10 @@ class _CopyWithStubImpl$Mutation$UseRecoveryApiKey TRes _res; - call( - {Mutation$UseRecoveryApiKey$useRecoveryApiKey? useRecoveryApiKey, - String? $__typename}) => + call({ + Mutation$UseRecoveryApiKey$useRecoveryApiKey? useRecoveryApiKey, + String? $__typename, + }) => _res; CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey get useRecoveryApiKey => @@ -5184,92 +8477,107 @@ class _CopyWithStubImpl$Mutation$UseRecoveryApiKey const documentNodeMutationUseRecoveryApiKey = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'UseRecoveryApiKey'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'input')), - type: NamedTypeNode( - name: NameNode(value: 'UseRecoveryKeyInput'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'useRecoveryApiKey'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'input'), - value: VariableNode(name: NameNode(value: 'input'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'UseRecoveryApiKey'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'input')), + type: NamedTypeNode( + name: NameNode(value: 'UseRecoveryKeyInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'useRecoveryApiKey'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'input'), + value: VariableNode(name: NameNode(value: 'input')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: 'token'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( + name: NameNode(value: 'token'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$UseRecoveryApiKey _parserFn$Mutation$UseRecoveryApiKey( Map data) => Mutation$UseRecoveryApiKey.fromJson(data); typedef OnMutationCompleted$Mutation$UseRecoveryApiKey = FutureOr - Function(dynamic, Mutation$UseRecoveryApiKey?); + Function( + dynamic, + Mutation$UseRecoveryApiKey?, +); class Options$Mutation$UseRecoveryApiKey extends graphql.MutationOptions { - Options$Mutation$UseRecoveryApiKey( - {String? operationName, - required Variables$Mutation$UseRecoveryApiKey variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$UseRecoveryApiKey? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$UseRecoveryApiKey({ + String? operationName, + required Variables$Mutation$UseRecoveryApiKey variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$UseRecoveryApiKey? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$UseRecoveryApiKey(data)), - update: update, - onError: onError, - document: documentNodeMutationUseRecoveryApiKey, - parserFn: _parserFn$Mutation$UseRecoveryApiKey); + : _parserFn$Mutation$UseRecoveryApiKey(data), + ), + update: update, + onError: onError, + document: documentNodeMutationUseRecoveryApiKey, + parserFn: _parserFn$Mutation$UseRecoveryApiKey, + ); final OnMutationCompleted$Mutation$UseRecoveryApiKey? onCompletedWithParsed; @@ -5278,38 +8586,39 @@ class Options$Mutation$UseRecoveryApiKey ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$UseRecoveryApiKey extends graphql.WatchQueryOptions { - WatchOptions$Mutation$UseRecoveryApiKey( - {String? operationName, - required Variables$Mutation$UseRecoveryApiKey variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationUseRecoveryApiKey, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$UseRecoveryApiKey); + WatchOptions$Mutation$UseRecoveryApiKey({ + String? operationName, + required Variables$Mutation$UseRecoveryApiKey variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationUseRecoveryApiKey, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$UseRecoveryApiKey, + ); } extension ClientExtension$Mutation$UseRecoveryApiKey on graphql.GraphQLClient { @@ -5323,20 +8632,32 @@ extension ClientExtension$Mutation$UseRecoveryApiKey on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$UseRecoveryApiKey$useRecoveryApiKey - implements Fragment$basicMutationReturnFields { - Mutation$UseRecoveryApiKey$useRecoveryApiKey( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.token}); + implements + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn { + Mutation$UseRecoveryApiKey$useRecoveryApiKey({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.token, + }); - @override factory Mutation$UseRecoveryApiKey$useRecoveryApiKey.fromJson( - Map json) => - _$Mutation$UseRecoveryApiKey$useRecoveryApiKeyFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$token = json['token']; + return Mutation$UseRecoveryApiKey$useRecoveryApiKey( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + token: (l$token as String?), + ); + } final int code; @@ -5344,43 +8665,75 @@ class Mutation$UseRecoveryApiKey$useRecoveryApiKey final bool success; - @JsonKey(name: '__typename') final String $__typename; final String? token; - Map toJson() => - _$Mutation$UseRecoveryApiKey$useRecoveryApiKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$token = token; + _resultData['token'] = l$token; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$token = token; - return Object.hashAll( - [l$code, l$message, l$success, l$$__typename, l$token]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$token, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$UseRecoveryApiKey$useRecoveryApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$token = token; final lOther$token = other.token; - if (l$token != lOther$token) return false; + if (l$token != lOther$token) { + return false; + } return true; } } @@ -5389,31 +8742,36 @@ extension UtilityExtension$Mutation$UseRecoveryApiKey$useRecoveryApiKey on Mutation$UseRecoveryApiKey$useRecoveryApiKey { CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey< Mutation$UseRecoveryApiKey$useRecoveryApiKey> - get copyWith => - CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey(this, (i) => i); + get copyWith => CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey { factory CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey( - Mutation$UseRecoveryApiKey$useRecoveryApiKey instance, - TRes Function(Mutation$UseRecoveryApiKey$useRecoveryApiKey) then) = - _CopyWithImpl$Mutation$UseRecoveryApiKey$useRecoveryApiKey; + Mutation$UseRecoveryApiKey$useRecoveryApiKey instance, + TRes Function(Mutation$UseRecoveryApiKey$useRecoveryApiKey) then, + ) = _CopyWithImpl$Mutation$UseRecoveryApiKey$useRecoveryApiKey; factory CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey.stub(TRes res) = _CopyWithStubImpl$Mutation$UseRecoveryApiKey$useRecoveryApiKey; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? token}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? token, + }); } class _CopyWithImpl$Mutation$UseRecoveryApiKey$useRecoveryApiKey implements CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey { _CopyWithImpl$Mutation$UseRecoveryApiKey$useRecoveryApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$UseRecoveryApiKey$useRecoveryApiKey _instance; @@ -5421,26 +8779,27 @@ class _CopyWithImpl$Mutation$UseRecoveryApiKey$useRecoveryApiKey static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? token = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? token = _undefined, + }) => _then(Mutation$UseRecoveryApiKey$useRecoveryApiKey( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - token: token == _undefined ? _instance.token : (token as String?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + token: token == _undefined ? _instance.token : (token as String?), + )); } class _CopyWithStubImpl$Mutation$UseRecoveryApiKey$useRecoveryApiKey @@ -5449,48 +8808,76 @@ class _CopyWithStubImpl$Mutation$UseRecoveryApiKey$useRecoveryApiKey TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? token}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? token, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$RefreshDeviceApiToken { - Mutation$RefreshDeviceApiToken( - {required this.refreshDeviceApiToken, required this.$__typename}); + Mutation$RefreshDeviceApiToken({ + required this.refreshDeviceApiToken, + required this.$__typename, + }); - @override - factory Mutation$RefreshDeviceApiToken.fromJson(Map json) => - _$Mutation$RefreshDeviceApiTokenFromJson(json); + factory Mutation$RefreshDeviceApiToken.fromJson(Map json) { + final l$refreshDeviceApiToken = json['refreshDeviceApiToken']; + final l$$__typename = json['__typename']; + return Mutation$RefreshDeviceApiToken( + refreshDeviceApiToken: + Mutation$RefreshDeviceApiToken$refreshDeviceApiToken.fromJson( + (l$refreshDeviceApiToken as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$RefreshDeviceApiToken$refreshDeviceApiToken refreshDeviceApiToken; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RefreshDeviceApiTokenToJson(this); + Map toJson() { + final _resultData = {}; + final l$refreshDeviceApiToken = refreshDeviceApiToken; + _resultData['refreshDeviceApiToken'] = l$refreshDeviceApiToken.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$refreshDeviceApiToken = refreshDeviceApiToken; final l$$__typename = $__typename; - return Object.hashAll([l$refreshDeviceApiToken, l$$__typename]); + return Object.hashAll([ + l$refreshDeviceApiToken, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RefreshDeviceApiToken) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$refreshDeviceApiToken = refreshDeviceApiToken; final lOther$refreshDeviceApiToken = other.refreshDeviceApiToken; - if (l$refreshDeviceApiToken != lOther$refreshDeviceApiToken) return false; + if (l$refreshDeviceApiToken != lOther$refreshDeviceApiToken) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -5498,29 +8885,35 @@ class Mutation$RefreshDeviceApiToken { extension UtilityExtension$Mutation$RefreshDeviceApiToken on Mutation$RefreshDeviceApiToken { CopyWith$Mutation$RefreshDeviceApiToken - get copyWith => CopyWith$Mutation$RefreshDeviceApiToken(this, (i) => i); + get copyWith => CopyWith$Mutation$RefreshDeviceApiToken( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RefreshDeviceApiToken { factory CopyWith$Mutation$RefreshDeviceApiToken( - Mutation$RefreshDeviceApiToken instance, - TRes Function(Mutation$RefreshDeviceApiToken) then) = - _CopyWithImpl$Mutation$RefreshDeviceApiToken; + Mutation$RefreshDeviceApiToken instance, + TRes Function(Mutation$RefreshDeviceApiToken) then, + ) = _CopyWithImpl$Mutation$RefreshDeviceApiToken; factory CopyWith$Mutation$RefreshDeviceApiToken.stub(TRes res) = _CopyWithStubImpl$Mutation$RefreshDeviceApiToken; - TRes call( - {Mutation$RefreshDeviceApiToken$refreshDeviceApiToken? - refreshDeviceApiToken, - String? $__typename}); + TRes call({ + Mutation$RefreshDeviceApiToken$refreshDeviceApiToken? refreshDeviceApiToken, + String? $__typename, + }); CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken get refreshDeviceApiToken; } class _CopyWithImpl$Mutation$RefreshDeviceApiToken implements CopyWith$Mutation$RefreshDeviceApiToken { - _CopyWithImpl$Mutation$RefreshDeviceApiToken(this._instance, this._then); + _CopyWithImpl$Mutation$RefreshDeviceApiToken( + this._instance, + this._then, + ); final Mutation$RefreshDeviceApiToken _instance; @@ -5528,18 +8921,20 @@ class _CopyWithImpl$Mutation$RefreshDeviceApiToken static const _undefined = {}; - TRes call( - {Object? refreshDeviceApiToken = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? refreshDeviceApiToken = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RefreshDeviceApiToken( - refreshDeviceApiToken: refreshDeviceApiToken == _undefined || - refreshDeviceApiToken == null - ? _instance.refreshDeviceApiToken - : (refreshDeviceApiToken - as Mutation$RefreshDeviceApiToken$refreshDeviceApiToken), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + refreshDeviceApiToken: + refreshDeviceApiToken == _undefined || refreshDeviceApiToken == null + ? _instance.refreshDeviceApiToken + : (refreshDeviceApiToken + as Mutation$RefreshDeviceApiToken$refreshDeviceApiToken), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken get refreshDeviceApiToken { final local$refreshDeviceApiToken = _instance.refreshDeviceApiToken; @@ -5554,10 +8949,10 @@ class _CopyWithStubImpl$Mutation$RefreshDeviceApiToken TRes _res; - call( - {Mutation$RefreshDeviceApiToken$refreshDeviceApiToken? - refreshDeviceApiToken, - String? $__typename}) => + call({ + Mutation$RefreshDeviceApiToken$refreshDeviceApiToken? refreshDeviceApiToken, + String? $__typename, + }) => _res; CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken get refreshDeviceApiToken => @@ -5567,79 +8962,90 @@ class _CopyWithStubImpl$Mutation$RefreshDeviceApiToken const documentNodeMutationRefreshDeviceApiToken = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'RefreshDeviceApiToken'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'refreshDeviceApiToken'), + type: OperationType.mutation, + name: NameNode(value: 'RefreshDeviceApiToken'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'refreshDeviceApiToken'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: 'token'), alias: null, arguments: [], directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: 'token'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$RefreshDeviceApiToken _parserFn$Mutation$RefreshDeviceApiToken( Map data) => Mutation$RefreshDeviceApiToken.fromJson(data); typedef OnMutationCompleted$Mutation$RefreshDeviceApiToken = FutureOr - Function(dynamic, Mutation$RefreshDeviceApiToken?); + Function( + dynamic, + Mutation$RefreshDeviceApiToken?, +); class Options$Mutation$RefreshDeviceApiToken extends graphql.MutationOptions { - Options$Mutation$RefreshDeviceApiToken( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$RefreshDeviceApiToken? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$RefreshDeviceApiToken({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$RefreshDeviceApiToken? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$RefreshDeviceApiToken(data)), - update: update, - onError: onError, - document: documentNodeMutationRefreshDeviceApiToken, - parserFn: _parserFn$Mutation$RefreshDeviceApiToken); + : _parserFn$Mutation$RefreshDeviceApiToken(data), + ), + update: update, + onError: onError, + document: documentNodeMutationRefreshDeviceApiToken, + parserFn: _parserFn$Mutation$RefreshDeviceApiToken, + ); final OnMutationCompleted$Mutation$RefreshDeviceApiToken? onCompletedWithParsed; @@ -5649,36 +9055,37 @@ class Options$Mutation$RefreshDeviceApiToken ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$RefreshDeviceApiToken extends graphql.WatchQueryOptions { - WatchOptions$Mutation$RefreshDeviceApiToken( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationRefreshDeviceApiToken, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$RefreshDeviceApiToken); + WatchOptions$Mutation$RefreshDeviceApiToken({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationRefreshDeviceApiToken, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$RefreshDeviceApiToken, + ); } extension ClientExtension$Mutation$RefreshDeviceApiToken @@ -5695,20 +9102,32 @@ extension ClientExtension$Mutation$RefreshDeviceApiToken options ?? WatchOptions$Mutation$RefreshDeviceApiToken()); } -@JsonSerializable(explicitToJson: true) class Mutation$RefreshDeviceApiToken$refreshDeviceApiToken - implements Fragment$basicMutationReturnFields { - Mutation$RefreshDeviceApiToken$refreshDeviceApiToken( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.token}); + implements + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn { + Mutation$RefreshDeviceApiToken$refreshDeviceApiToken({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.token, + }); - @override factory Mutation$RefreshDeviceApiToken$refreshDeviceApiToken.fromJson( - Map json) => - _$Mutation$RefreshDeviceApiToken$refreshDeviceApiTokenFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$token = json['token']; + return Mutation$RefreshDeviceApiToken$refreshDeviceApiToken( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + token: (l$token as String?), + ); + } final int code; @@ -5716,43 +9135,75 @@ class Mutation$RefreshDeviceApiToken$refreshDeviceApiToken final bool success; - @JsonKey(name: '__typename') final String $__typename; final String? token; - Map toJson() => - _$Mutation$RefreshDeviceApiToken$refreshDeviceApiTokenToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$token = token; + _resultData['token'] = l$token; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$token = token; - return Object.hashAll( - [l$code, l$message, l$success, l$$__typename, l$token]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$token, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RefreshDeviceApiToken$refreshDeviceApiToken) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$token = token; final lOther$token = other.token; - if (l$token != lOther$token) return false; + if (l$token != lOther$token) { + return false; + } return true; } } @@ -5763,34 +9214,38 @@ extension UtilityExtension$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken Mutation$RefreshDeviceApiToken$refreshDeviceApiToken> get copyWith => CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken< TRes> { factory CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken( - Mutation$RefreshDeviceApiToken$refreshDeviceApiToken instance, - TRes Function(Mutation$RefreshDeviceApiToken$refreshDeviceApiToken) - then) = - _CopyWithImpl$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken; + Mutation$RefreshDeviceApiToken$refreshDeviceApiToken instance, + TRes Function(Mutation$RefreshDeviceApiToken$refreshDeviceApiToken) then, + ) = _CopyWithImpl$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken; factory CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken.stub( TRes res) = _CopyWithStubImpl$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? token}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? token, + }); } class _CopyWithImpl$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken implements CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken { _CopyWithImpl$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$RefreshDeviceApiToken$refreshDeviceApiToken _instance; @@ -5799,26 +9254,27 @@ class _CopyWithImpl$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? token = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? token = _undefined, + }) => _then(Mutation$RefreshDeviceApiToken$refreshDeviceApiToken( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - token: token == _undefined ? _instance.token : (token as String?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + token: token == _undefined ? _instance.token : (token as String?), + )); } class _CopyWithStubImpl$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken< @@ -5830,55 +9286,77 @@ class _CopyWithStubImpl$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken< TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? token}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? token, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$DeleteDeviceApiToken { - Variables$Mutation$DeleteDeviceApiToken({required this.device}); + factory Variables$Mutation$DeleteDeviceApiToken({required String device}) => + Variables$Mutation$DeleteDeviceApiToken._({ + r'device': device, + }); + + Variables$Mutation$DeleteDeviceApiToken._(this._$data); - @override factory Variables$Mutation$DeleteDeviceApiToken.fromJson( - Map json) => - _$Variables$Mutation$DeleteDeviceApiTokenFromJson(json); - - final String device; - - Map toJson() => - _$Variables$Mutation$DeleteDeviceApiTokenToJson(this); - int get hashCode { - final l$device = device; - return Object.hashAll([l$device]); + Map data) { + final result$data = {}; + final l$device = data['device']; + result$data['device'] = (l$device as String); + return Variables$Mutation$DeleteDeviceApiToken._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$DeleteDeviceApiToken) || - runtimeType != other.runtimeType) return false; + Map _$data; + + String get device => (_$data['device'] as String); + Map toJson() { + final result$data = {}; final l$device = device; - final lOther$device = other.device; - if (l$device != lOther$device) return false; - return true; + result$data['device'] = l$device; + return result$data; } CopyWith$Variables$Mutation$DeleteDeviceApiToken< Variables$Mutation$DeleteDeviceApiToken> - get copyWith => - CopyWith$Variables$Mutation$DeleteDeviceApiToken(this, (i) => i); + get copyWith => CopyWith$Variables$Mutation$DeleteDeviceApiToken( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$DeleteDeviceApiToken) || + runtimeType != other.runtimeType) { + return false; + } + final l$device = device; + final lOther$device = other.device; + if (l$device != lOther$device) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$device = device; + return Object.hashAll([l$device]); + } } abstract class CopyWith$Variables$Mutation$DeleteDeviceApiToken { factory CopyWith$Variables$Mutation$DeleteDeviceApiToken( - Variables$Mutation$DeleteDeviceApiToken instance, - TRes Function(Variables$Mutation$DeleteDeviceApiToken) then) = - _CopyWithImpl$Variables$Mutation$DeleteDeviceApiToken; + Variables$Mutation$DeleteDeviceApiToken instance, + TRes Function(Variables$Mutation$DeleteDeviceApiToken) then, + ) = _CopyWithImpl$Variables$Mutation$DeleteDeviceApiToken; factory CopyWith$Variables$Mutation$DeleteDeviceApiToken.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$DeleteDeviceApiToken; @@ -5889,7 +9367,9 @@ abstract class CopyWith$Variables$Mutation$DeleteDeviceApiToken { class _CopyWithImpl$Variables$Mutation$DeleteDeviceApiToken implements CopyWith$Variables$Mutation$DeleteDeviceApiToken { _CopyWithImpl$Variables$Mutation$DeleteDeviceApiToken( - this._instance, this._then); + this._instance, + this._then, + ); final Variables$Mutation$DeleteDeviceApiToken _instance; @@ -5898,10 +9378,11 @@ class _CopyWithImpl$Variables$Mutation$DeleteDeviceApiToken static const _undefined = {}; TRes call({Object? device = _undefined}) => - _then(Variables$Mutation$DeleteDeviceApiToken( - device: device == _undefined || device == null - ? _instance.device - : (device as String))); + _then(Variables$Mutation$DeleteDeviceApiToken._({ + ..._instance._$data, + if (device != _undefined && device != null) + 'device': (device as String), + })); } class _CopyWithStubImpl$Variables$Mutation$DeleteDeviceApiToken @@ -5913,38 +9394,65 @@ class _CopyWithStubImpl$Variables$Mutation$DeleteDeviceApiToken call({String? device}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$DeleteDeviceApiToken { - Mutation$DeleteDeviceApiToken( - {required this.deleteDeviceApiToken, required this.$__typename}); + Mutation$DeleteDeviceApiToken({ + required this.deleteDeviceApiToken, + required this.$__typename, + }); - @override - factory Mutation$DeleteDeviceApiToken.fromJson(Map json) => - _$Mutation$DeleteDeviceApiTokenFromJson(json); + factory Mutation$DeleteDeviceApiToken.fromJson(Map json) { + final l$deleteDeviceApiToken = json['deleteDeviceApiToken']; + final l$$__typename = json['__typename']; + return Mutation$DeleteDeviceApiToken( + deleteDeviceApiToken: + Mutation$DeleteDeviceApiToken$deleteDeviceApiToken.fromJson( + (l$deleteDeviceApiToken as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$DeleteDeviceApiToken$deleteDeviceApiToken deleteDeviceApiToken; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$DeleteDeviceApiTokenToJson(this); + Map toJson() { + final _resultData = {}; + final l$deleteDeviceApiToken = deleteDeviceApiToken; + _resultData['deleteDeviceApiToken'] = l$deleteDeviceApiToken.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$deleteDeviceApiToken = deleteDeviceApiToken; final l$$__typename = $__typename; - return Object.hashAll([l$deleteDeviceApiToken, l$$__typename]); + return Object.hashAll([ + l$deleteDeviceApiToken, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$DeleteDeviceApiToken) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$deleteDeviceApiToken = deleteDeviceApiToken; final lOther$deleteDeviceApiToken = other.deleteDeviceApiToken; - if (l$deleteDeviceApiToken != lOther$deleteDeviceApiToken) return false; + if (l$deleteDeviceApiToken != lOther$deleteDeviceApiToken) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -5952,28 +9460,35 @@ class Mutation$DeleteDeviceApiToken { extension UtilityExtension$Mutation$DeleteDeviceApiToken on Mutation$DeleteDeviceApiToken { CopyWith$Mutation$DeleteDeviceApiToken - get copyWith => CopyWith$Mutation$DeleteDeviceApiToken(this, (i) => i); + get copyWith => CopyWith$Mutation$DeleteDeviceApiToken( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$DeleteDeviceApiToken { factory CopyWith$Mutation$DeleteDeviceApiToken( - Mutation$DeleteDeviceApiToken instance, - TRes Function(Mutation$DeleteDeviceApiToken) then) = - _CopyWithImpl$Mutation$DeleteDeviceApiToken; + Mutation$DeleteDeviceApiToken instance, + TRes Function(Mutation$DeleteDeviceApiToken) then, + ) = _CopyWithImpl$Mutation$DeleteDeviceApiToken; factory CopyWith$Mutation$DeleteDeviceApiToken.stub(TRes res) = _CopyWithStubImpl$Mutation$DeleteDeviceApiToken; - TRes call( - {Mutation$DeleteDeviceApiToken$deleteDeviceApiToken? deleteDeviceApiToken, - String? $__typename}); + TRes call({ + Mutation$DeleteDeviceApiToken$deleteDeviceApiToken? deleteDeviceApiToken, + String? $__typename, + }); CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken get deleteDeviceApiToken; } class _CopyWithImpl$Mutation$DeleteDeviceApiToken implements CopyWith$Mutation$DeleteDeviceApiToken { - _CopyWithImpl$Mutation$DeleteDeviceApiToken(this._instance, this._then); + _CopyWithImpl$Mutation$DeleteDeviceApiToken( + this._instance, + this._then, + ); final Mutation$DeleteDeviceApiToken _instance; @@ -5981,18 +9496,20 @@ class _CopyWithImpl$Mutation$DeleteDeviceApiToken static const _undefined = {}; - TRes call( - {Object? deleteDeviceApiToken = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? deleteDeviceApiToken = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$DeleteDeviceApiToken( - deleteDeviceApiToken: - deleteDeviceApiToken == _undefined || deleteDeviceApiToken == null - ? _instance.deleteDeviceApiToken - : (deleteDeviceApiToken - as Mutation$DeleteDeviceApiToken$deleteDeviceApiToken), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + deleteDeviceApiToken: + deleteDeviceApiToken == _undefined || deleteDeviceApiToken == null + ? _instance.deleteDeviceApiToken + : (deleteDeviceApiToken + as Mutation$DeleteDeviceApiToken$deleteDeviceApiToken), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken get deleteDeviceApiToken { final local$deleteDeviceApiToken = _instance.deleteDeviceApiToken; @@ -6007,10 +9524,10 @@ class _CopyWithStubImpl$Mutation$DeleteDeviceApiToken TRes _res; - call( - {Mutation$DeleteDeviceApiToken$deleteDeviceApiToken? - deleteDeviceApiToken, - String? $__typename}) => + call({ + Mutation$DeleteDeviceApiToken$deleteDeviceApiToken? deleteDeviceApiToken, + String? $__typename, + }) => _res; CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken get deleteDeviceApiToken => @@ -6020,86 +9537,100 @@ class _CopyWithStubImpl$Mutation$DeleteDeviceApiToken const documentNodeMutationDeleteDeviceApiToken = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'DeleteDeviceApiToken'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'device')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'deleteDeviceApiToken'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'device'), - value: VariableNode(name: NameNode(value: 'device'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'DeleteDeviceApiToken'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'device')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'deleteDeviceApiToken'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'device'), + value: VariableNode(name: NameNode(value: 'device')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$DeleteDeviceApiToken _parserFn$Mutation$DeleteDeviceApiToken( Map data) => Mutation$DeleteDeviceApiToken.fromJson(data); typedef OnMutationCompleted$Mutation$DeleteDeviceApiToken = FutureOr - Function(dynamic, Mutation$DeleteDeviceApiToken?); + Function( + dynamic, + Mutation$DeleteDeviceApiToken?, +); class Options$Mutation$DeleteDeviceApiToken extends graphql.MutationOptions { - Options$Mutation$DeleteDeviceApiToken( - {String? operationName, - required Variables$Mutation$DeleteDeviceApiToken variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$DeleteDeviceApiToken? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$DeleteDeviceApiToken({ + String? operationName, + required Variables$Mutation$DeleteDeviceApiToken variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$DeleteDeviceApiToken? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$DeleteDeviceApiToken(data)), - update: update, - onError: onError, - document: documentNodeMutationDeleteDeviceApiToken, - parserFn: _parserFn$Mutation$DeleteDeviceApiToken); + : _parserFn$Mutation$DeleteDeviceApiToken(data), + ), + update: update, + onError: onError, + document: documentNodeMutationDeleteDeviceApiToken, + parserFn: _parserFn$Mutation$DeleteDeviceApiToken, + ); final OnMutationCompleted$Mutation$DeleteDeviceApiToken? onCompletedWithParsed; @@ -6109,38 +9640,39 @@ class Options$Mutation$DeleteDeviceApiToken ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$DeleteDeviceApiToken extends graphql.WatchQueryOptions { - WatchOptions$Mutation$DeleteDeviceApiToken( - {String? operationName, - required Variables$Mutation$DeleteDeviceApiToken variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationDeleteDeviceApiToken, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$DeleteDeviceApiToken); + WatchOptions$Mutation$DeleteDeviceApiToken({ + String? operationName, + required Variables$Mutation$DeleteDeviceApiToken variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationDeleteDeviceApiToken, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$DeleteDeviceApiToken, + ); } extension ClientExtension$Mutation$DeleteDeviceApiToken @@ -6155,19 +9687,28 @@ extension ClientExtension$Mutation$DeleteDeviceApiToken this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$DeleteDeviceApiToken$deleteDeviceApiToken - implements Fragment$basicMutationReturnFields { - Mutation$DeleteDeviceApiToken$deleteDeviceApiToken( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$DeleteDeviceApiToken$deleteDeviceApiToken({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$DeleteDeviceApiToken$deleteDeviceApiToken.fromJson( - Map json) => - _$Mutation$DeleteDeviceApiToken$deleteDeviceApiTokenFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$DeleteDeviceApiToken$deleteDeviceApiToken( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -6175,36 +9716,64 @@ class Mutation$DeleteDeviceApiToken$deleteDeviceApiToken final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$DeleteDeviceApiToken$deleteDeviceApiTokenToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$DeleteDeviceApiToken$deleteDeviceApiToken) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -6215,29 +9784,37 @@ extension UtilityExtension$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken Mutation$DeleteDeviceApiToken$deleteDeviceApiToken> get copyWith => CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken< TRes> { factory CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken( - Mutation$DeleteDeviceApiToken$deleteDeviceApiToken instance, - TRes Function(Mutation$DeleteDeviceApiToken$deleteDeviceApiToken) - then) = - _CopyWithImpl$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken; + Mutation$DeleteDeviceApiToken$deleteDeviceApiToken instance, + TRes Function(Mutation$DeleteDeviceApiToken$deleteDeviceApiToken) then, + ) = _CopyWithImpl$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken; factory CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken.stub( TRes res) = _CopyWithStubImpl$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken implements CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken { _CopyWithImpl$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$DeleteDeviceApiToken$deleteDeviceApiToken _instance; @@ -6245,24 +9822,25 @@ class _CopyWithImpl$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$DeleteDeviceApiToken$deleteDeviceApiToken( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken @@ -6273,42 +9851,74 @@ class _CopyWithStubImpl$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$GetNewDeviceApiKey { - Mutation$GetNewDeviceApiKey( - {required this.getNewDeviceApiKey, required this.$__typename}); + Mutation$GetNewDeviceApiKey({ + required this.getNewDeviceApiKey, + required this.$__typename, + }); - @override - factory Mutation$GetNewDeviceApiKey.fromJson(Map json) => - _$Mutation$GetNewDeviceApiKeyFromJson(json); + factory Mutation$GetNewDeviceApiKey.fromJson(Map json) { + final l$getNewDeviceApiKey = json['getNewDeviceApiKey']; + final l$$__typename = json['__typename']; + return Mutation$GetNewDeviceApiKey( + getNewDeviceApiKey: + Mutation$GetNewDeviceApiKey$getNewDeviceApiKey.fromJson( + (l$getNewDeviceApiKey as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$GetNewDeviceApiKey$getNewDeviceApiKey getNewDeviceApiKey; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$GetNewDeviceApiKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$getNewDeviceApiKey = getNewDeviceApiKey; + _resultData['getNewDeviceApiKey'] = l$getNewDeviceApiKey.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$getNewDeviceApiKey = getNewDeviceApiKey; final l$$__typename = $__typename; - return Object.hashAll([l$getNewDeviceApiKey, l$$__typename]); + return Object.hashAll([ + l$getNewDeviceApiKey, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$GetNewDeviceApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$getNewDeviceApiKey = getNewDeviceApiKey; final lOther$getNewDeviceApiKey = other.getNewDeviceApiKey; - if (l$getNewDeviceApiKey != lOther$getNewDeviceApiKey) return false; + if (l$getNewDeviceApiKey != lOther$getNewDeviceApiKey) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -6316,28 +9926,35 @@ class Mutation$GetNewDeviceApiKey { extension UtilityExtension$Mutation$GetNewDeviceApiKey on Mutation$GetNewDeviceApiKey { CopyWith$Mutation$GetNewDeviceApiKey - get copyWith => CopyWith$Mutation$GetNewDeviceApiKey(this, (i) => i); + get copyWith => CopyWith$Mutation$GetNewDeviceApiKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$GetNewDeviceApiKey { factory CopyWith$Mutation$GetNewDeviceApiKey( - Mutation$GetNewDeviceApiKey instance, - TRes Function(Mutation$GetNewDeviceApiKey) then) = - _CopyWithImpl$Mutation$GetNewDeviceApiKey; + Mutation$GetNewDeviceApiKey instance, + TRes Function(Mutation$GetNewDeviceApiKey) then, + ) = _CopyWithImpl$Mutation$GetNewDeviceApiKey; factory CopyWith$Mutation$GetNewDeviceApiKey.stub(TRes res) = _CopyWithStubImpl$Mutation$GetNewDeviceApiKey; - TRes call( - {Mutation$GetNewDeviceApiKey$getNewDeviceApiKey? getNewDeviceApiKey, - String? $__typename}); + TRes call({ + Mutation$GetNewDeviceApiKey$getNewDeviceApiKey? getNewDeviceApiKey, + String? $__typename, + }); CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey get getNewDeviceApiKey; } class _CopyWithImpl$Mutation$GetNewDeviceApiKey implements CopyWith$Mutation$GetNewDeviceApiKey { - _CopyWithImpl$Mutation$GetNewDeviceApiKey(this._instance, this._then); + _CopyWithImpl$Mutation$GetNewDeviceApiKey( + this._instance, + this._then, + ); final Mutation$GetNewDeviceApiKey _instance; @@ -6345,18 +9962,20 @@ class _CopyWithImpl$Mutation$GetNewDeviceApiKey static const _undefined = {}; - TRes call( - {Object? getNewDeviceApiKey = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? getNewDeviceApiKey = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$GetNewDeviceApiKey( - getNewDeviceApiKey: - getNewDeviceApiKey == _undefined || getNewDeviceApiKey == null - ? _instance.getNewDeviceApiKey - : (getNewDeviceApiKey - as Mutation$GetNewDeviceApiKey$getNewDeviceApiKey), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + getNewDeviceApiKey: + getNewDeviceApiKey == _undefined || getNewDeviceApiKey == null + ? _instance.getNewDeviceApiKey + : (getNewDeviceApiKey + as Mutation$GetNewDeviceApiKey$getNewDeviceApiKey), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey get getNewDeviceApiKey { final local$getNewDeviceApiKey = _instance.getNewDeviceApiKey; @@ -6371,9 +9990,10 @@ class _CopyWithStubImpl$Mutation$GetNewDeviceApiKey TRes _res; - call( - {Mutation$GetNewDeviceApiKey$getNewDeviceApiKey? getNewDeviceApiKey, - String? $__typename}) => + call({ + Mutation$GetNewDeviceApiKey$getNewDeviceApiKey? getNewDeviceApiKey, + String? $__typename, + }) => _res; CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey get getNewDeviceApiKey => @@ -6382,79 +10002,90 @@ class _CopyWithStubImpl$Mutation$GetNewDeviceApiKey const documentNodeMutationGetNewDeviceApiKey = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'GetNewDeviceApiKey'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'getNewDeviceApiKey'), + type: OperationType.mutation, + name: NameNode(value: 'GetNewDeviceApiKey'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'getNewDeviceApiKey'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: 'key'), alias: null, arguments: [], directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: 'key'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$GetNewDeviceApiKey _parserFn$Mutation$GetNewDeviceApiKey( Map data) => Mutation$GetNewDeviceApiKey.fromJson(data); typedef OnMutationCompleted$Mutation$GetNewDeviceApiKey = FutureOr - Function(dynamic, Mutation$GetNewDeviceApiKey?); + Function( + dynamic, + Mutation$GetNewDeviceApiKey?, +); class Options$Mutation$GetNewDeviceApiKey extends graphql.MutationOptions { - Options$Mutation$GetNewDeviceApiKey( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$GetNewDeviceApiKey? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$GetNewDeviceApiKey({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$GetNewDeviceApiKey? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$GetNewDeviceApiKey(data)), - update: update, - onError: onError, - document: documentNodeMutationGetNewDeviceApiKey, - parserFn: _parserFn$Mutation$GetNewDeviceApiKey); + : _parserFn$Mutation$GetNewDeviceApiKey(data), + ), + update: update, + onError: onError, + document: documentNodeMutationGetNewDeviceApiKey, + parserFn: _parserFn$Mutation$GetNewDeviceApiKey, + ); final OnMutationCompleted$Mutation$GetNewDeviceApiKey? onCompletedWithParsed; @@ -6463,36 +10094,37 @@ class Options$Mutation$GetNewDeviceApiKey ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$GetNewDeviceApiKey extends graphql.WatchQueryOptions { - WatchOptions$Mutation$GetNewDeviceApiKey( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationGetNewDeviceApiKey, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$GetNewDeviceApiKey); + WatchOptions$Mutation$GetNewDeviceApiKey({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationGetNewDeviceApiKey, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$GetNewDeviceApiKey, + ); } extension ClientExtension$Mutation$GetNewDeviceApiKey on graphql.GraphQLClient { @@ -6506,20 +10138,31 @@ extension ClientExtension$Mutation$GetNewDeviceApiKey on graphql.GraphQLClient { this.watchMutation(options ?? WatchOptions$Mutation$GetNewDeviceApiKey()); } -@JsonSerializable(explicitToJson: true) class Mutation$GetNewDeviceApiKey$getNewDeviceApiKey - implements Fragment$basicMutationReturnFields { - Mutation$GetNewDeviceApiKey$getNewDeviceApiKey( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.key}); + implements Fragment$basicMutationReturnFields$$ApiKeyMutationReturn { + Mutation$GetNewDeviceApiKey$getNewDeviceApiKey({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.key, + }); - @override factory Mutation$GetNewDeviceApiKey$getNewDeviceApiKey.fromJson( - Map json) => - _$Mutation$GetNewDeviceApiKey$getNewDeviceApiKeyFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$key = json['key']; + return Mutation$GetNewDeviceApiKey$getNewDeviceApiKey( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + key: (l$key as String?), + ); + } final int code; @@ -6527,42 +10170,75 @@ class Mutation$GetNewDeviceApiKey$getNewDeviceApiKey final bool success; - @JsonKey(name: '__typename') final String $__typename; final String? key; - Map toJson() => - _$Mutation$GetNewDeviceApiKey$getNewDeviceApiKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$key = key; + _resultData['key'] = l$key; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$key = key; - return Object.hashAll([l$code, l$message, l$success, l$$__typename, l$key]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$key, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$GetNewDeviceApiKey$getNewDeviceApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$key = key; final lOther$key = other.key; - if (l$key != lOther$key) return false; + if (l$key != lOther$key) { + return false; + } return true; } } @@ -6572,31 +10248,36 @@ extension UtilityExtension$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey< Mutation$GetNewDeviceApiKey$getNewDeviceApiKey> get copyWith => CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey { factory CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey( - Mutation$GetNewDeviceApiKey$getNewDeviceApiKey instance, - TRes Function(Mutation$GetNewDeviceApiKey$getNewDeviceApiKey) then) = - _CopyWithImpl$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey; + Mutation$GetNewDeviceApiKey$getNewDeviceApiKey instance, + TRes Function(Mutation$GetNewDeviceApiKey$getNewDeviceApiKey) then, + ) = _CopyWithImpl$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey; factory CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey.stub( TRes res) = _CopyWithStubImpl$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? key}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? key, + }); } class _CopyWithImpl$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey implements CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey { _CopyWithImpl$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$GetNewDeviceApiKey$getNewDeviceApiKey _instance; @@ -6604,26 +10285,27 @@ class _CopyWithImpl$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? key = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? key = _undefined, + }) => _then(Mutation$GetNewDeviceApiKey$getNewDeviceApiKey( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - key: key == _undefined ? _instance.key : (key as String?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + key: key == _undefined ? _instance.key : (key as String?), + )); } class _CopyWithStubImpl$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey @@ -6632,51 +10314,78 @@ class _CopyWithStubImpl$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? key}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? key, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$InvalidateNewDeviceApiKey { - Mutation$InvalidateNewDeviceApiKey( - {required this.invalidateNewDeviceApiKey, required this.$__typename}); + Mutation$InvalidateNewDeviceApiKey({ + required this.invalidateNewDeviceApiKey, + required this.$__typename, + }); - @override factory Mutation$InvalidateNewDeviceApiKey.fromJson( - Map json) => - _$Mutation$InvalidateNewDeviceApiKeyFromJson(json); + Map json) { + final l$invalidateNewDeviceApiKey = json['invalidateNewDeviceApiKey']; + final l$$__typename = json['__typename']; + return Mutation$InvalidateNewDeviceApiKey( + invalidateNewDeviceApiKey: + Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey.fromJson( + (l$invalidateNewDeviceApiKey as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey invalidateNewDeviceApiKey; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$InvalidateNewDeviceApiKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$invalidateNewDeviceApiKey = invalidateNewDeviceApiKey; + _resultData['invalidateNewDeviceApiKey'] = + l$invalidateNewDeviceApiKey.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$invalidateNewDeviceApiKey = invalidateNewDeviceApiKey; final l$$__typename = $__typename; - return Object.hashAll([l$invalidateNewDeviceApiKey, l$$__typename]); + return Object.hashAll([ + l$invalidateNewDeviceApiKey, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$InvalidateNewDeviceApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$invalidateNewDeviceApiKey = invalidateNewDeviceApiKey; final lOther$invalidateNewDeviceApiKey = other.invalidateNewDeviceApiKey; - if (l$invalidateNewDeviceApiKey != lOther$invalidateNewDeviceApiKey) + if (l$invalidateNewDeviceApiKey != lOther$invalidateNewDeviceApiKey) { return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -6685,30 +10394,36 @@ extension UtilityExtension$Mutation$InvalidateNewDeviceApiKey on Mutation$InvalidateNewDeviceApiKey { CopyWith$Mutation$InvalidateNewDeviceApiKey< Mutation$InvalidateNewDeviceApiKey> - get copyWith => - CopyWith$Mutation$InvalidateNewDeviceApiKey(this, (i) => i); + get copyWith => CopyWith$Mutation$InvalidateNewDeviceApiKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$InvalidateNewDeviceApiKey { factory CopyWith$Mutation$InvalidateNewDeviceApiKey( - Mutation$InvalidateNewDeviceApiKey instance, - TRes Function(Mutation$InvalidateNewDeviceApiKey) then) = - _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey; + Mutation$InvalidateNewDeviceApiKey instance, + TRes Function(Mutation$InvalidateNewDeviceApiKey) then, + ) = _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey; factory CopyWith$Mutation$InvalidateNewDeviceApiKey.stub(TRes res) = _CopyWithStubImpl$Mutation$InvalidateNewDeviceApiKey; - TRes call( - {Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey? - invalidateNewDeviceApiKey, - String? $__typename}); + TRes call({ + Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey? + invalidateNewDeviceApiKey, + String? $__typename, + }); CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey get invalidateNewDeviceApiKey; } class _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey implements CopyWith$Mutation$InvalidateNewDeviceApiKey { - _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey(this._instance, this._then); + _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey( + this._instance, + this._then, + ); final Mutation$InvalidateNewDeviceApiKey _instance; @@ -6716,18 +10431,20 @@ class _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey static const _undefined = {}; - TRes call( - {Object? invalidateNewDeviceApiKey = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? invalidateNewDeviceApiKey = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$InvalidateNewDeviceApiKey( - invalidateNewDeviceApiKey: invalidateNewDeviceApiKey == _undefined || - invalidateNewDeviceApiKey == null - ? _instance.invalidateNewDeviceApiKey - : (invalidateNewDeviceApiKey - as Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + invalidateNewDeviceApiKey: invalidateNewDeviceApiKey == _undefined || + invalidateNewDeviceApiKey == null + ? _instance.invalidateNewDeviceApiKey + : (invalidateNewDeviceApiKey + as Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey get invalidateNewDeviceApiKey { final local$invalidateNewDeviceApiKey = _instance.invalidateNewDeviceApiKey; @@ -6743,10 +10460,11 @@ class _CopyWithStubImpl$Mutation$InvalidateNewDeviceApiKey TRes _res; - call( - {Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey? - invalidateNewDeviceApiKey, - String? $__typename}) => + call({ + Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey? + invalidateNewDeviceApiKey, + String? $__typename, + }) => _res; CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey get invalidateNewDeviceApiKey => @@ -6757,73 +10475,83 @@ class _CopyWithStubImpl$Mutation$InvalidateNewDeviceApiKey const documentNodeMutationInvalidateNewDeviceApiKey = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'InvalidateNewDeviceApiKey'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'invalidateNewDeviceApiKey'), - alias: null, - arguments: [], + type: OperationType.mutation, + name: NameNode(value: 'InvalidateNewDeviceApiKey'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'invalidateNewDeviceApiKey'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$InvalidateNewDeviceApiKey _parserFn$Mutation$InvalidateNewDeviceApiKey( Map data) => Mutation$InvalidateNewDeviceApiKey.fromJson(data); typedef OnMutationCompleted$Mutation$InvalidateNewDeviceApiKey = FutureOr - Function(dynamic, Mutation$InvalidateNewDeviceApiKey?); + Function( + dynamic, + Mutation$InvalidateNewDeviceApiKey?, +); class Options$Mutation$InvalidateNewDeviceApiKey extends graphql.MutationOptions { - Options$Mutation$InvalidateNewDeviceApiKey( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$InvalidateNewDeviceApiKey? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$InvalidateNewDeviceApiKey({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$InvalidateNewDeviceApiKey? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$InvalidateNewDeviceApiKey(data)), - update: update, - onError: onError, - document: documentNodeMutationInvalidateNewDeviceApiKey, - parserFn: _parserFn$Mutation$InvalidateNewDeviceApiKey); + : _parserFn$Mutation$InvalidateNewDeviceApiKey(data), + ), + update: update, + onError: onError, + document: documentNodeMutationInvalidateNewDeviceApiKey, + parserFn: _parserFn$Mutation$InvalidateNewDeviceApiKey, + ); final OnMutationCompleted$Mutation$InvalidateNewDeviceApiKey? onCompletedWithParsed; @@ -6833,36 +10561,37 @@ class Options$Mutation$InvalidateNewDeviceApiKey ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$InvalidateNewDeviceApiKey extends graphql.WatchQueryOptions { - WatchOptions$Mutation$InvalidateNewDeviceApiKey( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationInvalidateNewDeviceApiKey, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$InvalidateNewDeviceApiKey); + WatchOptions$Mutation$InvalidateNewDeviceApiKey({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationInvalidateNewDeviceApiKey, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$InvalidateNewDeviceApiKey, + ); } extension ClientExtension$Mutation$InvalidateNewDeviceApiKey @@ -6879,20 +10608,28 @@ extension ClientExtension$Mutation$InvalidateNewDeviceApiKey options ?? WatchOptions$Mutation$InvalidateNewDeviceApiKey()); } -@JsonSerializable(explicitToJson: true) class Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey - implements Fragment$basicMutationReturnFields { - Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey.fromJson( - Map json) => - _$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKeyFromJson( - json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -6900,38 +10637,65 @@ class Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKeyToJson( - this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -6942,23 +10706,29 @@ extension UtilityExtension$Mutation$InvalidateNewDeviceApiKey$invalidateNewDevic Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey> get copyWith => CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey< TRes> { factory CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey( - Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey instance, - TRes Function( - Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey) - then) = - _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey; + Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey instance, + TRes Function(Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey) + then, + ) = _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey; factory CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey.stub( TRes res) = _CopyWithStubImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey< @@ -6967,7 +10737,9 @@ class _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey< TRes> { _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey _instance; @@ -6976,24 +10748,25 @@ class _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey< @@ -7006,50 +10779,79 @@ class _CopyWithStubImpl$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceAp TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$AuthorizeWithNewDeviceApiKey { - Variables$Mutation$AuthorizeWithNewDeviceApiKey({required this.input}); + factory Variables$Mutation$AuthorizeWithNewDeviceApiKey( + {required Input$UseNewDeviceKeyInput input}) => + Variables$Mutation$AuthorizeWithNewDeviceApiKey._({ + r'input': input, + }); + + Variables$Mutation$AuthorizeWithNewDeviceApiKey._(this._$data); - @override factory Variables$Mutation$AuthorizeWithNewDeviceApiKey.fromJson( - Map json) => - _$Variables$Mutation$AuthorizeWithNewDeviceApiKeyFromJson(json); - - final Input$UseNewDeviceKeyInput input; - - Map toJson() => - _$Variables$Mutation$AuthorizeWithNewDeviceApiKeyToJson(this); - int get hashCode { - final l$input = input; - return Object.hashAll([l$input]); + Map data) { + final result$data = {}; + final l$input = data['input']; + result$data['input'] = + Input$UseNewDeviceKeyInput.fromJson((l$input as Map)); + return Variables$Mutation$AuthorizeWithNewDeviceApiKey._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$AuthorizeWithNewDeviceApiKey) || - runtimeType != other.runtimeType) return false; + Map _$data; + + Input$UseNewDeviceKeyInput get input => + (_$data['input'] as Input$UseNewDeviceKeyInput); + Map toJson() { + final result$data = {}; final l$input = input; - final lOther$input = other.input; - if (l$input != lOther$input) return false; - return true; + result$data['input'] = l$input.toJson(); + return result$data; } CopyWith$Variables$Mutation$AuthorizeWithNewDeviceApiKey< Variables$Mutation$AuthorizeWithNewDeviceApiKey> get copyWith => CopyWith$Variables$Mutation$AuthorizeWithNewDeviceApiKey( - this, (i) => i); + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$AuthorizeWithNewDeviceApiKey) || + runtimeType != other.runtimeType) { + return false; + } + final l$input = input; + final lOther$input = other.input; + if (l$input != lOther$input) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$input = input; + return Object.hashAll([l$input]); + } } abstract class CopyWith$Variables$Mutation$AuthorizeWithNewDeviceApiKey { factory CopyWith$Variables$Mutation$AuthorizeWithNewDeviceApiKey( - Variables$Mutation$AuthorizeWithNewDeviceApiKey instance, - TRes Function(Variables$Mutation$AuthorizeWithNewDeviceApiKey) then) = - _CopyWithImpl$Variables$Mutation$AuthorizeWithNewDeviceApiKey; + Variables$Mutation$AuthorizeWithNewDeviceApiKey instance, + TRes Function(Variables$Mutation$AuthorizeWithNewDeviceApiKey) then, + ) = _CopyWithImpl$Variables$Mutation$AuthorizeWithNewDeviceApiKey; factory CopyWith$Variables$Mutation$AuthorizeWithNewDeviceApiKey.stub( TRes res) = @@ -7061,7 +10863,9 @@ abstract class CopyWith$Variables$Mutation$AuthorizeWithNewDeviceApiKey { class _CopyWithImpl$Variables$Mutation$AuthorizeWithNewDeviceApiKey implements CopyWith$Variables$Mutation$AuthorizeWithNewDeviceApiKey { _CopyWithImpl$Variables$Mutation$AuthorizeWithNewDeviceApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Variables$Mutation$AuthorizeWithNewDeviceApiKey _instance; @@ -7070,10 +10874,11 @@ class _CopyWithImpl$Variables$Mutation$AuthorizeWithNewDeviceApiKey static const _undefined = {}; TRes call({Object? input = _undefined}) => - _then(Variables$Mutation$AuthorizeWithNewDeviceApiKey( - input: input == _undefined || input == null - ? _instance.input - : (input as Input$UseNewDeviceKeyInput))); + _then(Variables$Mutation$AuthorizeWithNewDeviceApiKey._({ + ..._instance._$data, + if (input != _undefined && input != null) + 'input': (input as Input$UseNewDeviceKeyInput), + })); } class _CopyWithStubImpl$Variables$Mutation$AuthorizeWithNewDeviceApiKey @@ -7085,43 +10890,70 @@ class _CopyWithStubImpl$Variables$Mutation$AuthorizeWithNewDeviceApiKey call({Input$UseNewDeviceKeyInput? input}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$AuthorizeWithNewDeviceApiKey { - Mutation$AuthorizeWithNewDeviceApiKey( - {required this.authorizeWithNewDeviceApiKey, required this.$__typename}); + Mutation$AuthorizeWithNewDeviceApiKey({ + required this.authorizeWithNewDeviceApiKey, + required this.$__typename, + }); - @override factory Mutation$AuthorizeWithNewDeviceApiKey.fromJson( - Map json) => - _$Mutation$AuthorizeWithNewDeviceApiKeyFromJson(json); + Map json) { + final l$authorizeWithNewDeviceApiKey = json['authorizeWithNewDeviceApiKey']; + final l$$__typename = json['__typename']; + return Mutation$AuthorizeWithNewDeviceApiKey( + authorizeWithNewDeviceApiKey: + Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey + .fromJson( + (l$authorizeWithNewDeviceApiKey as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey authorizeWithNewDeviceApiKey; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$AuthorizeWithNewDeviceApiKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$authorizeWithNewDeviceApiKey = authorizeWithNewDeviceApiKey; + _resultData['authorizeWithNewDeviceApiKey'] = + l$authorizeWithNewDeviceApiKey.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$authorizeWithNewDeviceApiKey = authorizeWithNewDeviceApiKey; final l$$__typename = $__typename; - return Object.hashAll([l$authorizeWithNewDeviceApiKey, l$$__typename]); + return Object.hashAll([ + l$authorizeWithNewDeviceApiKey, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$AuthorizeWithNewDeviceApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$authorizeWithNewDeviceApiKey = authorizeWithNewDeviceApiKey; final lOther$authorizeWithNewDeviceApiKey = other.authorizeWithNewDeviceApiKey; - if (l$authorizeWithNewDeviceApiKey != lOther$authorizeWithNewDeviceApiKey) + if (l$authorizeWithNewDeviceApiKey != lOther$authorizeWithNewDeviceApiKey) { return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -7130,23 +10962,26 @@ extension UtilityExtension$Mutation$AuthorizeWithNewDeviceApiKey on Mutation$AuthorizeWithNewDeviceApiKey { CopyWith$Mutation$AuthorizeWithNewDeviceApiKey< Mutation$AuthorizeWithNewDeviceApiKey> - get copyWith => - CopyWith$Mutation$AuthorizeWithNewDeviceApiKey(this, (i) => i); + get copyWith => CopyWith$Mutation$AuthorizeWithNewDeviceApiKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$AuthorizeWithNewDeviceApiKey { factory CopyWith$Mutation$AuthorizeWithNewDeviceApiKey( - Mutation$AuthorizeWithNewDeviceApiKey instance, - TRes Function(Mutation$AuthorizeWithNewDeviceApiKey) then) = - _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey; + Mutation$AuthorizeWithNewDeviceApiKey instance, + TRes Function(Mutation$AuthorizeWithNewDeviceApiKey) then, + ) = _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey; factory CopyWith$Mutation$AuthorizeWithNewDeviceApiKey.stub(TRes res) = _CopyWithStubImpl$Mutation$AuthorizeWithNewDeviceApiKey; - TRes call( - {Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey? - authorizeWithNewDeviceApiKey, - String? $__typename}); + TRes call({ + Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey? + authorizeWithNewDeviceApiKey, + String? $__typename, + }); CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey< TRes> get authorizeWithNewDeviceApiKey; } @@ -7154,7 +10989,9 @@ abstract class CopyWith$Mutation$AuthorizeWithNewDeviceApiKey { class _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey implements CopyWith$Mutation$AuthorizeWithNewDeviceApiKey { _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$AuthorizeWithNewDeviceApiKey _instance; @@ -7162,19 +10999,21 @@ class _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey static const _undefined = {}; - TRes call( - {Object? authorizeWithNewDeviceApiKey = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? authorizeWithNewDeviceApiKey = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$AuthorizeWithNewDeviceApiKey( - authorizeWithNewDeviceApiKey: authorizeWithNewDeviceApiKey == - _undefined || - authorizeWithNewDeviceApiKey == null - ? _instance.authorizeWithNewDeviceApiKey - : (authorizeWithNewDeviceApiKey - as Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + authorizeWithNewDeviceApiKey: authorizeWithNewDeviceApiKey == + _undefined || + authorizeWithNewDeviceApiKey == null + ? _instance.authorizeWithNewDeviceApiKey + : (authorizeWithNewDeviceApiKey + as Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey< TRes> get authorizeWithNewDeviceApiKey { final local$authorizeWithNewDeviceApiKey = @@ -7191,10 +11030,11 @@ class _CopyWithStubImpl$Mutation$AuthorizeWithNewDeviceApiKey TRes _res; - call( - {Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey? - authorizeWithNewDeviceApiKey, - String? $__typename}) => + call({ + Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey? + authorizeWithNewDeviceApiKey, + String? $__typename, + }) => _res; CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey< TRes> @@ -7206,51 +11046,61 @@ class _CopyWithStubImpl$Mutation$AuthorizeWithNewDeviceApiKey const documentNodeMutationAuthorizeWithNewDeviceApiKey = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'AuthorizeWithNewDeviceApiKey'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'input')), - type: NamedTypeNode( - name: NameNode(value: 'UseNewDeviceKeyInput'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'authorizeWithNewDeviceApiKey'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'input'), - value: VariableNode(name: NameNode(value: 'input'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'AuthorizeWithNewDeviceApiKey'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'input')), + type: NamedTypeNode( + name: NameNode(value: 'UseNewDeviceKeyInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'authorizeWithNewDeviceApiKey'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'input'), + value: VariableNode(name: NameNode(value: 'input')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: 'token'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( + name: NameNode(value: 'token'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$AuthorizeWithNewDeviceApiKey @@ -7258,42 +11108,46 @@ Mutation$AuthorizeWithNewDeviceApiKey Map data) => Mutation$AuthorizeWithNewDeviceApiKey.fromJson(data); typedef OnMutationCompleted$Mutation$AuthorizeWithNewDeviceApiKey - = FutureOr Function(dynamic, Mutation$AuthorizeWithNewDeviceApiKey?); + = FutureOr Function( + dynamic, + Mutation$AuthorizeWithNewDeviceApiKey?, +); class Options$Mutation$AuthorizeWithNewDeviceApiKey extends graphql.MutationOptions { - Options$Mutation$AuthorizeWithNewDeviceApiKey( - {String? operationName, - required Variables$Mutation$AuthorizeWithNewDeviceApiKey variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$AuthorizeWithNewDeviceApiKey? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$AuthorizeWithNewDeviceApiKey({ + String? operationName, + required Variables$Mutation$AuthorizeWithNewDeviceApiKey variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$AuthorizeWithNewDeviceApiKey? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$AuthorizeWithNewDeviceApiKey( - data)), - update: update, - onError: onError, - document: documentNodeMutationAuthorizeWithNewDeviceApiKey, - parserFn: _parserFn$Mutation$AuthorizeWithNewDeviceApiKey); + : _parserFn$Mutation$AuthorizeWithNewDeviceApiKey(data), + ), + update: update, + onError: onError, + document: documentNodeMutationAuthorizeWithNewDeviceApiKey, + parserFn: _parserFn$Mutation$AuthorizeWithNewDeviceApiKey, + ); final OnMutationCompleted$Mutation$AuthorizeWithNewDeviceApiKey? onCompletedWithParsed; @@ -7303,38 +11157,39 @@ class Options$Mutation$AuthorizeWithNewDeviceApiKey ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$AuthorizeWithNewDeviceApiKey extends graphql.WatchQueryOptions { - WatchOptions$Mutation$AuthorizeWithNewDeviceApiKey( - {String? operationName, - required Variables$Mutation$AuthorizeWithNewDeviceApiKey variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationAuthorizeWithNewDeviceApiKey, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$AuthorizeWithNewDeviceApiKey); + WatchOptions$Mutation$AuthorizeWithNewDeviceApiKey({ + String? operationName, + required Variables$Mutation$AuthorizeWithNewDeviceApiKey variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationAuthorizeWithNewDeviceApiKey, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$AuthorizeWithNewDeviceApiKey, + ); } extension ClientExtension$Mutation$AuthorizeWithNewDeviceApiKey @@ -7349,21 +11204,32 @@ extension ClientExtension$Mutation$AuthorizeWithNewDeviceApiKey this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey - implements Fragment$basicMutationReturnFields { - Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.token}); + implements + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn { + Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.token, + }); - @override factory Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey.fromJson( - Map json) => - _$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKeyFromJson( - json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$token = json['token']; + return Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + token: (l$token as String?), + ); + } final int code; @@ -7371,45 +11237,76 @@ class Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey final bool success; - @JsonKey(name: '__typename') final String $__typename; final String? token; - Map toJson() => - _$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKeyToJson( - this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$token = token; + _resultData['token'] = l$token; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$token = token; - return Object.hashAll( - [l$code, l$message, l$success, l$$__typename, l$token]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$token, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$token = token; final lOther$token = other.token; - if (l$token != lOther$token) return false; + if (l$token != lOther$token) { + return false; + } return true; } } @@ -7420,29 +11317,31 @@ extension UtilityExtension$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNe Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey> get copyWith => CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey< TRes> { factory CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey( - Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey - instance, - TRes Function( - Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey) - then) = - _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey; + Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey instance, + TRes Function( + Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey) + then, + ) = _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey; factory CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey.stub( TRes res) = _CopyWithStubImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? token}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? token, + }); } class _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey< @@ -7451,7 +11350,9 @@ class _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDevice CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey< TRes> { _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey _instance; @@ -7461,26 +11362,27 @@ class _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDevice static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? token = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? token = _undefined, + }) => _then(Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - token: token == _undefined ? _instance.token : (token as String?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + token: token == _undefined ? _instance.token : (token as String?), + )); } class _CopyWithStubImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey< @@ -7493,16 +11395,12 @@ class _CopyWithStubImpl$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDe TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? token}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? token, + }) => _res; } - -DateTime? _nullable$dateTimeFromJson(dynamic data) => - data == null ? null : dateTimeFromJson(data); -dynamic _nullable$dateTimeToJson(DateTime? data) => - data == null ? null : dateTimeToJson(data); diff --git a/lib/logic/api_maps/graphql_maps/schema/server_api.graphql.g.dart b/lib/logic/api_maps/graphql_maps/schema/server_api.graphql.g.dart deleted file mode 100644 index f0ec390c..00000000 --- a/lib/logic/api_maps/graphql_maps/schema/server_api.graphql.g.dart +++ /dev/null @@ -1,797 +0,0 @@ -// GENERATED CODE - DO NOT MODIFY BY HAND - -part of 'server_api.graphql.dart'; - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -Fragment$basicMutationReturnFields _$Fragment$basicMutationReturnFieldsFromJson( - Map json) => - Fragment$basicMutationReturnFields( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Fragment$basicMutationReturnFieldsToJson( - Fragment$basicMutationReturnFields instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Query$GetApiVersion _$Query$GetApiVersionFromJson(Map json) => - Query$GetApiVersion( - api: - Query$GetApiVersion$api.fromJson(json['api'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetApiVersionToJson( - Query$GetApiVersion instance) => - { - 'api': instance.api.toJson(), - '__typename': instance.$__typename, - }; - -Query$GetApiVersion$api _$Query$GetApiVersion$apiFromJson( - Map json) => - Query$GetApiVersion$api( - version: json['version'] as String, - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetApiVersion$apiToJson( - Query$GetApiVersion$api instance) => - { - 'version': instance.version, - '__typename': instance.$__typename, - }; - -Query$GetApiJobs _$Query$GetApiJobsFromJson(Map json) => - Query$GetApiJobs( - jobs: - Query$GetApiJobs$jobs.fromJson(json['jobs'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetApiJobsToJson(Query$GetApiJobs instance) => - { - 'jobs': instance.jobs.toJson(), - '__typename': instance.$__typename, - }; - -Query$GetApiJobs$jobs _$Query$GetApiJobs$jobsFromJson( - Map json) => - Query$GetApiJobs$jobs( - getJobs: (json['getJobs'] as List) - .map((e) => - Query$GetApiJobs$jobs$getJobs.fromJson(e as Map)) - .toList(), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetApiJobs$jobsToJson( - Query$GetApiJobs$jobs instance) => - { - 'getJobs': instance.getJobs.map((e) => e.toJson()).toList(), - '__typename': instance.$__typename, - }; - -Query$GetApiJobs$jobs$getJobs _$Query$GetApiJobs$jobs$getJobsFromJson( - Map json) => - Query$GetApiJobs$jobs$getJobs( - createdAt: dateTimeFromJson(json['createdAt']), - description: json['description'] as String, - error: json['error'] as String?, - finishedAt: _nullable$dateTimeFromJson(json['finishedAt']), - name: json['name'] as String, - progress: json['progress'] as int?, - result: json['result'] as String?, - status: json['status'] as String, - statusText: json['statusText'] as String?, - uid: json['uid'] as String, - updatedAt: dateTimeFromJson(json['updatedAt']), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetApiJobs$jobs$getJobsToJson( - Query$GetApiJobs$jobs$getJobs instance) => - { - 'createdAt': dateTimeToJson(instance.createdAt), - 'description': instance.description, - 'error': instance.error, - 'finishedAt': _nullable$dateTimeToJson(instance.finishedAt), - 'name': instance.name, - 'progress': instance.progress, - 'result': instance.result, - 'status': instance.status, - 'statusText': instance.statusText, - 'uid': instance.uid, - 'updatedAt': dateTimeToJson(instance.updatedAt), - '__typename': instance.$__typename, - }; - -Variables$Mutation$RemoveJob _$Variables$Mutation$RemoveJobFromJson( - Map json) => - Variables$Mutation$RemoveJob( - jobId: json['jobId'] as String, - ); - -Map _$Variables$Mutation$RemoveJobToJson( - Variables$Mutation$RemoveJob instance) => - { - 'jobId': instance.jobId, - }; - -Mutation$RemoveJob _$Mutation$RemoveJobFromJson(Map json) => - Mutation$RemoveJob( - removeJob: Mutation$RemoveJob$removeJob.fromJson( - json['removeJob'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RemoveJobToJson(Mutation$RemoveJob instance) => - { - 'removeJob': instance.removeJob.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$RemoveJob$removeJob _$Mutation$RemoveJob$removeJobFromJson( - Map json) => - Mutation$RemoveJob$removeJob( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RemoveJob$removeJobToJson( - Mutation$RemoveJob$removeJob instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Mutation$RunSystemRebuild _$Mutation$RunSystemRebuildFromJson( - Map json) => - Mutation$RunSystemRebuild( - runSystemRebuild: Mutation$RunSystemRebuild$runSystemRebuild.fromJson( - json['runSystemRebuild'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RunSystemRebuildToJson( - Mutation$RunSystemRebuild instance) => - { - 'runSystemRebuild': instance.runSystemRebuild.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$RunSystemRebuild$runSystemRebuild - _$Mutation$RunSystemRebuild$runSystemRebuildFromJson( - Map json) => - Mutation$RunSystemRebuild$runSystemRebuild( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RunSystemRebuild$runSystemRebuildToJson( - Mutation$RunSystemRebuild$runSystemRebuild instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Mutation$RunSystemRollback _$Mutation$RunSystemRollbackFromJson( - Map json) => - Mutation$RunSystemRollback( - runSystemRollback: Mutation$RunSystemRollback$runSystemRollback.fromJson( - json['runSystemRollback'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RunSystemRollbackToJson( - Mutation$RunSystemRollback instance) => - { - 'runSystemRollback': instance.runSystemRollback.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$RunSystemRollback$runSystemRollback - _$Mutation$RunSystemRollback$runSystemRollbackFromJson( - Map json) => - Mutation$RunSystemRollback$runSystemRollback( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RunSystemRollback$runSystemRollbackToJson( - Mutation$RunSystemRollback$runSystemRollback instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Mutation$RunSystemUpgrade _$Mutation$RunSystemUpgradeFromJson( - Map json) => - Mutation$RunSystemUpgrade( - runSystemUpgrade: Mutation$RunSystemUpgrade$runSystemUpgrade.fromJson( - json['runSystemUpgrade'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RunSystemUpgradeToJson( - Mutation$RunSystemUpgrade instance) => - { - 'runSystemUpgrade': instance.runSystemUpgrade.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$RunSystemUpgrade$runSystemUpgrade - _$Mutation$RunSystemUpgrade$runSystemUpgradeFromJson( - Map json) => - Mutation$RunSystemUpgrade$runSystemUpgrade( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RunSystemUpgrade$runSystemUpgradeToJson( - Mutation$RunSystemUpgrade$runSystemUpgrade instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Mutation$PullRepositoryChanges _$Mutation$PullRepositoryChangesFromJson( - Map json) => - Mutation$PullRepositoryChanges( - pullRepositoryChanges: - Mutation$PullRepositoryChanges$pullRepositoryChanges.fromJson( - json['pullRepositoryChanges'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$PullRepositoryChangesToJson( - Mutation$PullRepositoryChanges instance) => - { - 'pullRepositoryChanges': instance.pullRepositoryChanges.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$PullRepositoryChanges$pullRepositoryChanges - _$Mutation$PullRepositoryChanges$pullRepositoryChangesFromJson( - Map json) => - Mutation$PullRepositoryChanges$pullRepositoryChanges( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map - _$Mutation$PullRepositoryChanges$pullRepositoryChangesToJson( - Mutation$PullRepositoryChanges$pullRepositoryChanges instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Mutation$RebootSystem _$Mutation$RebootSystemFromJson( - Map json) => - Mutation$RebootSystem( - rebootSystem: Mutation$RebootSystem$rebootSystem.fromJson( - json['rebootSystem'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RebootSystemToJson( - Mutation$RebootSystem instance) => - { - 'rebootSystem': instance.rebootSystem.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$RebootSystem$rebootSystem _$Mutation$RebootSystem$rebootSystemFromJson( - Map json) => - Mutation$RebootSystem$rebootSystem( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RebootSystem$rebootSystemToJson( - Mutation$RebootSystem$rebootSystem instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Query$SystemServerProvider _$Query$SystemServerProviderFromJson( - Map json) => - Query$SystemServerProvider( - system: Query$SystemServerProvider$system.fromJson( - json['system'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemServerProviderToJson( - Query$SystemServerProvider instance) => - { - 'system': instance.system.toJson(), - '__typename': instance.$__typename, - }; - -Query$SystemServerProvider$system _$Query$SystemServerProvider$systemFromJson( - Map json) => - Query$SystemServerProvider$system( - provider: Query$SystemServerProvider$system$provider.fromJson( - json['provider'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemServerProvider$systemToJson( - Query$SystemServerProvider$system instance) => - { - 'provider': instance.provider.toJson(), - '__typename': instance.$__typename, - }; - -Query$SystemServerProvider$system$provider - _$Query$SystemServerProvider$system$providerFromJson( - Map json) => - Query$SystemServerProvider$system$provider( - provider: $enumDecode(_$Enum$ServerProviderEnumMap, json['provider'], - unknownValue: Enum$ServerProvider.$unknown), - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemServerProvider$system$providerToJson( - Query$SystemServerProvider$system$provider instance) => - { - 'provider': _$Enum$ServerProviderEnumMap[instance.provider]!, - '__typename': instance.$__typename, - }; - -const _$Enum$ServerProviderEnumMap = { - Enum$ServerProvider.HETZNER: 'HETZNER', - Enum$ServerProvider.DIGITALOCEAN: 'DIGITALOCEAN', - Enum$ServerProvider.$unknown: r'$unknown', -}; - -Query$GetApiTokens _$Query$GetApiTokensFromJson(Map json) => - Query$GetApiTokens( - api: Query$GetApiTokens$api.fromJson(json['api'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetApiTokensToJson(Query$GetApiTokens instance) => - { - 'api': instance.api.toJson(), - '__typename': instance.$__typename, - }; - -Query$GetApiTokens$api _$Query$GetApiTokens$apiFromJson( - Map json) => - Query$GetApiTokens$api( - devices: (json['devices'] as List) - .map((e) => Query$GetApiTokens$api$devices.fromJson( - e as Map)) - .toList(), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetApiTokens$apiToJson( - Query$GetApiTokens$api instance) => - { - 'devices': instance.devices.map((e) => e.toJson()).toList(), - '__typename': instance.$__typename, - }; - -Query$GetApiTokens$api$devices _$Query$GetApiTokens$api$devicesFromJson( - Map json) => - Query$GetApiTokens$api$devices( - creationDate: dateTimeFromJson(json['creationDate']), - isCaller: json['isCaller'] as bool, - name: json['name'] as String, - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetApiTokens$api$devicesToJson( - Query$GetApiTokens$api$devices instance) => - { - 'creationDate': dateTimeToJson(instance.creationDate), - 'isCaller': instance.isCaller, - 'name': instance.name, - '__typename': instance.$__typename, - }; - -Query$RecoveryKey _$Query$RecoveryKeyFromJson(Map json) => - Query$RecoveryKey( - api: Query$RecoveryKey$api.fromJson(json['api'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$RecoveryKeyToJson(Query$RecoveryKey instance) => - { - 'api': instance.api.toJson(), - '__typename': instance.$__typename, - }; - -Query$RecoveryKey$api _$Query$RecoveryKey$apiFromJson( - Map json) => - Query$RecoveryKey$api( - recoveryKey: Query$RecoveryKey$api$recoveryKey.fromJson( - json['recoveryKey'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$RecoveryKey$apiToJson( - Query$RecoveryKey$api instance) => - { - 'recoveryKey': instance.recoveryKey.toJson(), - '__typename': instance.$__typename, - }; - -Query$RecoveryKey$api$recoveryKey _$Query$RecoveryKey$api$recoveryKeyFromJson( - Map json) => - Query$RecoveryKey$api$recoveryKey( - creationDate: _nullable$dateTimeFromJson(json['creationDate']), - exists: json['exists'] as bool, - expirationDate: _nullable$dateTimeFromJson(json['expirationDate']), - usesLeft: json['usesLeft'] as int?, - valid: json['valid'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Query$RecoveryKey$api$recoveryKeyToJson( - Query$RecoveryKey$api$recoveryKey instance) => - { - 'creationDate': _nullable$dateTimeToJson(instance.creationDate), - 'exists': instance.exists, - 'expirationDate': _nullable$dateTimeToJson(instance.expirationDate), - 'usesLeft': instance.usesLeft, - 'valid': instance.valid, - '__typename': instance.$__typename, - }; - -Variables$Mutation$GetNewRecoveryApiKey - _$Variables$Mutation$GetNewRecoveryApiKeyFromJson( - Map json) => - Variables$Mutation$GetNewRecoveryApiKey( - limits: json['limits'] == null - ? null - : Input$RecoveryKeyLimitsInput.fromJson( - json['limits'] as Map), - ); - -Map _$Variables$Mutation$GetNewRecoveryApiKeyToJson( - Variables$Mutation$GetNewRecoveryApiKey instance) => - { - 'limits': instance.limits?.toJson(), - }; - -Mutation$GetNewRecoveryApiKey _$Mutation$GetNewRecoveryApiKeyFromJson( - Map json) => - Mutation$GetNewRecoveryApiKey( - getNewRecoveryApiKey: - Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey.fromJson( - json['getNewRecoveryApiKey'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$GetNewRecoveryApiKeyToJson( - Mutation$GetNewRecoveryApiKey instance) => - { - 'getNewRecoveryApiKey': instance.getNewRecoveryApiKey.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey - _$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKeyFromJson( - Map json) => - Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - key: json['key'] as String?, - ); - -Map _$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKeyToJson( - Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'key': instance.key, - }; - -Variables$Mutation$UseRecoveryApiKey - _$Variables$Mutation$UseRecoveryApiKeyFromJson(Map json) => - Variables$Mutation$UseRecoveryApiKey( - input: Input$UseRecoveryKeyInput.fromJson( - json['input'] as Map), - ); - -Map _$Variables$Mutation$UseRecoveryApiKeyToJson( - Variables$Mutation$UseRecoveryApiKey instance) => - { - 'input': instance.input.toJson(), - }; - -Mutation$UseRecoveryApiKey _$Mutation$UseRecoveryApiKeyFromJson( - Map json) => - Mutation$UseRecoveryApiKey( - useRecoveryApiKey: Mutation$UseRecoveryApiKey$useRecoveryApiKey.fromJson( - json['useRecoveryApiKey'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$UseRecoveryApiKeyToJson( - Mutation$UseRecoveryApiKey instance) => - { - 'useRecoveryApiKey': instance.useRecoveryApiKey.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$UseRecoveryApiKey$useRecoveryApiKey - _$Mutation$UseRecoveryApiKey$useRecoveryApiKeyFromJson( - Map json) => - Mutation$UseRecoveryApiKey$useRecoveryApiKey( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - token: json['token'] as String?, - ); - -Map _$Mutation$UseRecoveryApiKey$useRecoveryApiKeyToJson( - Mutation$UseRecoveryApiKey$useRecoveryApiKey instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'token': instance.token, - }; - -Mutation$RefreshDeviceApiToken _$Mutation$RefreshDeviceApiTokenFromJson( - Map json) => - Mutation$RefreshDeviceApiToken( - refreshDeviceApiToken: - Mutation$RefreshDeviceApiToken$refreshDeviceApiToken.fromJson( - json['refreshDeviceApiToken'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RefreshDeviceApiTokenToJson( - Mutation$RefreshDeviceApiToken instance) => - { - 'refreshDeviceApiToken': instance.refreshDeviceApiToken.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$RefreshDeviceApiToken$refreshDeviceApiToken - _$Mutation$RefreshDeviceApiToken$refreshDeviceApiTokenFromJson( - Map json) => - Mutation$RefreshDeviceApiToken$refreshDeviceApiToken( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - token: json['token'] as String?, - ); - -Map - _$Mutation$RefreshDeviceApiToken$refreshDeviceApiTokenToJson( - Mutation$RefreshDeviceApiToken$refreshDeviceApiToken instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'token': instance.token, - }; - -Variables$Mutation$DeleteDeviceApiToken - _$Variables$Mutation$DeleteDeviceApiTokenFromJson( - Map json) => - Variables$Mutation$DeleteDeviceApiToken( - device: json['device'] as String, - ); - -Map _$Variables$Mutation$DeleteDeviceApiTokenToJson( - Variables$Mutation$DeleteDeviceApiToken instance) => - { - 'device': instance.device, - }; - -Mutation$DeleteDeviceApiToken _$Mutation$DeleteDeviceApiTokenFromJson( - Map json) => - Mutation$DeleteDeviceApiToken( - deleteDeviceApiToken: - Mutation$DeleteDeviceApiToken$deleteDeviceApiToken.fromJson( - json['deleteDeviceApiToken'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$DeleteDeviceApiTokenToJson( - Mutation$DeleteDeviceApiToken instance) => - { - 'deleteDeviceApiToken': instance.deleteDeviceApiToken.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$DeleteDeviceApiToken$deleteDeviceApiToken - _$Mutation$DeleteDeviceApiToken$deleteDeviceApiTokenFromJson( - Map json) => - Mutation$DeleteDeviceApiToken$deleteDeviceApiToken( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$DeleteDeviceApiToken$deleteDeviceApiTokenToJson( - Mutation$DeleteDeviceApiToken$deleteDeviceApiToken instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Mutation$GetNewDeviceApiKey _$Mutation$GetNewDeviceApiKeyFromJson( - Map json) => - Mutation$GetNewDeviceApiKey( - getNewDeviceApiKey: - Mutation$GetNewDeviceApiKey$getNewDeviceApiKey.fromJson( - json['getNewDeviceApiKey'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$GetNewDeviceApiKeyToJson( - Mutation$GetNewDeviceApiKey instance) => - { - 'getNewDeviceApiKey': instance.getNewDeviceApiKey.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$GetNewDeviceApiKey$getNewDeviceApiKey - _$Mutation$GetNewDeviceApiKey$getNewDeviceApiKeyFromJson( - Map json) => - Mutation$GetNewDeviceApiKey$getNewDeviceApiKey( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - key: json['key'] as String?, - ); - -Map _$Mutation$GetNewDeviceApiKey$getNewDeviceApiKeyToJson( - Mutation$GetNewDeviceApiKey$getNewDeviceApiKey instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'key': instance.key, - }; - -Mutation$InvalidateNewDeviceApiKey _$Mutation$InvalidateNewDeviceApiKeyFromJson( - Map json) => - Mutation$InvalidateNewDeviceApiKey( - invalidateNewDeviceApiKey: - Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey.fromJson( - json['invalidateNewDeviceApiKey'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$InvalidateNewDeviceApiKeyToJson( - Mutation$InvalidateNewDeviceApiKey instance) => - { - 'invalidateNewDeviceApiKey': instance.invalidateNewDeviceApiKey.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey - _$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKeyFromJson( - Map json) => - Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map - _$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKeyToJson( - Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey - instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$AuthorizeWithNewDeviceApiKey - _$Variables$Mutation$AuthorizeWithNewDeviceApiKeyFromJson( - Map json) => - Variables$Mutation$AuthorizeWithNewDeviceApiKey( - input: Input$UseNewDeviceKeyInput.fromJson( - json['input'] as Map), - ); - -Map _$Variables$Mutation$AuthorizeWithNewDeviceApiKeyToJson( - Variables$Mutation$AuthorizeWithNewDeviceApiKey instance) => - { - 'input': instance.input.toJson(), - }; - -Mutation$AuthorizeWithNewDeviceApiKey - _$Mutation$AuthorizeWithNewDeviceApiKeyFromJson( - Map json) => - Mutation$AuthorizeWithNewDeviceApiKey( - authorizeWithNewDeviceApiKey: - Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey - .fromJson(json['authorizeWithNewDeviceApiKey'] - as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$AuthorizeWithNewDeviceApiKeyToJson( - Mutation$AuthorizeWithNewDeviceApiKey instance) => - { - 'authorizeWithNewDeviceApiKey': - instance.authorizeWithNewDeviceApiKey.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey - _$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKeyFromJson( - Map json) => - Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - token: json['token'] as String?, - ); - -Map - _$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKeyToJson( - Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey - instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'token': instance.token, - }; diff --git a/lib/logic/api_maps/graphql_maps/schema/server_settings.graphql.dart b/lib/logic/api_maps/graphql_maps/schema/server_settings.graphql.dart index a077cf7d..14996423 100644 --- a/lib/logic/api_maps/graphql_maps/schema/server_settings.graphql.dart +++ b/lib/logic/api_maps/graphql_maps/schema/server_settings.graphql.dart @@ -1,23 +1,69 @@ import 'dart:async'; +import 'disk_volumes.graphql.dart'; import 'package:gql/ast.dart'; import 'package:graphql/client.dart' as graphql; -import 'package:json_annotation/json_annotation.dart'; import 'schema.graphql.dart'; -import 'server_api.graphql.dart'; -part 'server_settings.graphql.g.dart'; -@JsonSerializable(explicitToJson: true) class Fragment$basicMutationReturnFields { - Fragment$basicMutationReturnFields( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + Fragment$basicMutationReturnFields({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Fragment$basicMutationReturnFields.fromJson( - Map json) => - _$Fragment$basicMutationReturnFieldsFromJson(json); + Map json) { + switch (json["__typename"] as String) { + case "ApiKeyMutationReturn": + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + .fromJson(json); + + case "AutoUpgradeSettingsMutationReturn": + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + .fromJson(json); + + case "DeviceApiTokenMutationReturn": + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + .fromJson(json); + + case "GenericJobButationReturn": + return Fragment$basicMutationReturnFields$$GenericJobButationReturn + .fromJson(json); + + case "GenericMutationReturn": + return Fragment$basicMutationReturnFields$$GenericMutationReturn + .fromJson(json); + + case "ServiceJobMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + .fromJson(json); + + case "ServiceMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceMutationReturn + .fromJson(json); + + case "TimezoneMutationReturn": + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn + .fromJson(json); + + case "UserMutationReturn": + return Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + json); + + default: + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + } final int code; @@ -25,36 +71,64 @@ class Fragment$basicMutationReturnFields { final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Fragment$basicMutationReturnFieldsToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Fragment$basicMutationReturnFields) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -63,25 +137,35 @@ extension UtilityExtension$Fragment$basicMutationReturnFields on Fragment$basicMutationReturnFields { CopyWith$Fragment$basicMutationReturnFields< Fragment$basicMutationReturnFields> - get copyWith => - CopyWith$Fragment$basicMutationReturnFields(this, (i) => i); + get copyWith => CopyWith$Fragment$basicMutationReturnFields( + this, + (i) => i, + ); } abstract class CopyWith$Fragment$basicMutationReturnFields { factory CopyWith$Fragment$basicMutationReturnFields( - Fragment$basicMutationReturnFields instance, - TRes Function(Fragment$basicMutationReturnFields) then) = - _CopyWithImpl$Fragment$basicMutationReturnFields; + Fragment$basicMutationReturnFields instance, + TRes Function(Fragment$basicMutationReturnFields) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields; factory CopyWith$Fragment$basicMutationReturnFields.stub(TRes res) = _CopyWithStubImpl$Fragment$basicMutationReturnFields; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Fragment$basicMutationReturnFields implements CopyWith$Fragment$basicMutationReturnFields { - _CopyWithImpl$Fragment$basicMutationReturnFields(this._instance, this._then); + _CopyWithImpl$Fragment$basicMutationReturnFields( + this._instance, + this._then, + ); final Fragment$basicMutationReturnFields _instance; @@ -89,24 +173,25 @@ class _CopyWithImpl$Fragment$basicMutationReturnFields static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Fragment$basicMutationReturnFields( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Fragment$basicMutationReturnFields @@ -115,43 +200,54 @@ class _CopyWithStubImpl$Fragment$basicMutationReturnFields TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } const fragmentDefinitionbasicMutationReturnFields = FragmentDefinitionNode( - name: NameNode(value: 'basicMutationReturnFields'), - typeCondition: TypeConditionNode( - on: NamedTypeNode( - name: NameNode(value: 'MutationReturnInterface'), - isNonNull: false)), - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'code'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'message'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'success'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])); + name: NameNode(value: 'basicMutationReturnFields'), + typeCondition: TypeConditionNode( + on: NamedTypeNode( + name: NameNode(value: 'MutationReturnInterface'), + isNonNull: false, + )), + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'code'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'message'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'success'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), +); const documentNodeFragmentbasicMutationReturnFields = DocumentNode(definitions: [ fragmentDefinitionbasicMutationReturnFields, @@ -159,88 +255,1752 @@ const documentNodeFragmentbasicMutationReturnFields = extension ClientExtension$Fragment$basicMutationReturnFields on graphql.GraphQLClient { - void writeFragment$basicMutationReturnFields( - {required Fragment$basicMutationReturnFields data, - required Map idFields, - bool broadcast = true}) => + void writeFragment$basicMutationReturnFields({ + required Fragment$basicMutationReturnFields data, + required Map idFields, + bool broadcast = true, + }) => this.writeFragment( - graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - data: data.toJson(), - broadcast: broadcast); - Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields( - {required Map idFields, bool optimistic = true}) { - final result = this.readFragment( graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - optimistic: optimistic); + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + data: data.toJson(), + broadcast: broadcast, + ); + Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields({ + required Map idFields, + bool optimistic = true, + }) { + final result = this.readFragment( + graphql.FragmentRequest( + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + optimistic: optimistic, + ); return result == null ? null : Fragment$basicMutationReturnFields.fromJson(result); } } -@JsonSerializable(explicitToJson: true) -class Query$SystemSettings { - Query$SystemSettings({required this.system, required this.$__typename}); +class Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override - factory Query$SystemSettings.fromJson(Map json) => - _$Query$SystemSettingsFromJson(json); + factory Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } - final Query$SystemSettings$system system; + final int code; + + final String message; + + final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$SystemSettingsToJson(this); - int get hashCode { - final l$system = system; + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; final l$$__typename = $__typename; - return Object.hashAll([l$system, l$$__typename]); + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$SystemSettings) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) || + runtimeType != other.runtimeType) { return false; - final l$system = system; - final lOther$system = other.system; - if (l$system != lOther$system) return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + on Fragment$basicMutationReturnFields$$ApiKeyMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ApiKeyMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + on Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + instance, + TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + on Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn instance, + TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericJobButationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericJobButationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericJobButationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$GenericJobButationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericJobButationReturn + on Fragment$basicMutationReturnFields$$GenericJobButationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + Fragment$basicMutationReturnFields$$GenericJobButationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + Fragment$basicMutationReturnFields$$GenericJobButationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericJobButationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericJobButationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$GenericJobButationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$GenericMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericMutationReturn + on Fragment$basicMutationReturnFields$$GenericMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + Fragment$basicMutationReturnFields$$GenericMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + Fragment$basicMutationReturnFields$$GenericMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + on Fragment$basicMutationReturnFields$$ServiceJobMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceJobMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ServiceMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceMutationReturn + on Fragment$basicMutationReturnFields$$ServiceMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + Fragment$basicMutationReturnFields$$ServiceMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + Fragment$basicMutationReturnFields$$ServiceMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$TimezoneMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$TimezoneMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$TimezoneMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$TimezoneMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$TimezoneMutationReturn + on Fragment$basicMutationReturnFields$$TimezoneMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + Fragment$basicMutationReturnFields$$TimezoneMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$TimezoneMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$TimezoneMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$UserMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$UserMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$UserMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$UserMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$UserMutationReturn + on Fragment$basicMutationReturnFields$$UserMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + Fragment$basicMutationReturnFields$$UserMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + Fragment$basicMutationReturnFields$$UserMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$UserMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$UserMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Query$SystemSettings { + Query$SystemSettings({ + required this.system, + required this.$__typename, + }); + + factory Query$SystemSettings.fromJson(Map json) { + final l$system = json['system']; + final l$$__typename = json['__typename']; + return Query$SystemSettings( + system: Query$SystemSettings$system.fromJson( + (l$system as Map)), + $__typename: (l$$__typename as String), + ); + } + + final Query$SystemSettings$system system; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$system = system; + _resultData['system'] = l$system.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$system = system; + final l$$__typename = $__typename; + return Object.hashAll([ + l$system, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Query$SystemSettings) || runtimeType != other.runtimeType) { + return false; + } + final l$system = system; + final lOther$system = other.system; + if (l$system != lOther$system) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$SystemSettings on Query$SystemSettings { CopyWith$Query$SystemSettings get copyWith => - CopyWith$Query$SystemSettings(this, (i) => i); + CopyWith$Query$SystemSettings( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemSettings { - factory CopyWith$Query$SystemSettings(Query$SystemSettings instance, - TRes Function(Query$SystemSettings) then) = - _CopyWithImpl$Query$SystemSettings; + factory CopyWith$Query$SystemSettings( + Query$SystemSettings instance, + TRes Function(Query$SystemSettings) then, + ) = _CopyWithImpl$Query$SystemSettings; factory CopyWith$Query$SystemSettings.stub(TRes res) = _CopyWithStubImpl$Query$SystemSettings; - TRes call({Query$SystemSettings$system? system, String? $__typename}); + TRes call({ + Query$SystemSettings$system? system, + String? $__typename, + }); CopyWith$Query$SystemSettings$system get system; } class _CopyWithImpl$Query$SystemSettings implements CopyWith$Query$SystemSettings { - _CopyWithImpl$Query$SystemSettings(this._instance, this._then); + _CopyWithImpl$Query$SystemSettings( + this._instance, + this._then, + ); final Query$SystemSettings _instance; @@ -248,14 +2008,18 @@ class _CopyWithImpl$Query$SystemSettings static const _undefined = {}; - TRes call({Object? system = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? system = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemSettings( - system: system == _undefined || system == null - ? _instance.system - : (system as Query$SystemSettings$system), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + system: system == _undefined || system == null + ? _instance.system + : (system as Query$SystemSettings$system), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$SystemSettings$system get system { final local$system = _instance.system; return CopyWith$Query$SystemSettings$system( @@ -269,107 +2033,126 @@ class _CopyWithStubImpl$Query$SystemSettings TRes _res; - call({Query$SystemSettings$system? system, String? $__typename}) => _res; + call({ + Query$SystemSettings$system? system, + String? $__typename, + }) => + _res; CopyWith$Query$SystemSettings$system get system => CopyWith$Query$SystemSettings$system.stub(_res); } const documentNodeQuerySystemSettings = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'SystemSettings'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'system'), + type: OperationType.query, + name: NameNode(value: 'SystemSettings'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'system'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'settings'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'settings'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'autoUpgrade'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'allowReboot'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'enable'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: 'ssh'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'enable'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'passwordAuthentication'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: 'timezone'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'autoUpgrade'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'allowReboot'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'enable'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'ssh'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'enable'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'passwordAuthentication'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: 'timezone'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), ]); Query$SystemSettings _parserFn$Query$SystemSettings( Map data) => @@ -377,60 +2160,63 @@ Query$SystemSettings _parserFn$Query$SystemSettings( class Options$Query$SystemSettings extends graphql.QueryOptions { - Options$Query$SystemSettings( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQuerySystemSettings, - parserFn: _parserFn$Query$SystemSettings); + Options$Query$SystemSettings({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQuerySystemSettings, + parserFn: _parserFn$Query$SystemSettings, + ); } class WatchOptions$Query$SystemSettings extends graphql.WatchQueryOptions { - WatchOptions$Query$SystemSettings( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQuerySystemSettings, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$SystemSettings); + WatchOptions$Query$SystemSettings({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQuerySystemSettings, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$SystemSettings, + ); } class FetchMoreOptions$Query$SystemSettings extends graphql.FetchMoreOptions { FetchMoreOptions$Query$SystemSettings( {required graphql.UpdateQuery updateQuery}) : super( - updateQuery: updateQuery, - document: documentNodeQuerySystemSettings); + updateQuery: updateQuery, + document: documentNodeQuerySystemSettings, + ); } extension ClientExtension$Query$SystemSettings on graphql.GraphQLClient { @@ -440,56 +2226,86 @@ extension ClientExtension$Query$SystemSettings on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$SystemSettings( [WatchOptions$Query$SystemSettings? options]) => this.watchQuery(options ?? WatchOptions$Query$SystemSettings()); - void writeQuery$SystemSettings( - {required Query$SystemSettings data, bool broadcast = true}) => + void writeQuery$SystemSettings({ + required Query$SystemSettings data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: - graphql.Operation(document: documentNodeQuerySystemSettings)), - data: data.toJson(), - broadcast: broadcast); - Query$SystemSettings? readQuery$SystemSettings({bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation(document: documentNodeQuerySystemSettings)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$SystemSettings? readQuery$SystemSettings({bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: + graphql.Operation(document: documentNodeQuerySystemSettings)), + optimistic: optimistic, + ); return result == null ? null : Query$SystemSettings.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$SystemSettings$system { - Query$SystemSettings$system( - {required this.settings, required this.$__typename}); + Query$SystemSettings$system({ + required this.settings, + required this.$__typename, + }); - @override - factory Query$SystemSettings$system.fromJson(Map json) => - _$Query$SystemSettings$systemFromJson(json); + factory Query$SystemSettings$system.fromJson(Map json) { + final l$settings = json['settings']; + final l$$__typename = json['__typename']; + return Query$SystemSettings$system( + settings: Query$SystemSettings$system$settings.fromJson( + (l$settings as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$SystemSettings$system$settings settings; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$SystemSettings$systemToJson(this); + Map toJson() { + final _resultData = {}; + final l$settings = settings; + _resultData['settings'] = l$settings.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$settings = settings; final l$$__typename = $__typename; - return Object.hashAll([l$settings, l$$__typename]); + return Object.hashAll([ + l$settings, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemSettings$system) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$settings = settings; final lOther$settings = other.settings; - if (l$settings != lOther$settings) return false; + if (l$settings != lOther$settings) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -497,26 +2313,34 @@ class Query$SystemSettings$system { extension UtilityExtension$Query$SystemSettings$system on Query$SystemSettings$system { CopyWith$Query$SystemSettings$system - get copyWith => CopyWith$Query$SystemSettings$system(this, (i) => i); + get copyWith => CopyWith$Query$SystemSettings$system( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemSettings$system { factory CopyWith$Query$SystemSettings$system( - Query$SystemSettings$system instance, - TRes Function(Query$SystemSettings$system) then) = - _CopyWithImpl$Query$SystemSettings$system; + Query$SystemSettings$system instance, + TRes Function(Query$SystemSettings$system) then, + ) = _CopyWithImpl$Query$SystemSettings$system; factory CopyWith$Query$SystemSettings$system.stub(TRes res) = _CopyWithStubImpl$Query$SystemSettings$system; - TRes call( - {Query$SystemSettings$system$settings? settings, String? $__typename}); + TRes call({ + Query$SystemSettings$system$settings? settings, + String? $__typename, + }); CopyWith$Query$SystemSettings$system$settings get settings; } class _CopyWithImpl$Query$SystemSettings$system implements CopyWith$Query$SystemSettings$system { - _CopyWithImpl$Query$SystemSettings$system(this._instance, this._then); + _CopyWithImpl$Query$SystemSettings$system( + this._instance, + this._then, + ); final Query$SystemSettings$system _instance; @@ -524,15 +2348,18 @@ class _CopyWithImpl$Query$SystemSettings$system static const _undefined = {}; - TRes call( - {Object? settings = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? settings = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemSettings$system( - settings: settings == _undefined || settings == null - ? _instance.settings - : (settings as Query$SystemSettings$system$settings), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + settings: settings == _undefined || settings == null + ? _instance.settings + : (settings as Query$SystemSettings$system$settings), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$SystemSettings$system$settings get settings { final local$settings = _instance.settings; return CopyWith$Query$SystemSettings$system$settings( @@ -546,24 +2373,38 @@ class _CopyWithStubImpl$Query$SystemSettings$system TRes _res; - call({Query$SystemSettings$system$settings? settings, String? $__typename}) => + call({ + Query$SystemSettings$system$settings? settings, + String? $__typename, + }) => _res; CopyWith$Query$SystemSettings$system$settings get settings => CopyWith$Query$SystemSettings$system$settings.stub(_res); } -@JsonSerializable(explicitToJson: true) class Query$SystemSettings$system$settings { - Query$SystemSettings$system$settings( - {required this.autoUpgrade, - required this.ssh, - required this.timezone, - required this.$__typename}); + Query$SystemSettings$system$settings({ + required this.autoUpgrade, + required this.ssh, + required this.timezone, + required this.$__typename, + }); - @override factory Query$SystemSettings$system$settings.fromJson( - Map json) => - _$Query$SystemSettings$system$settingsFromJson(json); + Map json) { + final l$autoUpgrade = json['autoUpgrade']; + final l$ssh = json['ssh']; + final l$timezone = json['timezone']; + final l$$__typename = json['__typename']; + return Query$SystemSettings$system$settings( + autoUpgrade: Query$SystemSettings$system$settings$autoUpgrade.fromJson( + (l$autoUpgrade as Map)), + ssh: Query$SystemSettings$system$settings$ssh.fromJson( + (l$ssh as Map)), + timezone: (l$timezone as String), + $__typename: (l$$__typename as String), + ); + } final Query$SystemSettings$system$settings$autoUpgrade autoUpgrade; @@ -571,36 +2412,64 @@ class Query$SystemSettings$system$settings { final String timezone; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$SystemSettings$system$settingsToJson(this); + Map toJson() { + final _resultData = {}; + final l$autoUpgrade = autoUpgrade; + _resultData['autoUpgrade'] = l$autoUpgrade.toJson(); + final l$ssh = ssh; + _resultData['ssh'] = l$ssh.toJson(); + final l$timezone = timezone; + _resultData['timezone'] = l$timezone; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$autoUpgrade = autoUpgrade; final l$ssh = ssh; final l$timezone = timezone; final l$$__typename = $__typename; - return Object.hashAll([l$autoUpgrade, l$ssh, l$timezone, l$$__typename]); + return Object.hashAll([ + l$autoUpgrade, + l$ssh, + l$timezone, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemSettings$system$settings) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$autoUpgrade = autoUpgrade; final lOther$autoUpgrade = other.autoUpgrade; - if (l$autoUpgrade != lOther$autoUpgrade) return false; + if (l$autoUpgrade != lOther$autoUpgrade) { + return false; + } final l$ssh = ssh; final lOther$ssh = other.ssh; - if (l$ssh != lOther$ssh) return false; + if (l$ssh != lOther$ssh) { + return false; + } final l$timezone = timezone; final lOther$timezone = other.timezone; - if (l$timezone != lOther$timezone) return false; + if (l$timezone != lOther$timezone) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -609,24 +2478,27 @@ extension UtilityExtension$Query$SystemSettings$system$settings on Query$SystemSettings$system$settings { CopyWith$Query$SystemSettings$system$settings< Query$SystemSettings$system$settings> - get copyWith => - CopyWith$Query$SystemSettings$system$settings(this, (i) => i); + get copyWith => CopyWith$Query$SystemSettings$system$settings( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemSettings$system$settings { factory CopyWith$Query$SystemSettings$system$settings( - Query$SystemSettings$system$settings instance, - TRes Function(Query$SystemSettings$system$settings) then) = - _CopyWithImpl$Query$SystemSettings$system$settings; + Query$SystemSettings$system$settings instance, + TRes Function(Query$SystemSettings$system$settings) then, + ) = _CopyWithImpl$Query$SystemSettings$system$settings; factory CopyWith$Query$SystemSettings$system$settings.stub(TRes res) = _CopyWithStubImpl$Query$SystemSettings$system$settings; - TRes call( - {Query$SystemSettings$system$settings$autoUpgrade? autoUpgrade, - Query$SystemSettings$system$settings$ssh? ssh, - String? timezone, - String? $__typename}); + TRes call({ + Query$SystemSettings$system$settings$autoUpgrade? autoUpgrade, + Query$SystemSettings$system$settings$ssh? ssh, + String? timezone, + String? $__typename, + }); CopyWith$Query$SystemSettings$system$settings$autoUpgrade get autoUpgrade; CopyWith$Query$SystemSettings$system$settings$ssh get ssh; @@ -635,7 +2507,9 @@ abstract class CopyWith$Query$SystemSettings$system$settings { class _CopyWithImpl$Query$SystemSettings$system$settings implements CopyWith$Query$SystemSettings$system$settings { _CopyWithImpl$Query$SystemSettings$system$settings( - this._instance, this._then); + this._instance, + this._then, + ); final Query$SystemSettings$system$settings _instance; @@ -643,25 +2517,26 @@ class _CopyWithImpl$Query$SystemSettings$system$settings static const _undefined = {}; - TRes call( - {Object? autoUpgrade = _undefined, - Object? ssh = _undefined, - Object? timezone = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? autoUpgrade = _undefined, + Object? ssh = _undefined, + Object? timezone = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemSettings$system$settings( - autoUpgrade: autoUpgrade == _undefined || autoUpgrade == null - ? _instance.autoUpgrade - : (autoUpgrade - as Query$SystemSettings$system$settings$autoUpgrade), - ssh: ssh == _undefined || ssh == null - ? _instance.ssh - : (ssh as Query$SystemSettings$system$settings$ssh), - timezone: timezone == _undefined || timezone == null - ? _instance.timezone - : (timezone as String), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + autoUpgrade: autoUpgrade == _undefined || autoUpgrade == null + ? _instance.autoUpgrade + : (autoUpgrade as Query$SystemSettings$system$settings$autoUpgrade), + ssh: ssh == _undefined || ssh == null + ? _instance.ssh + : (ssh as Query$SystemSettings$system$settings$ssh), + timezone: timezone == _undefined || timezone == null + ? _instance.timezone + : (timezone as String), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$SystemSettings$system$settings$autoUpgrade get autoUpgrade { final local$autoUpgrade = _instance.autoUpgrade; @@ -682,11 +2557,12 @@ class _CopyWithStubImpl$Query$SystemSettings$system$settings TRes _res; - call( - {Query$SystemSettings$system$settings$autoUpgrade? autoUpgrade, - Query$SystemSettings$system$settings$ssh? ssh, - String? timezone, - String? $__typename}) => + call({ + Query$SystemSettings$system$settings$autoUpgrade? autoUpgrade, + Query$SystemSettings$system$settings$ssh? ssh, + String? timezone, + String? $__typename, + }) => _res; CopyWith$Query$SystemSettings$system$settings$autoUpgrade get autoUpgrade => @@ -695,48 +2571,78 @@ class _CopyWithStubImpl$Query$SystemSettings$system$settings CopyWith$Query$SystemSettings$system$settings$ssh.stub(_res); } -@JsonSerializable(explicitToJson: true) class Query$SystemSettings$system$settings$autoUpgrade { - Query$SystemSettings$system$settings$autoUpgrade( - {required this.allowReboot, - required this.enable, - required this.$__typename}); + Query$SystemSettings$system$settings$autoUpgrade({ + required this.allowReboot, + required this.enable, + required this.$__typename, + }); - @override factory Query$SystemSettings$system$settings$autoUpgrade.fromJson( - Map json) => - _$Query$SystemSettings$system$settings$autoUpgradeFromJson(json); + Map json) { + final l$allowReboot = json['allowReboot']; + final l$enable = json['enable']; + final l$$__typename = json['__typename']; + return Query$SystemSettings$system$settings$autoUpgrade( + allowReboot: (l$allowReboot as bool), + enable: (l$enable as bool), + $__typename: (l$$__typename as String), + ); + } final bool allowReboot; final bool enable; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$SystemSettings$system$settings$autoUpgradeToJson(this); + Map toJson() { + final _resultData = {}; + final l$allowReboot = allowReboot; + _resultData['allowReboot'] = l$allowReboot; + final l$enable = enable; + _resultData['enable'] = l$enable; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$allowReboot = allowReboot; final l$enable = enable; final l$$__typename = $__typename; - return Object.hashAll([l$allowReboot, l$enable, l$$__typename]); + return Object.hashAll([ + l$allowReboot, + l$enable, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemSettings$system$settings$autoUpgrade) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$allowReboot = allowReboot; final lOther$allowReboot = other.allowReboot; - if (l$allowReboot != lOther$allowReboot) return false; + if (l$allowReboot != lOther$allowReboot) { + return false; + } final l$enable = enable; final lOther$enable = other.enable; - if (l$enable != lOther$enable) return false; + if (l$enable != lOther$enable) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -746,27 +2652,34 @@ extension UtilityExtension$Query$SystemSettings$system$settings$autoUpgrade CopyWith$Query$SystemSettings$system$settings$autoUpgrade< Query$SystemSettings$system$settings$autoUpgrade> get copyWith => CopyWith$Query$SystemSettings$system$settings$autoUpgrade( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemSettings$system$settings$autoUpgrade { factory CopyWith$Query$SystemSettings$system$settings$autoUpgrade( - Query$SystemSettings$system$settings$autoUpgrade instance, - TRes Function(Query$SystemSettings$system$settings$autoUpgrade) - then) = - _CopyWithImpl$Query$SystemSettings$system$settings$autoUpgrade; + Query$SystemSettings$system$settings$autoUpgrade instance, + TRes Function(Query$SystemSettings$system$settings$autoUpgrade) then, + ) = _CopyWithImpl$Query$SystemSettings$system$settings$autoUpgrade; factory CopyWith$Query$SystemSettings$system$settings$autoUpgrade.stub( TRes res) = _CopyWithStubImpl$Query$SystemSettings$system$settings$autoUpgrade; - TRes call({bool? allowReboot, bool? enable, String? $__typename}); + TRes call({ + bool? allowReboot, + bool? enable, + String? $__typename, + }); } class _CopyWithImpl$Query$SystemSettings$system$settings$autoUpgrade implements CopyWith$Query$SystemSettings$system$settings$autoUpgrade { _CopyWithImpl$Query$SystemSettings$system$settings$autoUpgrade( - this._instance, this._then); + this._instance, + this._then, + ); final Query$SystemSettings$system$settings$autoUpgrade _instance; @@ -774,20 +2687,22 @@ class _CopyWithImpl$Query$SystemSettings$system$settings$autoUpgrade static const _undefined = {}; - TRes call( - {Object? allowReboot = _undefined, - Object? enable = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? allowReboot = _undefined, + Object? enable = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemSettings$system$settings$autoUpgrade( - allowReboot: allowReboot == _undefined || allowReboot == null - ? _instance.allowReboot - : (allowReboot as bool), - enable: enable == _undefined || enable == null - ? _instance.enable - : (enable as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + allowReboot: allowReboot == _undefined || allowReboot == null + ? _instance.allowReboot + : (allowReboot as bool), + enable: enable == _undefined || enable == null + ? _instance.enable + : (enable as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$SystemSettings$system$settings$autoUpgrade @@ -796,51 +2711,86 @@ class _CopyWithStubImpl$Query$SystemSettings$system$settings$autoUpgrade TRes _res; - call({bool? allowReboot, bool? enable, String? $__typename}) => _res; + call({ + bool? allowReboot, + bool? enable, + String? $__typename, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Query$SystemSettings$system$settings$ssh { - Query$SystemSettings$system$settings$ssh( - {required this.enable, - required this.passwordAuthentication, - required this.$__typename}); + Query$SystemSettings$system$settings$ssh({ + required this.enable, + required this.passwordAuthentication, + required this.$__typename, + }); - @override factory Query$SystemSettings$system$settings$ssh.fromJson( - Map json) => - _$Query$SystemSettings$system$settings$sshFromJson(json); + Map json) { + final l$enable = json['enable']; + final l$passwordAuthentication = json['passwordAuthentication']; + final l$$__typename = json['__typename']; + return Query$SystemSettings$system$settings$ssh( + enable: (l$enable as bool), + passwordAuthentication: (l$passwordAuthentication as bool), + $__typename: (l$$__typename as String), + ); + } final bool enable; final bool passwordAuthentication; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$SystemSettings$system$settings$sshToJson(this); + Map toJson() { + final _resultData = {}; + final l$enable = enable; + _resultData['enable'] = l$enable; + final l$passwordAuthentication = passwordAuthentication; + _resultData['passwordAuthentication'] = l$passwordAuthentication; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$enable = enable; final l$passwordAuthentication = passwordAuthentication; final l$$__typename = $__typename; - return Object.hashAll([l$enable, l$passwordAuthentication, l$$__typename]); + return Object.hashAll([ + l$enable, + l$passwordAuthentication, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemSettings$system$settings$ssh) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$enable = enable; final lOther$enable = other.enable; - if (l$enable != lOther$enable) return false; + if (l$enable != lOther$enable) { + return false; + } final l$passwordAuthentication = passwordAuthentication; final lOther$passwordAuthentication = other.passwordAuthentication; - if (l$passwordAuthentication != lOther$passwordAuthentication) return false; + if (l$passwordAuthentication != lOther$passwordAuthentication) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -849,26 +2799,34 @@ extension UtilityExtension$Query$SystemSettings$system$settings$ssh on Query$SystemSettings$system$settings$ssh { CopyWith$Query$SystemSettings$system$settings$ssh< Query$SystemSettings$system$settings$ssh> - get copyWith => - CopyWith$Query$SystemSettings$system$settings$ssh(this, (i) => i); + get copyWith => CopyWith$Query$SystemSettings$system$settings$ssh( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemSettings$system$settings$ssh { factory CopyWith$Query$SystemSettings$system$settings$ssh( - Query$SystemSettings$system$settings$ssh instance, - TRes Function(Query$SystemSettings$system$settings$ssh) then) = - _CopyWithImpl$Query$SystemSettings$system$settings$ssh; + Query$SystemSettings$system$settings$ssh instance, + TRes Function(Query$SystemSettings$system$settings$ssh) then, + ) = _CopyWithImpl$Query$SystemSettings$system$settings$ssh; factory CopyWith$Query$SystemSettings$system$settings$ssh.stub(TRes res) = _CopyWithStubImpl$Query$SystemSettings$system$settings$ssh; - TRes call({bool? enable, bool? passwordAuthentication, String? $__typename}); + TRes call({ + bool? enable, + bool? passwordAuthentication, + String? $__typename, + }); } class _CopyWithImpl$Query$SystemSettings$system$settings$ssh implements CopyWith$Query$SystemSettings$system$settings$ssh { _CopyWithImpl$Query$SystemSettings$system$settings$ssh( - this._instance, this._then); + this._instance, + this._then, + ); final Query$SystemSettings$system$settings$ssh _instance; @@ -876,21 +2834,23 @@ class _CopyWithImpl$Query$SystemSettings$system$settings$ssh static const _undefined = {}; - TRes call( - {Object? enable = _undefined, - Object? passwordAuthentication = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? enable = _undefined, + Object? passwordAuthentication = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemSettings$system$settings$ssh( - enable: enable == _undefined || enable == null - ? _instance.enable - : (enable as bool), - passwordAuthentication: passwordAuthentication == _undefined || - passwordAuthentication == null - ? _instance.passwordAuthentication - : (passwordAuthentication as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + enable: enable == _undefined || enable == null + ? _instance.enable + : (enable as bool), + passwordAuthentication: passwordAuthentication == _undefined || + passwordAuthentication == null + ? _instance.passwordAuthentication + : (passwordAuthentication as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$SystemSettings$system$settings$ssh @@ -899,41 +2859,72 @@ class _CopyWithStubImpl$Query$SystemSettings$system$settings$ssh TRes _res; - call({bool? enable, bool? passwordAuthentication, String? $__typename}) => + call({ + bool? enable, + bool? passwordAuthentication, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Query$SystemIsUsingBinds { - Query$SystemIsUsingBinds({required this.system, required this.$__typename}); + Query$SystemIsUsingBinds({ + required this.system, + required this.$__typename, + }); - @override - factory Query$SystemIsUsingBinds.fromJson(Map json) => - _$Query$SystemIsUsingBindsFromJson(json); + factory Query$SystemIsUsingBinds.fromJson(Map json) { + final l$system = json['system']; + final l$$__typename = json['__typename']; + return Query$SystemIsUsingBinds( + system: Query$SystemIsUsingBinds$system.fromJson( + (l$system as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$SystemIsUsingBinds$system system; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$SystemIsUsingBindsToJson(this); + Map toJson() { + final _resultData = {}; + final l$system = system; + _resultData['system'] = l$system.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$system = system; final l$$__typename = $__typename; - return Object.hashAll([l$system, l$$__typename]); + return Object.hashAll([ + l$system, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemIsUsingBinds) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$system = system; final lOther$system = other.system; - if (l$system != lOther$system) return false; + if (l$system != lOther$system) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -941,24 +2932,34 @@ class Query$SystemIsUsingBinds { extension UtilityExtension$Query$SystemIsUsingBinds on Query$SystemIsUsingBinds { CopyWith$Query$SystemIsUsingBinds get copyWith => - CopyWith$Query$SystemIsUsingBinds(this, (i) => i); + CopyWith$Query$SystemIsUsingBinds( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemIsUsingBinds { - factory CopyWith$Query$SystemIsUsingBinds(Query$SystemIsUsingBinds instance, - TRes Function(Query$SystemIsUsingBinds) then) = - _CopyWithImpl$Query$SystemIsUsingBinds; + factory CopyWith$Query$SystemIsUsingBinds( + Query$SystemIsUsingBinds instance, + TRes Function(Query$SystemIsUsingBinds) then, + ) = _CopyWithImpl$Query$SystemIsUsingBinds; factory CopyWith$Query$SystemIsUsingBinds.stub(TRes res) = _CopyWithStubImpl$Query$SystemIsUsingBinds; - TRes call({Query$SystemIsUsingBinds$system? system, String? $__typename}); + TRes call({ + Query$SystemIsUsingBinds$system? system, + String? $__typename, + }); CopyWith$Query$SystemIsUsingBinds$system get system; } class _CopyWithImpl$Query$SystemIsUsingBinds implements CopyWith$Query$SystemIsUsingBinds { - _CopyWithImpl$Query$SystemIsUsingBinds(this._instance, this._then); + _CopyWithImpl$Query$SystemIsUsingBinds( + this._instance, + this._then, + ); final Query$SystemIsUsingBinds _instance; @@ -966,14 +2967,18 @@ class _CopyWithImpl$Query$SystemIsUsingBinds static const _undefined = {}; - TRes call({Object? system = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? system = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemIsUsingBinds( - system: system == _undefined || system == null - ? _instance.system - : (system as Query$SystemIsUsingBinds$system), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + system: system == _undefined || system == null + ? _instance.system + : (system as Query$SystemIsUsingBinds$system), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$SystemIsUsingBinds$system get system { final local$system = _instance.system; return CopyWith$Query$SystemIsUsingBinds$system( @@ -987,57 +2992,68 @@ class _CopyWithStubImpl$Query$SystemIsUsingBinds TRes _res; - call({Query$SystemIsUsingBinds$system? system, String? $__typename}) => _res; + call({ + Query$SystemIsUsingBinds$system? system, + String? $__typename, + }) => + _res; CopyWith$Query$SystemIsUsingBinds$system get system => CopyWith$Query$SystemIsUsingBinds$system.stub(_res); } const documentNodeQuerySystemIsUsingBinds = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'SystemIsUsingBinds'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'system'), + type: OperationType.query, + name: NameNode(value: 'SystemIsUsingBinds'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'system'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'info'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'info'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'usingBinds'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'usingBinds'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), ]); Query$SystemIsUsingBinds _parserFn$Query$SystemIsUsingBinds( Map data) => @@ -1045,52 +3061,54 @@ Query$SystemIsUsingBinds _parserFn$Query$SystemIsUsingBinds( class Options$Query$SystemIsUsingBinds extends graphql.QueryOptions { - Options$Query$SystemIsUsingBinds( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQuerySystemIsUsingBinds, - parserFn: _parserFn$Query$SystemIsUsingBinds); + Options$Query$SystemIsUsingBinds({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQuerySystemIsUsingBinds, + parserFn: _parserFn$Query$SystemIsUsingBinds, + ); } class WatchOptions$Query$SystemIsUsingBinds extends graphql.WatchQueryOptions { - WatchOptions$Query$SystemIsUsingBinds( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQuerySystemIsUsingBinds, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$SystemIsUsingBinds); + WatchOptions$Query$SystemIsUsingBinds({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQuerySystemIsUsingBinds, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$SystemIsUsingBinds, + ); } class FetchMoreOptions$Query$SystemIsUsingBinds @@ -1098,8 +3116,9 @@ class FetchMoreOptions$Query$SystemIsUsingBinds FetchMoreOptions$Query$SystemIsUsingBinds( {required graphql.UpdateQuery updateQuery}) : super( - updateQuery: updateQuery, - document: documentNodeQuerySystemIsUsingBinds); + updateQuery: updateQuery, + document: documentNodeQuerySystemIsUsingBinds, + ); } extension ClientExtension$Query$SystemIsUsingBinds on graphql.GraphQLClient { @@ -1111,58 +3130,87 @@ extension ClientExtension$Query$SystemIsUsingBinds on graphql.GraphQLClient { watchQuery$SystemIsUsingBinds( [WatchOptions$Query$SystemIsUsingBinds? options]) => this.watchQuery(options ?? WatchOptions$Query$SystemIsUsingBinds()); - void writeQuery$SystemIsUsingBinds( - {required Query$SystemIsUsingBinds data, bool broadcast = true}) => + void writeQuery$SystemIsUsingBinds({ + required Query$SystemIsUsingBinds data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: graphql.Operation( - document: documentNodeQuerySystemIsUsingBinds)), - data: data.toJson(), - broadcast: broadcast); - Query$SystemIsUsingBinds? readQuery$SystemIsUsingBinds( - {bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation( document: documentNodeQuerySystemIsUsingBinds)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$SystemIsUsingBinds? readQuery$SystemIsUsingBinds( + {bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: + graphql.Operation(document: documentNodeQuerySystemIsUsingBinds)), + optimistic: optimistic, + ); return result == null ? null : Query$SystemIsUsingBinds.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$SystemIsUsingBinds$system { - Query$SystemIsUsingBinds$system( - {required this.info, required this.$__typename}); + Query$SystemIsUsingBinds$system({ + required this.info, + required this.$__typename, + }); - @override - factory Query$SystemIsUsingBinds$system.fromJson(Map json) => - _$Query$SystemIsUsingBinds$systemFromJson(json); + factory Query$SystemIsUsingBinds$system.fromJson(Map json) { + final l$info = json['info']; + final l$$__typename = json['__typename']; + return Query$SystemIsUsingBinds$system( + info: Query$SystemIsUsingBinds$system$info.fromJson( + (l$info as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$SystemIsUsingBinds$system$info info; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$SystemIsUsingBinds$systemToJson(this); + Map toJson() { + final _resultData = {}; + final l$info = info; + _resultData['info'] = l$info.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$info = info; final l$$__typename = $__typename; - return Object.hashAll([l$info, l$$__typename]); + return Object.hashAll([ + l$info, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemIsUsingBinds$system) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$info = info; final lOther$info = other.info; - if (l$info != lOther$info) return false; + if (l$info != lOther$info) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1170,25 +3218,34 @@ class Query$SystemIsUsingBinds$system { extension UtilityExtension$Query$SystemIsUsingBinds$system on Query$SystemIsUsingBinds$system { CopyWith$Query$SystemIsUsingBinds$system - get copyWith => CopyWith$Query$SystemIsUsingBinds$system(this, (i) => i); + get copyWith => CopyWith$Query$SystemIsUsingBinds$system( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemIsUsingBinds$system { factory CopyWith$Query$SystemIsUsingBinds$system( - Query$SystemIsUsingBinds$system instance, - TRes Function(Query$SystemIsUsingBinds$system) then) = - _CopyWithImpl$Query$SystemIsUsingBinds$system; + Query$SystemIsUsingBinds$system instance, + TRes Function(Query$SystemIsUsingBinds$system) then, + ) = _CopyWithImpl$Query$SystemIsUsingBinds$system; factory CopyWith$Query$SystemIsUsingBinds$system.stub(TRes res) = _CopyWithStubImpl$Query$SystemIsUsingBinds$system; - TRes call({Query$SystemIsUsingBinds$system$info? info, String? $__typename}); + TRes call({ + Query$SystemIsUsingBinds$system$info? info, + String? $__typename, + }); CopyWith$Query$SystemIsUsingBinds$system$info get info; } class _CopyWithImpl$Query$SystemIsUsingBinds$system implements CopyWith$Query$SystemIsUsingBinds$system { - _CopyWithImpl$Query$SystemIsUsingBinds$system(this._instance, this._then); + _CopyWithImpl$Query$SystemIsUsingBinds$system( + this._instance, + this._then, + ); final Query$SystemIsUsingBinds$system _instance; @@ -1196,14 +3253,18 @@ class _CopyWithImpl$Query$SystemIsUsingBinds$system static const _undefined = {}; - TRes call({Object? info = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? info = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemIsUsingBinds$system( - info: info == _undefined || info == null - ? _instance.info - : (info as Query$SystemIsUsingBinds$system$info), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + info: info == _undefined || info == null + ? _instance.info + : (info as Query$SystemIsUsingBinds$system$info), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$SystemIsUsingBinds$system$info get info { final local$info = _instance.info; return CopyWith$Query$SystemIsUsingBinds$system$info( @@ -1217,46 +3278,73 @@ class _CopyWithStubImpl$Query$SystemIsUsingBinds$system TRes _res; - call({Query$SystemIsUsingBinds$system$info? info, String? $__typename}) => + call({ + Query$SystemIsUsingBinds$system$info? info, + String? $__typename, + }) => _res; CopyWith$Query$SystemIsUsingBinds$system$info get info => CopyWith$Query$SystemIsUsingBinds$system$info.stub(_res); } -@JsonSerializable(explicitToJson: true) class Query$SystemIsUsingBinds$system$info { - Query$SystemIsUsingBinds$system$info( - {required this.usingBinds, required this.$__typename}); + Query$SystemIsUsingBinds$system$info({ + required this.usingBinds, + required this.$__typename, + }); - @override factory Query$SystemIsUsingBinds$system$info.fromJson( - Map json) => - _$Query$SystemIsUsingBinds$system$infoFromJson(json); + Map json) { + final l$usingBinds = json['usingBinds']; + final l$$__typename = json['__typename']; + return Query$SystemIsUsingBinds$system$info( + usingBinds: (l$usingBinds as bool), + $__typename: (l$$__typename as String), + ); + } final bool usingBinds; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$SystemIsUsingBinds$system$infoToJson(this); + Map toJson() { + final _resultData = {}; + final l$usingBinds = usingBinds; + _resultData['usingBinds'] = l$usingBinds; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$usingBinds = usingBinds; final l$$__typename = $__typename; - return Object.hashAll([l$usingBinds, l$$__typename]); + return Object.hashAll([ + l$usingBinds, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$SystemIsUsingBinds$system$info) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$usingBinds = usingBinds; final lOther$usingBinds = other.usingBinds; - if (l$usingBinds != lOther$usingBinds) return false; + if (l$usingBinds != lOther$usingBinds) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1265,26 +3353,33 @@ extension UtilityExtension$Query$SystemIsUsingBinds$system$info on Query$SystemIsUsingBinds$system$info { CopyWith$Query$SystemIsUsingBinds$system$info< Query$SystemIsUsingBinds$system$info> - get copyWith => - CopyWith$Query$SystemIsUsingBinds$system$info(this, (i) => i); + get copyWith => CopyWith$Query$SystemIsUsingBinds$system$info( + this, + (i) => i, + ); } abstract class CopyWith$Query$SystemIsUsingBinds$system$info { factory CopyWith$Query$SystemIsUsingBinds$system$info( - Query$SystemIsUsingBinds$system$info instance, - TRes Function(Query$SystemIsUsingBinds$system$info) then) = - _CopyWithImpl$Query$SystemIsUsingBinds$system$info; + Query$SystemIsUsingBinds$system$info instance, + TRes Function(Query$SystemIsUsingBinds$system$info) then, + ) = _CopyWithImpl$Query$SystemIsUsingBinds$system$info; factory CopyWith$Query$SystemIsUsingBinds$system$info.stub(TRes res) = _CopyWithStubImpl$Query$SystemIsUsingBinds$system$info; - TRes call({bool? usingBinds, String? $__typename}); + TRes call({ + bool? usingBinds, + String? $__typename, + }); } class _CopyWithImpl$Query$SystemIsUsingBinds$system$info implements CopyWith$Query$SystemIsUsingBinds$system$info { _CopyWithImpl$Query$SystemIsUsingBinds$system$info( - this._instance, this._then); + this._instance, + this._then, + ); final Query$SystemIsUsingBinds$system$info _instance; @@ -1292,16 +3387,18 @@ class _CopyWithImpl$Query$SystemIsUsingBinds$system$info static const _undefined = {}; - TRes call( - {Object? usingBinds = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? usingBinds = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$SystemIsUsingBinds$system$info( - usingBinds: usingBinds == _undefined || usingBinds == null - ? _instance.usingBinds - : (usingBinds as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + usingBinds: usingBinds == _undefined || usingBinds == null + ? _instance.usingBinds + : (usingBinds as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$SystemIsUsingBinds$system$info @@ -1310,64 +3407,104 @@ class _CopyWithStubImpl$Query$SystemIsUsingBinds$system$info TRes _res; - call({bool? usingBinds, String? $__typename}) => _res; + call({ + bool? usingBinds, + String? $__typename, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Query$DomainInfo { - Query$DomainInfo({required this.system, required this.$__typename}); + Query$DomainInfo({ + required this.system, + required this.$__typename, + }); - @override - factory Query$DomainInfo.fromJson(Map json) => - _$Query$DomainInfoFromJson(json); + factory Query$DomainInfo.fromJson(Map json) { + final l$system = json['system']; + final l$$__typename = json['__typename']; + return Query$DomainInfo( + system: + Query$DomainInfo$system.fromJson((l$system as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$DomainInfo$system system; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$DomainInfoToJson(this); + Map toJson() { + final _resultData = {}; + final l$system = system; + _resultData['system'] = l$system.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$system = system; final l$$__typename = $__typename; - return Object.hashAll([l$system, l$$__typename]); + return Object.hashAll([ + l$system, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$DomainInfo) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$DomainInfo) || runtimeType != other.runtimeType) { return false; + } final l$system = system; final lOther$system = other.system; - if (l$system != lOther$system) return false; + if (l$system != lOther$system) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$DomainInfo on Query$DomainInfo { CopyWith$Query$DomainInfo get copyWith => - CopyWith$Query$DomainInfo(this, (i) => i); + CopyWith$Query$DomainInfo( + this, + (i) => i, + ); } abstract class CopyWith$Query$DomainInfo { factory CopyWith$Query$DomainInfo( - Query$DomainInfo instance, TRes Function(Query$DomainInfo) then) = - _CopyWithImpl$Query$DomainInfo; + Query$DomainInfo instance, + TRes Function(Query$DomainInfo) then, + ) = _CopyWithImpl$Query$DomainInfo; factory CopyWith$Query$DomainInfo.stub(TRes res) = _CopyWithStubImpl$Query$DomainInfo; - TRes call({Query$DomainInfo$system? system, String? $__typename}); + TRes call({ + Query$DomainInfo$system? system, + String? $__typename, + }); CopyWith$Query$DomainInfo$system get system; } class _CopyWithImpl$Query$DomainInfo implements CopyWith$Query$DomainInfo { - _CopyWithImpl$Query$DomainInfo(this._instance, this._then); + _CopyWithImpl$Query$DomainInfo( + this._instance, + this._then, + ); final Query$DomainInfo _instance; @@ -1375,14 +3512,18 @@ class _CopyWithImpl$Query$DomainInfo static const _undefined = {}; - TRes call({Object? system = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? system = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$DomainInfo( - system: system == _undefined || system == null - ? _instance.system - : (system as Query$DomainInfo$system), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + system: system == _undefined || system == null + ? _instance.system + : (system as Query$DomainInfo$system), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$DomainInfo$system get system { final local$system = _instance.system; return CopyWith$Query$DomainInfo$system( @@ -1396,142 +3537,163 @@ class _CopyWithStubImpl$Query$DomainInfo TRes _res; - call({Query$DomainInfo$system? system, String? $__typename}) => _res; + call({ + Query$DomainInfo$system? system, + String? $__typename, + }) => + _res; CopyWith$Query$DomainInfo$system get system => CopyWith$Query$DomainInfo$system.stub(_res); } const documentNodeQueryDomainInfo = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'DomainInfo'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'system'), + type: OperationType.query, + name: NameNode(value: 'DomainInfo'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'system'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'domainInfo'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'domainInfo'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'domain'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'hostname'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'provider'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'requiredDnsRecords'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'dnsRecordFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'domain'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'hostname'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'provider'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'requiredDnsRecords'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'dnsRecordFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitiondnsRecordFields, ]); Query$DomainInfo _parserFn$Query$DomainInfo(Map data) => Query$DomainInfo.fromJson(data); class Options$Query$DomainInfo extends graphql.QueryOptions { - Options$Query$DomainInfo( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryDomainInfo, - parserFn: _parserFn$Query$DomainInfo); + Options$Query$DomainInfo({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryDomainInfo, + parserFn: _parserFn$Query$DomainInfo, + ); } class WatchOptions$Query$DomainInfo extends graphql.WatchQueryOptions { - WatchOptions$Query$DomainInfo( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryDomainInfo, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$DomainInfo); + WatchOptions$Query$DomainInfo({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryDomainInfo, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$DomainInfo, + ); } class FetchMoreOptions$Query$DomainInfo extends graphql.FetchMoreOptions { FetchMoreOptions$Query$DomainInfo({required graphql.UpdateQuery updateQuery}) - : super(updateQuery: updateQuery, document: documentNodeQueryDomainInfo); + : super( + updateQuery: updateQuery, + document: documentNodeQueryDomainInfo, + ); } extension ClientExtension$Query$DomainInfo on graphql.GraphQLClient { @@ -1541,81 +3703,119 @@ extension ClientExtension$Query$DomainInfo on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$DomainInfo( [WatchOptions$Query$DomainInfo? options]) => this.watchQuery(options ?? WatchOptions$Query$DomainInfo()); - void writeQuery$DomainInfo( - {required Query$DomainInfo data, bool broadcast = true}) => + void writeQuery$DomainInfo({ + required Query$DomainInfo data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: - graphql.Operation(document: documentNodeQueryDomainInfo)), - data: data.toJson(), - broadcast: broadcast); - Query$DomainInfo? readQuery$DomainInfo({bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation(document: documentNodeQueryDomainInfo)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$DomainInfo? readQuery$DomainInfo({bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: graphql.Operation(document: documentNodeQueryDomainInfo)), + optimistic: optimistic, + ); return result == null ? null : Query$DomainInfo.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$DomainInfo$system { - Query$DomainInfo$system( - {required this.domainInfo, required this.$__typename}); + Query$DomainInfo$system({ + required this.domainInfo, + required this.$__typename, + }); - @override - factory Query$DomainInfo$system.fromJson(Map json) => - _$Query$DomainInfo$systemFromJson(json); + factory Query$DomainInfo$system.fromJson(Map json) { + final l$domainInfo = json['domainInfo']; + final l$$__typename = json['__typename']; + return Query$DomainInfo$system( + domainInfo: Query$DomainInfo$system$domainInfo.fromJson( + (l$domainInfo as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$DomainInfo$system$domainInfo domainInfo; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$DomainInfo$systemToJson(this); + Map toJson() { + final _resultData = {}; + final l$domainInfo = domainInfo; + _resultData['domainInfo'] = l$domainInfo.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$domainInfo = domainInfo; final l$$__typename = $__typename; - return Object.hashAll([l$domainInfo, l$$__typename]); + return Object.hashAll([ + l$domainInfo, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$DomainInfo$system) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$DomainInfo$system) || + runtimeType != other.runtimeType) { return false; + } final l$domainInfo = domainInfo; final lOther$domainInfo = other.domainInfo; - if (l$domainInfo != lOther$domainInfo) return false; + if (l$domainInfo != lOther$domainInfo) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$DomainInfo$system on Query$DomainInfo$system { CopyWith$Query$DomainInfo$system get copyWith => - CopyWith$Query$DomainInfo$system(this, (i) => i); + CopyWith$Query$DomainInfo$system( + this, + (i) => i, + ); } abstract class CopyWith$Query$DomainInfo$system { - factory CopyWith$Query$DomainInfo$system(Query$DomainInfo$system instance, - TRes Function(Query$DomainInfo$system) then) = - _CopyWithImpl$Query$DomainInfo$system; + factory CopyWith$Query$DomainInfo$system( + Query$DomainInfo$system instance, + TRes Function(Query$DomainInfo$system) then, + ) = _CopyWithImpl$Query$DomainInfo$system; factory CopyWith$Query$DomainInfo$system.stub(TRes res) = _CopyWithStubImpl$Query$DomainInfo$system; - TRes call( - {Query$DomainInfo$system$domainInfo? domainInfo, String? $__typename}); + TRes call({ + Query$DomainInfo$system$domainInfo? domainInfo, + String? $__typename, + }); CopyWith$Query$DomainInfo$system$domainInfo get domainInfo; } class _CopyWithImpl$Query$DomainInfo$system implements CopyWith$Query$DomainInfo$system { - _CopyWithImpl$Query$DomainInfo$system(this._instance, this._then); + _CopyWithImpl$Query$DomainInfo$system( + this._instance, + this._then, + ); final Query$DomainInfo$system _instance; @@ -1623,16 +3823,18 @@ class _CopyWithImpl$Query$DomainInfo$system static const _undefined = {}; - TRes call( - {Object? domainInfo = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? domainInfo = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$DomainInfo$system( - domainInfo: domainInfo == _undefined || domainInfo == null - ? _instance.domainInfo - : (domainInfo as Query$DomainInfo$system$domainInfo), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + domainInfo: domainInfo == _undefined || domainInfo == null + ? _instance.domainInfo + : (domainInfo as Query$DomainInfo$system$domainInfo), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$DomainInfo$system$domainInfo get domainInfo { final local$domainInfo = _instance.domainInfo; return CopyWith$Query$DomainInfo$system$domainInfo( @@ -1646,40 +3848,70 @@ class _CopyWithStubImpl$Query$DomainInfo$system TRes _res; - call({Query$DomainInfo$system$domainInfo? domainInfo, String? $__typename}) => + call({ + Query$DomainInfo$system$domainInfo? domainInfo, + String? $__typename, + }) => _res; CopyWith$Query$DomainInfo$system$domainInfo get domainInfo => CopyWith$Query$DomainInfo$system$domainInfo.stub(_res); } -@JsonSerializable(explicitToJson: true) class Query$DomainInfo$system$domainInfo { - Query$DomainInfo$system$domainInfo( - {required this.domain, - required this.hostname, - required this.provider, - required this.requiredDnsRecords, - required this.$__typename}); + Query$DomainInfo$system$domainInfo({ + required this.domain, + required this.hostname, + required this.provider, + required this.requiredDnsRecords, + required this.$__typename, + }); - @override factory Query$DomainInfo$system$domainInfo.fromJson( - Map json) => - _$Query$DomainInfo$system$domainInfoFromJson(json); + Map json) { + final l$domain = json['domain']; + final l$hostname = json['hostname']; + final l$provider = json['provider']; + final l$requiredDnsRecords = json['requiredDnsRecords']; + final l$$__typename = json['__typename']; + return Query$DomainInfo$system$domainInfo( + domain: (l$domain as String), + hostname: (l$hostname as String), + provider: fromJson$Enum$DnsProvider((l$provider as String)), + requiredDnsRecords: (l$requiredDnsRecords as List) + .map((e) => + Fragment$dnsRecordFields.fromJson((e as Map))) + .toList(), + $__typename: (l$$__typename as String), + ); + } final String domain; final String hostname; - @JsonKey(unknownEnumValue: Enum$DnsProvider.$unknown) final Enum$DnsProvider provider; final List requiredDnsRecords; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$DomainInfo$system$domainInfoToJson(this); + Map toJson() { + final _resultData = {}; + final l$domain = domain; + _resultData['domain'] = l$domain; + final l$hostname = hostname; + _resultData['hostname'] = l$hostname; + final l$provider = provider; + _resultData['provider'] = toJson$Enum$DnsProvider(l$provider); + final l$requiredDnsRecords = requiredDnsRecords; + _resultData['requiredDnsRecords'] = + l$requiredDnsRecords.map((e) => e.toJson()).toList(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$domain = domain; final l$hostname = hostname; @@ -1691,38 +3923,51 @@ class Query$DomainInfo$system$domainInfo { l$hostname, l$provider, Object.hashAll(l$requiredDnsRecords.map((v) => v)), - l$$__typename + l$$__typename, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$DomainInfo$system$domainInfo) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$domain = domain; final lOther$domain = other.domain; - if (l$domain != lOther$domain) return false; + if (l$domain != lOther$domain) { + return false; + } final l$hostname = hostname; final lOther$hostname = other.hostname; - if (l$hostname != lOther$hostname) return false; + if (l$hostname != lOther$hostname) { + return false; + } final l$provider = provider; final lOther$provider = other.provider; - if (l$provider != lOther$provider) return false; + if (l$provider != lOther$provider) { + return false; + } final l$requiredDnsRecords = requiredDnsRecords; final lOther$requiredDnsRecords = other.requiredDnsRecords; - if (l$requiredDnsRecords.length != lOther$requiredDnsRecords.length) + if (l$requiredDnsRecords.length != lOther$requiredDnsRecords.length) { return false; + } for (int i = 0; i < l$requiredDnsRecords.length; i++) { final l$requiredDnsRecords$entry = l$requiredDnsRecords[i]; final lOther$requiredDnsRecords$entry = lOther$requiredDnsRecords[i]; - if (l$requiredDnsRecords$entry != lOther$requiredDnsRecords$entry) + if (l$requiredDnsRecords$entry != lOther$requiredDnsRecords$entry) { return false; + } } - final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1731,25 +3976,28 @@ extension UtilityExtension$Query$DomainInfo$system$domainInfo on Query$DomainInfo$system$domainInfo { CopyWith$Query$DomainInfo$system$domainInfo< Query$DomainInfo$system$domainInfo> - get copyWith => - CopyWith$Query$DomainInfo$system$domainInfo(this, (i) => i); + get copyWith => CopyWith$Query$DomainInfo$system$domainInfo( + this, + (i) => i, + ); } abstract class CopyWith$Query$DomainInfo$system$domainInfo { factory CopyWith$Query$DomainInfo$system$domainInfo( - Query$DomainInfo$system$domainInfo instance, - TRes Function(Query$DomainInfo$system$domainInfo) then) = - _CopyWithImpl$Query$DomainInfo$system$domainInfo; + Query$DomainInfo$system$domainInfo instance, + TRes Function(Query$DomainInfo$system$domainInfo) then, + ) = _CopyWithImpl$Query$DomainInfo$system$domainInfo; factory CopyWith$Query$DomainInfo$system$domainInfo.stub(TRes res) = _CopyWithStubImpl$Query$DomainInfo$system$domainInfo; - TRes call( - {String? domain, - String? hostname, - Enum$DnsProvider? provider, - List? requiredDnsRecords, - String? $__typename}); + TRes call({ + String? domain, + String? hostname, + Enum$DnsProvider? provider, + List? requiredDnsRecords, + String? $__typename, + }); TRes requiredDnsRecords( Iterable Function( Iterable< @@ -1759,7 +4007,10 @@ abstract class CopyWith$Query$DomainInfo$system$domainInfo { class _CopyWithImpl$Query$DomainInfo$system$domainInfo implements CopyWith$Query$DomainInfo$system$domainInfo { - _CopyWithImpl$Query$DomainInfo$system$domainInfo(this._instance, this._then); + _CopyWithImpl$Query$DomainInfo$system$domainInfo( + this._instance, + this._then, + ); final Query$DomainInfo$system$domainInfo _instance; @@ -1767,29 +4018,31 @@ class _CopyWithImpl$Query$DomainInfo$system$domainInfo static const _undefined = {}; - TRes call( - {Object? domain = _undefined, - Object? hostname = _undefined, - Object? provider = _undefined, - Object? requiredDnsRecords = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? domain = _undefined, + Object? hostname = _undefined, + Object? provider = _undefined, + Object? requiredDnsRecords = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$DomainInfo$system$domainInfo( - domain: domain == _undefined || domain == null - ? _instance.domain - : (domain as String), - hostname: hostname == _undefined || hostname == null - ? _instance.hostname - : (hostname as String), - provider: provider == _undefined || provider == null - ? _instance.provider - : (provider as Enum$DnsProvider), - requiredDnsRecords: - requiredDnsRecords == _undefined || requiredDnsRecords == null - ? _instance.requiredDnsRecords - : (requiredDnsRecords as List), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + domain: domain == _undefined || domain == null + ? _instance.domain + : (domain as String), + hostname: hostname == _undefined || hostname == null + ? _instance.hostname + : (hostname as String), + provider: provider == _undefined || provider == null + ? _instance.provider + : (provider as Enum$DnsProvider), + requiredDnsRecords: + requiredDnsRecords == _undefined || requiredDnsRecords == null + ? _instance.requiredDnsRecords + : (requiredDnsRecords as List), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); TRes requiredDnsRecords( Iterable Function( Iterable< @@ -1798,8 +4051,10 @@ class _CopyWithImpl$Query$DomainInfo$system$domainInfo _fn) => call( requiredDnsRecords: _fn(_instance.requiredDnsRecords - .map((e) => CopyWith$Fragment$dnsRecordFields(e, (i) => i))) - .toList()); + .map((e) => CopyWith$Fragment$dnsRecordFields( + e, + (i) => i, + ))).toList()); } class _CopyWithStubImpl$Query$DomainInfo$system$domainInfo @@ -1808,55 +4063,77 @@ class _CopyWithStubImpl$Query$DomainInfo$system$domainInfo TRes _res; - call( - {String? domain, - String? hostname, - Enum$DnsProvider? provider, - List? requiredDnsRecords, - String? $__typename}) => + call({ + String? domain, + String? hostname, + Enum$DnsProvider? provider, + List? requiredDnsRecords, + String? $__typename, + }) => _res; requiredDnsRecords(_fn) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$ChangeTimezone { - Variables$Mutation$ChangeTimezone({required this.timezone}); + factory Variables$Mutation$ChangeTimezone({required String timezone}) => + Variables$Mutation$ChangeTimezone._({ + r'timezone': timezone, + }); + + Variables$Mutation$ChangeTimezone._(this._$data); + + factory Variables$Mutation$ChangeTimezone.fromJson( + Map data) { + final result$data = {}; + final l$timezone = data['timezone']; + result$data['timezone'] = (l$timezone as String); + return Variables$Mutation$ChangeTimezone._(result$data); + } + + Map _$data; + + String get timezone => (_$data['timezone'] as String); + Map toJson() { + final result$data = {}; + final l$timezone = timezone; + result$data['timezone'] = l$timezone; + return result$data; + } + + CopyWith$Variables$Mutation$ChangeTimezone + get copyWith => CopyWith$Variables$Mutation$ChangeTimezone( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$ChangeTimezone) || + runtimeType != other.runtimeType) { + return false; + } + final l$timezone = timezone; + final lOther$timezone = other.timezone; + if (l$timezone != lOther$timezone) { + return false; + } + return true; + } @override - factory Variables$Mutation$ChangeTimezone.fromJson( - Map json) => - _$Variables$Mutation$ChangeTimezoneFromJson(json); - - final String timezone; - - Map toJson() => - _$Variables$Mutation$ChangeTimezoneToJson(this); int get hashCode { final l$timezone = timezone; return Object.hashAll([l$timezone]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$ChangeTimezone) || - runtimeType != other.runtimeType) return false; - final l$timezone = timezone; - final lOther$timezone = other.timezone; - if (l$timezone != lOther$timezone) return false; - return true; - } - - CopyWith$Variables$Mutation$ChangeTimezone - get copyWith => - CopyWith$Variables$Mutation$ChangeTimezone(this, (i) => i); } abstract class CopyWith$Variables$Mutation$ChangeTimezone { factory CopyWith$Variables$Mutation$ChangeTimezone( - Variables$Mutation$ChangeTimezone instance, - TRes Function(Variables$Mutation$ChangeTimezone) then) = - _CopyWithImpl$Variables$Mutation$ChangeTimezone; + Variables$Mutation$ChangeTimezone instance, + TRes Function(Variables$Mutation$ChangeTimezone) then, + ) = _CopyWithImpl$Variables$Mutation$ChangeTimezone; factory CopyWith$Variables$Mutation$ChangeTimezone.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$ChangeTimezone; @@ -1866,7 +4143,10 @@ abstract class CopyWith$Variables$Mutation$ChangeTimezone { class _CopyWithImpl$Variables$Mutation$ChangeTimezone implements CopyWith$Variables$Mutation$ChangeTimezone { - _CopyWithImpl$Variables$Mutation$ChangeTimezone(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$ChangeTimezone( + this._instance, + this._then, + ); final Variables$Mutation$ChangeTimezone _instance; @@ -1875,10 +4155,11 @@ class _CopyWithImpl$Variables$Mutation$ChangeTimezone static const _undefined = {}; TRes call({Object? timezone = _undefined}) => - _then(Variables$Mutation$ChangeTimezone( - timezone: timezone == _undefined || timezone == null - ? _instance.timezone - : (timezone as String))); + _then(Variables$Mutation$ChangeTimezone._({ + ..._instance._$data, + if (timezone != _undefined && timezone != null) + 'timezone': (timezone as String), + })); } class _CopyWithStubImpl$Variables$Mutation$ChangeTimezone @@ -1890,64 +4171,98 @@ class _CopyWithStubImpl$Variables$Mutation$ChangeTimezone call({String? timezone}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$ChangeTimezone { - Mutation$ChangeTimezone( - {required this.changeTimezone, required this.$__typename}); + Mutation$ChangeTimezone({ + required this.changeTimezone, + required this.$__typename, + }); - @override - factory Mutation$ChangeTimezone.fromJson(Map json) => - _$Mutation$ChangeTimezoneFromJson(json); + factory Mutation$ChangeTimezone.fromJson(Map json) { + final l$changeTimezone = json['changeTimezone']; + final l$$__typename = json['__typename']; + return Mutation$ChangeTimezone( + changeTimezone: Mutation$ChangeTimezone$changeTimezone.fromJson( + (l$changeTimezone as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$ChangeTimezone$changeTimezone changeTimezone; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$ChangeTimezoneToJson(this); + Map toJson() { + final _resultData = {}; + final l$changeTimezone = changeTimezone; + _resultData['changeTimezone'] = l$changeTimezone.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$changeTimezone = changeTimezone; final l$$__typename = $__typename; - return Object.hashAll([l$changeTimezone, l$$__typename]); + return Object.hashAll([ + l$changeTimezone, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$ChangeTimezone) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$ChangeTimezone) || + runtimeType != other.runtimeType) { return false; + } final l$changeTimezone = changeTimezone; final lOther$changeTimezone = other.changeTimezone; - if (l$changeTimezone != lOther$changeTimezone) return false; + if (l$changeTimezone != lOther$changeTimezone) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$ChangeTimezone on Mutation$ChangeTimezone { CopyWith$Mutation$ChangeTimezone get copyWith => - CopyWith$Mutation$ChangeTimezone(this, (i) => i); + CopyWith$Mutation$ChangeTimezone( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$ChangeTimezone { - factory CopyWith$Mutation$ChangeTimezone(Mutation$ChangeTimezone instance, - TRes Function(Mutation$ChangeTimezone) then) = - _CopyWithImpl$Mutation$ChangeTimezone; + factory CopyWith$Mutation$ChangeTimezone( + Mutation$ChangeTimezone instance, + TRes Function(Mutation$ChangeTimezone) then, + ) = _CopyWithImpl$Mutation$ChangeTimezone; factory CopyWith$Mutation$ChangeTimezone.stub(TRes res) = _CopyWithStubImpl$Mutation$ChangeTimezone; - TRes call( - {Mutation$ChangeTimezone$changeTimezone? changeTimezone, - String? $__typename}); + TRes call({ + Mutation$ChangeTimezone$changeTimezone? changeTimezone, + String? $__typename, + }); CopyWith$Mutation$ChangeTimezone$changeTimezone get changeTimezone; } class _CopyWithImpl$Mutation$ChangeTimezone implements CopyWith$Mutation$ChangeTimezone { - _CopyWithImpl$Mutation$ChangeTimezone(this._instance, this._then); + _CopyWithImpl$Mutation$ChangeTimezone( + this._instance, + this._then, + ); final Mutation$ChangeTimezone _instance; @@ -1955,16 +4270,18 @@ class _CopyWithImpl$Mutation$ChangeTimezone static const _undefined = {}; - TRes call( - {Object? changeTimezone = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? changeTimezone = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$ChangeTimezone( - changeTimezone: changeTimezone == _undefined || changeTimezone == null - ? _instance.changeTimezone - : (changeTimezone as Mutation$ChangeTimezone$changeTimezone), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + changeTimezone: changeTimezone == _undefined || changeTimezone == null + ? _instance.changeTimezone + : (changeTimezone as Mutation$ChangeTimezone$changeTimezone), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$ChangeTimezone$changeTimezone get changeTimezone { final local$changeTimezone = _instance.changeTimezone; return CopyWith$Mutation$ChangeTimezone$changeTimezone( @@ -1978,9 +4295,10 @@ class _CopyWithStubImpl$Mutation$ChangeTimezone TRes _res; - call( - {Mutation$ChangeTimezone$changeTimezone? changeTimezone, - String? $__typename}) => + call({ + Mutation$ChangeTimezone$changeTimezone? changeTimezone, + String? $__typename, + }) => _res; CopyWith$Mutation$ChangeTimezone$changeTimezone get changeTimezone => CopyWith$Mutation$ChangeTimezone$changeTimezone.stub(_res); @@ -1988,92 +4306,106 @@ class _CopyWithStubImpl$Mutation$ChangeTimezone const documentNodeMutationChangeTimezone = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'ChangeTimezone'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'timezone')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'changeTimezone'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'timezone'), - value: VariableNode(name: NameNode(value: 'timezone'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'ChangeTimezone'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'timezone')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'changeTimezone'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'timezone'), + value: VariableNode(name: NameNode(value: 'timezone')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: 'timezone'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( + name: NameNode(value: 'timezone'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$ChangeTimezone _parserFn$Mutation$ChangeTimezone( Map data) => Mutation$ChangeTimezone.fromJson(data); typedef OnMutationCompleted$Mutation$ChangeTimezone = FutureOr Function( - dynamic, Mutation$ChangeTimezone?); + dynamic, + Mutation$ChangeTimezone?, +); class Options$Mutation$ChangeTimezone extends graphql.MutationOptions { - Options$Mutation$ChangeTimezone( - {String? operationName, - required Variables$Mutation$ChangeTimezone variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$ChangeTimezone? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$ChangeTimezone({ + String? operationName, + required Variables$Mutation$ChangeTimezone variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$ChangeTimezone? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$ChangeTimezone(data)), - update: update, - onError: onError, - document: documentNodeMutationChangeTimezone, - parserFn: _parserFn$Mutation$ChangeTimezone); + : _parserFn$Mutation$ChangeTimezone(data), + ), + update: update, + onError: onError, + document: documentNodeMutationChangeTimezone, + parserFn: _parserFn$Mutation$ChangeTimezone, + ); final OnMutationCompleted$Mutation$ChangeTimezone? onCompletedWithParsed; @@ -2082,38 +4414,39 @@ class Options$Mutation$ChangeTimezone ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$ChangeTimezone extends graphql.WatchQueryOptions { - WatchOptions$Mutation$ChangeTimezone( - {String? operationName, - required Variables$Mutation$ChangeTimezone variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationChangeTimezone, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$ChangeTimezone); + WatchOptions$Mutation$ChangeTimezone({ + String? operationName, + required Variables$Mutation$ChangeTimezone variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationChangeTimezone, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$ChangeTimezone, + ); } extension ClientExtension$Mutation$ChangeTimezone on graphql.GraphQLClient { @@ -2125,20 +4458,31 @@ extension ClientExtension$Mutation$ChangeTimezone on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$ChangeTimezone$changeTimezone - implements Fragment$basicMutationReturnFields { - Mutation$ChangeTimezone$changeTimezone( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.timezone}); + implements Fragment$basicMutationReturnFields$$TimezoneMutationReturn { + Mutation$ChangeTimezone$changeTimezone({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.timezone, + }); - @override factory Mutation$ChangeTimezone$changeTimezone.fromJson( - Map json) => - _$Mutation$ChangeTimezone$changeTimezoneFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$timezone = json['timezone']; + return Mutation$ChangeTimezone$changeTimezone( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + timezone: (l$timezone as String?), + ); + } final int code; @@ -2146,43 +4490,75 @@ class Mutation$ChangeTimezone$changeTimezone final bool success; - @JsonKey(name: '__typename') final String $__typename; final String? timezone; - Map toJson() => - _$Mutation$ChangeTimezone$changeTimezoneToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$timezone = timezone; + _resultData['timezone'] = l$timezone; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$timezone = timezone; - return Object.hashAll( - [l$code, l$message, l$success, l$$__typename, l$timezone]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$timezone, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$ChangeTimezone$changeTimezone) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$timezone = timezone; final lOther$timezone = other.timezone; - if (l$timezone != lOther$timezone) return false; + if (l$timezone != lOther$timezone) { + return false; + } return true; } } @@ -2191,31 +4567,36 @@ extension UtilityExtension$Mutation$ChangeTimezone$changeTimezone on Mutation$ChangeTimezone$changeTimezone { CopyWith$Mutation$ChangeTimezone$changeTimezone< Mutation$ChangeTimezone$changeTimezone> - get copyWith => - CopyWith$Mutation$ChangeTimezone$changeTimezone(this, (i) => i); + get copyWith => CopyWith$Mutation$ChangeTimezone$changeTimezone( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$ChangeTimezone$changeTimezone { factory CopyWith$Mutation$ChangeTimezone$changeTimezone( - Mutation$ChangeTimezone$changeTimezone instance, - TRes Function(Mutation$ChangeTimezone$changeTimezone) then) = - _CopyWithImpl$Mutation$ChangeTimezone$changeTimezone; + Mutation$ChangeTimezone$changeTimezone instance, + TRes Function(Mutation$ChangeTimezone$changeTimezone) then, + ) = _CopyWithImpl$Mutation$ChangeTimezone$changeTimezone; factory CopyWith$Mutation$ChangeTimezone$changeTimezone.stub(TRes res) = _CopyWithStubImpl$Mutation$ChangeTimezone$changeTimezone; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? timezone}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? timezone, + }); } class _CopyWithImpl$Mutation$ChangeTimezone$changeTimezone implements CopyWith$Mutation$ChangeTimezone$changeTimezone { _CopyWithImpl$Mutation$ChangeTimezone$changeTimezone( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$ChangeTimezone$changeTimezone _instance; @@ -2223,28 +4604,28 @@ class _CopyWithImpl$Mutation$ChangeTimezone$changeTimezone static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? timezone = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? timezone = _undefined, + }) => _then(Mutation$ChangeTimezone$changeTimezone( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - timezone: timezone == _undefined - ? _instance.timezone - : (timezone as String?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + timezone: + timezone == _undefined ? _instance.timezone : (timezone as String?), + )); } class _CopyWithStubImpl$Mutation$ChangeTimezone$changeTimezone @@ -2253,55 +4634,80 @@ class _CopyWithStubImpl$Mutation$ChangeTimezone$changeTimezone TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - String? timezone}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + String? timezone, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$ChangeAutoUpgradeSettings { - Variables$Mutation$ChangeAutoUpgradeSettings({required this.settings}); + factory Variables$Mutation$ChangeAutoUpgradeSettings( + {required Input$AutoUpgradeSettingsInput settings}) => + Variables$Mutation$ChangeAutoUpgradeSettings._({ + r'settings': settings, + }); + + Variables$Mutation$ChangeAutoUpgradeSettings._(this._$data); - @override factory Variables$Mutation$ChangeAutoUpgradeSettings.fromJson( - Map json) => - _$Variables$Mutation$ChangeAutoUpgradeSettingsFromJson(json); - - final Input$AutoUpgradeSettingsInput settings; - - Map toJson() => - _$Variables$Mutation$ChangeAutoUpgradeSettingsToJson(this); - int get hashCode { - final l$settings = settings; - return Object.hashAll([l$settings]); + Map data) { + final result$data = {}; + final l$settings = data['settings']; + result$data['settings'] = Input$AutoUpgradeSettingsInput.fromJson( + (l$settings as Map)); + return Variables$Mutation$ChangeAutoUpgradeSettings._(result$data); } - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$ChangeAutoUpgradeSettings) || - runtimeType != other.runtimeType) return false; + Map _$data; + + Input$AutoUpgradeSettingsInput get settings => + (_$data['settings'] as Input$AutoUpgradeSettingsInput); + Map toJson() { + final result$data = {}; final l$settings = settings; - final lOther$settings = other.settings; - if (l$settings != lOther$settings) return false; - return true; + result$data['settings'] = l$settings.toJson(); + return result$data; } CopyWith$Variables$Mutation$ChangeAutoUpgradeSettings< Variables$Mutation$ChangeAutoUpgradeSettings> - get copyWith => - CopyWith$Variables$Mutation$ChangeAutoUpgradeSettings(this, (i) => i); + get copyWith => CopyWith$Variables$Mutation$ChangeAutoUpgradeSettings( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$ChangeAutoUpgradeSettings) || + runtimeType != other.runtimeType) { + return false; + } + final l$settings = settings; + final lOther$settings = other.settings; + if (l$settings != lOther$settings) { + return false; + } + return true; + } + + @override + int get hashCode { + final l$settings = settings; + return Object.hashAll([l$settings]); + } } abstract class CopyWith$Variables$Mutation$ChangeAutoUpgradeSettings { factory CopyWith$Variables$Mutation$ChangeAutoUpgradeSettings( - Variables$Mutation$ChangeAutoUpgradeSettings instance, - TRes Function(Variables$Mutation$ChangeAutoUpgradeSettings) then) = - _CopyWithImpl$Variables$Mutation$ChangeAutoUpgradeSettings; + Variables$Mutation$ChangeAutoUpgradeSettings instance, + TRes Function(Variables$Mutation$ChangeAutoUpgradeSettings) then, + ) = _CopyWithImpl$Variables$Mutation$ChangeAutoUpgradeSettings; factory CopyWith$Variables$Mutation$ChangeAutoUpgradeSettings.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$ChangeAutoUpgradeSettings; @@ -2312,7 +4718,9 @@ abstract class CopyWith$Variables$Mutation$ChangeAutoUpgradeSettings { class _CopyWithImpl$Variables$Mutation$ChangeAutoUpgradeSettings implements CopyWith$Variables$Mutation$ChangeAutoUpgradeSettings { _CopyWithImpl$Variables$Mutation$ChangeAutoUpgradeSettings( - this._instance, this._then); + this._instance, + this._then, + ); final Variables$Mutation$ChangeAutoUpgradeSettings _instance; @@ -2321,10 +4729,11 @@ class _CopyWithImpl$Variables$Mutation$ChangeAutoUpgradeSettings static const _undefined = {}; TRes call({Object? settings = _undefined}) => - _then(Variables$Mutation$ChangeAutoUpgradeSettings( - settings: settings == _undefined || settings == null - ? _instance.settings - : (settings as Input$AutoUpgradeSettingsInput))); + _then(Variables$Mutation$ChangeAutoUpgradeSettings._({ + ..._instance._$data, + if (settings != _undefined && settings != null) + 'settings': (settings as Input$AutoUpgradeSettingsInput), + })); } class _CopyWithStubImpl$Variables$Mutation$ChangeAutoUpgradeSettings @@ -2336,42 +4745,68 @@ class _CopyWithStubImpl$Variables$Mutation$ChangeAutoUpgradeSettings call({Input$AutoUpgradeSettingsInput? settings}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$ChangeAutoUpgradeSettings { - Mutation$ChangeAutoUpgradeSettings( - {required this.changeAutoUpgradeSettings, required this.$__typename}); + Mutation$ChangeAutoUpgradeSettings({ + required this.changeAutoUpgradeSettings, + required this.$__typename, + }); - @override factory Mutation$ChangeAutoUpgradeSettings.fromJson( - Map json) => - _$Mutation$ChangeAutoUpgradeSettingsFromJson(json); + Map json) { + final l$changeAutoUpgradeSettings = json['changeAutoUpgradeSettings']; + final l$$__typename = json['__typename']; + return Mutation$ChangeAutoUpgradeSettings( + changeAutoUpgradeSettings: + Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings.fromJson( + (l$changeAutoUpgradeSettings as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings changeAutoUpgradeSettings; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$ChangeAutoUpgradeSettingsToJson(this); + Map toJson() { + final _resultData = {}; + final l$changeAutoUpgradeSettings = changeAutoUpgradeSettings; + _resultData['changeAutoUpgradeSettings'] = + l$changeAutoUpgradeSettings.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$changeAutoUpgradeSettings = changeAutoUpgradeSettings; final l$$__typename = $__typename; - return Object.hashAll([l$changeAutoUpgradeSettings, l$$__typename]); + return Object.hashAll([ + l$changeAutoUpgradeSettings, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$ChangeAutoUpgradeSettings) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$changeAutoUpgradeSettings = changeAutoUpgradeSettings; final lOther$changeAutoUpgradeSettings = other.changeAutoUpgradeSettings; - if (l$changeAutoUpgradeSettings != lOther$changeAutoUpgradeSettings) + if (l$changeAutoUpgradeSettings != lOther$changeAutoUpgradeSettings) { return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2380,30 +4815,36 @@ extension UtilityExtension$Mutation$ChangeAutoUpgradeSettings on Mutation$ChangeAutoUpgradeSettings { CopyWith$Mutation$ChangeAutoUpgradeSettings< Mutation$ChangeAutoUpgradeSettings> - get copyWith => - CopyWith$Mutation$ChangeAutoUpgradeSettings(this, (i) => i); + get copyWith => CopyWith$Mutation$ChangeAutoUpgradeSettings( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$ChangeAutoUpgradeSettings { factory CopyWith$Mutation$ChangeAutoUpgradeSettings( - Mutation$ChangeAutoUpgradeSettings instance, - TRes Function(Mutation$ChangeAutoUpgradeSettings) then) = - _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings; + Mutation$ChangeAutoUpgradeSettings instance, + TRes Function(Mutation$ChangeAutoUpgradeSettings) then, + ) = _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings; factory CopyWith$Mutation$ChangeAutoUpgradeSettings.stub(TRes res) = _CopyWithStubImpl$Mutation$ChangeAutoUpgradeSettings; - TRes call( - {Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings? - changeAutoUpgradeSettings, - String? $__typename}); + TRes call({ + Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings? + changeAutoUpgradeSettings, + String? $__typename, + }); CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings get changeAutoUpgradeSettings; } class _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings implements CopyWith$Mutation$ChangeAutoUpgradeSettings { - _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings(this._instance, this._then); + _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings( + this._instance, + this._then, + ); final Mutation$ChangeAutoUpgradeSettings _instance; @@ -2411,18 +4852,20 @@ class _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings static const _undefined = {}; - TRes call( - {Object? changeAutoUpgradeSettings = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? changeAutoUpgradeSettings = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$ChangeAutoUpgradeSettings( - changeAutoUpgradeSettings: changeAutoUpgradeSettings == _undefined || - changeAutoUpgradeSettings == null - ? _instance.changeAutoUpgradeSettings - : (changeAutoUpgradeSettings - as Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + changeAutoUpgradeSettings: changeAutoUpgradeSettings == _undefined || + changeAutoUpgradeSettings == null + ? _instance.changeAutoUpgradeSettings + : (changeAutoUpgradeSettings + as Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings get changeAutoUpgradeSettings { final local$changeAutoUpgradeSettings = _instance.changeAutoUpgradeSettings; @@ -2438,10 +4881,11 @@ class _CopyWithStubImpl$Mutation$ChangeAutoUpgradeSettings TRes _res; - call( - {Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings? - changeAutoUpgradeSettings, - String? $__typename}) => + call({ + Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings? + changeAutoUpgradeSettings, + String? $__typename, + }) => _res; CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings get changeAutoUpgradeSettings => @@ -2452,99 +4896,114 @@ class _CopyWithStubImpl$Mutation$ChangeAutoUpgradeSettings const documentNodeMutationChangeAutoUpgradeSettings = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'ChangeAutoUpgradeSettings'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'settings')), - type: NamedTypeNode( - name: NameNode(value: 'AutoUpgradeSettingsInput'), - isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'changeAutoUpgradeSettings'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'settings'), - value: VariableNode(name: NameNode(value: 'settings'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'ChangeAutoUpgradeSettings'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'settings')), + type: NamedTypeNode( + name: NameNode(value: 'AutoUpgradeSettingsInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'changeAutoUpgradeSettings'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'settings'), + value: VariableNode(name: NameNode(value: 'settings')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: 'allowReboot'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'enableAutoUpgrade'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( + name: NameNode(value: 'allowReboot'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'enableAutoUpgrade'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$ChangeAutoUpgradeSettings _parserFn$Mutation$ChangeAutoUpgradeSettings( Map data) => Mutation$ChangeAutoUpgradeSettings.fromJson(data); typedef OnMutationCompleted$Mutation$ChangeAutoUpgradeSettings = FutureOr - Function(dynamic, Mutation$ChangeAutoUpgradeSettings?); + Function( + dynamic, + Mutation$ChangeAutoUpgradeSettings?, +); class Options$Mutation$ChangeAutoUpgradeSettings extends graphql.MutationOptions { - Options$Mutation$ChangeAutoUpgradeSettings( - {String? operationName, - required Variables$Mutation$ChangeAutoUpgradeSettings variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$ChangeAutoUpgradeSettings? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$ChangeAutoUpgradeSettings({ + String? operationName, + required Variables$Mutation$ChangeAutoUpgradeSettings variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$ChangeAutoUpgradeSettings? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$ChangeAutoUpgradeSettings(data)), - update: update, - onError: onError, - document: documentNodeMutationChangeAutoUpgradeSettings, - parserFn: _parserFn$Mutation$ChangeAutoUpgradeSettings); + : _parserFn$Mutation$ChangeAutoUpgradeSettings(data), + ), + update: update, + onError: onError, + document: documentNodeMutationChangeAutoUpgradeSettings, + parserFn: _parserFn$Mutation$ChangeAutoUpgradeSettings, + ); final OnMutationCompleted$Mutation$ChangeAutoUpgradeSettings? onCompletedWithParsed; @@ -2554,38 +5013,39 @@ class Options$Mutation$ChangeAutoUpgradeSettings ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$ChangeAutoUpgradeSettings extends graphql.WatchQueryOptions { - WatchOptions$Mutation$ChangeAutoUpgradeSettings( - {String? operationName, - required Variables$Mutation$ChangeAutoUpgradeSettings variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationChangeAutoUpgradeSettings, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$ChangeAutoUpgradeSettings); + WatchOptions$Mutation$ChangeAutoUpgradeSettings({ + String? operationName, + required Variables$Mutation$ChangeAutoUpgradeSettings variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationChangeAutoUpgradeSettings, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$ChangeAutoUpgradeSettings, + ); } extension ClientExtension$Mutation$ChangeAutoUpgradeSettings @@ -2600,22 +5060,35 @@ extension ClientExtension$Mutation$ChangeAutoUpgradeSettings this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings - implements Fragment$basicMutationReturnFields { - Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - required this.allowReboot, - required this.enableAutoUpgrade}); + implements + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn { + Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + required this.allowReboot, + required this.enableAutoUpgrade, + }); - @override factory Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings.fromJson( - Map json) => - _$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettingsFromJson( - json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$allowReboot = json['allowReboot']; + final l$enableAutoUpgrade = json['enableAutoUpgrade']; + return Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + allowReboot: (l$allowReboot as bool), + enableAutoUpgrade: (l$enableAutoUpgrade as bool), + ); + } final int code; @@ -2623,16 +5096,30 @@ class Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings final bool success; - @JsonKey(name: '__typename') final String $__typename; final bool allowReboot; final bool enableAutoUpgrade; - Map toJson() => - _$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettingsToJson( - this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$allowReboot = allowReboot; + _resultData['allowReboot'] = l$allowReboot; + final l$enableAutoUpgrade = enableAutoUpgrade; + _resultData['enableAutoUpgrade'] = l$enableAutoUpgrade; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; @@ -2646,34 +5133,50 @@ class Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings l$success, l$$__typename, l$allowReboot, - l$enableAutoUpgrade + l$enableAutoUpgrade, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$allowReboot = allowReboot; final lOther$allowReboot = other.allowReboot; - if (l$allowReboot != lOther$allowReboot) return false; + if (l$allowReboot != lOther$allowReboot) { + return false; + } final l$enableAutoUpgrade = enableAutoUpgrade; final lOther$enableAutoUpgrade = other.enableAutoUpgrade; - if (l$enableAutoUpgrade != lOther$enableAutoUpgrade) return false; + if (l$enableAutoUpgrade != lOther$enableAutoUpgrade) { + return false; + } return true; } } @@ -2684,29 +5187,31 @@ extension UtilityExtension$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeS Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings> get copyWith => CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings< TRes> { factory CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings( - Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings instance, - TRes Function( - Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings) - then) = - _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings; + Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings instance, + TRes Function(Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings) + then, + ) = _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings; factory CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings.stub( TRes res) = _CopyWithStubImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - bool? allowReboot, - bool? enableAutoUpgrade}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + bool? allowReboot, + bool? enableAutoUpgrade, + }); } class _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings< @@ -2715,7 +5220,9 @@ class _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings< TRes> { _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings _instance; @@ -2724,33 +5231,34 @@ class _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? allowReboot = _undefined, - Object? enableAutoUpgrade = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? allowReboot = _undefined, + Object? enableAutoUpgrade = _undefined, + }) => _then(Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - allowReboot: allowReboot == _undefined || allowReboot == null - ? _instance.allowReboot - : (allowReboot as bool), - enableAutoUpgrade: - enableAutoUpgrade == _undefined || enableAutoUpgrade == null - ? _instance.enableAutoUpgrade - : (enableAutoUpgrade as bool))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + allowReboot: allowReboot == _undefined || allowReboot == null + ? _instance.allowReboot + : (allowReboot as bool), + enableAutoUpgrade: + enableAutoUpgrade == _undefined || enableAutoUpgrade == null + ? _instance.enableAutoUpgrade + : (enableAutoUpgrade as bool), + )); } class _CopyWithStubImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings< @@ -2763,12 +5271,13 @@ class _CopyWithStubImpl$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSett TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - bool? allowReboot, - bool? enableAutoUpgrade}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + bool? allowReboot, + bool? enableAutoUpgrade, + }) => _res; } diff --git a/lib/logic/api_maps/graphql_maps/schema/server_settings.graphql.g.dart b/lib/logic/api_maps/graphql_maps/schema/server_settings.graphql.g.dart deleted file mode 100644 index c928b177..00000000 --- a/lib/logic/api_maps/graphql_maps/schema/server_settings.graphql.g.dart +++ /dev/null @@ -1,315 +0,0 @@ -// GENERATED CODE - DO NOT MODIFY BY HAND - -part of 'server_settings.graphql.dart'; - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -Fragment$basicMutationReturnFields _$Fragment$basicMutationReturnFieldsFromJson( - Map json) => - Fragment$basicMutationReturnFields( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Fragment$basicMutationReturnFieldsToJson( - Fragment$basicMutationReturnFields instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Query$SystemSettings _$Query$SystemSettingsFromJson( - Map json) => - Query$SystemSettings( - system: Query$SystemSettings$system.fromJson( - json['system'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemSettingsToJson( - Query$SystemSettings instance) => - { - 'system': instance.system.toJson(), - '__typename': instance.$__typename, - }; - -Query$SystemSettings$system _$Query$SystemSettings$systemFromJson( - Map json) => - Query$SystemSettings$system( - settings: Query$SystemSettings$system$settings.fromJson( - json['settings'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemSettings$systemToJson( - Query$SystemSettings$system instance) => - { - 'settings': instance.settings.toJson(), - '__typename': instance.$__typename, - }; - -Query$SystemSettings$system$settings - _$Query$SystemSettings$system$settingsFromJson(Map json) => - Query$SystemSettings$system$settings( - autoUpgrade: - Query$SystemSettings$system$settings$autoUpgrade.fromJson( - json['autoUpgrade'] as Map), - ssh: Query$SystemSettings$system$settings$ssh.fromJson( - json['ssh'] as Map), - timezone: json['timezone'] as String, - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemSettings$system$settingsToJson( - Query$SystemSettings$system$settings instance) => - { - 'autoUpgrade': instance.autoUpgrade.toJson(), - 'ssh': instance.ssh.toJson(), - 'timezone': instance.timezone, - '__typename': instance.$__typename, - }; - -Query$SystemSettings$system$settings$autoUpgrade - _$Query$SystemSettings$system$settings$autoUpgradeFromJson( - Map json) => - Query$SystemSettings$system$settings$autoUpgrade( - allowReboot: json['allowReboot'] as bool, - enable: json['enable'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemSettings$system$settings$autoUpgradeToJson( - Query$SystemSettings$system$settings$autoUpgrade instance) => - { - 'allowReboot': instance.allowReboot, - 'enable': instance.enable, - '__typename': instance.$__typename, - }; - -Query$SystemSettings$system$settings$ssh - _$Query$SystemSettings$system$settings$sshFromJson( - Map json) => - Query$SystemSettings$system$settings$ssh( - enable: json['enable'] as bool, - passwordAuthentication: json['passwordAuthentication'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemSettings$system$settings$sshToJson( - Query$SystemSettings$system$settings$ssh instance) => - { - 'enable': instance.enable, - 'passwordAuthentication': instance.passwordAuthentication, - '__typename': instance.$__typename, - }; - -Query$SystemIsUsingBinds _$Query$SystemIsUsingBindsFromJson( - Map json) => - Query$SystemIsUsingBinds( - system: Query$SystemIsUsingBinds$system.fromJson( - json['system'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemIsUsingBindsToJson( - Query$SystemIsUsingBinds instance) => - { - 'system': instance.system.toJson(), - '__typename': instance.$__typename, - }; - -Query$SystemIsUsingBinds$system _$Query$SystemIsUsingBinds$systemFromJson( - Map json) => - Query$SystemIsUsingBinds$system( - info: Query$SystemIsUsingBinds$system$info.fromJson( - json['info'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemIsUsingBinds$systemToJson( - Query$SystemIsUsingBinds$system instance) => - { - 'info': instance.info.toJson(), - '__typename': instance.$__typename, - }; - -Query$SystemIsUsingBinds$system$info - _$Query$SystemIsUsingBinds$system$infoFromJson(Map json) => - Query$SystemIsUsingBinds$system$info( - usingBinds: json['usingBinds'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Query$SystemIsUsingBinds$system$infoToJson( - Query$SystemIsUsingBinds$system$info instance) => - { - 'usingBinds': instance.usingBinds, - '__typename': instance.$__typename, - }; - -Query$DomainInfo _$Query$DomainInfoFromJson(Map json) => - Query$DomainInfo( - system: Query$DomainInfo$system.fromJson( - json['system'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$DomainInfoToJson(Query$DomainInfo instance) => - { - 'system': instance.system.toJson(), - '__typename': instance.$__typename, - }; - -Query$DomainInfo$system _$Query$DomainInfo$systemFromJson( - Map json) => - Query$DomainInfo$system( - domainInfo: Query$DomainInfo$system$domainInfo.fromJson( - json['domainInfo'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$DomainInfo$systemToJson( - Query$DomainInfo$system instance) => - { - 'domainInfo': instance.domainInfo.toJson(), - '__typename': instance.$__typename, - }; - -Query$DomainInfo$system$domainInfo _$Query$DomainInfo$system$domainInfoFromJson( - Map json) => - Query$DomainInfo$system$domainInfo( - domain: json['domain'] as String, - hostname: json['hostname'] as String, - provider: $enumDecode(_$Enum$DnsProviderEnumMap, json['provider'], - unknownValue: Enum$DnsProvider.$unknown), - requiredDnsRecords: (json['requiredDnsRecords'] as List) - .map((e) => - Fragment$dnsRecordFields.fromJson(e as Map)) - .toList(), - $__typename: json['__typename'] as String, - ); - -Map _$Query$DomainInfo$system$domainInfoToJson( - Query$DomainInfo$system$domainInfo instance) => - { - 'domain': instance.domain, - 'hostname': instance.hostname, - 'provider': _$Enum$DnsProviderEnumMap[instance.provider]!, - 'requiredDnsRecords': - instance.requiredDnsRecords.map((e) => e.toJson()).toList(), - '__typename': instance.$__typename, - }; - -const _$Enum$DnsProviderEnumMap = { - Enum$DnsProvider.CLOUDFLARE: 'CLOUDFLARE', - Enum$DnsProvider.$unknown: r'$unknown', -}; - -Variables$Mutation$ChangeTimezone _$Variables$Mutation$ChangeTimezoneFromJson( - Map json) => - Variables$Mutation$ChangeTimezone( - timezone: json['timezone'] as String, - ); - -Map _$Variables$Mutation$ChangeTimezoneToJson( - Variables$Mutation$ChangeTimezone instance) => - { - 'timezone': instance.timezone, - }; - -Mutation$ChangeTimezone _$Mutation$ChangeTimezoneFromJson( - Map json) => - Mutation$ChangeTimezone( - changeTimezone: Mutation$ChangeTimezone$changeTimezone.fromJson( - json['changeTimezone'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$ChangeTimezoneToJson( - Mutation$ChangeTimezone instance) => - { - 'changeTimezone': instance.changeTimezone.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$ChangeTimezone$changeTimezone - _$Mutation$ChangeTimezone$changeTimezoneFromJson( - Map json) => - Mutation$ChangeTimezone$changeTimezone( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - timezone: json['timezone'] as String?, - ); - -Map _$Mutation$ChangeTimezone$changeTimezoneToJson( - Mutation$ChangeTimezone$changeTimezone instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'timezone': instance.timezone, - }; - -Variables$Mutation$ChangeAutoUpgradeSettings - _$Variables$Mutation$ChangeAutoUpgradeSettingsFromJson( - Map json) => - Variables$Mutation$ChangeAutoUpgradeSettings( - settings: Input$AutoUpgradeSettingsInput.fromJson( - json['settings'] as Map), - ); - -Map _$Variables$Mutation$ChangeAutoUpgradeSettingsToJson( - Variables$Mutation$ChangeAutoUpgradeSettings instance) => - { - 'settings': instance.settings.toJson(), - }; - -Mutation$ChangeAutoUpgradeSettings _$Mutation$ChangeAutoUpgradeSettingsFromJson( - Map json) => - Mutation$ChangeAutoUpgradeSettings( - changeAutoUpgradeSettings: - Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings.fromJson( - json['changeAutoUpgradeSettings'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$ChangeAutoUpgradeSettingsToJson( - Mutation$ChangeAutoUpgradeSettings instance) => - { - 'changeAutoUpgradeSettings': instance.changeAutoUpgradeSettings.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings - _$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettingsFromJson( - Map json) => - Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - allowReboot: json['allowReboot'] as bool, - enableAutoUpgrade: json['enableAutoUpgrade'] as bool, - ); - -Map - _$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettingsToJson( - Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings - instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'allowReboot': instance.allowReboot, - 'enableAutoUpgrade': instance.enableAutoUpgrade, - }; diff --git a/lib/logic/api_maps/graphql_maps/schema/services.graphql.dart b/lib/logic/api_maps/graphql_maps/schema/services.graphql.dart index 92138d02..dfea309c 100644 --- a/lib/logic/api_maps/graphql_maps/schema/services.graphql.dart +++ b/lib/logic/api_maps/graphql_maps/schema/services.graphql.dart @@ -1,24 +1,70 @@ import 'dart:async'; +import 'disk_volumes.graphql.dart'; import 'package:gql/ast.dart'; import 'package:graphql/client.dart' as graphql; -import 'package:json_annotation/json_annotation.dart'; import 'package:selfprivacy/utils/scalars.dart'; import 'schema.graphql.dart'; -import 'server_api.graphql.dart'; -part 'services.graphql.g.dart'; -@JsonSerializable(explicitToJson: true) class Fragment$basicMutationReturnFields { - Fragment$basicMutationReturnFields( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + Fragment$basicMutationReturnFields({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Fragment$basicMutationReturnFields.fromJson( - Map json) => - _$Fragment$basicMutationReturnFieldsFromJson(json); + Map json) { + switch (json["__typename"] as String) { + case "ApiKeyMutationReturn": + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + .fromJson(json); + + case "AutoUpgradeSettingsMutationReturn": + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + .fromJson(json); + + case "DeviceApiTokenMutationReturn": + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + .fromJson(json); + + case "GenericJobButationReturn": + return Fragment$basicMutationReturnFields$$GenericJobButationReturn + .fromJson(json); + + case "GenericMutationReturn": + return Fragment$basicMutationReturnFields$$GenericMutationReturn + .fromJson(json); + + case "ServiceJobMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + .fromJson(json); + + case "ServiceMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceMutationReturn + .fromJson(json); + + case "TimezoneMutationReturn": + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn + .fromJson(json); + + case "UserMutationReturn": + return Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + json); + + default: + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + } final int code; @@ -26,36 +72,64 @@ class Fragment$basicMutationReturnFields { final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Fragment$basicMutationReturnFieldsToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Fragment$basicMutationReturnFields) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -64,25 +138,35 @@ extension UtilityExtension$Fragment$basicMutationReturnFields on Fragment$basicMutationReturnFields { CopyWith$Fragment$basicMutationReturnFields< Fragment$basicMutationReturnFields> - get copyWith => - CopyWith$Fragment$basicMutationReturnFields(this, (i) => i); + get copyWith => CopyWith$Fragment$basicMutationReturnFields( + this, + (i) => i, + ); } abstract class CopyWith$Fragment$basicMutationReturnFields { factory CopyWith$Fragment$basicMutationReturnFields( - Fragment$basicMutationReturnFields instance, - TRes Function(Fragment$basicMutationReturnFields) then) = - _CopyWithImpl$Fragment$basicMutationReturnFields; + Fragment$basicMutationReturnFields instance, + TRes Function(Fragment$basicMutationReturnFields) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields; factory CopyWith$Fragment$basicMutationReturnFields.stub(TRes res) = _CopyWithStubImpl$Fragment$basicMutationReturnFields; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Fragment$basicMutationReturnFields implements CopyWith$Fragment$basicMutationReturnFields { - _CopyWithImpl$Fragment$basicMutationReturnFields(this._instance, this._then); + _CopyWithImpl$Fragment$basicMutationReturnFields( + this._instance, + this._then, + ); final Fragment$basicMutationReturnFields _instance; @@ -90,24 +174,25 @@ class _CopyWithImpl$Fragment$basicMutationReturnFields static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Fragment$basicMutationReturnFields( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Fragment$basicMutationReturnFields @@ -116,43 +201,54 @@ class _CopyWithStubImpl$Fragment$basicMutationReturnFields TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } const fragmentDefinitionbasicMutationReturnFields = FragmentDefinitionNode( - name: NameNode(value: 'basicMutationReturnFields'), - typeCondition: TypeConditionNode( - on: NamedTypeNode( - name: NameNode(value: 'MutationReturnInterface'), - isNonNull: false)), - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'code'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'message'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'success'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])); + name: NameNode(value: 'basicMutationReturnFields'), + typeCondition: TypeConditionNode( + on: NamedTypeNode( + name: NameNode(value: 'MutationReturnInterface'), + isNonNull: false, + )), + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'code'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'message'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'success'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), +); const documentNodeFragmentbasicMutationReturnFields = DocumentNode(definitions: [ fragmentDefinitionbasicMutationReturnFields, @@ -160,88 +256,1752 @@ const documentNodeFragmentbasicMutationReturnFields = extension ClientExtension$Fragment$basicMutationReturnFields on graphql.GraphQLClient { - void writeFragment$basicMutationReturnFields( - {required Fragment$basicMutationReturnFields data, - required Map idFields, - bool broadcast = true}) => + void writeFragment$basicMutationReturnFields({ + required Fragment$basicMutationReturnFields data, + required Map idFields, + bool broadcast = true, + }) => this.writeFragment( - graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - data: data.toJson(), - broadcast: broadcast); - Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields( - {required Map idFields, bool optimistic = true}) { - final result = this.readFragment( graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - optimistic: optimistic); + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + data: data.toJson(), + broadcast: broadcast, + ); + Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields({ + required Map idFields, + bool optimistic = true, + }) { + final result = this.readFragment( + graphql.FragmentRequest( + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + optimistic: optimistic, + ); return result == null ? null : Fragment$basicMutationReturnFields.fromJson(result); } } -@JsonSerializable(explicitToJson: true) -class Query$AllServices { - Query$AllServices({required this.services, required this.$__typename}); +class Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override - factory Query$AllServices.fromJson(Map json) => - _$Query$AllServicesFromJson(json); + factory Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } - final Query$AllServices$services services; + final int code; + + final String message; + + final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$AllServicesToJson(this); - int get hashCode { - final l$services = services; + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; final l$$__typename = $__typename; - return Object.hashAll([l$services, l$$__typename]); + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$AllServices) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) || + runtimeType != other.runtimeType) { return false; - final l$services = services; - final lOther$services = other.services; - if (l$services != lOther$services) return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + on Fragment$basicMutationReturnFields$$ApiKeyMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ApiKeyMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + on Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + instance, + TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + on Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn instance, + TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericJobButationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericJobButationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericJobButationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$GenericJobButationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericJobButationReturn + on Fragment$basicMutationReturnFields$$GenericJobButationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + Fragment$basicMutationReturnFields$$GenericJobButationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + Fragment$basicMutationReturnFields$$GenericJobButationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericJobButationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericJobButationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$GenericJobButationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$GenericMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericMutationReturn + on Fragment$basicMutationReturnFields$$GenericMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + Fragment$basicMutationReturnFields$$GenericMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + Fragment$basicMutationReturnFields$$GenericMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + on Fragment$basicMutationReturnFields$$ServiceJobMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceJobMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ServiceMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceMutationReturn + on Fragment$basicMutationReturnFields$$ServiceMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + Fragment$basicMutationReturnFields$$ServiceMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + Fragment$basicMutationReturnFields$$ServiceMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$TimezoneMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$TimezoneMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$TimezoneMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$TimezoneMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$TimezoneMutationReturn + on Fragment$basicMutationReturnFields$$TimezoneMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + Fragment$basicMutationReturnFields$$TimezoneMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$TimezoneMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$TimezoneMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$UserMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$UserMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$UserMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$UserMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$UserMutationReturn + on Fragment$basicMutationReturnFields$$UserMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + Fragment$basicMutationReturnFields$$UserMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + Fragment$basicMutationReturnFields$$UserMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$UserMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$UserMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Query$AllServices { + Query$AllServices({ + required this.services, + required this.$__typename, + }); + + factory Query$AllServices.fromJson(Map json) { + final l$services = json['services']; + final l$$__typename = json['__typename']; + return Query$AllServices( + services: Query$AllServices$services.fromJson( + (l$services as Map)), + $__typename: (l$$__typename as String), + ); + } + + final Query$AllServices$services services; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$services = services; + _resultData['services'] = l$services.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$services = services; + final l$$__typename = $__typename; + return Object.hashAll([ + l$services, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Query$AllServices) || runtimeType != other.runtimeType) { + return false; + } + final l$services = services; + final lOther$services = other.services; + if (l$services != lOther$services) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$AllServices on Query$AllServices { CopyWith$Query$AllServices get copyWith => - CopyWith$Query$AllServices(this, (i) => i); + CopyWith$Query$AllServices( + this, + (i) => i, + ); } abstract class CopyWith$Query$AllServices { factory CopyWith$Query$AllServices( - Query$AllServices instance, TRes Function(Query$AllServices) then) = - _CopyWithImpl$Query$AllServices; + Query$AllServices instance, + TRes Function(Query$AllServices) then, + ) = _CopyWithImpl$Query$AllServices; factory CopyWith$Query$AllServices.stub(TRes res) = _CopyWithStubImpl$Query$AllServices; - TRes call({Query$AllServices$services? services, String? $__typename}); + TRes call({ + Query$AllServices$services? services, + String? $__typename, + }); CopyWith$Query$AllServices$services get services; } class _CopyWithImpl$Query$AllServices implements CopyWith$Query$AllServices { - _CopyWithImpl$Query$AllServices(this._instance, this._then); + _CopyWithImpl$Query$AllServices( + this._instance, + this._then, + ); final Query$AllServices _instance; @@ -249,15 +2009,18 @@ class _CopyWithImpl$Query$AllServices static const _undefined = {}; - TRes call( - {Object? services = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? services = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$AllServices( - services: services == _undefined || services == null - ? _instance.services - : (services as Query$AllServices$services), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + services: services == _undefined || services == null + ? _instance.services + : (services as Query$AllServices$services), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$AllServices$services get services { final local$services = _instance.services; return CopyWith$Query$AllServices$services( @@ -271,165 +2034,194 @@ class _CopyWithStubImpl$Query$AllServices TRes _res; - call({Query$AllServices$services? services, String? $__typename}) => _res; + call({ + Query$AllServices$services? services, + String? $__typename, + }) => + _res; CopyWith$Query$AllServices$services get services => CopyWith$Query$AllServices$services.stub(_res); } const documentNodeQueryAllServices = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'AllServices'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'services'), + type: OperationType.query, + name: NameNode(value: 'AllServices'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'services'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'allServices'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FieldNode( - name: NameNode(value: 'allServices'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'description'), + name: NameNode(value: 'description'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'displayName'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'dnsRecords'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'dnsRecordFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: 'id'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'isEnabled'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'isMovable'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'isRequired'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'status'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'storageUsage'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'title'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'usedSpace'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'volume'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'name'), alias: null, arguments: [], directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'displayName'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'dnsRecords'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'dnsRecordFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: 'id'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'isEnabled'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'isMovable'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'isRequired'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'status'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'storageUsage'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'title'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'usedSpace'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'volume'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'name'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: 'svgIcon'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'url'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( + selectionSet: null, + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'svgIcon'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'url'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitiondnsRecordFields, ]); Query$AllServices _parserFn$Query$AllServices(Map data) => @@ -437,57 +2229,62 @@ Query$AllServices _parserFn$Query$AllServices(Map data) => class Options$Query$AllServices extends graphql.QueryOptions { - Options$Query$AllServices( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryAllServices, - parserFn: _parserFn$Query$AllServices); + Options$Query$AllServices({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryAllServices, + parserFn: _parserFn$Query$AllServices, + ); } class WatchOptions$Query$AllServices extends graphql.WatchQueryOptions { - WatchOptions$Query$AllServices( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryAllServices, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$AllServices); + WatchOptions$Query$AllServices({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryAllServices, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$AllServices, + ); } class FetchMoreOptions$Query$AllServices extends graphql.FetchMoreOptions { FetchMoreOptions$Query$AllServices({required graphql.UpdateQuery updateQuery}) - : super(updateQuery: updateQuery, document: documentNodeQueryAllServices); + : super( + updateQuery: updateQuery, + document: documentNodeQueryAllServices, + ); } extension ClientExtension$Query$AllServices on graphql.GraphQLClient { @@ -497,63 +2294,94 @@ extension ClientExtension$Query$AllServices on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$AllServices( [WatchOptions$Query$AllServices? options]) => this.watchQuery(options ?? WatchOptions$Query$AllServices()); - void writeQuery$AllServices( - {required Query$AllServices data, bool broadcast = true}) => + void writeQuery$AllServices({ + required Query$AllServices data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: - graphql.Operation(document: documentNodeQueryAllServices)), - data: data.toJson(), - broadcast: broadcast); - Query$AllServices? readQuery$AllServices({bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation(document: documentNodeQueryAllServices)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$AllServices? readQuery$AllServices({bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: graphql.Operation(document: documentNodeQueryAllServices)), + optimistic: optimistic, + ); return result == null ? null : Query$AllServices.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$AllServices$services { - Query$AllServices$services( - {required this.allServices, required this.$__typename}); + Query$AllServices$services({ + required this.allServices, + required this.$__typename, + }); - @override - factory Query$AllServices$services.fromJson(Map json) => - _$Query$AllServices$servicesFromJson(json); + factory Query$AllServices$services.fromJson(Map json) { + final l$allServices = json['allServices']; + final l$$__typename = json['__typename']; + return Query$AllServices$services( + allServices: (l$allServices as List) + .map((e) => Query$AllServices$services$allServices.fromJson( + (e as Map))) + .toList(), + $__typename: (l$$__typename as String), + ); + } final List allServices; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$AllServices$servicesToJson(this); + Map toJson() { + final _resultData = {}; + final l$allServices = allServices; + _resultData['allServices'] = l$allServices.map((e) => e.toJson()).toList(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$allServices = allServices; final l$$__typename = $__typename; - return Object.hashAll( - [Object.hashAll(l$allServices.map((v) => v)), l$$__typename]); + return Object.hashAll([ + Object.hashAll(l$allServices.map((v) => v)), + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$AllServices$services) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$allServices = allServices; final lOther$allServices = other.allServices; - if (l$allServices.length != lOther$allServices.length) return false; + if (l$allServices.length != lOther$allServices.length) { + return false; + } for (int i = 0; i < l$allServices.length; i++) { final l$allServices$entry = l$allServices[i]; final lOther$allServices$entry = lOther$allServices[i]; - if (l$allServices$entry != lOther$allServices$entry) return false; + if (l$allServices$entry != lOther$allServices$entry) { + return false; + } } - final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -561,21 +2389,25 @@ class Query$AllServices$services { extension UtilityExtension$Query$AllServices$services on Query$AllServices$services { CopyWith$Query$AllServices$services - get copyWith => CopyWith$Query$AllServices$services(this, (i) => i); + get copyWith => CopyWith$Query$AllServices$services( + this, + (i) => i, + ); } abstract class CopyWith$Query$AllServices$services { factory CopyWith$Query$AllServices$services( - Query$AllServices$services instance, - TRes Function(Query$AllServices$services) then) = - _CopyWithImpl$Query$AllServices$services; + Query$AllServices$services instance, + TRes Function(Query$AllServices$services) then, + ) = _CopyWithImpl$Query$AllServices$services; factory CopyWith$Query$AllServices$services.stub(TRes res) = _CopyWithStubImpl$Query$AllServices$services; - TRes call( - {List? allServices, - String? $__typename}); + TRes call({ + List? allServices, + String? $__typename, + }); TRes allServices( Iterable Function( Iterable< @@ -586,7 +2418,10 @@ abstract class CopyWith$Query$AllServices$services { class _CopyWithImpl$Query$AllServices$services implements CopyWith$Query$AllServices$services { - _CopyWithImpl$Query$AllServices$services(this._instance, this._then); + _CopyWithImpl$Query$AllServices$services( + this._instance, + this._then, + ); final Query$AllServices$services _instance; @@ -594,16 +2429,18 @@ class _CopyWithImpl$Query$AllServices$services static const _undefined = {}; - TRes call( - {Object? allServices = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? allServices = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$AllServices$services( - allServices: allServices == _undefined || allServices == null - ? _instance.allServices - : (allServices as List), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + allServices: allServices == _undefined || allServices == null + ? _instance.allServices + : (allServices as List), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); TRes allServices( Iterable Function( Iterable< @@ -611,9 +2448,11 @@ class _CopyWithImpl$Query$AllServices$services Query$AllServices$services$allServices>>) _fn) => call( - allServices: _fn(_instance.allServices.map((e) => - CopyWith$Query$AllServices$services$allServices(e, (i) => i))) - .toList()); + allServices: _fn(_instance.allServices + .map((e) => CopyWith$Query$AllServices$services$allServices( + e, + (i) => i, + ))).toList()); } class _CopyWithStubImpl$Query$AllServices$services @@ -622,33 +2461,64 @@ class _CopyWithStubImpl$Query$AllServices$services TRes _res; - call( - {List? allServices, - String? $__typename}) => + call({ + List? allServices, + String? $__typename, + }) => _res; allServices(_fn) => _res; } -@JsonSerializable(explicitToJson: true) class Query$AllServices$services$allServices { - Query$AllServices$services$allServices( - {required this.description, - required this.displayName, - this.dnsRecords, - required this.id, - required this.isEnabled, - required this.isMovable, - required this.isRequired, - required this.status, - required this.storageUsage, - required this.svgIcon, - this.url, - required this.$__typename}); + Query$AllServices$services$allServices({ + required this.description, + required this.displayName, + this.dnsRecords, + required this.id, + required this.isEnabled, + required this.isMovable, + required this.isRequired, + required this.status, + required this.storageUsage, + required this.svgIcon, + this.url, + required this.$__typename, + }); - @override factory Query$AllServices$services$allServices.fromJson( - Map json) => - _$Query$AllServices$services$allServicesFromJson(json); + Map json) { + final l$description = json['description']; + final l$displayName = json['displayName']; + final l$dnsRecords = json['dnsRecords']; + final l$id = json['id']; + final l$isEnabled = json['isEnabled']; + final l$isMovable = json['isMovable']; + final l$isRequired = json['isRequired']; + final l$status = json['status']; + final l$storageUsage = json['storageUsage']; + final l$svgIcon = json['svgIcon']; + final l$url = json['url']; + final l$$__typename = json['__typename']; + return Query$AllServices$services$allServices( + description: (l$description as String), + displayName: (l$displayName as String), + dnsRecords: (l$dnsRecords as List?) + ?.map((e) => + Fragment$dnsRecordFields.fromJson((e as Map))) + .toList(), + id: (l$id as String), + isEnabled: (l$isEnabled as bool), + isMovable: (l$isMovable as bool), + isRequired: (l$isRequired as bool), + status: fromJson$Enum$ServiceStatusEnum((l$status as String)), + storageUsage: + Query$AllServices$services$allServices$storageUsage.fromJson( + (l$storageUsage as Map)), + svgIcon: (l$svgIcon as String), + url: (l$url as String?), + $__typename: (l$$__typename as String), + ); + } final String description; @@ -664,7 +2534,6 @@ class Query$AllServices$services$allServices { final bool isRequired; - @JsonKey(unknownEnumValue: Enum$ServiceStatusEnum.$unknown) final Enum$ServiceStatusEnum status; final Query$AllServices$services$allServices$storageUsage storageUsage; @@ -673,11 +2542,38 @@ class Query$AllServices$services$allServices { final String? url; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$AllServices$services$allServicesToJson(this); + Map toJson() { + final _resultData = {}; + final l$description = description; + _resultData['description'] = l$description; + final l$displayName = displayName; + _resultData['displayName'] = l$displayName; + final l$dnsRecords = dnsRecords; + _resultData['dnsRecords'] = l$dnsRecords?.map((e) => e.toJson()).toList(); + final l$id = id; + _resultData['id'] = l$id; + final l$isEnabled = isEnabled; + _resultData['isEnabled'] = l$isEnabled; + final l$isMovable = isMovable; + _resultData['isMovable'] = l$isMovable; + final l$isRequired = isRequired; + _resultData['isRequired'] = l$isRequired; + final l$status = status; + _resultData['status'] = toJson$Enum$ServiceStatusEnum(l$status); + final l$storageUsage = storageUsage; + _resultData['storageUsage'] = l$storageUsage.toJson(); + final l$svgIcon = svgIcon; + _resultData['svgIcon'] = l$svgIcon; + final l$url = url; + _resultData['url'] = l$url; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$description = description; final l$displayName = displayName; @@ -703,61 +2599,90 @@ class Query$AllServices$services$allServices { l$storageUsage, l$svgIcon, l$url, - l$$__typename + l$$__typename, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$AllServices$services$allServices) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$description = description; final lOther$description = other.description; - if (l$description != lOther$description) return false; + if (l$description != lOther$description) { + return false; + } final l$displayName = displayName; final lOther$displayName = other.displayName; - if (l$displayName != lOther$displayName) return false; + if (l$displayName != lOther$displayName) { + return false; + } final l$dnsRecords = dnsRecords; final lOther$dnsRecords = other.dnsRecords; if (l$dnsRecords != null && lOther$dnsRecords != null) { - if (l$dnsRecords.length != lOther$dnsRecords.length) return false; + if (l$dnsRecords.length != lOther$dnsRecords.length) { + return false; + } for (int i = 0; i < l$dnsRecords.length; i++) { final l$dnsRecords$entry = l$dnsRecords[i]; final lOther$dnsRecords$entry = lOther$dnsRecords[i]; - if (l$dnsRecords$entry != lOther$dnsRecords$entry) return false; + if (l$dnsRecords$entry != lOther$dnsRecords$entry) { + return false; + } } } else if (l$dnsRecords != lOther$dnsRecords) { return false; } - final l$id = id; final lOther$id = other.id; - if (l$id != lOther$id) return false; + if (l$id != lOther$id) { + return false; + } final l$isEnabled = isEnabled; final lOther$isEnabled = other.isEnabled; - if (l$isEnabled != lOther$isEnabled) return false; + if (l$isEnabled != lOther$isEnabled) { + return false; + } final l$isMovable = isMovable; final lOther$isMovable = other.isMovable; - if (l$isMovable != lOther$isMovable) return false; + if (l$isMovable != lOther$isMovable) { + return false; + } final l$isRequired = isRequired; final lOther$isRequired = other.isRequired; - if (l$isRequired != lOther$isRequired) return false; + if (l$isRequired != lOther$isRequired) { + return false; + } final l$status = status; final lOther$status = other.status; - if (l$status != lOther$status) return false; + if (l$status != lOther$status) { + return false; + } final l$storageUsage = storageUsage; final lOther$storageUsage = other.storageUsage; - if (l$storageUsage != lOther$storageUsage) return false; + if (l$storageUsage != lOther$storageUsage) { + return false; + } final l$svgIcon = svgIcon; final lOther$svgIcon = other.svgIcon; - if (l$svgIcon != lOther$svgIcon) return false; + if (l$svgIcon != lOther$svgIcon) { + return false; + } final l$url = url; final lOther$url = other.url; - if (l$url != lOther$url) return false; + if (l$url != lOther$url) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -766,32 +2691,35 @@ extension UtilityExtension$Query$AllServices$services$allServices on Query$AllServices$services$allServices { CopyWith$Query$AllServices$services$allServices< Query$AllServices$services$allServices> - get copyWith => - CopyWith$Query$AllServices$services$allServices(this, (i) => i); + get copyWith => CopyWith$Query$AllServices$services$allServices( + this, + (i) => i, + ); } abstract class CopyWith$Query$AllServices$services$allServices { factory CopyWith$Query$AllServices$services$allServices( - Query$AllServices$services$allServices instance, - TRes Function(Query$AllServices$services$allServices) then) = - _CopyWithImpl$Query$AllServices$services$allServices; + Query$AllServices$services$allServices instance, + TRes Function(Query$AllServices$services$allServices) then, + ) = _CopyWithImpl$Query$AllServices$services$allServices; factory CopyWith$Query$AllServices$services$allServices.stub(TRes res) = _CopyWithStubImpl$Query$AllServices$services$allServices; - TRes call( - {String? description, - String? displayName, - List? dnsRecords, - String? id, - bool? isEnabled, - bool? isMovable, - bool? isRequired, - Enum$ServiceStatusEnum? status, - Query$AllServices$services$allServices$storageUsage? storageUsage, - String? svgIcon, - String? url, - String? $__typename}); + TRes call({ + String? description, + String? displayName, + List? dnsRecords, + String? id, + bool? isEnabled, + bool? isMovable, + bool? isRequired, + Enum$ServiceStatusEnum? status, + Query$AllServices$services$allServices$storageUsage? storageUsage, + String? svgIcon, + String? url, + String? $__typename, + }); TRes dnsRecords( Iterable? Function( Iterable< @@ -804,7 +2732,9 @@ abstract class CopyWith$Query$AllServices$services$allServices { class _CopyWithImpl$Query$AllServices$services$allServices implements CopyWith$Query$AllServices$services$allServices { _CopyWithImpl$Query$AllServices$services$allServices( - this._instance, this._then); + this._instance, + this._then, + ); final Query$AllServices$services$allServices _instance; @@ -812,53 +2742,55 @@ class _CopyWithImpl$Query$AllServices$services$allServices static const _undefined = {}; - TRes call( - {Object? description = _undefined, - Object? displayName = _undefined, - Object? dnsRecords = _undefined, - Object? id = _undefined, - Object? isEnabled = _undefined, - Object? isMovable = _undefined, - Object? isRequired = _undefined, - Object? status = _undefined, - Object? storageUsage = _undefined, - Object? svgIcon = _undefined, - Object? url = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? description = _undefined, + Object? displayName = _undefined, + Object? dnsRecords = _undefined, + Object? id = _undefined, + Object? isEnabled = _undefined, + Object? isMovable = _undefined, + Object? isRequired = _undefined, + Object? status = _undefined, + Object? storageUsage = _undefined, + Object? svgIcon = _undefined, + Object? url = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$AllServices$services$allServices( - description: description == _undefined || description == null - ? _instance.description - : (description as String), - displayName: displayName == _undefined || displayName == null - ? _instance.displayName - : (displayName as String), - dnsRecords: dnsRecords == _undefined - ? _instance.dnsRecords - : (dnsRecords as List?), - id: id == _undefined || id == null ? _instance.id : (id as String), - isEnabled: isEnabled == _undefined || isEnabled == null - ? _instance.isEnabled - : (isEnabled as bool), - isMovable: isMovable == _undefined || isMovable == null - ? _instance.isMovable - : (isMovable as bool), - isRequired: isRequired == _undefined || isRequired == null - ? _instance.isRequired - : (isRequired as bool), - status: status == _undefined || status == null - ? _instance.status - : (status as Enum$ServiceStatusEnum), - storageUsage: storageUsage == _undefined || storageUsage == null - ? _instance.storageUsage - : (storageUsage - as Query$AllServices$services$allServices$storageUsage), - svgIcon: svgIcon == _undefined || svgIcon == null - ? _instance.svgIcon - : (svgIcon as String), - url: url == _undefined ? _instance.url : (url as String?), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + description: description == _undefined || description == null + ? _instance.description + : (description as String), + displayName: displayName == _undefined || displayName == null + ? _instance.displayName + : (displayName as String), + dnsRecords: dnsRecords == _undefined + ? _instance.dnsRecords + : (dnsRecords as List?), + id: id == _undefined || id == null ? _instance.id : (id as String), + isEnabled: isEnabled == _undefined || isEnabled == null + ? _instance.isEnabled + : (isEnabled as bool), + isMovable: isMovable == _undefined || isMovable == null + ? _instance.isMovable + : (isMovable as bool), + isRequired: isRequired == _undefined || isRequired == null + ? _instance.isRequired + : (isRequired as bool), + status: status == _undefined || status == null + ? _instance.status + : (status as Enum$ServiceStatusEnum), + storageUsage: storageUsage == _undefined || storageUsage == null + ? _instance.storageUsage + : (storageUsage + as Query$AllServices$services$allServices$storageUsage), + svgIcon: svgIcon == _undefined || svgIcon == null + ? _instance.svgIcon + : (svgIcon as String), + url: url == _undefined ? _instance.url : (url as String?), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); TRes dnsRecords( Iterable? Function( Iterable< @@ -867,8 +2799,10 @@ class _CopyWithImpl$Query$AllServices$services$allServices _fn) => call( dnsRecords: _fn(_instance.dnsRecords - ?.map((e) => CopyWith$Fragment$dnsRecordFields(e, (i) => i))) - ?.toList()); + ?.map((e) => CopyWith$Fragment$dnsRecordFields( + e, + (i) => i, + )))?.toList()); CopyWith$Query$AllServices$services$allServices$storageUsage get storageUsage { final local$storageUsage = _instance.storageUsage; @@ -883,19 +2817,20 @@ class _CopyWithStubImpl$Query$AllServices$services$allServices TRes _res; - call( - {String? description, - String? displayName, - List? dnsRecords, - String? id, - bool? isEnabled, - bool? isMovable, - bool? isRequired, - Enum$ServiceStatusEnum? status, - Query$AllServices$services$allServices$storageUsage? storageUsage, - String? svgIcon, - String? url, - String? $__typename}) => + call({ + String? description, + String? displayName, + List? dnsRecords, + String? id, + bool? isEnabled, + bool? isMovable, + bool? isRequired, + Enum$ServiceStatusEnum? status, + Query$AllServices$services$allServices$storageUsage? storageUsage, + String? svgIcon, + String? url, + String? $__typename, + }) => _res; dnsRecords(_fn) => _res; CopyWith$Query$AllServices$services$allServices$storageUsage @@ -904,18 +2839,30 @@ class _CopyWithStubImpl$Query$AllServices$services$allServices _res); } -@JsonSerializable(explicitToJson: true) class Query$AllServices$services$allServices$storageUsage { - Query$AllServices$services$allServices$storageUsage( - {required this.title, - required this.usedSpace, - this.volume, - required this.$__typename}); + Query$AllServices$services$allServices$storageUsage({ + required this.title, + required this.usedSpace, + this.volume, + required this.$__typename, + }); - @override factory Query$AllServices$services$allServices$storageUsage.fromJson( - Map json) => - _$Query$AllServices$services$allServices$storageUsageFromJson(json); + Map json) { + final l$title = json['title']; + final l$usedSpace = json['usedSpace']; + final l$volume = json['volume']; + final l$$__typename = json['__typename']; + return Query$AllServices$services$allServices$storageUsage( + title: (l$title as String), + usedSpace: (l$usedSpace as String), + volume: l$volume == null + ? null + : Query$AllServices$services$allServices$storageUsage$volume.fromJson( + (l$volume as Map)), + $__typename: (l$$__typename as String), + ); + } final String title; @@ -923,36 +2870,64 @@ class Query$AllServices$services$allServices$storageUsage { final Query$AllServices$services$allServices$storageUsage$volume? volume; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$AllServices$services$allServices$storageUsageToJson(this); + Map toJson() { + final _resultData = {}; + final l$title = title; + _resultData['title'] = l$title; + final l$usedSpace = usedSpace; + _resultData['usedSpace'] = l$usedSpace; + final l$volume = volume; + _resultData['volume'] = l$volume?.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$title = title; final l$usedSpace = usedSpace; final l$volume = volume; final l$$__typename = $__typename; - return Object.hashAll([l$title, l$usedSpace, l$volume, l$$__typename]); + return Object.hashAll([ + l$title, + l$usedSpace, + l$volume, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$AllServices$services$allServices$storageUsage) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$title = title; final lOther$title = other.title; - if (l$title != lOther$title) return false; + if (l$title != lOther$title) { + return false; + } final l$usedSpace = usedSpace; final lOther$usedSpace = other.usedSpace; - if (l$usedSpace != lOther$usedSpace) return false; + if (l$usedSpace != lOther$usedSpace) { + return false; + } final l$volume = volume; final lOther$volume = other.volume; - if (l$volume != lOther$volume) return false; + if (l$volume != lOther$volume) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -963,26 +2938,28 @@ extension UtilityExtension$Query$AllServices$services$allServices$storageUsage Query$AllServices$services$allServices$storageUsage> get copyWith => CopyWith$Query$AllServices$services$allServices$storageUsage( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Query$AllServices$services$allServices$storageUsage< TRes> { factory CopyWith$Query$AllServices$services$allServices$storageUsage( - Query$AllServices$services$allServices$storageUsage instance, - TRes Function(Query$AllServices$services$allServices$storageUsage) - then) = - _CopyWithImpl$Query$AllServices$services$allServices$storageUsage; + Query$AllServices$services$allServices$storageUsage instance, + TRes Function(Query$AllServices$services$allServices$storageUsage) then, + ) = _CopyWithImpl$Query$AllServices$services$allServices$storageUsage; factory CopyWith$Query$AllServices$services$allServices$storageUsage.stub( TRes res) = _CopyWithStubImpl$Query$AllServices$services$allServices$storageUsage; - TRes call( - {String? title, - String? usedSpace, - Query$AllServices$services$allServices$storageUsage$volume? volume, - String? $__typename}); + TRes call({ + String? title, + String? usedSpace, + Query$AllServices$services$allServices$storageUsage$volume? volume, + String? $__typename, + }); CopyWith$Query$AllServices$services$allServices$storageUsage$volume get volume; } @@ -991,7 +2968,9 @@ class _CopyWithImpl$Query$AllServices$services$allServices$storageUsage implements CopyWith$Query$AllServices$services$allServices$storageUsage { _CopyWithImpl$Query$AllServices$services$allServices$storageUsage( - this._instance, this._then); + this._instance, + this._then, + ); final Query$AllServices$services$allServices$storageUsage _instance; @@ -1000,25 +2979,27 @@ class _CopyWithImpl$Query$AllServices$services$allServices$storageUsage static const _undefined = {}; - TRes call( - {Object? title = _undefined, - Object? usedSpace = _undefined, - Object? volume = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? title = _undefined, + Object? usedSpace = _undefined, + Object? volume = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$AllServices$services$allServices$storageUsage( - title: title == _undefined || title == null - ? _instance.title - : (title as String), - usedSpace: usedSpace == _undefined || usedSpace == null - ? _instance.usedSpace - : (usedSpace as String), - volume: volume == _undefined - ? _instance.volume - : (volume - as Query$AllServices$services$allServices$storageUsage$volume?), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + title: title == _undefined || title == null + ? _instance.title + : (title as String), + usedSpace: usedSpace == _undefined || usedSpace == null + ? _instance.usedSpace + : (usedSpace as String), + volume: volume == _undefined + ? _instance.volume + : (volume + as Query$AllServices$services$allServices$storageUsage$volume?), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$AllServices$services$allServices$storageUsage$volume get volume { final local$volume = _instance.volume; @@ -1039,11 +3020,12 @@ class _CopyWithStubImpl$Query$AllServices$services$allServices$storageUsage< TRes _res; - call( - {String? title, - String? usedSpace, - Query$AllServices$services$allServices$storageUsage$volume? volume, - String? $__typename}) => + call({ + String? title, + String? usedSpace, + Query$AllServices$services$allServices$storageUsage$volume? volume, + String? $__typename, + }) => _res; CopyWith$Query$AllServices$services$allServices$storageUsage$volume get volume => @@ -1051,42 +3033,65 @@ class _CopyWithStubImpl$Query$AllServices$services$allServices$storageUsage< .stub(_res); } -@JsonSerializable(explicitToJson: true) class Query$AllServices$services$allServices$storageUsage$volume { - Query$AllServices$services$allServices$storageUsage$volume( - {required this.name, required this.$__typename}); + Query$AllServices$services$allServices$storageUsage$volume({ + required this.name, + required this.$__typename, + }); - @override factory Query$AllServices$services$allServices$storageUsage$volume.fromJson( - Map json) => - _$Query$AllServices$services$allServices$storageUsage$volumeFromJson( - json); + Map json) { + final l$name = json['name']; + final l$$__typename = json['__typename']; + return Query$AllServices$services$allServices$storageUsage$volume( + name: (l$name as String), + $__typename: (l$$__typename as String), + ); + } final String name; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Query$AllServices$services$allServices$storageUsage$volumeToJson(this); + Map toJson() { + final _resultData = {}; + final l$name = name; + _resultData['name'] = l$name; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$name = name; final l$$__typename = $__typename; - return Object.hashAll([l$name, l$$__typename]); + return Object.hashAll([ + l$name, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Query$AllServices$services$allServices$storageUsage$volume) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$name = name; final lOther$name = other.name; - if (l$name != lOther$name) return false; + if (l$name != lOther$name) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1097,23 +3102,27 @@ extension UtilityExtension$Query$AllServices$services$allServices$storageUsage$v Query$AllServices$services$allServices$storageUsage$volume> get copyWith => CopyWith$Query$AllServices$services$allServices$storageUsage$volume( - this, (i) => i); + this, + (i) => i, + ); } abstract class CopyWith$Query$AllServices$services$allServices$storageUsage$volume< TRes> { factory CopyWith$Query$AllServices$services$allServices$storageUsage$volume( - Query$AllServices$services$allServices$storageUsage$volume instance, - TRes Function( - Query$AllServices$services$allServices$storageUsage$volume) - then) = - _CopyWithImpl$Query$AllServices$services$allServices$storageUsage$volume; + Query$AllServices$services$allServices$storageUsage$volume instance, + TRes Function(Query$AllServices$services$allServices$storageUsage$volume) + then, + ) = _CopyWithImpl$Query$AllServices$services$allServices$storageUsage$volume; factory CopyWith$Query$AllServices$services$allServices$storageUsage$volume.stub( TRes res) = _CopyWithStubImpl$Query$AllServices$services$allServices$storageUsage$volume; - TRes call({String? name, String? $__typename}); + TRes call({ + String? name, + String? $__typename, + }); } class _CopyWithImpl$Query$AllServices$services$allServices$storageUsage$volume< @@ -1122,7 +3131,9 @@ class _CopyWithImpl$Query$AllServices$services$allServices$storageUsage$volume< CopyWith$Query$AllServices$services$allServices$storageUsage$volume< TRes> { _CopyWithImpl$Query$AllServices$services$allServices$storageUsage$volume( - this._instance, this._then); + this._instance, + this._then, + ); final Query$AllServices$services$allServices$storageUsage$volume _instance; @@ -1131,14 +3142,18 @@ class _CopyWithImpl$Query$AllServices$services$allServices$storageUsage$volume< static const _undefined = {}; - TRes call({Object? name = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? name = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$AllServices$services$allServices$storageUsage$volume( - name: name == _undefined || name == null - ? _instance.name - : (name as String), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + name: name == _undefined || name == null + ? _instance.name + : (name as String), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Query$AllServices$services$allServices$storageUsage$volume< @@ -1151,47 +3166,72 @@ class _CopyWithStubImpl$Query$AllServices$services$allServices$storageUsage$volu TRes _res; - call({String? name, String? $__typename}) => _res; + call({ + String? name, + String? $__typename, + }) => + _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$EnableService { - Variables$Mutation$EnableService({required this.serviceId}); + factory Variables$Mutation$EnableService({required String serviceId}) => + Variables$Mutation$EnableService._({ + r'serviceId': serviceId, + }); + + Variables$Mutation$EnableService._(this._$data); + + factory Variables$Mutation$EnableService.fromJson(Map data) { + final result$data = {}; + final l$serviceId = data['serviceId']; + result$data['serviceId'] = (l$serviceId as String); + return Variables$Mutation$EnableService._(result$data); + } + + Map _$data; + + String get serviceId => (_$data['serviceId'] as String); + Map toJson() { + final result$data = {}; + final l$serviceId = serviceId; + result$data['serviceId'] = l$serviceId; + return result$data; + } + + CopyWith$Variables$Mutation$EnableService + get copyWith => CopyWith$Variables$Mutation$EnableService( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$EnableService) || + runtimeType != other.runtimeType) { + return false; + } + final l$serviceId = serviceId; + final lOther$serviceId = other.serviceId; + if (l$serviceId != lOther$serviceId) { + return false; + } + return true; + } @override - factory Variables$Mutation$EnableService.fromJson( - Map json) => - _$Variables$Mutation$EnableServiceFromJson(json); - - final String serviceId; - - Map toJson() => - _$Variables$Mutation$EnableServiceToJson(this); int get hashCode { final l$serviceId = serviceId; return Object.hashAll([l$serviceId]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$EnableService) || - runtimeType != other.runtimeType) return false; - final l$serviceId = serviceId; - final lOther$serviceId = other.serviceId; - if (l$serviceId != lOther$serviceId) return false; - return true; - } - - CopyWith$Variables$Mutation$EnableService - get copyWith => CopyWith$Variables$Mutation$EnableService(this, (i) => i); } abstract class CopyWith$Variables$Mutation$EnableService { factory CopyWith$Variables$Mutation$EnableService( - Variables$Mutation$EnableService instance, - TRes Function(Variables$Mutation$EnableService) then) = - _CopyWithImpl$Variables$Mutation$EnableService; + Variables$Mutation$EnableService instance, + TRes Function(Variables$Mutation$EnableService) then, + ) = _CopyWithImpl$Variables$Mutation$EnableService; factory CopyWith$Variables$Mutation$EnableService.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$EnableService; @@ -1201,7 +3241,10 @@ abstract class CopyWith$Variables$Mutation$EnableService { class _CopyWithImpl$Variables$Mutation$EnableService implements CopyWith$Variables$Mutation$EnableService { - _CopyWithImpl$Variables$Mutation$EnableService(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$EnableService( + this._instance, + this._then, + ); final Variables$Mutation$EnableService _instance; @@ -1210,10 +3253,11 @@ class _CopyWithImpl$Variables$Mutation$EnableService static const _undefined = {}; TRes call({Object? serviceId = _undefined}) => - _then(Variables$Mutation$EnableService( - serviceId: serviceId == _undefined || serviceId == null - ? _instance.serviceId - : (serviceId as String))); + _then(Variables$Mutation$EnableService._({ + ..._instance._$data, + if (serviceId != _undefined && serviceId != null) + 'serviceId': (serviceId as String), + })); } class _CopyWithStubImpl$Variables$Mutation$EnableService @@ -1225,64 +3269,98 @@ class _CopyWithStubImpl$Variables$Mutation$EnableService call({String? serviceId}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$EnableService { - Mutation$EnableService( - {required this.enableService, required this.$__typename}); + Mutation$EnableService({ + required this.enableService, + required this.$__typename, + }); - @override - factory Mutation$EnableService.fromJson(Map json) => - _$Mutation$EnableServiceFromJson(json); + factory Mutation$EnableService.fromJson(Map json) { + final l$enableService = json['enableService']; + final l$$__typename = json['__typename']; + return Mutation$EnableService( + enableService: Mutation$EnableService$enableService.fromJson( + (l$enableService as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$EnableService$enableService enableService; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$EnableServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$enableService = enableService; + _resultData['enableService'] = l$enableService.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$enableService = enableService; final l$$__typename = $__typename; - return Object.hashAll([l$enableService, l$$__typename]); + return Object.hashAll([ + l$enableService, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$EnableService) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$EnableService) || + runtimeType != other.runtimeType) { return false; + } final l$enableService = enableService; final lOther$enableService = other.enableService; - if (l$enableService != lOther$enableService) return false; + if (l$enableService != lOther$enableService) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$EnableService on Mutation$EnableService { CopyWith$Mutation$EnableService get copyWith => - CopyWith$Mutation$EnableService(this, (i) => i); + CopyWith$Mutation$EnableService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$EnableService { - factory CopyWith$Mutation$EnableService(Mutation$EnableService instance, - TRes Function(Mutation$EnableService) then) = - _CopyWithImpl$Mutation$EnableService; + factory CopyWith$Mutation$EnableService( + Mutation$EnableService instance, + TRes Function(Mutation$EnableService) then, + ) = _CopyWithImpl$Mutation$EnableService; factory CopyWith$Mutation$EnableService.stub(TRes res) = _CopyWithStubImpl$Mutation$EnableService; - TRes call( - {Mutation$EnableService$enableService? enableService, - String? $__typename}); + TRes call({ + Mutation$EnableService$enableService? enableService, + String? $__typename, + }); CopyWith$Mutation$EnableService$enableService get enableService; } class _CopyWithImpl$Mutation$EnableService implements CopyWith$Mutation$EnableService { - _CopyWithImpl$Mutation$EnableService(this._instance, this._then); + _CopyWithImpl$Mutation$EnableService( + this._instance, + this._then, + ); final Mutation$EnableService _instance; @@ -1290,16 +3368,18 @@ class _CopyWithImpl$Mutation$EnableService static const _undefined = {}; - TRes call( - {Object? enableService = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? enableService = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$EnableService( - enableService: enableService == _undefined || enableService == null - ? _instance.enableService - : (enableService as Mutation$EnableService$enableService), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + enableService: enableService == _undefined || enableService == null + ? _instance.enableService + : (enableService as Mutation$EnableService$enableService), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$EnableService$enableService get enableService { final local$enableService = _instance.enableService; return CopyWith$Mutation$EnableService$enableService( @@ -1313,9 +3393,10 @@ class _CopyWithStubImpl$Mutation$EnableService TRes _res; - call( - {Mutation$EnableService$enableService? enableService, - String? $__typename}) => + call({ + Mutation$EnableService$enableService? enableService, + String? $__typename, + }) => _res; CopyWith$Mutation$EnableService$enableService get enableService => CopyWith$Mutation$EnableService$enableService.stub(_res); @@ -1323,86 +3404,99 @@ class _CopyWithStubImpl$Mutation$EnableService const documentNodeMutationEnableService = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'EnableService'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'serviceId')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'enableService'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'serviceId'), - value: VariableNode(name: NameNode(value: 'serviceId'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'EnableService'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'serviceId')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'enableService'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'serviceId'), + value: VariableNode(name: NameNode(value: 'serviceId')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$EnableService _parserFn$Mutation$EnableService( Map data) => Mutation$EnableService.fromJson(data); typedef OnMutationCompleted$Mutation$EnableService = FutureOr Function( - dynamic, Mutation$EnableService?); + dynamic, + Mutation$EnableService?, +); class Options$Mutation$EnableService extends graphql.MutationOptions { - Options$Mutation$EnableService( - {String? operationName, - required Variables$Mutation$EnableService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$EnableService? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$EnableService({ + String? operationName, + required Variables$Mutation$EnableService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$EnableService? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$EnableService(data)), - update: update, - onError: onError, - document: documentNodeMutationEnableService, - parserFn: _parserFn$Mutation$EnableService); + : _parserFn$Mutation$EnableService(data), + ), + update: update, + onError: onError, + document: documentNodeMutationEnableService, + parserFn: _parserFn$Mutation$EnableService, + ); final OnMutationCompleted$Mutation$EnableService? onCompletedWithParsed; @@ -1411,38 +3505,39 @@ class Options$Mutation$EnableService ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$EnableService extends graphql.WatchQueryOptions { - WatchOptions$Mutation$EnableService( - {String? operationName, - required Variables$Mutation$EnableService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationEnableService, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$EnableService); + WatchOptions$Mutation$EnableService({ + String? operationName, + required Variables$Mutation$EnableService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationEnableService, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$EnableService, + ); } extension ClientExtension$Mutation$EnableService on graphql.GraphQLClient { @@ -1454,19 +3549,28 @@ extension ClientExtension$Mutation$EnableService on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$EnableService$enableService - implements Fragment$basicMutationReturnFields { - Mutation$EnableService$enableService( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$ServiceMutationReturn { + Mutation$EnableService$enableService({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$EnableService$enableService.fromJson( - Map json) => - _$Mutation$EnableService$enableServiceFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$EnableService$enableService( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -1474,36 +3578,64 @@ class Mutation$EnableService$enableService final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$EnableService$enableServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$EnableService$enableService) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1512,26 +3644,35 @@ extension UtilityExtension$Mutation$EnableService$enableService on Mutation$EnableService$enableService { CopyWith$Mutation$EnableService$enableService< Mutation$EnableService$enableService> - get copyWith => - CopyWith$Mutation$EnableService$enableService(this, (i) => i); + get copyWith => CopyWith$Mutation$EnableService$enableService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$EnableService$enableService { factory CopyWith$Mutation$EnableService$enableService( - Mutation$EnableService$enableService instance, - TRes Function(Mutation$EnableService$enableService) then) = - _CopyWithImpl$Mutation$EnableService$enableService; + Mutation$EnableService$enableService instance, + TRes Function(Mutation$EnableService$enableService) then, + ) = _CopyWithImpl$Mutation$EnableService$enableService; factory CopyWith$Mutation$EnableService$enableService.stub(TRes res) = _CopyWithStubImpl$Mutation$EnableService$enableService; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$EnableService$enableService implements CopyWith$Mutation$EnableService$enableService { _CopyWithImpl$Mutation$EnableService$enableService( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$EnableService$enableService _instance; @@ -1539,24 +3680,25 @@ class _CopyWithImpl$Mutation$EnableService$enableService static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$EnableService$enableService( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$EnableService$enableService @@ -1565,49 +3707,75 @@ class _CopyWithStubImpl$Mutation$EnableService$enableService TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$DisableService { - Variables$Mutation$DisableService({required this.serviceId}); + factory Variables$Mutation$DisableService({required String serviceId}) => + Variables$Mutation$DisableService._({ + r'serviceId': serviceId, + }); + + Variables$Mutation$DisableService._(this._$data); + + factory Variables$Mutation$DisableService.fromJson( + Map data) { + final result$data = {}; + final l$serviceId = data['serviceId']; + result$data['serviceId'] = (l$serviceId as String); + return Variables$Mutation$DisableService._(result$data); + } + + Map _$data; + + String get serviceId => (_$data['serviceId'] as String); + Map toJson() { + final result$data = {}; + final l$serviceId = serviceId; + result$data['serviceId'] = l$serviceId; + return result$data; + } + + CopyWith$Variables$Mutation$DisableService + get copyWith => CopyWith$Variables$Mutation$DisableService( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$DisableService) || + runtimeType != other.runtimeType) { + return false; + } + final l$serviceId = serviceId; + final lOther$serviceId = other.serviceId; + if (l$serviceId != lOther$serviceId) { + return false; + } + return true; + } @override - factory Variables$Mutation$DisableService.fromJson( - Map json) => - _$Variables$Mutation$DisableServiceFromJson(json); - - final String serviceId; - - Map toJson() => - _$Variables$Mutation$DisableServiceToJson(this); int get hashCode { final l$serviceId = serviceId; return Object.hashAll([l$serviceId]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$DisableService) || - runtimeType != other.runtimeType) return false; - final l$serviceId = serviceId; - final lOther$serviceId = other.serviceId; - if (l$serviceId != lOther$serviceId) return false; - return true; - } - - CopyWith$Variables$Mutation$DisableService - get copyWith => - CopyWith$Variables$Mutation$DisableService(this, (i) => i); } abstract class CopyWith$Variables$Mutation$DisableService { factory CopyWith$Variables$Mutation$DisableService( - Variables$Mutation$DisableService instance, - TRes Function(Variables$Mutation$DisableService) then) = - _CopyWithImpl$Variables$Mutation$DisableService; + Variables$Mutation$DisableService instance, + TRes Function(Variables$Mutation$DisableService) then, + ) = _CopyWithImpl$Variables$Mutation$DisableService; factory CopyWith$Variables$Mutation$DisableService.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$DisableService; @@ -1617,7 +3785,10 @@ abstract class CopyWith$Variables$Mutation$DisableService { class _CopyWithImpl$Variables$Mutation$DisableService implements CopyWith$Variables$Mutation$DisableService { - _CopyWithImpl$Variables$Mutation$DisableService(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$DisableService( + this._instance, + this._then, + ); final Variables$Mutation$DisableService _instance; @@ -1626,10 +3797,11 @@ class _CopyWithImpl$Variables$Mutation$DisableService static const _undefined = {}; TRes call({Object? serviceId = _undefined}) => - _then(Variables$Mutation$DisableService( - serviceId: serviceId == _undefined || serviceId == null - ? _instance.serviceId - : (serviceId as String))); + _then(Variables$Mutation$DisableService._({ + ..._instance._$data, + if (serviceId != _undefined && serviceId != null) + 'serviceId': (serviceId as String), + })); } class _CopyWithStubImpl$Variables$Mutation$DisableService @@ -1641,64 +3813,98 @@ class _CopyWithStubImpl$Variables$Mutation$DisableService call({String? serviceId}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$DisableService { - Mutation$DisableService( - {required this.disableService, required this.$__typename}); + Mutation$DisableService({ + required this.disableService, + required this.$__typename, + }); - @override - factory Mutation$DisableService.fromJson(Map json) => - _$Mutation$DisableServiceFromJson(json); + factory Mutation$DisableService.fromJson(Map json) { + final l$disableService = json['disableService']; + final l$$__typename = json['__typename']; + return Mutation$DisableService( + disableService: Mutation$DisableService$disableService.fromJson( + (l$disableService as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$DisableService$disableService disableService; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$DisableServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$disableService = disableService; + _resultData['disableService'] = l$disableService.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$disableService = disableService; final l$$__typename = $__typename; - return Object.hashAll([l$disableService, l$$__typename]); + return Object.hashAll([ + l$disableService, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$DisableService) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$DisableService) || + runtimeType != other.runtimeType) { return false; + } final l$disableService = disableService; final lOther$disableService = other.disableService; - if (l$disableService != lOther$disableService) return false; + if (l$disableService != lOther$disableService) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$DisableService on Mutation$DisableService { CopyWith$Mutation$DisableService get copyWith => - CopyWith$Mutation$DisableService(this, (i) => i); + CopyWith$Mutation$DisableService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$DisableService { - factory CopyWith$Mutation$DisableService(Mutation$DisableService instance, - TRes Function(Mutation$DisableService) then) = - _CopyWithImpl$Mutation$DisableService; + factory CopyWith$Mutation$DisableService( + Mutation$DisableService instance, + TRes Function(Mutation$DisableService) then, + ) = _CopyWithImpl$Mutation$DisableService; factory CopyWith$Mutation$DisableService.stub(TRes res) = _CopyWithStubImpl$Mutation$DisableService; - TRes call( - {Mutation$DisableService$disableService? disableService, - String? $__typename}); + TRes call({ + Mutation$DisableService$disableService? disableService, + String? $__typename, + }); CopyWith$Mutation$DisableService$disableService get disableService; } class _CopyWithImpl$Mutation$DisableService implements CopyWith$Mutation$DisableService { - _CopyWithImpl$Mutation$DisableService(this._instance, this._then); + _CopyWithImpl$Mutation$DisableService( + this._instance, + this._then, + ); final Mutation$DisableService _instance; @@ -1706,16 +3912,18 @@ class _CopyWithImpl$Mutation$DisableService static const _undefined = {}; - TRes call( - {Object? disableService = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? disableService = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$DisableService( - disableService: disableService == _undefined || disableService == null - ? _instance.disableService - : (disableService as Mutation$DisableService$disableService), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + disableService: disableService == _undefined || disableService == null + ? _instance.disableService + : (disableService as Mutation$DisableService$disableService), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$DisableService$disableService get disableService { final local$disableService = _instance.disableService; return CopyWith$Mutation$DisableService$disableService( @@ -1729,9 +3937,10 @@ class _CopyWithStubImpl$Mutation$DisableService TRes _res; - call( - {Mutation$DisableService$disableService? disableService, - String? $__typename}) => + call({ + Mutation$DisableService$disableService? disableService, + String? $__typename, + }) => _res; CopyWith$Mutation$DisableService$disableService get disableService => CopyWith$Mutation$DisableService$disableService.stub(_res); @@ -1739,86 +3948,99 @@ class _CopyWithStubImpl$Mutation$DisableService const documentNodeMutationDisableService = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'DisableService'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'serviceId')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'disableService'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'serviceId'), - value: VariableNode(name: NameNode(value: 'serviceId'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'DisableService'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'serviceId')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'disableService'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'serviceId'), + value: VariableNode(name: NameNode(value: 'serviceId')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$DisableService _parserFn$Mutation$DisableService( Map data) => Mutation$DisableService.fromJson(data); typedef OnMutationCompleted$Mutation$DisableService = FutureOr Function( - dynamic, Mutation$DisableService?); + dynamic, + Mutation$DisableService?, +); class Options$Mutation$DisableService extends graphql.MutationOptions { - Options$Mutation$DisableService( - {String? operationName, - required Variables$Mutation$DisableService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$DisableService? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$DisableService({ + String? operationName, + required Variables$Mutation$DisableService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$DisableService? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$DisableService(data)), - update: update, - onError: onError, - document: documentNodeMutationDisableService, - parserFn: _parserFn$Mutation$DisableService); + : _parserFn$Mutation$DisableService(data), + ), + update: update, + onError: onError, + document: documentNodeMutationDisableService, + parserFn: _parserFn$Mutation$DisableService, + ); final OnMutationCompleted$Mutation$DisableService? onCompletedWithParsed; @@ -1827,38 +4049,39 @@ class Options$Mutation$DisableService ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$DisableService extends graphql.WatchQueryOptions { - WatchOptions$Mutation$DisableService( - {String? operationName, - required Variables$Mutation$DisableService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationDisableService, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$DisableService); + WatchOptions$Mutation$DisableService({ + String? operationName, + required Variables$Mutation$DisableService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationDisableService, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$DisableService, + ); } extension ClientExtension$Mutation$DisableService on graphql.GraphQLClient { @@ -1870,19 +4093,28 @@ extension ClientExtension$Mutation$DisableService on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$DisableService$disableService - implements Fragment$basicMutationReturnFields { - Mutation$DisableService$disableService( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$ServiceMutationReturn { + Mutation$DisableService$disableService({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$DisableService$disableService.fromJson( - Map json) => - _$Mutation$DisableService$disableServiceFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$DisableService$disableService( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -1890,36 +4122,64 @@ class Mutation$DisableService$disableService final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$DisableService$disableServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$DisableService$disableService) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1928,26 +4188,35 @@ extension UtilityExtension$Mutation$DisableService$disableService on Mutation$DisableService$disableService { CopyWith$Mutation$DisableService$disableService< Mutation$DisableService$disableService> - get copyWith => - CopyWith$Mutation$DisableService$disableService(this, (i) => i); + get copyWith => CopyWith$Mutation$DisableService$disableService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$DisableService$disableService { factory CopyWith$Mutation$DisableService$disableService( - Mutation$DisableService$disableService instance, - TRes Function(Mutation$DisableService$disableService) then) = - _CopyWithImpl$Mutation$DisableService$disableService; + Mutation$DisableService$disableService instance, + TRes Function(Mutation$DisableService$disableService) then, + ) = _CopyWithImpl$Mutation$DisableService$disableService; factory CopyWith$Mutation$DisableService$disableService.stub(TRes res) = _CopyWithStubImpl$Mutation$DisableService$disableService; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$DisableService$disableService implements CopyWith$Mutation$DisableService$disableService { _CopyWithImpl$Mutation$DisableService$disableService( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$DisableService$disableService _instance; @@ -1955,24 +4224,25 @@ class _CopyWithImpl$Mutation$DisableService$disableService static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$DisableService$disableService( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$DisableService$disableService @@ -1981,46 +4251,74 @@ class _CopyWithStubImpl$Mutation$DisableService$disableService TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$StopService { - Variables$Mutation$StopService({required this.serviceId}); + factory Variables$Mutation$StopService({required String serviceId}) => + Variables$Mutation$StopService._({ + r'serviceId': serviceId, + }); + + Variables$Mutation$StopService._(this._$data); + + factory Variables$Mutation$StopService.fromJson(Map data) { + final result$data = {}; + final l$serviceId = data['serviceId']; + result$data['serviceId'] = (l$serviceId as String); + return Variables$Mutation$StopService._(result$data); + } + + Map _$data; + + String get serviceId => (_$data['serviceId'] as String); + Map toJson() { + final result$data = {}; + final l$serviceId = serviceId; + result$data['serviceId'] = l$serviceId; + return result$data; + } + + CopyWith$Variables$Mutation$StopService + get copyWith => CopyWith$Variables$Mutation$StopService( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$StopService) || + runtimeType != other.runtimeType) { + return false; + } + final l$serviceId = serviceId; + final lOther$serviceId = other.serviceId; + if (l$serviceId != lOther$serviceId) { + return false; + } + return true; + } @override - factory Variables$Mutation$StopService.fromJson(Map json) => - _$Variables$Mutation$StopServiceFromJson(json); - - final String serviceId; - - Map toJson() => _$Variables$Mutation$StopServiceToJson(this); int get hashCode { final l$serviceId = serviceId; return Object.hashAll([l$serviceId]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$StopService) || - runtimeType != other.runtimeType) return false; - final l$serviceId = serviceId; - final lOther$serviceId = other.serviceId; - if (l$serviceId != lOther$serviceId) return false; - return true; - } - - CopyWith$Variables$Mutation$StopService - get copyWith => CopyWith$Variables$Mutation$StopService(this, (i) => i); } abstract class CopyWith$Variables$Mutation$StopService { factory CopyWith$Variables$Mutation$StopService( - Variables$Mutation$StopService instance, - TRes Function(Variables$Mutation$StopService) then) = - _CopyWithImpl$Variables$Mutation$StopService; + Variables$Mutation$StopService instance, + TRes Function(Variables$Mutation$StopService) then, + ) = _CopyWithImpl$Variables$Mutation$StopService; factory CopyWith$Variables$Mutation$StopService.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$StopService; @@ -2030,7 +4328,10 @@ abstract class CopyWith$Variables$Mutation$StopService { class _CopyWithImpl$Variables$Mutation$StopService implements CopyWith$Variables$Mutation$StopService { - _CopyWithImpl$Variables$Mutation$StopService(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$StopService( + this._instance, + this._then, + ); final Variables$Mutation$StopService _instance; @@ -2039,10 +4340,11 @@ class _CopyWithImpl$Variables$Mutation$StopService static const _undefined = {}; TRes call({Object? serviceId = _undefined}) => - _then(Variables$Mutation$StopService( - serviceId: serviceId == _undefined || serviceId == null - ? _instance.serviceId - : (serviceId as String))); + _then(Variables$Mutation$StopService._({ + ..._instance._$data, + if (serviceId != _undefined && serviceId != null) + 'serviceId': (serviceId as String), + })); } class _CopyWithStubImpl$Variables$Mutation$StopService @@ -2054,62 +4356,97 @@ class _CopyWithStubImpl$Variables$Mutation$StopService call({String? serviceId}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$StopService { - Mutation$StopService({required this.stopService, required this.$__typename}); + Mutation$StopService({ + required this.stopService, + required this.$__typename, + }); - @override - factory Mutation$StopService.fromJson(Map json) => - _$Mutation$StopServiceFromJson(json); + factory Mutation$StopService.fromJson(Map json) { + final l$stopService = json['stopService']; + final l$$__typename = json['__typename']; + return Mutation$StopService( + stopService: Mutation$StopService$stopService.fromJson( + (l$stopService as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$StopService$stopService stopService; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$StopServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$stopService = stopService; + _resultData['stopService'] = l$stopService.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$stopService = stopService; final l$$__typename = $__typename; - return Object.hashAll([l$stopService, l$$__typename]); + return Object.hashAll([ + l$stopService, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$StopService) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$StopService) || runtimeType != other.runtimeType) { return false; + } final l$stopService = stopService; final lOther$stopService = other.stopService; - if (l$stopService != lOther$stopService) return false; + if (l$stopService != lOther$stopService) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$StopService on Mutation$StopService { CopyWith$Mutation$StopService get copyWith => - CopyWith$Mutation$StopService(this, (i) => i); + CopyWith$Mutation$StopService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$StopService { - factory CopyWith$Mutation$StopService(Mutation$StopService instance, - TRes Function(Mutation$StopService) then) = - _CopyWithImpl$Mutation$StopService; + factory CopyWith$Mutation$StopService( + Mutation$StopService instance, + TRes Function(Mutation$StopService) then, + ) = _CopyWithImpl$Mutation$StopService; factory CopyWith$Mutation$StopService.stub(TRes res) = _CopyWithStubImpl$Mutation$StopService; - TRes call( - {Mutation$StopService$stopService? stopService, String? $__typename}); + TRes call({ + Mutation$StopService$stopService? stopService, + String? $__typename, + }); CopyWith$Mutation$StopService$stopService get stopService; } class _CopyWithImpl$Mutation$StopService implements CopyWith$Mutation$StopService { - _CopyWithImpl$Mutation$StopService(this._instance, this._then); + _CopyWithImpl$Mutation$StopService( + this._instance, + this._then, + ); final Mutation$StopService _instance; @@ -2117,16 +4454,18 @@ class _CopyWithImpl$Mutation$StopService static const _undefined = {}; - TRes call( - {Object? stopService = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? stopService = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$StopService( - stopService: stopService == _undefined || stopService == null - ? _instance.stopService - : (stopService as Mutation$StopService$stopService), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + stopService: stopService == _undefined || stopService == null + ? _instance.stopService + : (stopService as Mutation$StopService$stopService), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$StopService$stopService get stopService { final local$stopService = _instance.stopService; return CopyWith$Mutation$StopService$stopService( @@ -2140,7 +4479,10 @@ class _CopyWithStubImpl$Mutation$StopService TRes _res; - call({Mutation$StopService$stopService? stopService, String? $__typename}) => + call({ + Mutation$StopService$stopService? stopService, + String? $__typename, + }) => _res; CopyWith$Mutation$StopService$stopService get stopService => CopyWith$Mutation$StopService$stopService.stub(_res); @@ -2148,83 +4490,97 @@ class _CopyWithStubImpl$Mutation$StopService const documentNodeMutationStopService = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'StopService'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'serviceId')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'stopService'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'serviceId'), - value: VariableNode(name: NameNode(value: 'serviceId'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'StopService'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'serviceId')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'stopService'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'serviceId'), + value: VariableNode(name: NameNode(value: 'serviceId')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$StopService _parserFn$Mutation$StopService( Map data) => Mutation$StopService.fromJson(data); typedef OnMutationCompleted$Mutation$StopService = FutureOr Function( - dynamic, Mutation$StopService?); + dynamic, + Mutation$StopService?, +); class Options$Mutation$StopService extends graphql.MutationOptions { - Options$Mutation$StopService( - {String? operationName, - required Variables$Mutation$StopService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$StopService? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$StopService({ + String? operationName, + required Variables$Mutation$StopService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$StopService? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted(data, - data == null ? null : _parserFn$Mutation$StopService(data)), - update: update, - onError: onError, - document: documentNodeMutationStopService, - parserFn: _parserFn$Mutation$StopService); + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( + data, + data == null ? null : _parserFn$Mutation$StopService(data), + ), + update: update, + onError: onError, + document: documentNodeMutationStopService, + parserFn: _parserFn$Mutation$StopService, + ); final OnMutationCompleted$Mutation$StopService? onCompletedWithParsed; @@ -2233,38 +4589,39 @@ class Options$Mutation$StopService ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$StopService extends graphql.WatchQueryOptions { - WatchOptions$Mutation$StopService( - {String? operationName, - required Variables$Mutation$StopService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationStopService, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$StopService); + WatchOptions$Mutation$StopService({ + String? operationName, + required Variables$Mutation$StopService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationStopService, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$StopService, + ); } extension ClientExtension$Mutation$StopService on graphql.GraphQLClient { @@ -2276,19 +4633,27 @@ extension ClientExtension$Mutation$StopService on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$StopService$stopService - implements Fragment$basicMutationReturnFields { - Mutation$StopService$stopService( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$ServiceMutationReturn { + Mutation$StopService$stopService({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override - factory Mutation$StopService$stopService.fromJson( - Map json) => - _$Mutation$StopService$stopServiceFromJson(json); + factory Mutation$StopService$stopService.fromJson(Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$StopService$stopService( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -2296,36 +4661,64 @@ class Mutation$StopService$stopService final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$StopService$stopServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$StopService$stopService) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2333,24 +4726,35 @@ class Mutation$StopService$stopService extension UtilityExtension$Mutation$StopService$stopService on Mutation$StopService$stopService { CopyWith$Mutation$StopService$stopService - get copyWith => CopyWith$Mutation$StopService$stopService(this, (i) => i); + get copyWith => CopyWith$Mutation$StopService$stopService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$StopService$stopService { factory CopyWith$Mutation$StopService$stopService( - Mutation$StopService$stopService instance, - TRes Function(Mutation$StopService$stopService) then) = - _CopyWithImpl$Mutation$StopService$stopService; + Mutation$StopService$stopService instance, + TRes Function(Mutation$StopService$stopService) then, + ) = _CopyWithImpl$Mutation$StopService$stopService; factory CopyWith$Mutation$StopService$stopService.stub(TRes res) = _CopyWithStubImpl$Mutation$StopService$stopService; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$StopService$stopService implements CopyWith$Mutation$StopService$stopService { - _CopyWithImpl$Mutation$StopService$stopService(this._instance, this._then); + _CopyWithImpl$Mutation$StopService$stopService( + this._instance, + this._then, + ); final Mutation$StopService$stopService _instance; @@ -2358,24 +4762,25 @@ class _CopyWithImpl$Mutation$StopService$stopService static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$StopService$stopService( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$StopService$stopService @@ -2384,47 +4789,74 @@ class _CopyWithStubImpl$Mutation$StopService$stopService TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$StartService { - Variables$Mutation$StartService({required this.serviceId}); + factory Variables$Mutation$StartService({required String serviceId}) => + Variables$Mutation$StartService._({ + r'serviceId': serviceId, + }); + + Variables$Mutation$StartService._(this._$data); + + factory Variables$Mutation$StartService.fromJson(Map data) { + final result$data = {}; + final l$serviceId = data['serviceId']; + result$data['serviceId'] = (l$serviceId as String); + return Variables$Mutation$StartService._(result$data); + } + + Map _$data; + + String get serviceId => (_$data['serviceId'] as String); + Map toJson() { + final result$data = {}; + final l$serviceId = serviceId; + result$data['serviceId'] = l$serviceId; + return result$data; + } + + CopyWith$Variables$Mutation$StartService + get copyWith => CopyWith$Variables$Mutation$StartService( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$StartService) || + runtimeType != other.runtimeType) { + return false; + } + final l$serviceId = serviceId; + final lOther$serviceId = other.serviceId; + if (l$serviceId != lOther$serviceId) { + return false; + } + return true; + } @override - factory Variables$Mutation$StartService.fromJson(Map json) => - _$Variables$Mutation$StartServiceFromJson(json); - - final String serviceId; - - Map toJson() => - _$Variables$Mutation$StartServiceToJson(this); int get hashCode { final l$serviceId = serviceId; return Object.hashAll([l$serviceId]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$StartService) || - runtimeType != other.runtimeType) return false; - final l$serviceId = serviceId; - final lOther$serviceId = other.serviceId; - if (l$serviceId != lOther$serviceId) return false; - return true; - } - - CopyWith$Variables$Mutation$StartService - get copyWith => CopyWith$Variables$Mutation$StartService(this, (i) => i); } abstract class CopyWith$Variables$Mutation$StartService { factory CopyWith$Variables$Mutation$StartService( - Variables$Mutation$StartService instance, - TRes Function(Variables$Mutation$StartService) then) = - _CopyWithImpl$Variables$Mutation$StartService; + Variables$Mutation$StartService instance, + TRes Function(Variables$Mutation$StartService) then, + ) = _CopyWithImpl$Variables$Mutation$StartService; factory CopyWith$Variables$Mutation$StartService.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$StartService; @@ -2434,7 +4866,10 @@ abstract class CopyWith$Variables$Mutation$StartService { class _CopyWithImpl$Variables$Mutation$StartService implements CopyWith$Variables$Mutation$StartService { - _CopyWithImpl$Variables$Mutation$StartService(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$StartService( + this._instance, + this._then, + ); final Variables$Mutation$StartService _instance; @@ -2443,10 +4878,11 @@ class _CopyWithImpl$Variables$Mutation$StartService static const _undefined = {}; TRes call({Object? serviceId = _undefined}) => - _then(Variables$Mutation$StartService( - serviceId: serviceId == _undefined || serviceId == null - ? _instance.serviceId - : (serviceId as String))); + _then(Variables$Mutation$StartService._({ + ..._instance._$data, + if (serviceId != _undefined && serviceId != null) + 'serviceId': (serviceId as String), + })); } class _CopyWithStubImpl$Variables$Mutation$StartService @@ -2458,63 +4894,97 @@ class _CopyWithStubImpl$Variables$Mutation$StartService call({String? serviceId}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$StartService { - Mutation$StartService( - {required this.startService, required this.$__typename}); + Mutation$StartService({ + required this.startService, + required this.$__typename, + }); - @override - factory Mutation$StartService.fromJson(Map json) => - _$Mutation$StartServiceFromJson(json); + factory Mutation$StartService.fromJson(Map json) { + final l$startService = json['startService']; + final l$$__typename = json['__typename']; + return Mutation$StartService( + startService: Mutation$StartService$startService.fromJson( + (l$startService as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$StartService$startService startService; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$StartServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$startService = startService; + _resultData['startService'] = l$startService.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$startService = startService; final l$$__typename = $__typename; - return Object.hashAll([l$startService, l$$__typename]); + return Object.hashAll([ + l$startService, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$StartService) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$StartService) || runtimeType != other.runtimeType) { return false; + } final l$startService = startService; final lOther$startService = other.startService; - if (l$startService != lOther$startService) return false; + if (l$startService != lOther$startService) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$StartService on Mutation$StartService { CopyWith$Mutation$StartService get copyWith => - CopyWith$Mutation$StartService(this, (i) => i); + CopyWith$Mutation$StartService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$StartService { - factory CopyWith$Mutation$StartService(Mutation$StartService instance, - TRes Function(Mutation$StartService) then) = - _CopyWithImpl$Mutation$StartService; + factory CopyWith$Mutation$StartService( + Mutation$StartService instance, + TRes Function(Mutation$StartService) then, + ) = _CopyWithImpl$Mutation$StartService; factory CopyWith$Mutation$StartService.stub(TRes res) = _CopyWithStubImpl$Mutation$StartService; - TRes call( - {Mutation$StartService$startService? startService, String? $__typename}); + TRes call({ + Mutation$StartService$startService? startService, + String? $__typename, + }); CopyWith$Mutation$StartService$startService get startService; } class _CopyWithImpl$Mutation$StartService implements CopyWith$Mutation$StartService { - _CopyWithImpl$Mutation$StartService(this._instance, this._then); + _CopyWithImpl$Mutation$StartService( + this._instance, + this._then, + ); final Mutation$StartService _instance; @@ -2522,16 +4992,18 @@ class _CopyWithImpl$Mutation$StartService static const _undefined = {}; - TRes call( - {Object? startService = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? startService = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$StartService( - startService: startService == _undefined || startService == null - ? _instance.startService - : (startService as Mutation$StartService$startService), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + startService: startService == _undefined || startService == null + ? _instance.startService + : (startService as Mutation$StartService$startService), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$StartService$startService get startService { final local$startService = _instance.startService; return CopyWith$Mutation$StartService$startService( @@ -2545,9 +5017,10 @@ class _CopyWithStubImpl$Mutation$StartService TRes _res; - call( - {Mutation$StartService$startService? startService, - String? $__typename}) => + call({ + Mutation$StartService$startService? startService, + String? $__typename, + }) => _res; CopyWith$Mutation$StartService$startService get startService => CopyWith$Mutation$StartService$startService.stub(_res); @@ -2555,86 +5028,97 @@ class _CopyWithStubImpl$Mutation$StartService const documentNodeMutationStartService = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'StartService'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'serviceId')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'startService'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'serviceId'), - value: VariableNode(name: NameNode(value: 'serviceId'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'StartService'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'serviceId')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'startService'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'serviceId'), + value: VariableNode(name: NameNode(value: 'serviceId')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$StartService _parserFn$Mutation$StartService( Map data) => Mutation$StartService.fromJson(data); typedef OnMutationCompleted$Mutation$StartService = FutureOr Function( - dynamic, Mutation$StartService?); + dynamic, + Mutation$StartService?, +); class Options$Mutation$StartService extends graphql.MutationOptions { - Options$Mutation$StartService( - {String? operationName, - required Variables$Mutation$StartService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$StartService? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$StartService({ + String? operationName, + required Variables$Mutation$StartService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$StartService? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, - data == null - ? null - : _parserFn$Mutation$StartService(data)), - update: update, - onError: onError, - document: documentNodeMutationStartService, - parserFn: _parserFn$Mutation$StartService); + data == null ? null : _parserFn$Mutation$StartService(data), + ), + update: update, + onError: onError, + document: documentNodeMutationStartService, + parserFn: _parserFn$Mutation$StartService, + ); final OnMutationCompleted$Mutation$StartService? onCompletedWithParsed; @@ -2643,38 +5127,39 @@ class Options$Mutation$StartService ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$StartService extends graphql.WatchQueryOptions { - WatchOptions$Mutation$StartService( - {String? operationName, - required Variables$Mutation$StartService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationStartService, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$StartService); + WatchOptions$Mutation$StartService({ + String? operationName, + required Variables$Mutation$StartService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationStartService, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$StartService, + ); } extension ClientExtension$Mutation$StartService on graphql.GraphQLClient { @@ -2686,19 +5171,28 @@ extension ClientExtension$Mutation$StartService on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$StartService$startService - implements Fragment$basicMutationReturnFields { - Mutation$StartService$startService( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$ServiceMutationReturn { + Mutation$StartService$startService({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$StartService$startService.fromJson( - Map json) => - _$Mutation$StartService$startServiceFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$StartService$startService( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -2706,36 +5200,64 @@ class Mutation$StartService$startService final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$StartService$startServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$StartService$startService) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -2744,25 +5266,35 @@ extension UtilityExtension$Mutation$StartService$startService on Mutation$StartService$startService { CopyWith$Mutation$StartService$startService< Mutation$StartService$startService> - get copyWith => - CopyWith$Mutation$StartService$startService(this, (i) => i); + get copyWith => CopyWith$Mutation$StartService$startService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$StartService$startService { factory CopyWith$Mutation$StartService$startService( - Mutation$StartService$startService instance, - TRes Function(Mutation$StartService$startService) then) = - _CopyWithImpl$Mutation$StartService$startService; + Mutation$StartService$startService instance, + TRes Function(Mutation$StartService$startService) then, + ) = _CopyWithImpl$Mutation$StartService$startService; factory CopyWith$Mutation$StartService$startService.stub(TRes res) = _CopyWithStubImpl$Mutation$StartService$startService; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$StartService$startService implements CopyWith$Mutation$StartService$startService { - _CopyWithImpl$Mutation$StartService$startService(this._instance, this._then); + _CopyWithImpl$Mutation$StartService$startService( + this._instance, + this._then, + ); final Mutation$StartService$startService _instance; @@ -2770,24 +5302,25 @@ class _CopyWithImpl$Mutation$StartService$startService static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$StartService$startService( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$StartService$startService @@ -2796,49 +5329,75 @@ class _CopyWithStubImpl$Mutation$StartService$startService TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$RestartService { - Variables$Mutation$RestartService({required this.serviceId}); + factory Variables$Mutation$RestartService({required String serviceId}) => + Variables$Mutation$RestartService._({ + r'serviceId': serviceId, + }); + + Variables$Mutation$RestartService._(this._$data); + + factory Variables$Mutation$RestartService.fromJson( + Map data) { + final result$data = {}; + final l$serviceId = data['serviceId']; + result$data['serviceId'] = (l$serviceId as String); + return Variables$Mutation$RestartService._(result$data); + } + + Map _$data; + + String get serviceId => (_$data['serviceId'] as String); + Map toJson() { + final result$data = {}; + final l$serviceId = serviceId; + result$data['serviceId'] = l$serviceId; + return result$data; + } + + CopyWith$Variables$Mutation$RestartService + get copyWith => CopyWith$Variables$Mutation$RestartService( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$RestartService) || + runtimeType != other.runtimeType) { + return false; + } + final l$serviceId = serviceId; + final lOther$serviceId = other.serviceId; + if (l$serviceId != lOther$serviceId) { + return false; + } + return true; + } @override - factory Variables$Mutation$RestartService.fromJson( - Map json) => - _$Variables$Mutation$RestartServiceFromJson(json); - - final String serviceId; - - Map toJson() => - _$Variables$Mutation$RestartServiceToJson(this); int get hashCode { final l$serviceId = serviceId; return Object.hashAll([l$serviceId]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$RestartService) || - runtimeType != other.runtimeType) return false; - final l$serviceId = serviceId; - final lOther$serviceId = other.serviceId; - if (l$serviceId != lOther$serviceId) return false; - return true; - } - - CopyWith$Variables$Mutation$RestartService - get copyWith => - CopyWith$Variables$Mutation$RestartService(this, (i) => i); } abstract class CopyWith$Variables$Mutation$RestartService { factory CopyWith$Variables$Mutation$RestartService( - Variables$Mutation$RestartService instance, - TRes Function(Variables$Mutation$RestartService) then) = - _CopyWithImpl$Variables$Mutation$RestartService; + Variables$Mutation$RestartService instance, + TRes Function(Variables$Mutation$RestartService) then, + ) = _CopyWithImpl$Variables$Mutation$RestartService; factory CopyWith$Variables$Mutation$RestartService.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$RestartService; @@ -2848,7 +5407,10 @@ abstract class CopyWith$Variables$Mutation$RestartService { class _CopyWithImpl$Variables$Mutation$RestartService implements CopyWith$Variables$Mutation$RestartService { - _CopyWithImpl$Variables$Mutation$RestartService(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$RestartService( + this._instance, + this._then, + ); final Variables$Mutation$RestartService _instance; @@ -2857,10 +5419,11 @@ class _CopyWithImpl$Variables$Mutation$RestartService static const _undefined = {}; TRes call({Object? serviceId = _undefined}) => - _then(Variables$Mutation$RestartService( - serviceId: serviceId == _undefined || serviceId == null - ? _instance.serviceId - : (serviceId as String))); + _then(Variables$Mutation$RestartService._({ + ..._instance._$data, + if (serviceId != _undefined && serviceId != null) + 'serviceId': (serviceId as String), + })); } class _CopyWithStubImpl$Variables$Mutation$RestartService @@ -2872,64 +5435,98 @@ class _CopyWithStubImpl$Variables$Mutation$RestartService call({String? serviceId}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$RestartService { - Mutation$RestartService( - {required this.restartService, required this.$__typename}); + Mutation$RestartService({ + required this.restartService, + required this.$__typename, + }); - @override - factory Mutation$RestartService.fromJson(Map json) => - _$Mutation$RestartServiceFromJson(json); + factory Mutation$RestartService.fromJson(Map json) { + final l$restartService = json['restartService']; + final l$$__typename = json['__typename']; + return Mutation$RestartService( + restartService: Mutation$RestartService$restartService.fromJson( + (l$restartService as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$RestartService$restartService restartService; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RestartServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$restartService = restartService; + _resultData['restartService'] = l$restartService.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$restartService = restartService; final l$$__typename = $__typename; - return Object.hashAll([l$restartService, l$$__typename]); + return Object.hashAll([ + l$restartService, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$RestartService) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$RestartService) || + runtimeType != other.runtimeType) { return false; + } final l$restartService = restartService; final lOther$restartService = other.restartService; - if (l$restartService != lOther$restartService) return false; + if (l$restartService != lOther$restartService) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$RestartService on Mutation$RestartService { CopyWith$Mutation$RestartService get copyWith => - CopyWith$Mutation$RestartService(this, (i) => i); + CopyWith$Mutation$RestartService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RestartService { - factory CopyWith$Mutation$RestartService(Mutation$RestartService instance, - TRes Function(Mutation$RestartService) then) = - _CopyWithImpl$Mutation$RestartService; + factory CopyWith$Mutation$RestartService( + Mutation$RestartService instance, + TRes Function(Mutation$RestartService) then, + ) = _CopyWithImpl$Mutation$RestartService; factory CopyWith$Mutation$RestartService.stub(TRes res) = _CopyWithStubImpl$Mutation$RestartService; - TRes call( - {Mutation$RestartService$restartService? restartService, - String? $__typename}); + TRes call({ + Mutation$RestartService$restartService? restartService, + String? $__typename, + }); CopyWith$Mutation$RestartService$restartService get restartService; } class _CopyWithImpl$Mutation$RestartService implements CopyWith$Mutation$RestartService { - _CopyWithImpl$Mutation$RestartService(this._instance, this._then); + _CopyWithImpl$Mutation$RestartService( + this._instance, + this._then, + ); final Mutation$RestartService _instance; @@ -2937,16 +5534,18 @@ class _CopyWithImpl$Mutation$RestartService static const _undefined = {}; - TRes call( - {Object? restartService = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? restartService = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RestartService( - restartService: restartService == _undefined || restartService == null - ? _instance.restartService - : (restartService as Mutation$RestartService$restartService), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + restartService: restartService == _undefined || restartService == null + ? _instance.restartService + : (restartService as Mutation$RestartService$restartService), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$RestartService$restartService get restartService { final local$restartService = _instance.restartService; return CopyWith$Mutation$RestartService$restartService( @@ -2960,9 +5559,10 @@ class _CopyWithStubImpl$Mutation$RestartService TRes _res; - call( - {Mutation$RestartService$restartService? restartService, - String? $__typename}) => + call({ + Mutation$RestartService$restartService? restartService, + String? $__typename, + }) => _res; CopyWith$Mutation$RestartService$restartService get restartService => CopyWith$Mutation$RestartService$restartService.stub(_res); @@ -2970,86 +5570,99 @@ class _CopyWithStubImpl$Mutation$RestartService const documentNodeMutationRestartService = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'RestartService'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'serviceId')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'restartService'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'serviceId'), - value: VariableNode(name: NameNode(value: 'serviceId'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'RestartService'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'serviceId')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'restartService'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'serviceId'), + value: VariableNode(name: NameNode(value: 'serviceId')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$RestartService _parserFn$Mutation$RestartService( Map data) => Mutation$RestartService.fromJson(data); typedef OnMutationCompleted$Mutation$RestartService = FutureOr Function( - dynamic, Mutation$RestartService?); + dynamic, + Mutation$RestartService?, +); class Options$Mutation$RestartService extends graphql.MutationOptions { - Options$Mutation$RestartService( - {String? operationName, - required Variables$Mutation$RestartService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$RestartService? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$RestartService({ + String? operationName, + required Variables$Mutation$RestartService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$RestartService? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, data == null ? null - : _parserFn$Mutation$RestartService(data)), - update: update, - onError: onError, - document: documentNodeMutationRestartService, - parserFn: _parserFn$Mutation$RestartService); + : _parserFn$Mutation$RestartService(data), + ), + update: update, + onError: onError, + document: documentNodeMutationRestartService, + parserFn: _parserFn$Mutation$RestartService, + ); final OnMutationCompleted$Mutation$RestartService? onCompletedWithParsed; @@ -3058,38 +5671,39 @@ class Options$Mutation$RestartService ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$RestartService extends graphql.WatchQueryOptions { - WatchOptions$Mutation$RestartService( - {String? operationName, - required Variables$Mutation$RestartService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationRestartService, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$RestartService); + WatchOptions$Mutation$RestartService({ + String? operationName, + required Variables$Mutation$RestartService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationRestartService, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$RestartService, + ); } extension ClientExtension$Mutation$RestartService on graphql.GraphQLClient { @@ -3101,19 +5715,28 @@ extension ClientExtension$Mutation$RestartService on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$RestartService$restartService - implements Fragment$basicMutationReturnFields { - Mutation$RestartService$restartService( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$ServiceMutationReturn { + Mutation$RestartService$restartService({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Mutation$RestartService$restartService.fromJson( - Map json) => - _$Mutation$RestartService$restartServiceFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$RestartService$restartService( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -3121,36 +5744,64 @@ class Mutation$RestartService$restartService final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$RestartService$restartServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RestartService$restartService) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -3159,26 +5810,35 @@ extension UtilityExtension$Mutation$RestartService$restartService on Mutation$RestartService$restartService { CopyWith$Mutation$RestartService$restartService< Mutation$RestartService$restartService> - get copyWith => - CopyWith$Mutation$RestartService$restartService(this, (i) => i); + get copyWith => CopyWith$Mutation$RestartService$restartService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RestartService$restartService { factory CopyWith$Mutation$RestartService$restartService( - Mutation$RestartService$restartService instance, - TRes Function(Mutation$RestartService$restartService) then) = - _CopyWithImpl$Mutation$RestartService$restartService; + Mutation$RestartService$restartService instance, + TRes Function(Mutation$RestartService$restartService) then, + ) = _CopyWithImpl$Mutation$RestartService$restartService; factory CopyWith$Mutation$RestartService$restartService.stub(TRes res) = _CopyWithStubImpl$Mutation$RestartService$restartService; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$RestartService$restartService implements CopyWith$Mutation$RestartService$restartService { _CopyWithImpl$Mutation$RestartService$restartService( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$RestartService$restartService _instance; @@ -3186,24 +5846,25 @@ class _CopyWithImpl$Mutation$RestartService$restartService static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RestartService$restartService( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$RestartService$restartService @@ -3212,46 +5873,77 @@ class _CopyWithStubImpl$Mutation$RestartService$restartService TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$MoveService { - Variables$Mutation$MoveService({required this.input}); + factory Variables$Mutation$MoveService( + {required Input$MoveServiceInput input}) => + Variables$Mutation$MoveService._({ + r'input': input, + }); + + Variables$Mutation$MoveService._(this._$data); + + factory Variables$Mutation$MoveService.fromJson(Map data) { + final result$data = {}; + final l$input = data['input']; + result$data['input'] = + Input$MoveServiceInput.fromJson((l$input as Map)); + return Variables$Mutation$MoveService._(result$data); + } + + Map _$data; + + Input$MoveServiceInput get input => + (_$data['input'] as Input$MoveServiceInput); + Map toJson() { + final result$data = {}; + final l$input = input; + result$data['input'] = l$input.toJson(); + return result$data; + } + + CopyWith$Variables$Mutation$MoveService + get copyWith => CopyWith$Variables$Mutation$MoveService( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$MoveService) || + runtimeType != other.runtimeType) { + return false; + } + final l$input = input; + final lOther$input = other.input; + if (l$input != lOther$input) { + return false; + } + return true; + } @override - factory Variables$Mutation$MoveService.fromJson(Map json) => - _$Variables$Mutation$MoveServiceFromJson(json); - - final Input$MoveServiceInput input; - - Map toJson() => _$Variables$Mutation$MoveServiceToJson(this); int get hashCode { final l$input = input; return Object.hashAll([l$input]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$MoveService) || - runtimeType != other.runtimeType) return false; - final l$input = input; - final lOther$input = other.input; - if (l$input != lOther$input) return false; - return true; - } - - CopyWith$Variables$Mutation$MoveService - get copyWith => CopyWith$Variables$Mutation$MoveService(this, (i) => i); } abstract class CopyWith$Variables$Mutation$MoveService { factory CopyWith$Variables$Mutation$MoveService( - Variables$Mutation$MoveService instance, - TRes Function(Variables$Mutation$MoveService) then) = - _CopyWithImpl$Variables$Mutation$MoveService; + Variables$Mutation$MoveService instance, + TRes Function(Variables$Mutation$MoveService) then, + ) = _CopyWithImpl$Variables$Mutation$MoveService; factory CopyWith$Variables$Mutation$MoveService.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$MoveService; @@ -3261,7 +5953,10 @@ abstract class CopyWith$Variables$Mutation$MoveService { class _CopyWithImpl$Variables$Mutation$MoveService implements CopyWith$Variables$Mutation$MoveService { - _CopyWithImpl$Variables$Mutation$MoveService(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$MoveService( + this._instance, + this._then, + ); final Variables$Mutation$MoveService _instance; @@ -3270,10 +5965,11 @@ class _CopyWithImpl$Variables$Mutation$MoveService static const _undefined = {}; TRes call({Object? input = _undefined}) => - _then(Variables$Mutation$MoveService( - input: input == _undefined || input == null - ? _instance.input - : (input as Input$MoveServiceInput))); + _then(Variables$Mutation$MoveService._({ + ..._instance._$data, + if (input != _undefined && input != null) + 'input': (input as Input$MoveServiceInput), + })); } class _CopyWithStubImpl$Variables$Mutation$MoveService @@ -3285,62 +5981,97 @@ class _CopyWithStubImpl$Variables$Mutation$MoveService call({Input$MoveServiceInput? input}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$MoveService { - Mutation$MoveService({required this.moveService, required this.$__typename}); + Mutation$MoveService({ + required this.moveService, + required this.$__typename, + }); - @override - factory Mutation$MoveService.fromJson(Map json) => - _$Mutation$MoveServiceFromJson(json); + factory Mutation$MoveService.fromJson(Map json) { + final l$moveService = json['moveService']; + final l$$__typename = json['__typename']; + return Mutation$MoveService( + moveService: Mutation$MoveService$moveService.fromJson( + (l$moveService as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$MoveService$moveService moveService; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$MoveServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$moveService = moveService; + _resultData['moveService'] = l$moveService.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$moveService = moveService; final l$$__typename = $__typename; - return Object.hashAll([l$moveService, l$$__typename]); + return Object.hashAll([ + l$moveService, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$MoveService) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$MoveService) || runtimeType != other.runtimeType) { return false; + } final l$moveService = moveService; final lOther$moveService = other.moveService; - if (l$moveService != lOther$moveService) return false; + if (l$moveService != lOther$moveService) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$MoveService on Mutation$MoveService { CopyWith$Mutation$MoveService get copyWith => - CopyWith$Mutation$MoveService(this, (i) => i); + CopyWith$Mutation$MoveService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$MoveService { - factory CopyWith$Mutation$MoveService(Mutation$MoveService instance, - TRes Function(Mutation$MoveService) then) = - _CopyWithImpl$Mutation$MoveService; + factory CopyWith$Mutation$MoveService( + Mutation$MoveService instance, + TRes Function(Mutation$MoveService) then, + ) = _CopyWithImpl$Mutation$MoveService; factory CopyWith$Mutation$MoveService.stub(TRes res) = _CopyWithStubImpl$Mutation$MoveService; - TRes call( - {Mutation$MoveService$moveService? moveService, String? $__typename}); + TRes call({ + Mutation$MoveService$moveService? moveService, + String? $__typename, + }); CopyWith$Mutation$MoveService$moveService get moveService; } class _CopyWithImpl$Mutation$MoveService implements CopyWith$Mutation$MoveService { - _CopyWithImpl$Mutation$MoveService(this._instance, this._then); + _CopyWithImpl$Mutation$MoveService( + this._instance, + this._then, + ); final Mutation$MoveService _instance; @@ -3348,16 +6079,18 @@ class _CopyWithImpl$Mutation$MoveService static const _undefined = {}; - TRes call( - {Object? moveService = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? moveService = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$MoveService( - moveService: moveService == _undefined || moveService == null - ? _instance.moveService - : (moveService as Mutation$MoveService$moveService), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + moveService: moveService == _undefined || moveService == null + ? _instance.moveService + : (moveService as Mutation$MoveService$moveService), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$MoveService$moveService get moveService { final local$moveService = _instance.moveService; return CopyWith$Mutation$MoveService$moveService( @@ -3371,7 +6104,10 @@ class _CopyWithStubImpl$Mutation$MoveService TRes _res; - call({Mutation$MoveService$moveService? moveService, String? $__typename}) => + call({ + Mutation$MoveService$moveService? moveService, + String? $__typename, + }) => _res; CopyWith$Mutation$MoveService$moveService get moveService => CopyWith$Mutation$MoveService$moveService.stub(_res); @@ -3379,162 +6115,189 @@ class _CopyWithStubImpl$Mutation$MoveService const documentNodeMutationMoveService = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'MoveService'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'input')), - type: NamedTypeNode( - name: NameNode(value: 'MoveServiceInput'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'moveService'), + type: OperationType.mutation, + name: NameNode(value: 'MoveService'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'input')), + type: NamedTypeNode( + name: NameNode(value: 'MoveServiceInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'moveService'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'input'), + value: VariableNode(name: NameNode(value: 'input')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: 'job'), alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'input'), - value: VariableNode(name: NameNode(value: 'input'))) - ], + arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), FieldNode( - name: NameNode(value: 'job'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'createdAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'description'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'error'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'finishedAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'name'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'progress'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'result'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'status'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'statusText'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'uid'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'updatedAt'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: 'createdAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: 'description'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'error'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'finishedAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'name'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'progress'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'result'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'status'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'statusText'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'uid'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'updatedAt'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$MoveService _parserFn$Mutation$MoveService( Map data) => Mutation$MoveService.fromJson(data); typedef OnMutationCompleted$Mutation$MoveService = FutureOr Function( - dynamic, Mutation$MoveService?); + dynamic, + Mutation$MoveService?, +); class Options$Mutation$MoveService extends graphql.MutationOptions { - Options$Mutation$MoveService( - {String? operationName, - required Variables$Mutation$MoveService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$MoveService? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$MoveService({ + String? operationName, + required Variables$Mutation$MoveService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$MoveService? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted(data, - data == null ? null : _parserFn$Mutation$MoveService(data)), - update: update, - onError: onError, - document: documentNodeMutationMoveService, - parserFn: _parserFn$Mutation$MoveService); + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( + data, + data == null ? null : _parserFn$Mutation$MoveService(data), + ), + update: update, + onError: onError, + document: documentNodeMutationMoveService, + parserFn: _parserFn$Mutation$MoveService, + ); final OnMutationCompleted$Mutation$MoveService? onCompletedWithParsed; @@ -3543,38 +6306,39 @@ class Options$Mutation$MoveService ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$MoveService extends graphql.WatchQueryOptions { - WatchOptions$Mutation$MoveService( - {String? operationName, - required Variables$Mutation$MoveService variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationMoveService, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$MoveService); + WatchOptions$Mutation$MoveService({ + String? operationName, + required Variables$Mutation$MoveService variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationMoveService, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$MoveService, + ); } extension ClientExtension$Mutation$MoveService on graphql.GraphQLClient { @@ -3586,20 +6350,33 @@ extension ClientExtension$Mutation$MoveService on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$MoveService$moveService - implements Fragment$basicMutationReturnFields { - Mutation$MoveService$moveService( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.job}); + implements Fragment$basicMutationReturnFields$$ServiceJobMutationReturn { + Mutation$MoveService$moveService({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.job, + }); - @override - factory Mutation$MoveService$moveService.fromJson( - Map json) => - _$Mutation$MoveService$moveServiceFromJson(json); + factory Mutation$MoveService$moveService.fromJson(Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$job = json['job']; + return Mutation$MoveService$moveService( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + job: l$job == null + ? null + : Mutation$MoveService$moveService$job.fromJson( + (l$job as Map)), + ); + } final int code; @@ -3607,42 +6384,75 @@ class Mutation$MoveService$moveService final bool success; - @JsonKey(name: '__typename') final String $__typename; final Mutation$MoveService$moveService$job? job; - Map toJson() => - _$Mutation$MoveService$moveServiceToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$job = job; + _resultData['job'] = l$job?.toJson(); + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$job = job; - return Object.hashAll([l$code, l$message, l$success, l$$__typename, l$job]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$job, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$MoveService$moveService) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$job = job; final lOther$job = other.job; - if (l$job != lOther$job) return false; + if (l$job != lOther$job) { + return false; + } return true; } } @@ -3650,30 +6460,37 @@ class Mutation$MoveService$moveService extension UtilityExtension$Mutation$MoveService$moveService on Mutation$MoveService$moveService { CopyWith$Mutation$MoveService$moveService - get copyWith => CopyWith$Mutation$MoveService$moveService(this, (i) => i); + get copyWith => CopyWith$Mutation$MoveService$moveService( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$MoveService$moveService { factory CopyWith$Mutation$MoveService$moveService( - Mutation$MoveService$moveService instance, - TRes Function(Mutation$MoveService$moveService) then) = - _CopyWithImpl$Mutation$MoveService$moveService; + Mutation$MoveService$moveService instance, + TRes Function(Mutation$MoveService$moveService) then, + ) = _CopyWithImpl$Mutation$MoveService$moveService; factory CopyWith$Mutation$MoveService$moveService.stub(TRes res) = _CopyWithStubImpl$Mutation$MoveService$moveService; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - Mutation$MoveService$moveService$job? job}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + Mutation$MoveService$moveService$job? job, + }); CopyWith$Mutation$MoveService$moveService$job get job; } class _CopyWithImpl$Mutation$MoveService$moveService implements CopyWith$Mutation$MoveService$moveService { - _CopyWithImpl$Mutation$MoveService$moveService(this._instance, this._then); + _CopyWithImpl$Mutation$MoveService$moveService( + this._instance, + this._then, + ); final Mutation$MoveService$moveService _instance; @@ -3681,28 +6498,29 @@ class _CopyWithImpl$Mutation$MoveService$moveService static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? job = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? job = _undefined, + }) => _then(Mutation$MoveService$moveService( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - job: job == _undefined - ? _instance.job - : (job as Mutation$MoveService$moveService$job?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + job: job == _undefined + ? _instance.job + : (job as Mutation$MoveService$moveService$job?), + )); CopyWith$Mutation$MoveService$moveService$job get job { final local$job = _instance.job; return local$job == null @@ -3718,47 +6536,70 @@ class _CopyWithStubImpl$Mutation$MoveService$moveService TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - Mutation$MoveService$moveService$job? job}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + Mutation$MoveService$moveService$job? job, + }) => _res; CopyWith$Mutation$MoveService$moveService$job get job => CopyWith$Mutation$MoveService$moveService$job.stub(_res); } -@JsonSerializable(explicitToJson: true) class Mutation$MoveService$moveService$job { - Mutation$MoveService$moveService$job( - {required this.createdAt, - required this.description, - this.error, - this.finishedAt, - required this.name, - this.progress, - this.result, - required this.status, - this.statusText, - required this.uid, - required this.updatedAt, - required this.$__typename}); + Mutation$MoveService$moveService$job({ + required this.createdAt, + required this.description, + this.error, + this.finishedAt, + required this.name, + this.progress, + this.result, + required this.status, + this.statusText, + required this.uid, + required this.updatedAt, + required this.$__typename, + }); - @override factory Mutation$MoveService$moveService$job.fromJson( - Map json) => - _$Mutation$MoveService$moveService$jobFromJson(json); + Map json) { + final l$createdAt = json['createdAt']; + final l$description = json['description']; + final l$error = json['error']; + final l$finishedAt = json['finishedAt']; + final l$name = json['name']; + final l$progress = json['progress']; + final l$result = json['result']; + final l$status = json['status']; + final l$statusText = json['statusText']; + final l$uid = json['uid']; + final l$updatedAt = json['updatedAt']; + final l$$__typename = json['__typename']; + return Mutation$MoveService$moveService$job( + createdAt: dateTimeFromJson(l$createdAt), + description: (l$description as String), + error: (l$error as String?), + finishedAt: l$finishedAt == null ? null : dateTimeFromJson(l$finishedAt), + name: (l$name as String), + progress: (l$progress as int?), + result: (l$result as String?), + status: (l$status as String), + statusText: (l$statusText as String?), + uid: (l$uid as String), + updatedAt: dateTimeFromJson(l$updatedAt), + $__typename: (l$$__typename as String), + ); + } - @JsonKey(fromJson: dateTimeFromJson, toJson: dateTimeToJson) final DateTime createdAt; final String description; final String? error; - @JsonKey( - fromJson: _nullable$dateTimeFromJson, toJson: _nullable$dateTimeToJson) final DateTime? finishedAt; final String name; @@ -3773,14 +6614,41 @@ class Mutation$MoveService$moveService$job { final String uid; - @JsonKey(fromJson: dateTimeFromJson, toJson: dateTimeToJson) final DateTime updatedAt; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Mutation$MoveService$moveService$jobToJson(this); + Map toJson() { + final _resultData = {}; + final l$createdAt = createdAt; + _resultData['createdAt'] = dateTimeToJson(l$createdAt); + final l$description = description; + _resultData['description'] = l$description; + final l$error = error; + _resultData['error'] = l$error; + final l$finishedAt = finishedAt; + _resultData['finishedAt'] = + l$finishedAt == null ? null : dateTimeToJson(l$finishedAt); + final l$name = name; + _resultData['name'] = l$name; + final l$progress = progress; + _resultData['progress'] = l$progress; + final l$result = result; + _resultData['result'] = l$result; + final l$status = status; + _resultData['status'] = l$status; + final l$statusText = statusText; + _resultData['statusText'] = l$statusText; + final l$uid = uid; + _resultData['uid'] = l$uid; + final l$updatedAt = updatedAt; + _resultData['updatedAt'] = dateTimeToJson(l$updatedAt); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$createdAt = createdAt; final l$description = description; @@ -3806,51 +6674,79 @@ class Mutation$MoveService$moveService$job { l$statusText, l$uid, l$updatedAt, - l$$__typename + l$$__typename, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$MoveService$moveService$job) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$createdAt = createdAt; final lOther$createdAt = other.createdAt; - if (l$createdAt != lOther$createdAt) return false; + if (l$createdAt != lOther$createdAt) { + return false; + } final l$description = description; final lOther$description = other.description; - if (l$description != lOther$description) return false; + if (l$description != lOther$description) { + return false; + } final l$error = error; final lOther$error = other.error; - if (l$error != lOther$error) return false; + if (l$error != lOther$error) { + return false; + } final l$finishedAt = finishedAt; final lOther$finishedAt = other.finishedAt; - if (l$finishedAt != lOther$finishedAt) return false; + if (l$finishedAt != lOther$finishedAt) { + return false; + } final l$name = name; final lOther$name = other.name; - if (l$name != lOther$name) return false; + if (l$name != lOther$name) { + return false; + } final l$progress = progress; final lOther$progress = other.progress; - if (l$progress != lOther$progress) return false; + if (l$progress != lOther$progress) { + return false; + } final l$result = result; final lOther$result = other.result; - if (l$result != lOther$result) return false; + if (l$result != lOther$result) { + return false; + } final l$status = status; final lOther$status = other.status; - if (l$status != lOther$status) return false; + if (l$status != lOther$status) { + return false; + } final l$statusText = statusText; final lOther$statusText = other.statusText; - if (l$statusText != lOther$statusText) return false; + if (l$statusText != lOther$statusText) { + return false; + } final l$uid = uid; final lOther$uid = other.uid; - if (l$uid != lOther$uid) return false; + if (l$uid != lOther$uid) { + return false; + } final l$updatedAt = updatedAt; final lOther$updatedAt = other.updatedAt; - if (l$updatedAt != lOther$updatedAt) return false; + if (l$updatedAt != lOther$updatedAt) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -3859,38 +6755,43 @@ extension UtilityExtension$Mutation$MoveService$moveService$job on Mutation$MoveService$moveService$job { CopyWith$Mutation$MoveService$moveService$job< Mutation$MoveService$moveService$job> - get copyWith => - CopyWith$Mutation$MoveService$moveService$job(this, (i) => i); + get copyWith => CopyWith$Mutation$MoveService$moveService$job( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$MoveService$moveService$job { factory CopyWith$Mutation$MoveService$moveService$job( - Mutation$MoveService$moveService$job instance, - TRes Function(Mutation$MoveService$moveService$job) then) = - _CopyWithImpl$Mutation$MoveService$moveService$job; + Mutation$MoveService$moveService$job instance, + TRes Function(Mutation$MoveService$moveService$job) then, + ) = _CopyWithImpl$Mutation$MoveService$moveService$job; factory CopyWith$Mutation$MoveService$moveService$job.stub(TRes res) = _CopyWithStubImpl$Mutation$MoveService$moveService$job; - TRes call( - {DateTime? createdAt, - String? description, - String? error, - DateTime? finishedAt, - String? name, - int? progress, - String? result, - String? status, - String? statusText, - String? uid, - DateTime? updatedAt, - String? $__typename}); + TRes call({ + DateTime? createdAt, + String? description, + String? error, + DateTime? finishedAt, + String? name, + int? progress, + String? result, + String? status, + String? statusText, + String? uid, + DateTime? updatedAt, + String? $__typename, + }); } class _CopyWithImpl$Mutation$MoveService$moveService$job implements CopyWith$Mutation$MoveService$moveService$job { _CopyWithImpl$Mutation$MoveService$moveService$job( - this._instance, this._then); + this._instance, + this._then, + ); final Mutation$MoveService$moveService$job _instance; @@ -3898,51 +6799,51 @@ class _CopyWithImpl$Mutation$MoveService$moveService$job static const _undefined = {}; - TRes call( - {Object? createdAt = _undefined, - Object? description = _undefined, - Object? error = _undefined, - Object? finishedAt = _undefined, - Object? name = _undefined, - Object? progress = _undefined, - Object? result = _undefined, - Object? status = _undefined, - Object? statusText = _undefined, - Object? uid = _undefined, - Object? updatedAt = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? createdAt = _undefined, + Object? description = _undefined, + Object? error = _undefined, + Object? finishedAt = _undefined, + Object? name = _undefined, + Object? progress = _undefined, + Object? result = _undefined, + Object? status = _undefined, + Object? statusText = _undefined, + Object? uid = _undefined, + Object? updatedAt = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$MoveService$moveService$job( - createdAt: createdAt == _undefined || createdAt == null - ? _instance.createdAt - : (createdAt as DateTime), - description: description == _undefined || description == null - ? _instance.description - : (description as String), - error: error == _undefined ? _instance.error : (error as String?), - finishedAt: finishedAt == _undefined - ? _instance.finishedAt - : (finishedAt as DateTime?), - name: name == _undefined || name == null - ? _instance.name - : (name as String), - progress: - progress == _undefined ? _instance.progress : (progress as int?), - result: result == _undefined ? _instance.result : (result as String?), - status: status == _undefined || status == null - ? _instance.status - : (status as String), - statusText: statusText == _undefined - ? _instance.statusText - : (statusText as String?), - uid: uid == _undefined || uid == null - ? _instance.uid - : (uid as String), - updatedAt: updatedAt == _undefined || updatedAt == null - ? _instance.updatedAt - : (updatedAt as DateTime), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + createdAt: createdAt == _undefined || createdAt == null + ? _instance.createdAt + : (createdAt as DateTime), + description: description == _undefined || description == null + ? _instance.description + : (description as String), + error: error == _undefined ? _instance.error : (error as String?), + finishedAt: finishedAt == _undefined + ? _instance.finishedAt + : (finishedAt as DateTime?), + name: name == _undefined || name == null + ? _instance.name + : (name as String), + progress: + progress == _undefined ? _instance.progress : (progress as int?), + result: result == _undefined ? _instance.result : (result as String?), + status: status == _undefined || status == null + ? _instance.status + : (status as String), + statusText: statusText == _undefined + ? _instance.statusText + : (statusText as String?), + uid: uid == _undefined || uid == null ? _instance.uid : (uid as String), + updatedAt: updatedAt == _undefined || updatedAt == null + ? _instance.updatedAt + : (updatedAt as DateTime), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$MoveService$moveService$job @@ -3951,23 +6852,19 @@ class _CopyWithStubImpl$Mutation$MoveService$moveService$job TRes _res; - call( - {DateTime? createdAt, - String? description, - String? error, - DateTime? finishedAt, - String? name, - int? progress, - String? result, - String? status, - String? statusText, - String? uid, - DateTime? updatedAt, - String? $__typename}) => + call({ + DateTime? createdAt, + String? description, + String? error, + DateTime? finishedAt, + String? name, + int? progress, + String? result, + String? status, + String? statusText, + String? uid, + DateTime? updatedAt, + String? $__typename, + }) => _res; } - -DateTime? _nullable$dateTimeFromJson(dynamic data) => - data == null ? null : dateTimeFromJson(data); -dynamic _nullable$dateTimeToJson(DateTime? data) => - data == null ? null : dateTimeToJson(data); diff --git a/lib/logic/api_maps/graphql_maps/schema/services.graphql.g.dart b/lib/logic/api_maps/graphql_maps/schema/services.graphql.g.dart deleted file mode 100644 index 52663401..00000000 --- a/lib/logic/api_maps/graphql_maps/schema/services.graphql.g.dart +++ /dev/null @@ -1,458 +0,0 @@ -// GENERATED CODE - DO NOT MODIFY BY HAND - -part of 'services.graphql.dart'; - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -Fragment$basicMutationReturnFields _$Fragment$basicMutationReturnFieldsFromJson( - Map json) => - Fragment$basicMutationReturnFields( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Fragment$basicMutationReturnFieldsToJson( - Fragment$basicMutationReturnFields instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Query$AllServices _$Query$AllServicesFromJson(Map json) => - Query$AllServices( - services: Query$AllServices$services.fromJson( - json['services'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$AllServicesToJson(Query$AllServices instance) => - { - 'services': instance.services.toJson(), - '__typename': instance.$__typename, - }; - -Query$AllServices$services _$Query$AllServices$servicesFromJson( - Map json) => - Query$AllServices$services( - allServices: (json['allServices'] as List) - .map((e) => Query$AllServices$services$allServices.fromJson( - e as Map)) - .toList(), - $__typename: json['__typename'] as String, - ); - -Map _$Query$AllServices$servicesToJson( - Query$AllServices$services instance) => - { - 'allServices': instance.allServices.map((e) => e.toJson()).toList(), - '__typename': instance.$__typename, - }; - -Query$AllServices$services$allServices - _$Query$AllServices$services$allServicesFromJson( - Map json) => - Query$AllServices$services$allServices( - description: json['description'] as String, - displayName: json['displayName'] as String, - dnsRecords: (json['dnsRecords'] as List?) - ?.map((e) => - Fragment$dnsRecordFields.fromJson(e as Map)) - .toList(), - id: json['id'] as String, - isEnabled: json['isEnabled'] as bool, - isMovable: json['isMovable'] as bool, - isRequired: json['isRequired'] as bool, - status: $enumDecode(_$Enum$ServiceStatusEnumEnumMap, json['status'], - unknownValue: Enum$ServiceStatusEnum.$unknown), - storageUsage: - Query$AllServices$services$allServices$storageUsage.fromJson( - json['storageUsage'] as Map), - svgIcon: json['svgIcon'] as String, - url: json['url'] as String?, - $__typename: json['__typename'] as String, - ); - -Map _$Query$AllServices$services$allServicesToJson( - Query$AllServices$services$allServices instance) => - { - 'description': instance.description, - 'displayName': instance.displayName, - 'dnsRecords': instance.dnsRecords?.map((e) => e.toJson()).toList(), - 'id': instance.id, - 'isEnabled': instance.isEnabled, - 'isMovable': instance.isMovable, - 'isRequired': instance.isRequired, - 'status': _$Enum$ServiceStatusEnumEnumMap[instance.status]!, - 'storageUsage': instance.storageUsage.toJson(), - 'svgIcon': instance.svgIcon, - 'url': instance.url, - '__typename': instance.$__typename, - }; - -const _$Enum$ServiceStatusEnumEnumMap = { - Enum$ServiceStatusEnum.ACTIVATING: 'ACTIVATING', - Enum$ServiceStatusEnum.ACTIVE: 'ACTIVE', - Enum$ServiceStatusEnum.DEACTIVATING: 'DEACTIVATING', - Enum$ServiceStatusEnum.FAILED: 'FAILED', - Enum$ServiceStatusEnum.INACTIVE: 'INACTIVE', - Enum$ServiceStatusEnum.OFF: 'OFF', - Enum$ServiceStatusEnum.RELOADING: 'RELOADING', - Enum$ServiceStatusEnum.$unknown: r'$unknown', -}; - -Query$AllServices$services$allServices$storageUsage - _$Query$AllServices$services$allServices$storageUsageFromJson( - Map json) => - Query$AllServices$services$allServices$storageUsage( - title: json['title'] as String, - usedSpace: json['usedSpace'] as String, - volume: json['volume'] == null - ? null - : Query$AllServices$services$allServices$storageUsage$volume - .fromJson(json['volume'] as Map), - $__typename: json['__typename'] as String, - ); - -Map - _$Query$AllServices$services$allServices$storageUsageToJson( - Query$AllServices$services$allServices$storageUsage instance) => - { - 'title': instance.title, - 'usedSpace': instance.usedSpace, - 'volume': instance.volume?.toJson(), - '__typename': instance.$__typename, - }; - -Query$AllServices$services$allServices$storageUsage$volume - _$Query$AllServices$services$allServices$storageUsage$volumeFromJson( - Map json) => - Query$AllServices$services$allServices$storageUsage$volume( - name: json['name'] as String, - $__typename: json['__typename'] as String, - ); - -Map _$Query$AllServices$services$allServices$storageUsage$volumeToJson( - Query$AllServices$services$allServices$storageUsage$volume instance) => - { - 'name': instance.name, - '__typename': instance.$__typename, - }; - -Variables$Mutation$EnableService _$Variables$Mutation$EnableServiceFromJson( - Map json) => - Variables$Mutation$EnableService( - serviceId: json['serviceId'] as String, - ); - -Map _$Variables$Mutation$EnableServiceToJson( - Variables$Mutation$EnableService instance) => - { - 'serviceId': instance.serviceId, - }; - -Mutation$EnableService _$Mutation$EnableServiceFromJson( - Map json) => - Mutation$EnableService( - enableService: Mutation$EnableService$enableService.fromJson( - json['enableService'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$EnableServiceToJson( - Mutation$EnableService instance) => - { - 'enableService': instance.enableService.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$EnableService$enableService - _$Mutation$EnableService$enableServiceFromJson(Map json) => - Mutation$EnableService$enableService( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$EnableService$enableServiceToJson( - Mutation$EnableService$enableService instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$DisableService _$Variables$Mutation$DisableServiceFromJson( - Map json) => - Variables$Mutation$DisableService( - serviceId: json['serviceId'] as String, - ); - -Map _$Variables$Mutation$DisableServiceToJson( - Variables$Mutation$DisableService instance) => - { - 'serviceId': instance.serviceId, - }; - -Mutation$DisableService _$Mutation$DisableServiceFromJson( - Map json) => - Mutation$DisableService( - disableService: Mutation$DisableService$disableService.fromJson( - json['disableService'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$DisableServiceToJson( - Mutation$DisableService instance) => - { - 'disableService': instance.disableService.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$DisableService$disableService - _$Mutation$DisableService$disableServiceFromJson( - Map json) => - Mutation$DisableService$disableService( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$DisableService$disableServiceToJson( - Mutation$DisableService$disableService instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$StopService _$Variables$Mutation$StopServiceFromJson( - Map json) => - Variables$Mutation$StopService( - serviceId: json['serviceId'] as String, - ); - -Map _$Variables$Mutation$StopServiceToJson( - Variables$Mutation$StopService instance) => - { - 'serviceId': instance.serviceId, - }; - -Mutation$StopService _$Mutation$StopServiceFromJson( - Map json) => - Mutation$StopService( - stopService: Mutation$StopService$stopService.fromJson( - json['stopService'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$StopServiceToJson( - Mutation$StopService instance) => - { - 'stopService': instance.stopService.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$StopService$stopService _$Mutation$StopService$stopServiceFromJson( - Map json) => - Mutation$StopService$stopService( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$StopService$stopServiceToJson( - Mutation$StopService$stopService instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$StartService _$Variables$Mutation$StartServiceFromJson( - Map json) => - Variables$Mutation$StartService( - serviceId: json['serviceId'] as String, - ); - -Map _$Variables$Mutation$StartServiceToJson( - Variables$Mutation$StartService instance) => - { - 'serviceId': instance.serviceId, - }; - -Mutation$StartService _$Mutation$StartServiceFromJson( - Map json) => - Mutation$StartService( - startService: Mutation$StartService$startService.fromJson( - json['startService'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$StartServiceToJson( - Mutation$StartService instance) => - { - 'startService': instance.startService.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$StartService$startService _$Mutation$StartService$startServiceFromJson( - Map json) => - Mutation$StartService$startService( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$StartService$startServiceToJson( - Mutation$StartService$startService instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$RestartService _$Variables$Mutation$RestartServiceFromJson( - Map json) => - Variables$Mutation$RestartService( - serviceId: json['serviceId'] as String, - ); - -Map _$Variables$Mutation$RestartServiceToJson( - Variables$Mutation$RestartService instance) => - { - 'serviceId': instance.serviceId, - }; - -Mutation$RestartService _$Mutation$RestartServiceFromJson( - Map json) => - Mutation$RestartService( - restartService: Mutation$RestartService$restartService.fromJson( - json['restartService'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RestartServiceToJson( - Mutation$RestartService instance) => - { - 'restartService': instance.restartService.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$RestartService$restartService - _$Mutation$RestartService$restartServiceFromJson( - Map json) => - Mutation$RestartService$restartService( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RestartService$restartServiceToJson( - Mutation$RestartService$restartService instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$MoveService _$Variables$Mutation$MoveServiceFromJson( - Map json) => - Variables$Mutation$MoveService( - input: Input$MoveServiceInput.fromJson( - json['input'] as Map), - ); - -Map _$Variables$Mutation$MoveServiceToJson( - Variables$Mutation$MoveService instance) => - { - 'input': instance.input.toJson(), - }; - -Mutation$MoveService _$Mutation$MoveServiceFromJson( - Map json) => - Mutation$MoveService( - moveService: Mutation$MoveService$moveService.fromJson( - json['moveService'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$MoveServiceToJson( - Mutation$MoveService instance) => - { - 'moveService': instance.moveService.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$MoveService$moveService _$Mutation$MoveService$moveServiceFromJson( - Map json) => - Mutation$MoveService$moveService( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - job: json['job'] == null - ? null - : Mutation$MoveService$moveService$job.fromJson( - json['job'] as Map), - ); - -Map _$Mutation$MoveService$moveServiceToJson( - Mutation$MoveService$moveService instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'job': instance.job?.toJson(), - }; - -Mutation$MoveService$moveService$job - _$Mutation$MoveService$moveService$jobFromJson(Map json) => - Mutation$MoveService$moveService$job( - createdAt: dateTimeFromJson(json['createdAt']), - description: json['description'] as String, - error: json['error'] as String?, - finishedAt: _nullable$dateTimeFromJson(json['finishedAt']), - name: json['name'] as String, - progress: json['progress'] as int?, - result: json['result'] as String?, - status: json['status'] as String, - statusText: json['statusText'] as String?, - uid: json['uid'] as String, - updatedAt: dateTimeFromJson(json['updatedAt']), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$MoveService$moveService$jobToJson( - Mutation$MoveService$moveService$job instance) => - { - 'createdAt': dateTimeToJson(instance.createdAt), - 'description': instance.description, - 'error': instance.error, - 'finishedAt': _nullable$dateTimeToJson(instance.finishedAt), - 'name': instance.name, - 'progress': instance.progress, - 'result': instance.result, - 'status': instance.status, - 'statusText': instance.statusText, - 'uid': instance.uid, - 'updatedAt': dateTimeToJson(instance.updatedAt), - '__typename': instance.$__typename, - }; diff --git a/lib/logic/api_maps/graphql_maps/schema/users.graphql.dart b/lib/logic/api_maps/graphql_maps/schema/users.graphql.dart index ce846b30..c2d0027f 100644 --- a/lib/logic/api_maps/graphql_maps/schema/users.graphql.dart +++ b/lib/logic/api_maps/graphql_maps/schema/users.graphql.dart @@ -1,23 +1,69 @@ import 'dart:async'; +import 'disk_volumes.graphql.dart'; import 'package:gql/ast.dart'; import 'package:graphql/client.dart' as graphql; -import 'package:json_annotation/json_annotation.dart'; import 'schema.graphql.dart'; -import 'server_api.graphql.dart'; -part 'users.graphql.g.dart'; -@JsonSerializable(explicitToJson: true) class Fragment$basicMutationReturnFields { - Fragment$basicMutationReturnFields( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + Fragment$basicMutationReturnFields({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override factory Fragment$basicMutationReturnFields.fromJson( - Map json) => - _$Fragment$basicMutationReturnFieldsFromJson(json); + Map json) { + switch (json["__typename"] as String) { + case "ApiKeyMutationReturn": + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + .fromJson(json); + + case "AutoUpgradeSettingsMutationReturn": + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + .fromJson(json); + + case "DeviceApiTokenMutationReturn": + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + .fromJson(json); + + case "GenericJobButationReturn": + return Fragment$basicMutationReturnFields$$GenericJobButationReturn + .fromJson(json); + + case "GenericMutationReturn": + return Fragment$basicMutationReturnFields$$GenericMutationReturn + .fromJson(json); + + case "ServiceJobMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + .fromJson(json); + + case "ServiceMutationReturn": + return Fragment$basicMutationReturnFields$$ServiceMutationReturn + .fromJson(json); + + case "TimezoneMutationReturn": + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn + .fromJson(json); + + case "UserMutationReturn": + return Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + json); + + default: + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + } final int code; @@ -25,36 +71,64 @@ class Fragment$basicMutationReturnFields { final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => - _$Fragment$basicMutationReturnFieldsToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Fragment$basicMutationReturnFields) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -63,25 +137,35 @@ extension UtilityExtension$Fragment$basicMutationReturnFields on Fragment$basicMutationReturnFields { CopyWith$Fragment$basicMutationReturnFields< Fragment$basicMutationReturnFields> - get copyWith => - CopyWith$Fragment$basicMutationReturnFields(this, (i) => i); + get copyWith => CopyWith$Fragment$basicMutationReturnFields( + this, + (i) => i, + ); } abstract class CopyWith$Fragment$basicMutationReturnFields { factory CopyWith$Fragment$basicMutationReturnFields( - Fragment$basicMutationReturnFields instance, - TRes Function(Fragment$basicMutationReturnFields) then) = - _CopyWithImpl$Fragment$basicMutationReturnFields; + Fragment$basicMutationReturnFields instance, + TRes Function(Fragment$basicMutationReturnFields) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields; factory CopyWith$Fragment$basicMutationReturnFields.stub(TRes res) = _CopyWithStubImpl$Fragment$basicMutationReturnFields; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Fragment$basicMutationReturnFields implements CopyWith$Fragment$basicMutationReturnFields { - _CopyWithImpl$Fragment$basicMutationReturnFields(this._instance, this._then); + _CopyWithImpl$Fragment$basicMutationReturnFields( + this._instance, + this._then, + ); final Fragment$basicMutationReturnFields _instance; @@ -89,24 +173,25 @@ class _CopyWithImpl$Fragment$basicMutationReturnFields static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Fragment$basicMutationReturnFields( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Fragment$basicMutationReturnFields @@ -115,43 +200,54 @@ class _CopyWithStubImpl$Fragment$basicMutationReturnFields TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } const fragmentDefinitionbasicMutationReturnFields = FragmentDefinitionNode( - name: NameNode(value: 'basicMutationReturnFields'), - typeCondition: TypeConditionNode( - on: NamedTypeNode( - name: NameNode(value: 'MutationReturnInterface'), - isNonNull: false)), - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'code'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'message'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'success'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])); + name: NameNode(value: 'basicMutationReturnFields'), + typeCondition: TypeConditionNode( + on: NamedTypeNode( + name: NameNode(value: 'MutationReturnInterface'), + isNonNull: false, + )), + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'code'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'message'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'success'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), +); const documentNodeFragmentbasicMutationReturnFields = DocumentNode(definitions: [ fragmentDefinitionbasicMutationReturnFields, @@ -159,56 +255,1704 @@ const documentNodeFragmentbasicMutationReturnFields = extension ClientExtension$Fragment$basicMutationReturnFields on graphql.GraphQLClient { - void writeFragment$basicMutationReturnFields( - {required Fragment$basicMutationReturnFields data, - required Map idFields, - bool broadcast = true}) => + void writeFragment$basicMutationReturnFields({ + required Fragment$basicMutationReturnFields data, + required Map idFields, + bool broadcast = true, + }) => this.writeFragment( - graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - data: data.toJson(), - broadcast: broadcast); - Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields( - {required Map idFields, bool optimistic = true}) { - final result = this.readFragment( graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'basicMutationReturnFields', - document: documentNodeFragmentbasicMutationReturnFields)), - optimistic: optimistic); + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + data: data.toJson(), + broadcast: broadcast, + ); + Fragment$basicMutationReturnFields? readFragment$basicMutationReturnFields({ + required Map idFields, + bool optimistic = true, + }) { + final result = this.readFragment( + graphql.FragmentRequest( + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'basicMutationReturnFields', + document: documentNodeFragmentbasicMutationReturnFields, + ), + ), + optimistic: optimistic, + ); return result == null ? null : Fragment$basicMutationReturnFields.fromJson(result); } } -@JsonSerializable(explicitToJson: true) -class Fragment$userFields { - Fragment$userFields( - {required this.username, - required this.userType, - required this.sshKeys, - required this.$__typename}); +class Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } @override - factory Fragment$userFields.fromJson(Map json) => - _$Fragment$userFieldsFromJson(json); + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn + on Fragment$basicMutationReturnFields$$ApiKeyMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + Fragment$basicMutationReturnFields$$ApiKeyMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ApiKeyMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ApiKeyMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + on Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + instance, + TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then( + Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$AutoUpgradeSettingsMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + on Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn instance, + TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn + _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$DeviceApiTokenMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericJobButationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericJobButationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericJobButationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$GenericJobButationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericJobButationReturn + on Fragment$basicMutationReturnFields$$GenericJobButationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + Fragment$basicMutationReturnFields$$GenericJobButationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + Fragment$basicMutationReturnFields$$GenericJobButationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericJobButationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericJobButationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$GenericJobButationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericJobButationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericJobButationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericJobButationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$GenericMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$GenericMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$GenericMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$GenericMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$GenericMutationReturn + on Fragment$basicMutationReturnFields$$GenericMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + Fragment$basicMutationReturnFields$$GenericMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn( + Fragment$basicMutationReturnFields$$GenericMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$GenericMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$GenericMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$GenericMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$GenericMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$GenericMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn + on Fragment$basicMutationReturnFields$$ServiceJobMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceJobMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$ServiceJobMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceJobMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$ServiceMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$ServiceMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$ServiceMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$ServiceMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$ServiceMutationReturn + on Fragment$basicMutationReturnFields$$ServiceMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + Fragment$basicMutationReturnFields$$ServiceMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + Fragment$basicMutationReturnFields$$ServiceMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$ServiceMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$ServiceMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$ServiceMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$ServiceMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$ServiceMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$TimezoneMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$TimezoneMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$TimezoneMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other + is Fragment$basicMutationReturnFields$$TimezoneMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$TimezoneMutationReturn + on Fragment$basicMutationReturnFields$$TimezoneMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + Fragment$basicMutationReturnFields$$TimezoneMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$TimezoneMutationReturn) + then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$TimezoneMutationReturn _instance; + + final TRes Function( + Fragment$basicMutationReturnFields$$TimezoneMutationReturn) _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$TimezoneMutationReturn< + TRes> { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$TimezoneMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$basicMutationReturnFields$$UserMutationReturn + implements Fragment$basicMutationReturnFields { + Fragment$basicMutationReturnFields$$UserMutationReturn({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); + + factory Fragment$basicMutationReturnFields$$UserMutationReturn.fromJson( + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Fragment$basicMutationReturnFields$$UserMutationReturn( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } + + final int code; + + final String message; + + final bool success; + + final String $__typename; + + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override + int get hashCode { + final l$code = code; + final l$message = message; + final l$success = success; + final l$$__typename = $__typename; + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); + } + + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$basicMutationReturnFields$$UserMutationReturn) || + runtimeType != other.runtimeType) { + return false; + } + final l$code = code; + final lOther$code = other.code; + if (l$code != lOther$code) { + return false; + } + final l$message = message; + final lOther$message = other.message; + if (l$message != lOther$message) { + return false; + } + final l$success = success; + final lOther$success = other.success; + if (l$success != lOther$success) { + return false; + } + final l$$__typename = $__typename; + final lOther$$__typename = other.$__typename; + if (l$$__typename != lOther$$__typename) { + return false; + } + return true; + } +} + +extension UtilityExtension$Fragment$basicMutationReturnFields$$UserMutationReturn + on Fragment$basicMutationReturnFields$$UserMutationReturn { + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + Fragment$basicMutationReturnFields$$UserMutationReturn> + get copyWith => + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + this, + (i) => i, + ); +} + +abstract class CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> { + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn( + Fragment$basicMutationReturnFields$$UserMutationReturn instance, + TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) then, + ) = _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + factory CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn.stub( + TRes res) = + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn; + + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); +} + +class _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._instance, + this._then, + ); + + final Fragment$basicMutationReturnFields$$UserMutationReturn _instance; + + final TRes Function(Fragment$basicMutationReturnFields$$UserMutationReturn) + _then; + + static const _undefined = {}; + + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => + _then(Fragment$basicMutationReturnFields$$UserMutationReturn( + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); +} + +class _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn< + TRes> + implements + CopyWith$Fragment$basicMutationReturnFields$$UserMutationReturn { + _CopyWithStubImpl$Fragment$basicMutationReturnFields$$UserMutationReturn( + this._res); + + TRes _res; + + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => + _res; +} + +class Fragment$userFields { + Fragment$userFields({ + required this.username, + required this.userType, + required this.sshKeys, + required this.$__typename, + }); + + factory Fragment$userFields.fromJson(Map json) { + final l$username = json['username']; + final l$userType = json['userType']; + final l$sshKeys = json['sshKeys']; + final l$$__typename = json['__typename']; + return Fragment$userFields( + username: (l$username as String), + userType: fromJson$Enum$UserType((l$userType as String)), + sshKeys: (l$sshKeys as List).map((e) => (e as String)).toList(), + $__typename: (l$$__typename as String), + ); + } final String username; - @JsonKey(unknownEnumValue: Enum$UserType.$unknown) final Enum$UserType userType; final List sshKeys; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Fragment$userFieldsToJson(this); + Map toJson() { + final _resultData = {}; + final l$username = username; + _resultData['username'] = l$username; + final l$userType = userType; + _resultData['userType'] = toJson$Enum$UserType(l$userType); + final l$sshKeys = sshKeys; + _resultData['sshKeys'] = l$sshKeys.map((e) => e).toList(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$username = username; final l$userType = userType; @@ -218,60 +1962,80 @@ class Fragment$userFields { l$username, l$userType, Object.hashAll(l$sshKeys.map((v) => v)), - l$$__typename + l$$__typename, ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Fragment$userFields) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Fragment$userFields) || runtimeType != other.runtimeType) { return false; + } final l$username = username; final lOther$username = other.username; - if (l$username != lOther$username) return false; + if (l$username != lOther$username) { + return false; + } final l$userType = userType; final lOther$userType = other.userType; - if (l$userType != lOther$userType) return false; + if (l$userType != lOther$userType) { + return false; + } final l$sshKeys = sshKeys; final lOther$sshKeys = other.sshKeys; - if (l$sshKeys.length != lOther$sshKeys.length) return false; + if (l$sshKeys.length != lOther$sshKeys.length) { + return false; + } for (int i = 0; i < l$sshKeys.length; i++) { final l$sshKeys$entry = l$sshKeys[i]; final lOther$sshKeys$entry = lOther$sshKeys[i]; - if (l$sshKeys$entry != lOther$sshKeys$entry) return false; + if (l$sshKeys$entry != lOther$sshKeys$entry) { + return false; + } } - final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Fragment$userFields on Fragment$userFields { CopyWith$Fragment$userFields get copyWith => - CopyWith$Fragment$userFields(this, (i) => i); + CopyWith$Fragment$userFields( + this, + (i) => i, + ); } abstract class CopyWith$Fragment$userFields { - factory CopyWith$Fragment$userFields(Fragment$userFields instance, - TRes Function(Fragment$userFields) then) = - _CopyWithImpl$Fragment$userFields; + factory CopyWith$Fragment$userFields( + Fragment$userFields instance, + TRes Function(Fragment$userFields) then, + ) = _CopyWithImpl$Fragment$userFields; factory CopyWith$Fragment$userFields.stub(TRes res) = _CopyWithStubImpl$Fragment$userFields; - TRes call( - {String? username, - Enum$UserType? userType, - List? sshKeys, - String? $__typename}); + TRes call({ + String? username, + Enum$UserType? userType, + List? sshKeys, + String? $__typename, + }); } class _CopyWithImpl$Fragment$userFields implements CopyWith$Fragment$userFields { - _CopyWithImpl$Fragment$userFields(this._instance, this._then); + _CopyWithImpl$Fragment$userFields( + this._instance, + this._then, + ); final Fragment$userFields _instance; @@ -279,24 +2043,26 @@ class _CopyWithImpl$Fragment$userFields static const _undefined = {}; - TRes call( - {Object? username = _undefined, - Object? userType = _undefined, - Object? sshKeys = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? username = _undefined, + Object? userType = _undefined, + Object? sshKeys = _undefined, + Object? $__typename = _undefined, + }) => _then(Fragment$userFields( - username: username == _undefined || username == null - ? _instance.username - : (username as String), - userType: userType == _undefined || userType == null - ? _instance.userType - : (userType as Enum$UserType), - sshKeys: sshKeys == _undefined || sshKeys == null - ? _instance.sshKeys - : (sshKeys as List), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + username: username == _undefined || username == null + ? _instance.username + : (username as String), + userType: userType == _undefined || userType == null + ? _instance.userType + : (userType as Enum$UserType), + sshKeys: sshKeys == _undefined || sshKeys == null + ? _instance.sshKeys + : (sshKeys as List), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Fragment$userFields @@ -305,130 +2071,183 @@ class _CopyWithStubImpl$Fragment$userFields TRes _res; - call( - {String? username, - Enum$UserType? userType, - List? sshKeys, - String? $__typename}) => + call({ + String? username, + Enum$UserType? userType, + List? sshKeys, + String? $__typename, + }) => _res; } const fragmentDefinitionuserFields = FragmentDefinitionNode( - name: NameNode(value: 'userFields'), - typeCondition: TypeConditionNode( - on: NamedTypeNode(name: NameNode(value: 'User'), isNonNull: false)), - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'username'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'userType'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: 'sshKeys'), - alias: null, - arguments: [], - directives: [], - selectionSet: null), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])); + name: NameNode(value: 'userFields'), + typeCondition: TypeConditionNode( + on: NamedTypeNode( + name: NameNode(value: 'User'), + isNonNull: false, + )), + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'username'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'userType'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: 'sshKeys'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), +); const documentNodeFragmentuserFields = DocumentNode(definitions: [ fragmentDefinitionuserFields, ]); extension ClientExtension$Fragment$userFields on graphql.GraphQLClient { - void writeFragment$userFields( - {required Fragment$userFields data, - required Map idFields, - bool broadcast = true}) => + void writeFragment$userFields({ + required Fragment$userFields data, + required Map idFields, + bool broadcast = true, + }) => this.writeFragment( - graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'userFields', - document: documentNodeFragmentuserFields)), - data: data.toJson(), - broadcast: broadcast); - Fragment$userFields? readFragment$userFields( - {required Map idFields, bool optimistic = true}) { - final result = this.readFragment( graphql.FragmentRequest( - idFields: idFields, - fragment: const graphql.Fragment( - fragmentName: 'userFields', - document: documentNodeFragmentuserFields)), - optimistic: optimistic); + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'userFields', + document: documentNodeFragmentuserFields, + ), + ), + data: data.toJson(), + broadcast: broadcast, + ); + Fragment$userFields? readFragment$userFields({ + required Map idFields, + bool optimistic = true, + }) { + final result = this.readFragment( + graphql.FragmentRequest( + idFields: idFields, + fragment: const graphql.Fragment( + fragmentName: 'userFields', + document: documentNodeFragmentuserFields, + ), + ), + optimistic: optimistic, + ); return result == null ? null : Fragment$userFields.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$AllUsers { - Query$AllUsers({required this.users, required this.$__typename}); + Query$AllUsers({ + required this.users, + required this.$__typename, + }); - @override - factory Query$AllUsers.fromJson(Map json) => - _$Query$AllUsersFromJson(json); + factory Query$AllUsers.fromJson(Map json) { + final l$users = json['users']; + final l$$__typename = json['__typename']; + return Query$AllUsers( + users: Query$AllUsers$users.fromJson((l$users as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$AllUsers$users users; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$AllUsersToJson(this); + Map toJson() { + final _resultData = {}; + final l$users = users; + _resultData['users'] = l$users.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$users = users; final l$$__typename = $__typename; - return Object.hashAll([l$users, l$$__typename]); + return Object.hashAll([ + l$users, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$AllUsers) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$AllUsers) || runtimeType != other.runtimeType) { return false; + } final l$users = users; final lOther$users = other.users; - if (l$users != lOther$users) return false; + if (l$users != lOther$users) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$AllUsers on Query$AllUsers { CopyWith$Query$AllUsers get copyWith => - CopyWith$Query$AllUsers(this, (i) => i); + CopyWith$Query$AllUsers( + this, + (i) => i, + ); } abstract class CopyWith$Query$AllUsers { factory CopyWith$Query$AllUsers( - Query$AllUsers instance, TRes Function(Query$AllUsers) then) = - _CopyWithImpl$Query$AllUsers; + Query$AllUsers instance, + TRes Function(Query$AllUsers) then, + ) = _CopyWithImpl$Query$AllUsers; factory CopyWith$Query$AllUsers.stub(TRes res) = _CopyWithStubImpl$Query$AllUsers; - TRes call({Query$AllUsers$users? users, String? $__typename}); + TRes call({ + Query$AllUsers$users? users, + String? $__typename, + }); CopyWith$Query$AllUsers$users get users; } class _CopyWithImpl$Query$AllUsers implements CopyWith$Query$AllUsers { - _CopyWithImpl$Query$AllUsers(this._instance, this._then); + _CopyWithImpl$Query$AllUsers( + this._instance, + this._then, + ); final Query$AllUsers _instance; @@ -436,14 +2255,18 @@ class _CopyWithImpl$Query$AllUsers static const _undefined = {}; - TRes call({Object? users = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? users = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$AllUsers( - users: users == _undefined || users == null - ? _instance.users - : (users as Query$AllUsers$users), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + users: users == _undefined || users == null + ? _instance.users + : (users as Query$AllUsers$users), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$AllUsers$users get users { final local$users = _instance.users; return CopyWith$Query$AllUsers$users(local$users, (e) => call(users: e)); @@ -456,129 +2279,154 @@ class _CopyWithStubImpl$Query$AllUsers TRes _res; - call({Query$AllUsers$users? users, String? $__typename}) => _res; + call({ + Query$AllUsers$users? users, + String? $__typename, + }) => + _res; CopyWith$Query$AllUsers$users get users => CopyWith$Query$AllUsers$users.stub(_res); } const documentNodeQueryAllUsers = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'AllUsers'), - variableDefinitions: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'users'), + type: OperationType.query, + name: NameNode(value: 'AllUsers'), + variableDefinitions: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'users'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'allUsers'), alias: null, arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'userFields'), + directives: [], + ), FieldNode( - name: NameNode(value: 'allUsers'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'userFields'), directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: 'getUser'), + alias: NameNode(value: 'rootUser'), + arguments: [ + ArgumentNode( + name: NameNode(value: 'username'), + value: StringValueNode( + value: 'root', + isBlock: false, + ), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'userFields'), + directives: [], + ), FieldNode( - name: NameNode(value: 'getUser'), - alias: NameNode(value: 'rootUser'), - arguments: [ - ArgumentNode( - name: NameNode(value: 'username'), - value: StringValueNode(value: 'root', isBlock: false)) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'userFields'), directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionuserFields, ]); Query$AllUsers _parserFn$Query$AllUsers(Map data) => Query$AllUsers.fromJson(data); class Options$Query$AllUsers extends graphql.QueryOptions { - Options$Query$AllUsers( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryAllUsers, - parserFn: _parserFn$Query$AllUsers); + Options$Query$AllUsers({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryAllUsers, + parserFn: _parserFn$Query$AllUsers, + ); } class WatchOptions$Query$AllUsers extends graphql.WatchQueryOptions { - WatchOptions$Query$AllUsers( - {String? operationName, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryAllUsers, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$AllUsers); + WatchOptions$Query$AllUsers({ + String? operationName, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryAllUsers, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$AllUsers, + ); } class FetchMoreOptions$Query$AllUsers extends graphql.FetchMoreOptions { FetchMoreOptions$Query$AllUsers({required graphql.UpdateQuery updateQuery}) - : super(updateQuery: updateQuery, document: documentNodeQueryAllUsers); + : super( + updateQuery: updateQuery, + document: documentNodeQueryAllUsers, + ); } extension ClientExtension$Query$AllUsers on graphql.GraphQLClient { @@ -588,89 +2436,133 @@ extension ClientExtension$Query$AllUsers on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$AllUsers( [WatchOptions$Query$AllUsers? options]) => this.watchQuery(options ?? WatchOptions$Query$AllUsers()); - void writeQuery$AllUsers( - {required Query$AllUsers data, bool broadcast = true}) => + void writeQuery$AllUsers({ + required Query$AllUsers data, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: - graphql.Operation(document: documentNodeQueryAllUsers)), - data: data.toJson(), - broadcast: broadcast); - Query$AllUsers? readQuery$AllUsers({bool optimistic = true}) { - final result = this.readQuery( graphql.Request( operation: graphql.Operation(document: documentNodeQueryAllUsers)), - optimistic: optimistic); + data: data.toJson(), + broadcast: broadcast, + ); + Query$AllUsers? readQuery$AllUsers({bool optimistic = true}) { + final result = this.readQuery( + graphql.Request( + operation: graphql.Operation(document: documentNodeQueryAllUsers)), + optimistic: optimistic, + ); return result == null ? null : Query$AllUsers.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$AllUsers$users { - Query$AllUsers$users( - {required this.allUsers, this.rootUser, required this.$__typename}); + Query$AllUsers$users({ + required this.allUsers, + this.rootUser, + required this.$__typename, + }); - @override - factory Query$AllUsers$users.fromJson(Map json) => - _$Query$AllUsers$usersFromJson(json); + factory Query$AllUsers$users.fromJson(Map json) { + final l$allUsers = json['allUsers']; + final l$rootUser = json['rootUser']; + final l$$__typename = json['__typename']; + return Query$AllUsers$users( + allUsers: (l$allUsers as List) + .map((e) => Fragment$userFields.fromJson((e as Map))) + .toList(), + rootUser: l$rootUser == null + ? null + : Fragment$userFields.fromJson((l$rootUser as Map)), + $__typename: (l$$__typename as String), + ); + } final List allUsers; final Fragment$userFields? rootUser; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$AllUsers$usersToJson(this); + Map toJson() { + final _resultData = {}; + final l$allUsers = allUsers; + _resultData['allUsers'] = l$allUsers.map((e) => e.toJson()).toList(); + final l$rootUser = rootUser; + _resultData['rootUser'] = l$rootUser?.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$allUsers = allUsers; final l$rootUser = rootUser; final l$$__typename = $__typename; - return Object.hashAll( - [Object.hashAll(l$allUsers.map((v) => v)), l$rootUser, l$$__typename]); + return Object.hashAll([ + Object.hashAll(l$allUsers.map((v) => v)), + l$rootUser, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$AllUsers$users) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$AllUsers$users) || runtimeType != other.runtimeType) { return false; + } final l$allUsers = allUsers; final lOther$allUsers = other.allUsers; - if (l$allUsers.length != lOther$allUsers.length) return false; + if (l$allUsers.length != lOther$allUsers.length) { + return false; + } for (int i = 0; i < l$allUsers.length; i++) { final l$allUsers$entry = l$allUsers[i]; final lOther$allUsers$entry = lOther$allUsers[i]; - if (l$allUsers$entry != lOther$allUsers$entry) return false; + if (l$allUsers$entry != lOther$allUsers$entry) { + return false; + } } - final l$rootUser = rootUser; final lOther$rootUser = other.rootUser; - if (l$rootUser != lOther$rootUser) return false; + if (l$rootUser != lOther$rootUser) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$AllUsers$users on Query$AllUsers$users { CopyWith$Query$AllUsers$users get copyWith => - CopyWith$Query$AllUsers$users(this, (i) => i); + CopyWith$Query$AllUsers$users( + this, + (i) => i, + ); } abstract class CopyWith$Query$AllUsers$users { - factory CopyWith$Query$AllUsers$users(Query$AllUsers$users instance, - TRes Function(Query$AllUsers$users) then) = - _CopyWithImpl$Query$AllUsers$users; + factory CopyWith$Query$AllUsers$users( + Query$AllUsers$users instance, + TRes Function(Query$AllUsers$users) then, + ) = _CopyWithImpl$Query$AllUsers$users; factory CopyWith$Query$AllUsers$users.stub(TRes res) = _CopyWithStubImpl$Query$AllUsers$users; - TRes call( - {List? allUsers, - Fragment$userFields? rootUser, - String? $__typename}); + TRes call({ + List? allUsers, + Fragment$userFields? rootUser, + String? $__typename, + }); TRes allUsers( Iterable Function( Iterable>) @@ -680,7 +2572,10 @@ abstract class CopyWith$Query$AllUsers$users { class _CopyWithImpl$Query$AllUsers$users implements CopyWith$Query$AllUsers$users { - _CopyWithImpl$Query$AllUsers$users(this._instance, this._then); + _CopyWithImpl$Query$AllUsers$users( + this._instance, + this._then, + ); final Query$AllUsers$users _instance; @@ -688,27 +2583,32 @@ class _CopyWithImpl$Query$AllUsers$users static const _undefined = {}; - TRes call( - {Object? allUsers = _undefined, - Object? rootUser = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? allUsers = _undefined, + Object? rootUser = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$AllUsers$users( - allUsers: allUsers == _undefined || allUsers == null - ? _instance.allUsers - : (allUsers as List), - rootUser: rootUser == _undefined - ? _instance.rootUser - : (rootUser as Fragment$userFields?), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + allUsers: allUsers == _undefined || allUsers == null + ? _instance.allUsers + : (allUsers as List), + rootUser: rootUser == _undefined + ? _instance.rootUser + : (rootUser as Fragment$userFields?), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); TRes allUsers( Iterable Function( Iterable>) _fn) => call( - allUsers: _fn(_instance.allUsers - .map((e) => CopyWith$Fragment$userFields(e, (i) => i))).toList()); + allUsers: + _fn(_instance.allUsers.map((e) => CopyWith$Fragment$userFields( + e, + (i) => i, + ))).toList()); CopyWith$Fragment$userFields get rootUser { final local$rootUser = _instance.rootUser; return local$rootUser == null @@ -724,51 +2624,76 @@ class _CopyWithStubImpl$Query$AllUsers$users TRes _res; - call( - {List? allUsers, - Fragment$userFields? rootUser, - String? $__typename}) => + call({ + List? allUsers, + Fragment$userFields? rootUser, + String? $__typename, + }) => _res; allUsers(_fn) => _res; CopyWith$Fragment$userFields get rootUser => CopyWith$Fragment$userFields.stub(_res); } -@JsonSerializable(explicitToJson: true) class Variables$Query$GetUser { - Variables$Query$GetUser({required this.username}); + factory Variables$Query$GetUser({required String username}) => + Variables$Query$GetUser._({ + r'username': username, + }); + + Variables$Query$GetUser._(this._$data); + + factory Variables$Query$GetUser.fromJson(Map data) { + final result$data = {}; + final l$username = data['username']; + result$data['username'] = (l$username as String); + return Variables$Query$GetUser._(result$data); + } + + Map _$data; + + String get username => (_$data['username'] as String); + Map toJson() { + final result$data = {}; + final l$username = username; + result$data['username'] = l$username; + return result$data; + } + + CopyWith$Variables$Query$GetUser get copyWith => + CopyWith$Variables$Query$GetUser( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Query$GetUser) || + runtimeType != other.runtimeType) { + return false; + } + final l$username = username; + final lOther$username = other.username; + if (l$username != lOther$username) { + return false; + } + return true; + } @override - factory Variables$Query$GetUser.fromJson(Map json) => - _$Variables$Query$GetUserFromJson(json); - - final String username; - - Map toJson() => _$Variables$Query$GetUserToJson(this); int get hashCode { final l$username = username; return Object.hashAll([l$username]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Query$GetUser) || runtimeType != other.runtimeType) - return false; - final l$username = username; - final lOther$username = other.username; - if (l$username != lOther$username) return false; - return true; - } - - CopyWith$Variables$Query$GetUser get copyWith => - CopyWith$Variables$Query$GetUser(this, (i) => i); } abstract class CopyWith$Variables$Query$GetUser { - factory CopyWith$Variables$Query$GetUser(Variables$Query$GetUser instance, - TRes Function(Variables$Query$GetUser) then) = - _CopyWithImpl$Variables$Query$GetUser; + factory CopyWith$Variables$Query$GetUser( + Variables$Query$GetUser instance, + TRes Function(Variables$Query$GetUser) then, + ) = _CopyWithImpl$Variables$Query$GetUser; factory CopyWith$Variables$Query$GetUser.stub(TRes res) = _CopyWithStubImpl$Variables$Query$GetUser; @@ -778,7 +2703,10 @@ abstract class CopyWith$Variables$Query$GetUser { class _CopyWithImpl$Variables$Query$GetUser implements CopyWith$Variables$Query$GetUser { - _CopyWithImpl$Variables$Query$GetUser(this._instance, this._then); + _CopyWithImpl$Variables$Query$GetUser( + this._instance, + this._then, + ); final Variables$Query$GetUser _instance; @@ -786,10 +2714,12 @@ class _CopyWithImpl$Variables$Query$GetUser static const _undefined = {}; - TRes call({Object? username = _undefined}) => _then(Variables$Query$GetUser( - username: username == _undefined || username == null - ? _instance.username - : (username as String))); + TRes call({Object? username = _undefined}) => + _then(Variables$Query$GetUser._({ + ..._instance._$data, + if (username != _undefined && username != null) + 'username': (username as String), + })); } class _CopyWithStubImpl$Variables$Query$GetUser @@ -801,61 +2731,95 @@ class _CopyWithStubImpl$Variables$Query$GetUser call({String? username}) => _res; } -@JsonSerializable(explicitToJson: true) class Query$GetUser { - Query$GetUser({required this.users, required this.$__typename}); + Query$GetUser({ + required this.users, + required this.$__typename, + }); - @override - factory Query$GetUser.fromJson(Map json) => - _$Query$GetUserFromJson(json); + factory Query$GetUser.fromJson(Map json) { + final l$users = json['users']; + final l$$__typename = json['__typename']; + return Query$GetUser( + users: Query$GetUser$users.fromJson((l$users as Map)), + $__typename: (l$$__typename as String), + ); + } final Query$GetUser$users users; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetUserToJson(this); + Map toJson() { + final _resultData = {}; + final l$users = users; + _resultData['users'] = l$users.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$users = users; final l$$__typename = $__typename; - return Object.hashAll([l$users, l$$__typename]); + return Object.hashAll([ + l$users, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetUser) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetUser) || runtimeType != other.runtimeType) { return false; + } final l$users = users; final lOther$users = other.users; - if (l$users != lOther$users) return false; + if (l$users != lOther$users) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$GetUser on Query$GetUser { - CopyWith$Query$GetUser get copyWith => - CopyWith$Query$GetUser(this, (i) => i); + CopyWith$Query$GetUser get copyWith => CopyWith$Query$GetUser( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetUser { factory CopyWith$Query$GetUser( - Query$GetUser instance, TRes Function(Query$GetUser) then) = - _CopyWithImpl$Query$GetUser; + Query$GetUser instance, + TRes Function(Query$GetUser) then, + ) = _CopyWithImpl$Query$GetUser; factory CopyWith$Query$GetUser.stub(TRes res) = _CopyWithStubImpl$Query$GetUser; - TRes call({Query$GetUser$users? users, String? $__typename}); + TRes call({ + Query$GetUser$users? users, + String? $__typename, + }); CopyWith$Query$GetUser$users get users; } class _CopyWithImpl$Query$GetUser implements CopyWith$Query$GetUser { - _CopyWithImpl$Query$GetUser(this._instance, this._then); + _CopyWithImpl$Query$GetUser( + this._instance, + this._then, + ); final Query$GetUser _instance; @@ -863,14 +2827,18 @@ class _CopyWithImpl$Query$GetUser static const _undefined = {}; - TRes call({Object? users = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? users = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetUser( - users: users == _undefined || users == null - ? _instance.users - : (users as Query$GetUser$users), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + users: users == _undefined || users == null + ? _instance.users + : (users as Query$GetUser$users), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Query$GetUser$users get users { final local$users = _instance.users; return CopyWith$Query$GetUser$users(local$users, (e) => call(users: e)); @@ -883,130 +2851,149 @@ class _CopyWithStubImpl$Query$GetUser TRes _res; - call({Query$GetUser$users? users, String? $__typename}) => _res; + call({ + Query$GetUser$users? users, + String? $__typename, + }) => + _res; CopyWith$Query$GetUser$users get users => CopyWith$Query$GetUser$users.stub(_res); } const documentNodeQueryGetUser = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.query, - name: NameNode(value: 'GetUser'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'username')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'users'), + type: OperationType.query, + name: NameNode(value: 'GetUser'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'username')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'users'), + alias: null, + arguments: [], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'getUser'), alias: null, - arguments: [], + arguments: [ + ArgumentNode( + name: NameNode(value: 'username'), + value: VariableNode(name: NameNode(value: 'username')), + ) + ], directives: [], selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'userFields'), + directives: [], + ), FieldNode( - name: NameNode(value: 'getUser'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'username'), - value: VariableNode(name: NameNode(value: 'username'))) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'userFields'), directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionuserFields, ]); Query$GetUser _parserFn$Query$GetUser(Map data) => Query$GetUser.fromJson(data); class Options$Query$GetUser extends graphql.QueryOptions { - Options$Query$GetUser( - {String? operationName, - required Variables$Query$GetUser variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - Duration? pollInterval, - graphql.Context? context}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - pollInterval: pollInterval, - context: context, - document: documentNodeQueryGetUser, - parserFn: _parserFn$Query$GetUser); + Options$Query$GetUser({ + String? operationName, + required Variables$Query$GetUser variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + Duration? pollInterval, + graphql.Context? context, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + pollInterval: pollInterval, + context: context, + document: documentNodeQueryGetUser, + parserFn: _parserFn$Query$GetUser, + ); } class WatchOptions$Query$GetUser extends graphql.WatchQueryOptions { - WatchOptions$Query$GetUser( - {String? operationName, - required Variables$Query$GetUser variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeQueryGetUser, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Query$GetUser); + WatchOptions$Query$GetUser({ + String? operationName, + required Variables$Query$GetUser variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeQueryGetUser, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Query$GetUser, + ); } class FetchMoreOptions$Query$GetUser extends graphql.FetchMoreOptions { - FetchMoreOptions$Query$GetUser( - {required graphql.UpdateQuery updateQuery, - required Variables$Query$GetUser variables}) - : super( - updateQuery: updateQuery, - variables: variables.toJson(), - document: documentNodeQueryGetUser); + FetchMoreOptions$Query$GetUser({ + required graphql.UpdateQuery updateQuery, + required Variables$Query$GetUser variables, + }) : super( + updateQuery: updateQuery, + variables: variables.toJson(), + document: documentNodeQueryGetUser, + ); } extension ClientExtension$Query$GetUser on graphql.GraphQLClient { @@ -1016,82 +3003,126 @@ extension ClientExtension$Query$GetUser on graphql.GraphQLClient { graphql.ObservableQuery watchQuery$GetUser( WatchOptions$Query$GetUser options) => this.watchQuery(options); - void writeQuery$GetUser( - {required Query$GetUser data, - required Variables$Query$GetUser variables, - bool broadcast = true}) => + void writeQuery$GetUser({ + required Query$GetUser data, + required Variables$Query$GetUser variables, + bool broadcast = true, + }) => this.writeQuery( - graphql.Request( - operation: graphql.Operation(document: documentNodeQueryGetUser), - variables: variables.toJson()), - data: data.toJson(), - broadcast: broadcast); - Query$GetUser? readQuery$GetUser( - {required Variables$Query$GetUser variables, bool optimistic = true}) { - final result = this.readQuery( graphql.Request( - operation: graphql.Operation(document: documentNodeQueryGetUser), - variables: variables.toJson()), - optimistic: optimistic); + operation: graphql.Operation(document: documentNodeQueryGetUser), + variables: variables.toJson(), + ), + data: data.toJson(), + broadcast: broadcast, + ); + Query$GetUser? readQuery$GetUser({ + required Variables$Query$GetUser variables, + bool optimistic = true, + }) { + final result = this.readQuery( + graphql.Request( + operation: graphql.Operation(document: documentNodeQueryGetUser), + variables: variables.toJson(), + ), + optimistic: optimistic, + ); return result == null ? null : Query$GetUser.fromJson(result); } } -@JsonSerializable(explicitToJson: true) class Query$GetUser$users { - Query$GetUser$users({this.getUser, required this.$__typename}); + Query$GetUser$users({ + this.getUser, + required this.$__typename, + }); - @override - factory Query$GetUser$users.fromJson(Map json) => - _$Query$GetUser$usersFromJson(json); + factory Query$GetUser$users.fromJson(Map json) { + final l$getUser = json['getUser']; + final l$$__typename = json['__typename']; + return Query$GetUser$users( + getUser: l$getUser == null + ? null + : Fragment$userFields.fromJson((l$getUser as Map)), + $__typename: (l$$__typename as String), + ); + } final Fragment$userFields? getUser; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Query$GetUser$usersToJson(this); + Map toJson() { + final _resultData = {}; + final l$getUser = getUser; + _resultData['getUser'] = l$getUser?.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$getUser = getUser; final l$$__typename = $__typename; - return Object.hashAll([l$getUser, l$$__typename]); + return Object.hashAll([ + l$getUser, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Query$GetUser$users) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Query$GetUser$users) || runtimeType != other.runtimeType) { return false; + } final l$getUser = getUser; final lOther$getUser = other.getUser; - if (l$getUser != lOther$getUser) return false; + if (l$getUser != lOther$getUser) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Query$GetUser$users on Query$GetUser$users { CopyWith$Query$GetUser$users get copyWith => - CopyWith$Query$GetUser$users(this, (i) => i); + CopyWith$Query$GetUser$users( + this, + (i) => i, + ); } abstract class CopyWith$Query$GetUser$users { - factory CopyWith$Query$GetUser$users(Query$GetUser$users instance, - TRes Function(Query$GetUser$users) then) = - _CopyWithImpl$Query$GetUser$users; + factory CopyWith$Query$GetUser$users( + Query$GetUser$users instance, + TRes Function(Query$GetUser$users) then, + ) = _CopyWithImpl$Query$GetUser$users; factory CopyWith$Query$GetUser$users.stub(TRes res) = _CopyWithStubImpl$Query$GetUser$users; - TRes call({Fragment$userFields? getUser, String? $__typename}); + TRes call({ + Fragment$userFields? getUser, + String? $__typename, + }); CopyWith$Fragment$userFields get getUser; } class _CopyWithImpl$Query$GetUser$users implements CopyWith$Query$GetUser$users { - _CopyWithImpl$Query$GetUser$users(this._instance, this._then); + _CopyWithImpl$Query$GetUser$users( + this._instance, + this._then, + ); final Query$GetUser$users _instance; @@ -1099,14 +3130,18 @@ class _CopyWithImpl$Query$GetUser$users static const _undefined = {}; - TRes call({Object? getUser = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? getUser = _undefined, + Object? $__typename = _undefined, + }) => _then(Query$GetUser$users( - getUser: getUser == _undefined - ? _instance.getUser - : (getUser as Fragment$userFields?), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + getUser: getUser == _undefined + ? _instance.getUser + : (getUser as Fragment$userFields?), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Fragment$userFields get getUser { final local$getUser = _instance.getUser; return local$getUser == null @@ -1121,47 +3156,77 @@ class _CopyWithStubImpl$Query$GetUser$users TRes _res; - call({Fragment$userFields? getUser, String? $__typename}) => _res; + call({ + Fragment$userFields? getUser, + String? $__typename, + }) => + _res; CopyWith$Fragment$userFields get getUser => CopyWith$Fragment$userFields.stub(_res); } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$CreateUser { - Variables$Mutation$CreateUser({required this.user}); + factory Variables$Mutation$CreateUser( + {required Input$UserMutationInput user}) => + Variables$Mutation$CreateUser._({ + r'user': user, + }); + + Variables$Mutation$CreateUser._(this._$data); + + factory Variables$Mutation$CreateUser.fromJson(Map data) { + final result$data = {}; + final l$user = data['user']; + result$data['user'] = + Input$UserMutationInput.fromJson((l$user as Map)); + return Variables$Mutation$CreateUser._(result$data); + } + + Map _$data; + + Input$UserMutationInput get user => + (_$data['user'] as Input$UserMutationInput); + Map toJson() { + final result$data = {}; + final l$user = user; + result$data['user'] = l$user.toJson(); + return result$data; + } + + CopyWith$Variables$Mutation$CreateUser + get copyWith => CopyWith$Variables$Mutation$CreateUser( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$CreateUser) || + runtimeType != other.runtimeType) { + return false; + } + final l$user = user; + final lOther$user = other.user; + if (l$user != lOther$user) { + return false; + } + return true; + } @override - factory Variables$Mutation$CreateUser.fromJson(Map json) => - _$Variables$Mutation$CreateUserFromJson(json); - - final Input$UserMutationInput user; - - Map toJson() => _$Variables$Mutation$CreateUserToJson(this); int get hashCode { final l$user = user; return Object.hashAll([l$user]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$CreateUser) || - runtimeType != other.runtimeType) return false; - final l$user = user; - final lOther$user = other.user; - if (l$user != lOther$user) return false; - return true; - } - - CopyWith$Variables$Mutation$CreateUser - get copyWith => CopyWith$Variables$Mutation$CreateUser(this, (i) => i); } abstract class CopyWith$Variables$Mutation$CreateUser { factory CopyWith$Variables$Mutation$CreateUser( - Variables$Mutation$CreateUser instance, - TRes Function(Variables$Mutation$CreateUser) then) = - _CopyWithImpl$Variables$Mutation$CreateUser; + Variables$Mutation$CreateUser instance, + TRes Function(Variables$Mutation$CreateUser) then, + ) = _CopyWithImpl$Variables$Mutation$CreateUser; factory CopyWith$Variables$Mutation$CreateUser.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$CreateUser; @@ -1171,7 +3236,10 @@ abstract class CopyWith$Variables$Mutation$CreateUser { class _CopyWithImpl$Variables$Mutation$CreateUser implements CopyWith$Variables$Mutation$CreateUser { - _CopyWithImpl$Variables$Mutation$CreateUser(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$CreateUser( + this._instance, + this._then, + ); final Variables$Mutation$CreateUser _instance; @@ -1179,10 +3247,12 @@ class _CopyWithImpl$Variables$Mutation$CreateUser static const _undefined = {}; - TRes call({Object? user = _undefined}) => _then(Variables$Mutation$CreateUser( - user: user == _undefined || user == null - ? _instance.user - : (user as Input$UserMutationInput))); + TRes call({Object? user = _undefined}) => + _then(Variables$Mutation$CreateUser._({ + ..._instance._$data, + if (user != _undefined && user != null) + 'user': (user as Input$UserMutationInput), + })); } class _CopyWithStubImpl$Variables$Mutation$CreateUser @@ -1194,61 +3264,97 @@ class _CopyWithStubImpl$Variables$Mutation$CreateUser call({Input$UserMutationInput? user}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$CreateUser { - Mutation$CreateUser({required this.createUser, required this.$__typename}); + Mutation$CreateUser({ + required this.createUser, + required this.$__typename, + }); - @override - factory Mutation$CreateUser.fromJson(Map json) => - _$Mutation$CreateUserFromJson(json); + factory Mutation$CreateUser.fromJson(Map json) { + final l$createUser = json['createUser']; + final l$$__typename = json['__typename']; + return Mutation$CreateUser( + createUser: Mutation$CreateUser$createUser.fromJson( + (l$createUser as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$CreateUser$createUser createUser; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$CreateUserToJson(this); + Map toJson() { + final _resultData = {}; + final l$createUser = createUser; + _resultData['createUser'] = l$createUser.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$createUser = createUser; final l$$__typename = $__typename; - return Object.hashAll([l$createUser, l$$__typename]); + return Object.hashAll([ + l$createUser, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$CreateUser) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$CreateUser) || runtimeType != other.runtimeType) { return false; + } final l$createUser = createUser; final lOther$createUser = other.createUser; - if (l$createUser != lOther$createUser) return false; + if (l$createUser != lOther$createUser) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$CreateUser on Mutation$CreateUser { CopyWith$Mutation$CreateUser get copyWith => - CopyWith$Mutation$CreateUser(this, (i) => i); + CopyWith$Mutation$CreateUser( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$CreateUser { - factory CopyWith$Mutation$CreateUser(Mutation$CreateUser instance, - TRes Function(Mutation$CreateUser) then) = - _CopyWithImpl$Mutation$CreateUser; + factory CopyWith$Mutation$CreateUser( + Mutation$CreateUser instance, + TRes Function(Mutation$CreateUser) then, + ) = _CopyWithImpl$Mutation$CreateUser; factory CopyWith$Mutation$CreateUser.stub(TRes res) = _CopyWithStubImpl$Mutation$CreateUser; - TRes call({Mutation$CreateUser$createUser? createUser, String? $__typename}); + TRes call({ + Mutation$CreateUser$createUser? createUser, + String? $__typename, + }); CopyWith$Mutation$CreateUser$createUser get createUser; } class _CopyWithImpl$Mutation$CreateUser implements CopyWith$Mutation$CreateUser { - _CopyWithImpl$Mutation$CreateUser(this._instance, this._then); + _CopyWithImpl$Mutation$CreateUser( + this._instance, + this._then, + ); final Mutation$CreateUser _instance; @@ -1256,16 +3362,18 @@ class _CopyWithImpl$Mutation$CreateUser static const _undefined = {}; - TRes call( - {Object? createUser = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? createUser = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$CreateUser( - createUser: createUser == _undefined || createUser == null - ? _instance.createUser - : (createUser as Mutation$CreateUser$createUser), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + createUser: createUser == _undefined || createUser == null + ? _instance.createUser + : (createUser as Mutation$CreateUser$createUser), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$CreateUser$createUser get createUser { final local$createUser = _instance.createUser; return CopyWith$Mutation$CreateUser$createUser( @@ -1279,7 +3387,10 @@ class _CopyWithStubImpl$Mutation$CreateUser TRes _res; - call({Mutation$CreateUser$createUser? createUser, String? $__typename}) => + call({ + Mutation$CreateUser$createUser? createUser, + String? $__typename, + }) => _res; CopyWith$Mutation$CreateUser$createUser get createUser => CopyWith$Mutation$CreateUser$createUser.stub(_res); @@ -1287,98 +3398,116 @@ class _CopyWithStubImpl$Mutation$CreateUser const documentNodeMutationCreateUser = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'CreateUser'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'user')), - type: NamedTypeNode( - name: NameNode(value: 'UserMutationInput'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'createUser'), + type: OperationType.mutation, + name: NameNode(value: 'CreateUser'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'user')), + type: NamedTypeNode( + name: NameNode(value: 'UserMutationInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'createUser'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'user'), + value: VariableNode(name: NameNode(value: 'user')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: 'user'), alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'user'), - value: VariableNode(name: NameNode(value: 'user'))) - ], + arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), + name: NameNode(value: 'userFields'), + directives: [], + ), FieldNode( - name: NameNode(value: 'user'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'userFields'), directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, fragmentDefinitionuserFields, ]); Mutation$CreateUser _parserFn$Mutation$CreateUser(Map data) => Mutation$CreateUser.fromJson(data); typedef OnMutationCompleted$Mutation$CreateUser = FutureOr Function( - dynamic, Mutation$CreateUser?); + dynamic, + Mutation$CreateUser?, +); class Options$Mutation$CreateUser extends graphql.MutationOptions { - Options$Mutation$CreateUser( - {String? operationName, - required Variables$Mutation$CreateUser variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$CreateUser? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$CreateUser({ + String? operationName, + required Variables$Mutation$CreateUser variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$CreateUser? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted(data, - data == null ? null : _parserFn$Mutation$CreateUser(data)), - update: update, - onError: onError, - document: documentNodeMutationCreateUser, - parserFn: _parserFn$Mutation$CreateUser); + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( + data, + data == null ? null : _parserFn$Mutation$CreateUser(data), + ), + update: update, + onError: onError, + document: documentNodeMutationCreateUser, + parserFn: _parserFn$Mutation$CreateUser, + ); final OnMutationCompleted$Mutation$CreateUser? onCompletedWithParsed; @@ -1387,38 +3516,39 @@ class Options$Mutation$CreateUser ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$CreateUser extends graphql.WatchQueryOptions { - WatchOptions$Mutation$CreateUser( - {String? operationName, - required Variables$Mutation$CreateUser variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationCreateUser, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$CreateUser); + WatchOptions$Mutation$CreateUser({ + String? operationName, + required Variables$Mutation$CreateUser variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationCreateUser, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$CreateUser, + ); } extension ClientExtension$Mutation$CreateUser on graphql.GraphQLClient { @@ -1430,19 +3560,32 @@ extension ClientExtension$Mutation$CreateUser on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$CreateUser$createUser - implements Fragment$basicMutationReturnFields { - Mutation$CreateUser$createUser( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.user}); + implements Fragment$basicMutationReturnFields$$UserMutationReturn { + Mutation$CreateUser$createUser({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.user, + }); - @override - factory Mutation$CreateUser$createUser.fromJson(Map json) => - _$Mutation$CreateUser$createUserFromJson(json); + factory Mutation$CreateUser$createUser.fromJson(Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$user = json['user']; + return Mutation$CreateUser$createUser( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + user: l$user == null + ? null + : Fragment$userFields.fromJson((l$user as Map)), + ); + } final int code; @@ -1450,42 +3593,75 @@ class Mutation$CreateUser$createUser final bool success; - @JsonKey(name: '__typename') final String $__typename; final Fragment$userFields? user; - Map toJson() => _$Mutation$CreateUser$createUserToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$user = user; + _resultData['user'] = l$user?.toJson(); + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$user = user; - return Object.hashAll( - [l$code, l$message, l$success, l$$__typename, l$user]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$user, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$CreateUser$createUser) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$user = user; final lOther$user = other.user; - if (l$user != lOther$user) return false; + if (l$user != lOther$user) { + return false; + } return true; } } @@ -1493,30 +3669,37 @@ class Mutation$CreateUser$createUser extension UtilityExtension$Mutation$CreateUser$createUser on Mutation$CreateUser$createUser { CopyWith$Mutation$CreateUser$createUser - get copyWith => CopyWith$Mutation$CreateUser$createUser(this, (i) => i); + get copyWith => CopyWith$Mutation$CreateUser$createUser( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$CreateUser$createUser { factory CopyWith$Mutation$CreateUser$createUser( - Mutation$CreateUser$createUser instance, - TRes Function(Mutation$CreateUser$createUser) then) = - _CopyWithImpl$Mutation$CreateUser$createUser; + Mutation$CreateUser$createUser instance, + TRes Function(Mutation$CreateUser$createUser) then, + ) = _CopyWithImpl$Mutation$CreateUser$createUser; factory CopyWith$Mutation$CreateUser$createUser.stub(TRes res) = _CopyWithStubImpl$Mutation$CreateUser$createUser; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - Fragment$userFields? user}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + Fragment$userFields? user, + }); CopyWith$Fragment$userFields get user; } class _CopyWithImpl$Mutation$CreateUser$createUser implements CopyWith$Mutation$CreateUser$createUser { - _CopyWithImpl$Mutation$CreateUser$createUser(this._instance, this._then); + _CopyWithImpl$Mutation$CreateUser$createUser( + this._instance, + this._then, + ); final Mutation$CreateUser$createUser _instance; @@ -1524,28 +3707,29 @@ class _CopyWithImpl$Mutation$CreateUser$createUser static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? user = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? user = _undefined, + }) => _then(Mutation$CreateUser$createUser( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - user: user == _undefined - ? _instance.user - : (user as Fragment$userFields?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + user: user == _undefined + ? _instance.user + : (user as Fragment$userFields?), + )); CopyWith$Fragment$userFields get user { final local$user = _instance.user; return local$user == null @@ -1560,53 +3744,77 @@ class _CopyWithStubImpl$Mutation$CreateUser$createUser TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - Fragment$userFields? user}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + Fragment$userFields? user, + }) => _res; CopyWith$Fragment$userFields get user => CopyWith$Fragment$userFields.stub(_res); } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$DeleteUser { - Variables$Mutation$DeleteUser({required this.username}); + factory Variables$Mutation$DeleteUser({required String username}) => + Variables$Mutation$DeleteUser._({ + r'username': username, + }); + + Variables$Mutation$DeleteUser._(this._$data); + + factory Variables$Mutation$DeleteUser.fromJson(Map data) { + final result$data = {}; + final l$username = data['username']; + result$data['username'] = (l$username as String); + return Variables$Mutation$DeleteUser._(result$data); + } + + Map _$data; + + String get username => (_$data['username'] as String); + Map toJson() { + final result$data = {}; + final l$username = username; + result$data['username'] = l$username; + return result$data; + } + + CopyWith$Variables$Mutation$DeleteUser + get copyWith => CopyWith$Variables$Mutation$DeleteUser( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$DeleteUser) || + runtimeType != other.runtimeType) { + return false; + } + final l$username = username; + final lOther$username = other.username; + if (l$username != lOther$username) { + return false; + } + return true; + } @override - factory Variables$Mutation$DeleteUser.fromJson(Map json) => - _$Variables$Mutation$DeleteUserFromJson(json); - - final String username; - - Map toJson() => _$Variables$Mutation$DeleteUserToJson(this); int get hashCode { final l$username = username; return Object.hashAll([l$username]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$DeleteUser) || - runtimeType != other.runtimeType) return false; - final l$username = username; - final lOther$username = other.username; - if (l$username != lOther$username) return false; - return true; - } - - CopyWith$Variables$Mutation$DeleteUser - get copyWith => CopyWith$Variables$Mutation$DeleteUser(this, (i) => i); } abstract class CopyWith$Variables$Mutation$DeleteUser { factory CopyWith$Variables$Mutation$DeleteUser( - Variables$Mutation$DeleteUser instance, - TRes Function(Variables$Mutation$DeleteUser) then) = - _CopyWithImpl$Variables$Mutation$DeleteUser; + Variables$Mutation$DeleteUser instance, + TRes Function(Variables$Mutation$DeleteUser) then, + ) = _CopyWithImpl$Variables$Mutation$DeleteUser; factory CopyWith$Variables$Mutation$DeleteUser.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$DeleteUser; @@ -1616,7 +3824,10 @@ abstract class CopyWith$Variables$Mutation$DeleteUser { class _CopyWithImpl$Variables$Mutation$DeleteUser implements CopyWith$Variables$Mutation$DeleteUser { - _CopyWithImpl$Variables$Mutation$DeleteUser(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$DeleteUser( + this._instance, + this._then, + ); final Variables$Mutation$DeleteUser _instance; @@ -1624,11 +3835,12 @@ class _CopyWithImpl$Variables$Mutation$DeleteUser static const _undefined = {}; - TRes call({Object? username = _undefined}) => _then( - Variables$Mutation$DeleteUser( - username: username == _undefined || username == null - ? _instance.username - : (username as String))); + TRes call({Object? username = _undefined}) => + _then(Variables$Mutation$DeleteUser._({ + ..._instance._$data, + if (username != _undefined && username != null) + 'username': (username as String), + })); } class _CopyWithStubImpl$Variables$Mutation$DeleteUser @@ -1640,61 +3852,97 @@ class _CopyWithStubImpl$Variables$Mutation$DeleteUser call({String? username}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$DeleteUser { - Mutation$DeleteUser({required this.deleteUser, required this.$__typename}); + Mutation$DeleteUser({ + required this.deleteUser, + required this.$__typename, + }); - @override - factory Mutation$DeleteUser.fromJson(Map json) => - _$Mutation$DeleteUserFromJson(json); + factory Mutation$DeleteUser.fromJson(Map json) { + final l$deleteUser = json['deleteUser']; + final l$$__typename = json['__typename']; + return Mutation$DeleteUser( + deleteUser: Mutation$DeleteUser$deleteUser.fromJson( + (l$deleteUser as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$DeleteUser$deleteUser deleteUser; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$DeleteUserToJson(this); + Map toJson() { + final _resultData = {}; + final l$deleteUser = deleteUser; + _resultData['deleteUser'] = l$deleteUser.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$deleteUser = deleteUser; final l$$__typename = $__typename; - return Object.hashAll([l$deleteUser, l$$__typename]); + return Object.hashAll([ + l$deleteUser, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$DeleteUser) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$DeleteUser) || runtimeType != other.runtimeType) { return false; + } final l$deleteUser = deleteUser; final lOther$deleteUser = other.deleteUser; - if (l$deleteUser != lOther$deleteUser) return false; + if (l$deleteUser != lOther$deleteUser) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$DeleteUser on Mutation$DeleteUser { CopyWith$Mutation$DeleteUser get copyWith => - CopyWith$Mutation$DeleteUser(this, (i) => i); + CopyWith$Mutation$DeleteUser( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$DeleteUser { - factory CopyWith$Mutation$DeleteUser(Mutation$DeleteUser instance, - TRes Function(Mutation$DeleteUser) then) = - _CopyWithImpl$Mutation$DeleteUser; + factory CopyWith$Mutation$DeleteUser( + Mutation$DeleteUser instance, + TRes Function(Mutation$DeleteUser) then, + ) = _CopyWithImpl$Mutation$DeleteUser; factory CopyWith$Mutation$DeleteUser.stub(TRes res) = _CopyWithStubImpl$Mutation$DeleteUser; - TRes call({Mutation$DeleteUser$deleteUser? deleteUser, String? $__typename}); + TRes call({ + Mutation$DeleteUser$deleteUser? deleteUser, + String? $__typename, + }); CopyWith$Mutation$DeleteUser$deleteUser get deleteUser; } class _CopyWithImpl$Mutation$DeleteUser implements CopyWith$Mutation$DeleteUser { - _CopyWithImpl$Mutation$DeleteUser(this._instance, this._then); + _CopyWithImpl$Mutation$DeleteUser( + this._instance, + this._then, + ); final Mutation$DeleteUser _instance; @@ -1702,16 +3950,18 @@ class _CopyWithImpl$Mutation$DeleteUser static const _undefined = {}; - TRes call( - {Object? deleteUser = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? deleteUser = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$DeleteUser( - deleteUser: deleteUser == _undefined || deleteUser == null - ? _instance.deleteUser - : (deleteUser as Mutation$DeleteUser$deleteUser), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + deleteUser: deleteUser == _undefined || deleteUser == null + ? _instance.deleteUser + : (deleteUser as Mutation$DeleteUser$deleteUser), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$DeleteUser$deleteUser get deleteUser { final local$deleteUser = _instance.deleteUser; return CopyWith$Mutation$DeleteUser$deleteUser( @@ -1725,7 +3975,10 @@ class _CopyWithStubImpl$Mutation$DeleteUser TRes _res; - call({Mutation$DeleteUser$deleteUser? deleteUser, String? $__typename}) => + call({ + Mutation$DeleteUser$deleteUser? deleteUser, + String? $__typename, + }) => _res; CopyWith$Mutation$DeleteUser$deleteUser get deleteUser => CopyWith$Mutation$DeleteUser$deleteUser.stub(_res); @@ -1733,82 +3986,96 @@ class _CopyWithStubImpl$Mutation$DeleteUser const documentNodeMutationDeleteUser = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'DeleteUser'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'username')), - type: - NamedTypeNode(name: NameNode(value: 'String'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'deleteUser'), - alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'username'), - value: VariableNode(name: NameNode(value: 'username'))) - ], + type: OperationType.mutation, + name: NameNode(value: 'DeleteUser'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'username')), + type: NamedTypeNode( + name: NameNode(value: 'String'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'deleteUser'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'username'), + value: VariableNode(name: NameNode(value: 'username')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, ]); Mutation$DeleteUser _parserFn$Mutation$DeleteUser(Map data) => Mutation$DeleteUser.fromJson(data); typedef OnMutationCompleted$Mutation$DeleteUser = FutureOr Function( - dynamic, Mutation$DeleteUser?); + dynamic, + Mutation$DeleteUser?, +); class Options$Mutation$DeleteUser extends graphql.MutationOptions { - Options$Mutation$DeleteUser( - {String? operationName, - required Variables$Mutation$DeleteUser variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$DeleteUser? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$DeleteUser({ + String? operationName, + required Variables$Mutation$DeleteUser variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$DeleteUser? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted(data, - data == null ? null : _parserFn$Mutation$DeleteUser(data)), - update: update, - onError: onError, - document: documentNodeMutationDeleteUser, - parserFn: _parserFn$Mutation$DeleteUser); + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( + data, + data == null ? null : _parserFn$Mutation$DeleteUser(data), + ), + update: update, + onError: onError, + document: documentNodeMutationDeleteUser, + parserFn: _parserFn$Mutation$DeleteUser, + ); final OnMutationCompleted$Mutation$DeleteUser? onCompletedWithParsed; @@ -1817,38 +4084,39 @@ class Options$Mutation$DeleteUser ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$DeleteUser extends graphql.WatchQueryOptions { - WatchOptions$Mutation$DeleteUser( - {String? operationName, - required Variables$Mutation$DeleteUser variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationDeleteUser, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$DeleteUser); + WatchOptions$Mutation$DeleteUser({ + String? operationName, + required Variables$Mutation$DeleteUser variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationDeleteUser, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$DeleteUser, + ); } extension ClientExtension$Mutation$DeleteUser on graphql.GraphQLClient { @@ -1860,18 +4128,27 @@ extension ClientExtension$Mutation$DeleteUser on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$DeleteUser$deleteUser - implements Fragment$basicMutationReturnFields { - Mutation$DeleteUser$deleteUser( - {required this.code, - required this.message, - required this.success, - required this.$__typename}); + implements Fragment$basicMutationReturnFields$$GenericMutationReturn { + Mutation$DeleteUser$deleteUser({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + }); - @override - factory Mutation$DeleteUser$deleteUser.fromJson(Map json) => - _$Mutation$DeleteUser$deleteUserFromJson(json); + factory Mutation$DeleteUser$deleteUser.fromJson(Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + return Mutation$DeleteUser$deleteUser( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + ); + } final int code; @@ -1879,35 +4156,64 @@ class Mutation$DeleteUser$deleteUser final bool success; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$DeleteUser$deleteUserToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; - return Object.hashAll([l$code, l$message, l$success, l$$__typename]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$DeleteUser$deleteUser) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } @@ -1915,24 +4221,35 @@ class Mutation$DeleteUser$deleteUser extension UtilityExtension$Mutation$DeleteUser$deleteUser on Mutation$DeleteUser$deleteUser { CopyWith$Mutation$DeleteUser$deleteUser - get copyWith => CopyWith$Mutation$DeleteUser$deleteUser(this, (i) => i); + get copyWith => CopyWith$Mutation$DeleteUser$deleteUser( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$DeleteUser$deleteUser { factory CopyWith$Mutation$DeleteUser$deleteUser( - Mutation$DeleteUser$deleteUser instance, - TRes Function(Mutation$DeleteUser$deleteUser) then) = - _CopyWithImpl$Mutation$DeleteUser$deleteUser; + Mutation$DeleteUser$deleteUser instance, + TRes Function(Mutation$DeleteUser$deleteUser) then, + ) = _CopyWithImpl$Mutation$DeleteUser$deleteUser; factory CopyWith$Mutation$DeleteUser$deleteUser.stub(TRes res) = _CopyWithStubImpl$Mutation$DeleteUser$deleteUser; - TRes call({int? code, String? message, bool? success, String? $__typename}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + }); } class _CopyWithImpl$Mutation$DeleteUser$deleteUser implements CopyWith$Mutation$DeleteUser$deleteUser { - _CopyWithImpl$Mutation$DeleteUser$deleteUser(this._instance, this._then); + _CopyWithImpl$Mutation$DeleteUser$deleteUser( + this._instance, + this._then, + ); final Mutation$DeleteUser$deleteUser _instance; @@ -1940,24 +4257,25 @@ class _CopyWithImpl$Mutation$DeleteUser$deleteUser static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$DeleteUser$deleteUser( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); } class _CopyWithStubImpl$Mutation$DeleteUser$deleteUser @@ -1966,46 +4284,77 @@ class _CopyWithStubImpl$Mutation$DeleteUser$deleteUser TRes _res; - call({int? code, String? message, bool? success, String? $__typename}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + }) => _res; } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$UpdateUser { - Variables$Mutation$UpdateUser({required this.user}); + factory Variables$Mutation$UpdateUser( + {required Input$UserMutationInput user}) => + Variables$Mutation$UpdateUser._({ + r'user': user, + }); + + Variables$Mutation$UpdateUser._(this._$data); + + factory Variables$Mutation$UpdateUser.fromJson(Map data) { + final result$data = {}; + final l$user = data['user']; + result$data['user'] = + Input$UserMutationInput.fromJson((l$user as Map)); + return Variables$Mutation$UpdateUser._(result$data); + } + + Map _$data; + + Input$UserMutationInput get user => + (_$data['user'] as Input$UserMutationInput); + Map toJson() { + final result$data = {}; + final l$user = user; + result$data['user'] = l$user.toJson(); + return result$data; + } + + CopyWith$Variables$Mutation$UpdateUser + get copyWith => CopyWith$Variables$Mutation$UpdateUser( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$UpdateUser) || + runtimeType != other.runtimeType) { + return false; + } + final l$user = user; + final lOther$user = other.user; + if (l$user != lOther$user) { + return false; + } + return true; + } @override - factory Variables$Mutation$UpdateUser.fromJson(Map json) => - _$Variables$Mutation$UpdateUserFromJson(json); - - final Input$UserMutationInput user; - - Map toJson() => _$Variables$Mutation$UpdateUserToJson(this); int get hashCode { final l$user = user; return Object.hashAll([l$user]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$UpdateUser) || - runtimeType != other.runtimeType) return false; - final l$user = user; - final lOther$user = other.user; - if (l$user != lOther$user) return false; - return true; - } - - CopyWith$Variables$Mutation$UpdateUser - get copyWith => CopyWith$Variables$Mutation$UpdateUser(this, (i) => i); } abstract class CopyWith$Variables$Mutation$UpdateUser { factory CopyWith$Variables$Mutation$UpdateUser( - Variables$Mutation$UpdateUser instance, - TRes Function(Variables$Mutation$UpdateUser) then) = - _CopyWithImpl$Variables$Mutation$UpdateUser; + Variables$Mutation$UpdateUser instance, + TRes Function(Variables$Mutation$UpdateUser) then, + ) = _CopyWithImpl$Variables$Mutation$UpdateUser; factory CopyWith$Variables$Mutation$UpdateUser.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$UpdateUser; @@ -2015,7 +4364,10 @@ abstract class CopyWith$Variables$Mutation$UpdateUser { class _CopyWithImpl$Variables$Mutation$UpdateUser implements CopyWith$Variables$Mutation$UpdateUser { - _CopyWithImpl$Variables$Mutation$UpdateUser(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$UpdateUser( + this._instance, + this._then, + ); final Variables$Mutation$UpdateUser _instance; @@ -2023,10 +4375,12 @@ class _CopyWithImpl$Variables$Mutation$UpdateUser static const _undefined = {}; - TRes call({Object? user = _undefined}) => _then(Variables$Mutation$UpdateUser( - user: user == _undefined || user == null - ? _instance.user - : (user as Input$UserMutationInput))); + TRes call({Object? user = _undefined}) => + _then(Variables$Mutation$UpdateUser._({ + ..._instance._$data, + if (user != _undefined && user != null) + 'user': (user as Input$UserMutationInput), + })); } class _CopyWithStubImpl$Variables$Mutation$UpdateUser @@ -2038,61 +4392,97 @@ class _CopyWithStubImpl$Variables$Mutation$UpdateUser call({Input$UserMutationInput? user}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$UpdateUser { - Mutation$UpdateUser({required this.updateUser, required this.$__typename}); + Mutation$UpdateUser({ + required this.updateUser, + required this.$__typename, + }); - @override - factory Mutation$UpdateUser.fromJson(Map json) => - _$Mutation$UpdateUserFromJson(json); + factory Mutation$UpdateUser.fromJson(Map json) { + final l$updateUser = json['updateUser']; + final l$$__typename = json['__typename']; + return Mutation$UpdateUser( + updateUser: Mutation$UpdateUser$updateUser.fromJson( + (l$updateUser as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$UpdateUser$updateUser updateUser; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$UpdateUserToJson(this); + Map toJson() { + final _resultData = {}; + final l$updateUser = updateUser; + _resultData['updateUser'] = l$updateUser.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$updateUser = updateUser; final l$$__typename = $__typename; - return Object.hashAll([l$updateUser, l$$__typename]); + return Object.hashAll([ + l$updateUser, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$UpdateUser) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$UpdateUser) || runtimeType != other.runtimeType) { return false; + } final l$updateUser = updateUser; final lOther$updateUser = other.updateUser; - if (l$updateUser != lOther$updateUser) return false; + if (l$updateUser != lOther$updateUser) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$UpdateUser on Mutation$UpdateUser { CopyWith$Mutation$UpdateUser get copyWith => - CopyWith$Mutation$UpdateUser(this, (i) => i); + CopyWith$Mutation$UpdateUser( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$UpdateUser { - factory CopyWith$Mutation$UpdateUser(Mutation$UpdateUser instance, - TRes Function(Mutation$UpdateUser) then) = - _CopyWithImpl$Mutation$UpdateUser; + factory CopyWith$Mutation$UpdateUser( + Mutation$UpdateUser instance, + TRes Function(Mutation$UpdateUser) then, + ) = _CopyWithImpl$Mutation$UpdateUser; factory CopyWith$Mutation$UpdateUser.stub(TRes res) = _CopyWithStubImpl$Mutation$UpdateUser; - TRes call({Mutation$UpdateUser$updateUser? updateUser, String? $__typename}); + TRes call({ + Mutation$UpdateUser$updateUser? updateUser, + String? $__typename, + }); CopyWith$Mutation$UpdateUser$updateUser get updateUser; } class _CopyWithImpl$Mutation$UpdateUser implements CopyWith$Mutation$UpdateUser { - _CopyWithImpl$Mutation$UpdateUser(this._instance, this._then); + _CopyWithImpl$Mutation$UpdateUser( + this._instance, + this._then, + ); final Mutation$UpdateUser _instance; @@ -2100,16 +4490,18 @@ class _CopyWithImpl$Mutation$UpdateUser static const _undefined = {}; - TRes call( - {Object? updateUser = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? updateUser = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$UpdateUser( - updateUser: updateUser == _undefined || updateUser == null - ? _instance.updateUser - : (updateUser as Mutation$UpdateUser$updateUser), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + updateUser: updateUser == _undefined || updateUser == null + ? _instance.updateUser + : (updateUser as Mutation$UpdateUser$updateUser), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$UpdateUser$updateUser get updateUser { final local$updateUser = _instance.updateUser; return CopyWith$Mutation$UpdateUser$updateUser( @@ -2123,7 +4515,10 @@ class _CopyWithStubImpl$Mutation$UpdateUser TRes _res; - call({Mutation$UpdateUser$updateUser? updateUser, String? $__typename}) => + call({ + Mutation$UpdateUser$updateUser? updateUser, + String? $__typename, + }) => _res; CopyWith$Mutation$UpdateUser$updateUser get updateUser => CopyWith$Mutation$UpdateUser$updateUser.stub(_res); @@ -2131,98 +4526,116 @@ class _CopyWithStubImpl$Mutation$UpdateUser const documentNodeMutationUpdateUser = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'UpdateUser'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'user')), - type: NamedTypeNode( - name: NameNode(value: 'UserMutationInput'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'updateUser'), + type: OperationType.mutation, + name: NameNode(value: 'UpdateUser'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'user')), + type: NamedTypeNode( + name: NameNode(value: 'UserMutationInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'updateUser'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'user'), + value: VariableNode(name: NameNode(value: 'user')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: 'user'), alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'user'), - value: VariableNode(name: NameNode(value: 'user'))) - ], + arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), + name: NameNode(value: 'userFields'), + directives: [], + ), FieldNode( - name: NameNode(value: 'user'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'userFields'), directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, fragmentDefinitionuserFields, ]); Mutation$UpdateUser _parserFn$Mutation$UpdateUser(Map data) => Mutation$UpdateUser.fromJson(data); typedef OnMutationCompleted$Mutation$UpdateUser = FutureOr Function( - dynamic, Mutation$UpdateUser?); + dynamic, + Mutation$UpdateUser?, +); class Options$Mutation$UpdateUser extends graphql.MutationOptions { - Options$Mutation$UpdateUser( - {String? operationName, - required Variables$Mutation$UpdateUser variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$UpdateUser? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$UpdateUser({ + String? operationName, + required Variables$Mutation$UpdateUser variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$UpdateUser? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted(data, - data == null ? null : _parserFn$Mutation$UpdateUser(data)), - update: update, - onError: onError, - document: documentNodeMutationUpdateUser, - parserFn: _parserFn$Mutation$UpdateUser); + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( + data, + data == null ? null : _parserFn$Mutation$UpdateUser(data), + ), + update: update, + onError: onError, + document: documentNodeMutationUpdateUser, + parserFn: _parserFn$Mutation$UpdateUser, + ); final OnMutationCompleted$Mutation$UpdateUser? onCompletedWithParsed; @@ -2231,38 +4644,39 @@ class Options$Mutation$UpdateUser ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$UpdateUser extends graphql.WatchQueryOptions { - WatchOptions$Mutation$UpdateUser( - {String? operationName, - required Variables$Mutation$UpdateUser variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationUpdateUser, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$UpdateUser); + WatchOptions$Mutation$UpdateUser({ + String? operationName, + required Variables$Mutation$UpdateUser variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationUpdateUser, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$UpdateUser, + ); } extension ClientExtension$Mutation$UpdateUser on graphql.GraphQLClient { @@ -2274,19 +4688,32 @@ extension ClientExtension$Mutation$UpdateUser on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$UpdateUser$updateUser - implements Fragment$basicMutationReturnFields { - Mutation$UpdateUser$updateUser( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.user}); + implements Fragment$basicMutationReturnFields$$UserMutationReturn { + Mutation$UpdateUser$updateUser({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.user, + }); - @override - factory Mutation$UpdateUser$updateUser.fromJson(Map json) => - _$Mutation$UpdateUser$updateUserFromJson(json); + factory Mutation$UpdateUser$updateUser.fromJson(Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$user = json['user']; + return Mutation$UpdateUser$updateUser( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + user: l$user == null + ? null + : Fragment$userFields.fromJson((l$user as Map)), + ); + } final int code; @@ -2294,42 +4721,75 @@ class Mutation$UpdateUser$updateUser final bool success; - @JsonKey(name: '__typename') final String $__typename; final Fragment$userFields? user; - Map toJson() => _$Mutation$UpdateUser$updateUserToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$user = user; + _resultData['user'] = l$user?.toJson(); + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$user = user; - return Object.hashAll( - [l$code, l$message, l$success, l$$__typename, l$user]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$user, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$UpdateUser$updateUser) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$user = user; final lOther$user = other.user; - if (l$user != lOther$user) return false; + if (l$user != lOther$user) { + return false; + } return true; } } @@ -2337,30 +4797,37 @@ class Mutation$UpdateUser$updateUser extension UtilityExtension$Mutation$UpdateUser$updateUser on Mutation$UpdateUser$updateUser { CopyWith$Mutation$UpdateUser$updateUser - get copyWith => CopyWith$Mutation$UpdateUser$updateUser(this, (i) => i); + get copyWith => CopyWith$Mutation$UpdateUser$updateUser( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$UpdateUser$updateUser { factory CopyWith$Mutation$UpdateUser$updateUser( - Mutation$UpdateUser$updateUser instance, - TRes Function(Mutation$UpdateUser$updateUser) then) = - _CopyWithImpl$Mutation$UpdateUser$updateUser; + Mutation$UpdateUser$updateUser instance, + TRes Function(Mutation$UpdateUser$updateUser) then, + ) = _CopyWithImpl$Mutation$UpdateUser$updateUser; factory CopyWith$Mutation$UpdateUser$updateUser.stub(TRes res) = _CopyWithStubImpl$Mutation$UpdateUser$updateUser; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - Fragment$userFields? user}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + Fragment$userFields? user, + }); CopyWith$Fragment$userFields get user; } class _CopyWithImpl$Mutation$UpdateUser$updateUser implements CopyWith$Mutation$UpdateUser$updateUser { - _CopyWithImpl$Mutation$UpdateUser$updateUser(this._instance, this._then); + _CopyWithImpl$Mutation$UpdateUser$updateUser( + this._instance, + this._then, + ); final Mutation$UpdateUser$updateUser _instance; @@ -2368,28 +4835,29 @@ class _CopyWithImpl$Mutation$UpdateUser$updateUser static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? user = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? user = _undefined, + }) => _then(Mutation$UpdateUser$updateUser( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - user: user == _undefined - ? _instance.user - : (user as Fragment$userFields?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + user: user == _undefined + ? _instance.user + : (user as Fragment$userFields?), + )); CopyWith$Fragment$userFields get user { final local$user = _instance.user; return local$user == null @@ -2404,53 +4872,80 @@ class _CopyWithStubImpl$Mutation$UpdateUser$updateUser TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - Fragment$userFields? user}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + Fragment$userFields? user, + }) => _res; CopyWith$Fragment$userFields get user => CopyWith$Fragment$userFields.stub(_res); } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$AddSshKey { - Variables$Mutation$AddSshKey({required this.sshInput}); + factory Variables$Mutation$AddSshKey( + {required Input$SshMutationInput sshInput}) => + Variables$Mutation$AddSshKey._({ + r'sshInput': sshInput, + }); + + Variables$Mutation$AddSshKey._(this._$data); + + factory Variables$Mutation$AddSshKey.fromJson(Map data) { + final result$data = {}; + final l$sshInput = data['sshInput']; + result$data['sshInput'] = + Input$SshMutationInput.fromJson((l$sshInput as Map)); + return Variables$Mutation$AddSshKey._(result$data); + } + + Map _$data; + + Input$SshMutationInput get sshInput => + (_$data['sshInput'] as Input$SshMutationInput); + Map toJson() { + final result$data = {}; + final l$sshInput = sshInput; + result$data['sshInput'] = l$sshInput.toJson(); + return result$data; + } + + CopyWith$Variables$Mutation$AddSshKey + get copyWith => CopyWith$Variables$Mutation$AddSshKey( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$AddSshKey) || + runtimeType != other.runtimeType) { + return false; + } + final l$sshInput = sshInput; + final lOther$sshInput = other.sshInput; + if (l$sshInput != lOther$sshInput) { + return false; + } + return true; + } @override - factory Variables$Mutation$AddSshKey.fromJson(Map json) => - _$Variables$Mutation$AddSshKeyFromJson(json); - - final Input$SshMutationInput sshInput; - - Map toJson() => _$Variables$Mutation$AddSshKeyToJson(this); int get hashCode { final l$sshInput = sshInput; return Object.hashAll([l$sshInput]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$AddSshKey) || - runtimeType != other.runtimeType) return false; - final l$sshInput = sshInput; - final lOther$sshInput = other.sshInput; - if (l$sshInput != lOther$sshInput) return false; - return true; - } - - CopyWith$Variables$Mutation$AddSshKey - get copyWith => CopyWith$Variables$Mutation$AddSshKey(this, (i) => i); } abstract class CopyWith$Variables$Mutation$AddSshKey { factory CopyWith$Variables$Mutation$AddSshKey( - Variables$Mutation$AddSshKey instance, - TRes Function(Variables$Mutation$AddSshKey) then) = - _CopyWithImpl$Variables$Mutation$AddSshKey; + Variables$Mutation$AddSshKey instance, + TRes Function(Variables$Mutation$AddSshKey) then, + ) = _CopyWithImpl$Variables$Mutation$AddSshKey; factory CopyWith$Variables$Mutation$AddSshKey.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$AddSshKey; @@ -2460,7 +4955,10 @@ abstract class CopyWith$Variables$Mutation$AddSshKey { class _CopyWithImpl$Variables$Mutation$AddSshKey implements CopyWith$Variables$Mutation$AddSshKey { - _CopyWithImpl$Variables$Mutation$AddSshKey(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$AddSshKey( + this._instance, + this._then, + ); final Variables$Mutation$AddSshKey _instance; @@ -2469,10 +4967,11 @@ class _CopyWithImpl$Variables$Mutation$AddSshKey static const _undefined = {}; TRes call({Object? sshInput = _undefined}) => - _then(Variables$Mutation$AddSshKey( - sshInput: sshInput == _undefined || sshInput == null - ? _instance.sshInput - : (sshInput as Input$SshMutationInput))); + _then(Variables$Mutation$AddSshKey._({ + ..._instance._$data, + if (sshInput != _undefined && sshInput != null) + 'sshInput': (sshInput as Input$SshMutationInput), + })); } class _CopyWithStubImpl$Variables$Mutation$AddSshKey @@ -2484,61 +4983,97 @@ class _CopyWithStubImpl$Variables$Mutation$AddSshKey call({Input$SshMutationInput? sshInput}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$AddSshKey { - Mutation$AddSshKey({required this.addSshKey, required this.$__typename}); + Mutation$AddSshKey({ + required this.addSshKey, + required this.$__typename, + }); - @override - factory Mutation$AddSshKey.fromJson(Map json) => - _$Mutation$AddSshKeyFromJson(json); + factory Mutation$AddSshKey.fromJson(Map json) { + final l$addSshKey = json['addSshKey']; + final l$$__typename = json['__typename']; + return Mutation$AddSshKey( + addSshKey: Mutation$AddSshKey$addSshKey.fromJson( + (l$addSshKey as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$AddSshKey$addSshKey addSshKey; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$AddSshKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$addSshKey = addSshKey; + _resultData['addSshKey'] = l$addSshKey.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$addSshKey = addSshKey; final l$$__typename = $__typename; - return Object.hashAll([l$addSshKey, l$$__typename]); + return Object.hashAll([ + l$addSshKey, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$AddSshKey) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$AddSshKey) || runtimeType != other.runtimeType) { return false; + } final l$addSshKey = addSshKey; final lOther$addSshKey = other.addSshKey; - if (l$addSshKey != lOther$addSshKey) return false; + if (l$addSshKey != lOther$addSshKey) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$AddSshKey on Mutation$AddSshKey { CopyWith$Mutation$AddSshKey get copyWith => - CopyWith$Mutation$AddSshKey(this, (i) => i); + CopyWith$Mutation$AddSshKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$AddSshKey { factory CopyWith$Mutation$AddSshKey( - Mutation$AddSshKey instance, TRes Function(Mutation$AddSshKey) then) = - _CopyWithImpl$Mutation$AddSshKey; + Mutation$AddSshKey instance, + TRes Function(Mutation$AddSshKey) then, + ) = _CopyWithImpl$Mutation$AddSshKey; factory CopyWith$Mutation$AddSshKey.stub(TRes res) = _CopyWithStubImpl$Mutation$AddSshKey; - TRes call({Mutation$AddSshKey$addSshKey? addSshKey, String? $__typename}); + TRes call({ + Mutation$AddSshKey$addSshKey? addSshKey, + String? $__typename, + }); CopyWith$Mutation$AddSshKey$addSshKey get addSshKey; } class _CopyWithImpl$Mutation$AddSshKey implements CopyWith$Mutation$AddSshKey { - _CopyWithImpl$Mutation$AddSshKey(this._instance, this._then); + _CopyWithImpl$Mutation$AddSshKey( + this._instance, + this._then, + ); final Mutation$AddSshKey _instance; @@ -2546,15 +5081,18 @@ class _CopyWithImpl$Mutation$AddSshKey static const _undefined = {}; - TRes call( - {Object? addSshKey = _undefined, Object? $__typename = _undefined}) => + TRes call({ + Object? addSshKey = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$AddSshKey( - addSshKey: addSshKey == _undefined || addSshKey == null - ? _instance.addSshKey - : (addSshKey as Mutation$AddSshKey$addSshKey), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + addSshKey: addSshKey == _undefined || addSshKey == null + ? _instance.addSshKey + : (addSshKey as Mutation$AddSshKey$addSshKey), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$AddSshKey$addSshKey get addSshKey { final local$addSshKey = _instance.addSshKey; return CopyWith$Mutation$AddSshKey$addSshKey( @@ -2568,105 +5106,127 @@ class _CopyWithStubImpl$Mutation$AddSshKey TRes _res; - call({Mutation$AddSshKey$addSshKey? addSshKey, String? $__typename}) => _res; + call({ + Mutation$AddSshKey$addSshKey? addSshKey, + String? $__typename, + }) => + _res; CopyWith$Mutation$AddSshKey$addSshKey get addSshKey => CopyWith$Mutation$AddSshKey$addSshKey.stub(_res); } const documentNodeMutationAddSshKey = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'AddSshKey'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'sshInput')), - type: NamedTypeNode( - name: NameNode(value: 'SshMutationInput'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'addSshKey'), + type: OperationType.mutation, + name: NameNode(value: 'AddSshKey'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'sshInput')), + type: NamedTypeNode( + name: NameNode(value: 'SshMutationInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'addSshKey'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'sshInput'), + value: VariableNode(name: NameNode(value: 'sshInput')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: 'user'), alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'sshInput'), - value: VariableNode(name: NameNode(value: 'sshInput'))) - ], + arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), + name: NameNode(value: 'userFields'), + directives: [], + ), FieldNode( - name: NameNode(value: 'user'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'userFields'), directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, fragmentDefinitionuserFields, ]); Mutation$AddSshKey _parserFn$Mutation$AddSshKey(Map data) => Mutation$AddSshKey.fromJson(data); typedef OnMutationCompleted$Mutation$AddSshKey = FutureOr Function( - dynamic, Mutation$AddSshKey?); + dynamic, + Mutation$AddSshKey?, +); class Options$Mutation$AddSshKey extends graphql.MutationOptions { - Options$Mutation$AddSshKey( - {String? operationName, - required Variables$Mutation$AddSshKey variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$AddSshKey? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$AddSshKey({ + String? operationName, + required Variables$Mutation$AddSshKey variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$AddSshKey? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted(data, - data == null ? null : _parserFn$Mutation$AddSshKey(data)), - update: update, - onError: onError, - document: documentNodeMutationAddSshKey, - parserFn: _parserFn$Mutation$AddSshKey); + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( + data, + data == null ? null : _parserFn$Mutation$AddSshKey(data), + ), + update: update, + onError: onError, + document: documentNodeMutationAddSshKey, + parserFn: _parserFn$Mutation$AddSshKey, + ); final OnMutationCompleted$Mutation$AddSshKey? onCompletedWithParsed; @@ -2675,38 +5235,39 @@ class Options$Mutation$AddSshKey ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$AddSshKey extends graphql.WatchQueryOptions { - WatchOptions$Mutation$AddSshKey( - {String? operationName, - required Variables$Mutation$AddSshKey variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationAddSshKey, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$AddSshKey); + WatchOptions$Mutation$AddSshKey({ + String? operationName, + required Variables$Mutation$AddSshKey variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationAddSshKey, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$AddSshKey, + ); } extension ClientExtension$Mutation$AddSshKey on graphql.GraphQLClient { @@ -2718,19 +5279,32 @@ extension ClientExtension$Mutation$AddSshKey on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$AddSshKey$addSshKey - implements Fragment$basicMutationReturnFields { - Mutation$AddSshKey$addSshKey( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.user}); + implements Fragment$basicMutationReturnFields$$UserMutationReturn { + Mutation$AddSshKey$addSshKey({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.user, + }); - @override - factory Mutation$AddSshKey$addSshKey.fromJson(Map json) => - _$Mutation$AddSshKey$addSshKeyFromJson(json); + factory Mutation$AddSshKey$addSshKey.fromJson(Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$user = json['user']; + return Mutation$AddSshKey$addSshKey( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + user: l$user == null + ? null + : Fragment$userFields.fromJson((l$user as Map)), + ); + } final int code; @@ -2738,42 +5312,75 @@ class Mutation$AddSshKey$addSshKey final bool success; - @JsonKey(name: '__typename') final String $__typename; final Fragment$userFields? user; - Map toJson() => _$Mutation$AddSshKey$addSshKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$user = user; + _resultData['user'] = l$user?.toJson(); + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$user = user; - return Object.hashAll( - [l$code, l$message, l$success, l$$__typename, l$user]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$user, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$AddSshKey$addSshKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$user = user; final lOther$user = other.user; - if (l$user != lOther$user) return false; + if (l$user != lOther$user) { + return false; + } return true; } } @@ -2781,30 +5388,37 @@ class Mutation$AddSshKey$addSshKey extension UtilityExtension$Mutation$AddSshKey$addSshKey on Mutation$AddSshKey$addSshKey { CopyWith$Mutation$AddSshKey$addSshKey - get copyWith => CopyWith$Mutation$AddSshKey$addSshKey(this, (i) => i); + get copyWith => CopyWith$Mutation$AddSshKey$addSshKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$AddSshKey$addSshKey { factory CopyWith$Mutation$AddSshKey$addSshKey( - Mutation$AddSshKey$addSshKey instance, - TRes Function(Mutation$AddSshKey$addSshKey) then) = - _CopyWithImpl$Mutation$AddSshKey$addSshKey; + Mutation$AddSshKey$addSshKey instance, + TRes Function(Mutation$AddSshKey$addSshKey) then, + ) = _CopyWithImpl$Mutation$AddSshKey$addSshKey; factory CopyWith$Mutation$AddSshKey$addSshKey.stub(TRes res) = _CopyWithStubImpl$Mutation$AddSshKey$addSshKey; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - Fragment$userFields? user}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + Fragment$userFields? user, + }); CopyWith$Fragment$userFields get user; } class _CopyWithImpl$Mutation$AddSshKey$addSshKey implements CopyWith$Mutation$AddSshKey$addSshKey { - _CopyWithImpl$Mutation$AddSshKey$addSshKey(this._instance, this._then); + _CopyWithImpl$Mutation$AddSshKey$addSshKey( + this._instance, + this._then, + ); final Mutation$AddSshKey$addSshKey _instance; @@ -2812,28 +5426,29 @@ class _CopyWithImpl$Mutation$AddSshKey$addSshKey static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? user = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? user = _undefined, + }) => _then(Mutation$AddSshKey$addSshKey( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - user: user == _undefined - ? _instance.user - : (user as Fragment$userFields?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + user: user == _undefined + ? _instance.user + : (user as Fragment$userFields?), + )); CopyWith$Fragment$userFields get user { final local$user = _instance.user; return local$user == null @@ -2848,54 +5463,80 @@ class _CopyWithStubImpl$Mutation$AddSshKey$addSshKey TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - Fragment$userFields? user}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + Fragment$userFields? user, + }) => _res; CopyWith$Fragment$userFields get user => CopyWith$Fragment$userFields.stub(_res); } -@JsonSerializable(explicitToJson: true) class Variables$Mutation$RemoveSshKey { - Variables$Mutation$RemoveSshKey({required this.sshInput}); + factory Variables$Mutation$RemoveSshKey( + {required Input$SshMutationInput sshInput}) => + Variables$Mutation$RemoveSshKey._({ + r'sshInput': sshInput, + }); + + Variables$Mutation$RemoveSshKey._(this._$data); + + factory Variables$Mutation$RemoveSshKey.fromJson(Map data) { + final result$data = {}; + final l$sshInput = data['sshInput']; + result$data['sshInput'] = + Input$SshMutationInput.fromJson((l$sshInput as Map)); + return Variables$Mutation$RemoveSshKey._(result$data); + } + + Map _$data; + + Input$SshMutationInput get sshInput => + (_$data['sshInput'] as Input$SshMutationInput); + Map toJson() { + final result$data = {}; + final l$sshInput = sshInput; + result$data['sshInput'] = l$sshInput.toJson(); + return result$data; + } + + CopyWith$Variables$Mutation$RemoveSshKey + get copyWith => CopyWith$Variables$Mutation$RemoveSshKey( + this, + (i) => i, + ); + @override + bool operator ==(Object other) { + if (identical(this, other)) { + return true; + } + if (!(other is Variables$Mutation$RemoveSshKey) || + runtimeType != other.runtimeType) { + return false; + } + final l$sshInput = sshInput; + final lOther$sshInput = other.sshInput; + if (l$sshInput != lOther$sshInput) { + return false; + } + return true; + } @override - factory Variables$Mutation$RemoveSshKey.fromJson(Map json) => - _$Variables$Mutation$RemoveSshKeyFromJson(json); - - final Input$SshMutationInput sshInput; - - Map toJson() => - _$Variables$Mutation$RemoveSshKeyToJson(this); int get hashCode { final l$sshInput = sshInput; return Object.hashAll([l$sshInput]); } - - @override - bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Variables$Mutation$RemoveSshKey) || - runtimeType != other.runtimeType) return false; - final l$sshInput = sshInput; - final lOther$sshInput = other.sshInput; - if (l$sshInput != lOther$sshInput) return false; - return true; - } - - CopyWith$Variables$Mutation$RemoveSshKey - get copyWith => CopyWith$Variables$Mutation$RemoveSshKey(this, (i) => i); } abstract class CopyWith$Variables$Mutation$RemoveSshKey { factory CopyWith$Variables$Mutation$RemoveSshKey( - Variables$Mutation$RemoveSshKey instance, - TRes Function(Variables$Mutation$RemoveSshKey) then) = - _CopyWithImpl$Variables$Mutation$RemoveSshKey; + Variables$Mutation$RemoveSshKey instance, + TRes Function(Variables$Mutation$RemoveSshKey) then, + ) = _CopyWithImpl$Variables$Mutation$RemoveSshKey; factory CopyWith$Variables$Mutation$RemoveSshKey.stub(TRes res) = _CopyWithStubImpl$Variables$Mutation$RemoveSshKey; @@ -2905,7 +5546,10 @@ abstract class CopyWith$Variables$Mutation$RemoveSshKey { class _CopyWithImpl$Variables$Mutation$RemoveSshKey implements CopyWith$Variables$Mutation$RemoveSshKey { - _CopyWithImpl$Variables$Mutation$RemoveSshKey(this._instance, this._then); + _CopyWithImpl$Variables$Mutation$RemoveSshKey( + this._instance, + this._then, + ); final Variables$Mutation$RemoveSshKey _instance; @@ -2914,10 +5558,11 @@ class _CopyWithImpl$Variables$Mutation$RemoveSshKey static const _undefined = {}; TRes call({Object? sshInput = _undefined}) => - _then(Variables$Mutation$RemoveSshKey( - sshInput: sshInput == _undefined || sshInput == null - ? _instance.sshInput - : (sshInput as Input$SshMutationInput))); + _then(Variables$Mutation$RemoveSshKey._({ + ..._instance._$data, + if (sshInput != _undefined && sshInput != null) + 'sshInput': (sshInput as Input$SshMutationInput), + })); } class _CopyWithStubImpl$Variables$Mutation$RemoveSshKey @@ -2929,63 +5574,97 @@ class _CopyWithStubImpl$Variables$Mutation$RemoveSshKey call({Input$SshMutationInput? sshInput}) => _res; } -@JsonSerializable(explicitToJson: true) class Mutation$RemoveSshKey { - Mutation$RemoveSshKey( - {required this.removeSshKey, required this.$__typename}); + Mutation$RemoveSshKey({ + required this.removeSshKey, + required this.$__typename, + }); - @override - factory Mutation$RemoveSshKey.fromJson(Map json) => - _$Mutation$RemoveSshKeyFromJson(json); + factory Mutation$RemoveSshKey.fromJson(Map json) { + final l$removeSshKey = json['removeSshKey']; + final l$$__typename = json['__typename']; + return Mutation$RemoveSshKey( + removeSshKey: Mutation$RemoveSshKey$removeSshKey.fromJson( + (l$removeSshKey as Map)), + $__typename: (l$$__typename as String), + ); + } final Mutation$RemoveSshKey$removeSshKey removeSshKey; - @JsonKey(name: '__typename') final String $__typename; - Map toJson() => _$Mutation$RemoveSshKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$removeSshKey = removeSshKey; + _resultData['removeSshKey'] = l$removeSshKey.toJson(); + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + return _resultData; + } + + @override int get hashCode { final l$removeSshKey = removeSshKey; final l$$__typename = $__typename; - return Object.hashAll([l$removeSshKey, l$$__typename]); + return Object.hashAll([ + l$removeSshKey, + l$$__typename, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; - if (!(other is Mutation$RemoveSshKey) || runtimeType != other.runtimeType) + if (identical(this, other)) { + return true; + } + if (!(other is Mutation$RemoveSshKey) || runtimeType != other.runtimeType) { return false; + } final l$removeSshKey = removeSshKey; final lOther$removeSshKey = other.removeSshKey; - if (l$removeSshKey != lOther$removeSshKey) return false; + if (l$removeSshKey != lOther$removeSshKey) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } return true; } } extension UtilityExtension$Mutation$RemoveSshKey on Mutation$RemoveSshKey { CopyWith$Mutation$RemoveSshKey get copyWith => - CopyWith$Mutation$RemoveSshKey(this, (i) => i); + CopyWith$Mutation$RemoveSshKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RemoveSshKey { - factory CopyWith$Mutation$RemoveSshKey(Mutation$RemoveSshKey instance, - TRes Function(Mutation$RemoveSshKey) then) = - _CopyWithImpl$Mutation$RemoveSshKey; + factory CopyWith$Mutation$RemoveSshKey( + Mutation$RemoveSshKey instance, + TRes Function(Mutation$RemoveSshKey) then, + ) = _CopyWithImpl$Mutation$RemoveSshKey; factory CopyWith$Mutation$RemoveSshKey.stub(TRes res) = _CopyWithStubImpl$Mutation$RemoveSshKey; - TRes call( - {Mutation$RemoveSshKey$removeSshKey? removeSshKey, String? $__typename}); + TRes call({ + Mutation$RemoveSshKey$removeSshKey? removeSshKey, + String? $__typename, + }); CopyWith$Mutation$RemoveSshKey$removeSshKey get removeSshKey; } class _CopyWithImpl$Mutation$RemoveSshKey implements CopyWith$Mutation$RemoveSshKey { - _CopyWithImpl$Mutation$RemoveSshKey(this._instance, this._then); + _CopyWithImpl$Mutation$RemoveSshKey( + this._instance, + this._then, + ); final Mutation$RemoveSshKey _instance; @@ -2993,16 +5672,18 @@ class _CopyWithImpl$Mutation$RemoveSshKey static const _undefined = {}; - TRes call( - {Object? removeSshKey = _undefined, - Object? $__typename = _undefined}) => + TRes call({ + Object? removeSshKey = _undefined, + Object? $__typename = _undefined, + }) => _then(Mutation$RemoveSshKey( - removeSshKey: removeSshKey == _undefined || removeSshKey == null - ? _instance.removeSshKey - : (removeSshKey as Mutation$RemoveSshKey$removeSshKey), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String))); + removeSshKey: removeSshKey == _undefined || removeSshKey == null + ? _instance.removeSshKey + : (removeSshKey as Mutation$RemoveSshKey$removeSshKey), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + )); CopyWith$Mutation$RemoveSshKey$removeSshKey get removeSshKey { final local$removeSshKey = _instance.removeSshKey; return CopyWith$Mutation$RemoveSshKey$removeSshKey( @@ -3016,9 +5697,10 @@ class _CopyWithStubImpl$Mutation$RemoveSshKey TRes _res; - call( - {Mutation$RemoveSshKey$removeSshKey? removeSshKey, - String? $__typename}) => + call({ + Mutation$RemoveSshKey$removeSshKey? removeSshKey, + String? $__typename, + }) => _res; CopyWith$Mutation$RemoveSshKey$removeSshKey get removeSshKey => CopyWith$Mutation$RemoveSshKey$removeSshKey.stub(_res); @@ -3026,60 +5708,73 @@ class _CopyWithStubImpl$Mutation$RemoveSshKey const documentNodeMutationRemoveSshKey = DocumentNode(definitions: [ OperationDefinitionNode( - type: OperationType.mutation, - name: NameNode(value: 'RemoveSshKey'), - variableDefinitions: [ - VariableDefinitionNode( - variable: VariableNode(name: NameNode(value: 'sshInput')), - type: NamedTypeNode( - name: NameNode(value: 'SshMutationInput'), isNonNull: true), - defaultValue: DefaultValueNode(value: null), - directives: []) - ], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FieldNode( - name: NameNode(value: 'removeSshKey'), + type: OperationType.mutation, + name: NameNode(value: 'RemoveSshKey'), + variableDefinitions: [ + VariableDefinitionNode( + variable: VariableNode(name: NameNode(value: 'sshInput')), + type: NamedTypeNode( + name: NameNode(value: 'SshMutationInput'), + isNonNull: true, + ), + defaultValue: DefaultValueNode(value: null), + directives: [], + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FieldNode( + name: NameNode(value: 'removeSshKey'), + alias: null, + arguments: [ + ArgumentNode( + name: NameNode(value: 'sshInput'), + value: VariableNode(name: NameNode(value: 'sshInput')), + ) + ], + directives: [], + selectionSet: SelectionSetNode(selections: [ + FragmentSpreadNode( + name: NameNode(value: 'basicMutationReturnFields'), + directives: [], + ), + FieldNode( + name: NameNode(value: 'user'), alias: null, - arguments: [ - ArgumentNode( - name: NameNode(value: 'sshInput'), - value: VariableNode(name: NameNode(value: 'sshInput'))) - ], + arguments: [], directives: [], selectionSet: SelectionSetNode(selections: [ FragmentSpreadNode( - name: NameNode(value: 'basicMutationReturnFields'), - directives: []), + name: NameNode(value: 'userFields'), + directives: [], + ), FieldNode( - name: NameNode(value: 'user'), - alias: null, - arguments: [], - directives: [], - selectionSet: SelectionSetNode(selections: [ - FragmentSpreadNode( - name: NameNode(value: 'userFields'), directives: []), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( - name: NameNode(value: '__typename'), - alias: null, - arguments: [], - directives: [], - selectionSet: null) - ])), - FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), + FieldNode( name: NameNode(value: '__typename'), alias: null, arguments: [], directives: [], - selectionSet: null) - ])), + selectionSet: null, + ), + ]), + ), + FieldNode( + name: NameNode(value: '__typename'), + alias: null, + arguments: [], + directives: [], + selectionSet: null, + ), + ]), + ), fragmentDefinitionbasicMutationReturnFields, fragmentDefinitionuserFields, ]); @@ -3087,41 +5782,43 @@ Mutation$RemoveSshKey _parserFn$Mutation$RemoveSshKey( Map data) => Mutation$RemoveSshKey.fromJson(data); typedef OnMutationCompleted$Mutation$RemoveSshKey = FutureOr Function( - dynamic, Mutation$RemoveSshKey?); + dynamic, + Mutation$RemoveSshKey?, +); class Options$Mutation$RemoveSshKey extends graphql.MutationOptions { - Options$Mutation$RemoveSshKey( - {String? operationName, - required Variables$Mutation$RemoveSshKey variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - OnMutationCompleted$Mutation$RemoveSshKey? onCompleted, - graphql.OnMutationUpdate? update, - graphql.OnError? onError}) - : onCompletedWithParsed = onCompleted, + Options$Mutation$RemoveSshKey({ + String? operationName, + required Variables$Mutation$RemoveSshKey variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + OnMutationCompleted$Mutation$RemoveSshKey? onCompleted, + graphql.OnMutationUpdate? update, + graphql.OnError? onError, + }) : onCompletedWithParsed = onCompleted, super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - onCompleted: onCompleted == null - ? null - : (data) => onCompleted( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + onCompleted: onCompleted == null + ? null + : (data) => onCompleted( data, - data == null - ? null - : _parserFn$Mutation$RemoveSshKey(data)), - update: update, - onError: onError, - document: documentNodeMutationRemoveSshKey, - parserFn: _parserFn$Mutation$RemoveSshKey); + data == null ? null : _parserFn$Mutation$RemoveSshKey(data), + ), + update: update, + onError: onError, + document: documentNodeMutationRemoveSshKey, + parserFn: _parserFn$Mutation$RemoveSshKey, + ); final OnMutationCompleted$Mutation$RemoveSshKey? onCompletedWithParsed; @@ -3130,38 +5827,39 @@ class Options$Mutation$RemoveSshKey ...super.onCompleted == null ? super.properties : super.properties.where((property) => property != onCompleted), - onCompletedWithParsed + onCompletedWithParsed, ]; } class WatchOptions$Mutation$RemoveSshKey extends graphql.WatchQueryOptions { - WatchOptions$Mutation$RemoveSshKey( - {String? operationName, - required Variables$Mutation$RemoveSshKey variables, - graphql.FetchPolicy? fetchPolicy, - graphql.ErrorPolicy? errorPolicy, - graphql.CacheRereadPolicy? cacheRereadPolicy, - Object? optimisticResult, - graphql.Context? context, - Duration? pollInterval, - bool? eagerlyFetchResults, - bool carryForwardDataOnException = true, - bool fetchResults = false}) - : super( - variables: variables.toJson(), - operationName: operationName, - fetchPolicy: fetchPolicy, - errorPolicy: errorPolicy, - cacheRereadPolicy: cacheRereadPolicy, - optimisticResult: optimisticResult, - context: context, - document: documentNodeMutationRemoveSshKey, - pollInterval: pollInterval, - eagerlyFetchResults: eagerlyFetchResults, - carryForwardDataOnException: carryForwardDataOnException, - fetchResults: fetchResults, - parserFn: _parserFn$Mutation$RemoveSshKey); + WatchOptions$Mutation$RemoveSshKey({ + String? operationName, + required Variables$Mutation$RemoveSshKey variables, + graphql.FetchPolicy? fetchPolicy, + graphql.ErrorPolicy? errorPolicy, + graphql.CacheRereadPolicy? cacheRereadPolicy, + Object? optimisticResult, + graphql.Context? context, + Duration? pollInterval, + bool? eagerlyFetchResults, + bool carryForwardDataOnException = true, + bool fetchResults = false, + }) : super( + variables: variables.toJson(), + operationName: operationName, + fetchPolicy: fetchPolicy, + errorPolicy: errorPolicy, + cacheRereadPolicy: cacheRereadPolicy, + optimisticResult: optimisticResult, + context: context, + document: documentNodeMutationRemoveSshKey, + pollInterval: pollInterval, + eagerlyFetchResults: eagerlyFetchResults, + carryForwardDataOnException: carryForwardDataOnException, + fetchResults: fetchResults, + parserFn: _parserFn$Mutation$RemoveSshKey, + ); } extension ClientExtension$Mutation$RemoveSshKey on graphql.GraphQLClient { @@ -3173,20 +5871,33 @@ extension ClientExtension$Mutation$RemoveSshKey on graphql.GraphQLClient { this.watchMutation(options); } -@JsonSerializable(explicitToJson: true) class Mutation$RemoveSshKey$removeSshKey - implements Fragment$basicMutationReturnFields { - Mutation$RemoveSshKey$removeSshKey( - {required this.code, - required this.message, - required this.success, - required this.$__typename, - this.user}); + implements Fragment$basicMutationReturnFields$$UserMutationReturn { + Mutation$RemoveSshKey$removeSshKey({ + required this.code, + required this.message, + required this.success, + required this.$__typename, + this.user, + }); - @override factory Mutation$RemoveSshKey$removeSshKey.fromJson( - Map json) => - _$Mutation$RemoveSshKey$removeSshKeyFromJson(json); + Map json) { + final l$code = json['code']; + final l$message = json['message']; + final l$success = json['success']; + final l$$__typename = json['__typename']; + final l$user = json['user']; + return Mutation$RemoveSshKey$removeSshKey( + code: (l$code as int), + message: (l$message as String), + success: (l$success as bool), + $__typename: (l$$__typename as String), + user: l$user == null + ? null + : Fragment$userFields.fromJson((l$user as Map)), + ); + } final int code; @@ -3194,43 +5905,75 @@ class Mutation$RemoveSshKey$removeSshKey final bool success; - @JsonKey(name: '__typename') final String $__typename; final Fragment$userFields? user; - Map toJson() => - _$Mutation$RemoveSshKey$removeSshKeyToJson(this); + Map toJson() { + final _resultData = {}; + final l$code = code; + _resultData['code'] = l$code; + final l$message = message; + _resultData['message'] = l$message; + final l$success = success; + _resultData['success'] = l$success; + final l$$__typename = $__typename; + _resultData['__typename'] = l$$__typename; + final l$user = user; + _resultData['user'] = l$user?.toJson(); + return _resultData; + } + + @override int get hashCode { final l$code = code; final l$message = message; final l$success = success; final l$$__typename = $__typename; final l$user = user; - return Object.hashAll( - [l$code, l$message, l$success, l$$__typename, l$user]); + return Object.hashAll([ + l$code, + l$message, + l$success, + l$$__typename, + l$user, + ]); } @override bool operator ==(Object other) { - if (identical(this, other)) return true; + if (identical(this, other)) { + return true; + } if (!(other is Mutation$RemoveSshKey$removeSshKey) || - runtimeType != other.runtimeType) return false; + runtimeType != other.runtimeType) { + return false; + } final l$code = code; final lOther$code = other.code; - if (l$code != lOther$code) return false; + if (l$code != lOther$code) { + return false; + } final l$message = message; final lOther$message = other.message; - if (l$message != lOther$message) return false; + if (l$message != lOther$message) { + return false; + } final l$success = success; final lOther$success = other.success; - if (l$success != lOther$success) return false; + if (l$success != lOther$success) { + return false; + } final l$$__typename = $__typename; final lOther$$__typename = other.$__typename; - if (l$$__typename != lOther$$__typename) return false; + if (l$$__typename != lOther$$__typename) { + return false; + } final l$user = user; final lOther$user = other.user; - if (l$user != lOther$user) return false; + if (l$user != lOther$user) { + return false; + } return true; } } @@ -3239,31 +5982,37 @@ extension UtilityExtension$Mutation$RemoveSshKey$removeSshKey on Mutation$RemoveSshKey$removeSshKey { CopyWith$Mutation$RemoveSshKey$removeSshKey< Mutation$RemoveSshKey$removeSshKey> - get copyWith => - CopyWith$Mutation$RemoveSshKey$removeSshKey(this, (i) => i); + get copyWith => CopyWith$Mutation$RemoveSshKey$removeSshKey( + this, + (i) => i, + ); } abstract class CopyWith$Mutation$RemoveSshKey$removeSshKey { factory CopyWith$Mutation$RemoveSshKey$removeSshKey( - Mutation$RemoveSshKey$removeSshKey instance, - TRes Function(Mutation$RemoveSshKey$removeSshKey) then) = - _CopyWithImpl$Mutation$RemoveSshKey$removeSshKey; + Mutation$RemoveSshKey$removeSshKey instance, + TRes Function(Mutation$RemoveSshKey$removeSshKey) then, + ) = _CopyWithImpl$Mutation$RemoveSshKey$removeSshKey; factory CopyWith$Mutation$RemoveSshKey$removeSshKey.stub(TRes res) = _CopyWithStubImpl$Mutation$RemoveSshKey$removeSshKey; - TRes call( - {int? code, - String? message, - bool? success, - String? $__typename, - Fragment$userFields? user}); + TRes call({ + int? code, + String? message, + bool? success, + String? $__typename, + Fragment$userFields? user, + }); CopyWith$Fragment$userFields get user; } class _CopyWithImpl$Mutation$RemoveSshKey$removeSshKey implements CopyWith$Mutation$RemoveSshKey$removeSshKey { - _CopyWithImpl$Mutation$RemoveSshKey$removeSshKey(this._instance, this._then); + _CopyWithImpl$Mutation$RemoveSshKey$removeSshKey( + this._instance, + this._then, + ); final Mutation$RemoveSshKey$removeSshKey _instance; @@ -3271,28 +6020,29 @@ class _CopyWithImpl$Mutation$RemoveSshKey$removeSshKey static const _undefined = {}; - TRes call( - {Object? code = _undefined, - Object? message = _undefined, - Object? success = _undefined, - Object? $__typename = _undefined, - Object? user = _undefined}) => + TRes call({ + Object? code = _undefined, + Object? message = _undefined, + Object? success = _undefined, + Object? $__typename = _undefined, + Object? user = _undefined, + }) => _then(Mutation$RemoveSshKey$removeSshKey( - code: code == _undefined || code == null - ? _instance.code - : (code as int), - message: message == _undefined || message == null - ? _instance.message - : (message as String), - success: success == _undefined || success == null - ? _instance.success - : (success as bool), - $__typename: $__typename == _undefined || $__typename == null - ? _instance.$__typename - : ($__typename as String), - user: user == _undefined - ? _instance.user - : (user as Fragment$userFields?))); + code: + code == _undefined || code == null ? _instance.code : (code as int), + message: message == _undefined || message == null + ? _instance.message + : (message as String), + success: success == _undefined || success == null + ? _instance.success + : (success as bool), + $__typename: $__typename == _undefined || $__typename == null + ? _instance.$__typename + : ($__typename as String), + user: user == _undefined + ? _instance.user + : (user as Fragment$userFields?), + )); CopyWith$Fragment$userFields get user { final local$user = _instance.user; return local$user == null @@ -3307,12 +6057,13 @@ class _CopyWithStubImpl$Mutation$RemoveSshKey$removeSshKey TRes _res; - call( - {int? code, - String? message, - bool? success, - String? $__typename, - Fragment$userFields? user}) => + call({ + int? code, + String? message, + bool? success, + String? $__typename, + Fragment$userFields? user, + }) => _res; CopyWith$Fragment$userFields get user => CopyWith$Fragment$userFields.stub(_res); diff --git a/lib/logic/api_maps/graphql_maps/schema/users.graphql.g.dart b/lib/logic/api_maps/graphql_maps/schema/users.graphql.g.dart deleted file mode 100644 index 7fb93e4e..00000000 --- a/lib/logic/api_maps/graphql_maps/schema/users.graphql.g.dart +++ /dev/null @@ -1,366 +0,0 @@ -// GENERATED CODE - DO NOT MODIFY BY HAND - -part of 'users.graphql.dart'; - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -Fragment$basicMutationReturnFields _$Fragment$basicMutationReturnFieldsFromJson( - Map json) => - Fragment$basicMutationReturnFields( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Fragment$basicMutationReturnFieldsToJson( - Fragment$basicMutationReturnFields instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Fragment$userFields _$Fragment$userFieldsFromJson(Map json) => - Fragment$userFields( - username: json['username'] as String, - userType: $enumDecode(_$Enum$UserTypeEnumMap, json['userType'], - unknownValue: Enum$UserType.$unknown), - sshKeys: - (json['sshKeys'] as List).map((e) => e as String).toList(), - $__typename: json['__typename'] as String, - ); - -Map _$Fragment$userFieldsToJson( - Fragment$userFields instance) => - { - 'username': instance.username, - 'userType': _$Enum$UserTypeEnumMap[instance.userType]!, - 'sshKeys': instance.sshKeys, - '__typename': instance.$__typename, - }; - -const _$Enum$UserTypeEnumMap = { - Enum$UserType.NORMAL: 'NORMAL', - Enum$UserType.PRIMARY: 'PRIMARY', - Enum$UserType.ROOT: 'ROOT', - Enum$UserType.$unknown: r'$unknown', -}; - -Query$AllUsers _$Query$AllUsersFromJson(Map json) => - Query$AllUsers( - users: - Query$AllUsers$users.fromJson(json['users'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$AllUsersToJson(Query$AllUsers instance) => - { - 'users': instance.users.toJson(), - '__typename': instance.$__typename, - }; - -Query$AllUsers$users _$Query$AllUsers$usersFromJson( - Map json) => - Query$AllUsers$users( - allUsers: (json['allUsers'] as List) - .map((e) => Fragment$userFields.fromJson(e as Map)) - .toList(), - rootUser: json['rootUser'] == null - ? null - : Fragment$userFields.fromJson( - json['rootUser'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$AllUsers$usersToJson( - Query$AllUsers$users instance) => - { - 'allUsers': instance.allUsers.map((e) => e.toJson()).toList(), - 'rootUser': instance.rootUser?.toJson(), - '__typename': instance.$__typename, - }; - -Variables$Query$GetUser _$Variables$Query$GetUserFromJson( - Map json) => - Variables$Query$GetUser( - username: json['username'] as String, - ); - -Map _$Variables$Query$GetUserToJson( - Variables$Query$GetUser instance) => - { - 'username': instance.username, - }; - -Query$GetUser _$Query$GetUserFromJson(Map json) => - Query$GetUser( - users: - Query$GetUser$users.fromJson(json['users'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetUserToJson(Query$GetUser instance) => - { - 'users': instance.users.toJson(), - '__typename': instance.$__typename, - }; - -Query$GetUser$users _$Query$GetUser$usersFromJson(Map json) => - Query$GetUser$users( - getUser: json['getUser'] == null - ? null - : Fragment$userFields.fromJson( - json['getUser'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Query$GetUser$usersToJson( - Query$GetUser$users instance) => - { - 'getUser': instance.getUser?.toJson(), - '__typename': instance.$__typename, - }; - -Variables$Mutation$CreateUser _$Variables$Mutation$CreateUserFromJson( - Map json) => - Variables$Mutation$CreateUser( - user: Input$UserMutationInput.fromJson( - json['user'] as Map), - ); - -Map _$Variables$Mutation$CreateUserToJson( - Variables$Mutation$CreateUser instance) => - { - 'user': instance.user.toJson(), - }; - -Mutation$CreateUser _$Mutation$CreateUserFromJson(Map json) => - Mutation$CreateUser( - createUser: Mutation$CreateUser$createUser.fromJson( - json['createUser'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$CreateUserToJson( - Mutation$CreateUser instance) => - { - 'createUser': instance.createUser.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$CreateUser$createUser _$Mutation$CreateUser$createUserFromJson( - Map json) => - Mutation$CreateUser$createUser( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - user: json['user'] == null - ? null - : Fragment$userFields.fromJson(json['user'] as Map), - ); - -Map _$Mutation$CreateUser$createUserToJson( - Mutation$CreateUser$createUser instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'user': instance.user?.toJson(), - }; - -Variables$Mutation$DeleteUser _$Variables$Mutation$DeleteUserFromJson( - Map json) => - Variables$Mutation$DeleteUser( - username: json['username'] as String, - ); - -Map _$Variables$Mutation$DeleteUserToJson( - Variables$Mutation$DeleteUser instance) => - { - 'username': instance.username, - }; - -Mutation$DeleteUser _$Mutation$DeleteUserFromJson(Map json) => - Mutation$DeleteUser( - deleteUser: Mutation$DeleteUser$deleteUser.fromJson( - json['deleteUser'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$DeleteUserToJson( - Mutation$DeleteUser instance) => - { - 'deleteUser': instance.deleteUser.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$DeleteUser$deleteUser _$Mutation$DeleteUser$deleteUserFromJson( - Map json) => - Mutation$DeleteUser$deleteUser( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$DeleteUser$deleteUserToJson( - Mutation$DeleteUser$deleteUser instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - }; - -Variables$Mutation$UpdateUser _$Variables$Mutation$UpdateUserFromJson( - Map json) => - Variables$Mutation$UpdateUser( - user: Input$UserMutationInput.fromJson( - json['user'] as Map), - ); - -Map _$Variables$Mutation$UpdateUserToJson( - Variables$Mutation$UpdateUser instance) => - { - 'user': instance.user.toJson(), - }; - -Mutation$UpdateUser _$Mutation$UpdateUserFromJson(Map json) => - Mutation$UpdateUser( - updateUser: Mutation$UpdateUser$updateUser.fromJson( - json['updateUser'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$UpdateUserToJson( - Mutation$UpdateUser instance) => - { - 'updateUser': instance.updateUser.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$UpdateUser$updateUser _$Mutation$UpdateUser$updateUserFromJson( - Map json) => - Mutation$UpdateUser$updateUser( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - user: json['user'] == null - ? null - : Fragment$userFields.fromJson(json['user'] as Map), - ); - -Map _$Mutation$UpdateUser$updateUserToJson( - Mutation$UpdateUser$updateUser instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'user': instance.user?.toJson(), - }; - -Variables$Mutation$AddSshKey _$Variables$Mutation$AddSshKeyFromJson( - Map json) => - Variables$Mutation$AddSshKey( - sshInput: Input$SshMutationInput.fromJson( - json['sshInput'] as Map), - ); - -Map _$Variables$Mutation$AddSshKeyToJson( - Variables$Mutation$AddSshKey instance) => - { - 'sshInput': instance.sshInput.toJson(), - }; - -Mutation$AddSshKey _$Mutation$AddSshKeyFromJson(Map json) => - Mutation$AddSshKey( - addSshKey: Mutation$AddSshKey$addSshKey.fromJson( - json['addSshKey'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$AddSshKeyToJson(Mutation$AddSshKey instance) => - { - 'addSshKey': instance.addSshKey.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$AddSshKey$addSshKey _$Mutation$AddSshKey$addSshKeyFromJson( - Map json) => - Mutation$AddSshKey$addSshKey( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - user: json['user'] == null - ? null - : Fragment$userFields.fromJson(json['user'] as Map), - ); - -Map _$Mutation$AddSshKey$addSshKeyToJson( - Mutation$AddSshKey$addSshKey instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'user': instance.user?.toJson(), - }; - -Variables$Mutation$RemoveSshKey _$Variables$Mutation$RemoveSshKeyFromJson( - Map json) => - Variables$Mutation$RemoveSshKey( - sshInput: Input$SshMutationInput.fromJson( - json['sshInput'] as Map), - ); - -Map _$Variables$Mutation$RemoveSshKeyToJson( - Variables$Mutation$RemoveSshKey instance) => - { - 'sshInput': instance.sshInput.toJson(), - }; - -Mutation$RemoveSshKey _$Mutation$RemoveSshKeyFromJson( - Map json) => - Mutation$RemoveSshKey( - removeSshKey: Mutation$RemoveSshKey$removeSshKey.fromJson( - json['removeSshKey'] as Map), - $__typename: json['__typename'] as String, - ); - -Map _$Mutation$RemoveSshKeyToJson( - Mutation$RemoveSshKey instance) => - { - 'removeSshKey': instance.removeSshKey.toJson(), - '__typename': instance.$__typename, - }; - -Mutation$RemoveSshKey$removeSshKey _$Mutation$RemoveSshKey$removeSshKeyFromJson( - Map json) => - Mutation$RemoveSshKey$removeSshKey( - code: json['code'] as int, - message: json['message'] as String, - success: json['success'] as bool, - $__typename: json['__typename'] as String, - user: json['user'] == null - ? null - : Fragment$userFields.fromJson(json['user'] as Map), - ); - -Map _$Mutation$RemoveSshKey$removeSshKeyToJson( - Mutation$RemoveSshKey$removeSshKey instance) => - { - 'code': instance.code, - 'message': instance.message, - 'success': instance.success, - '__typename': instance.$__typename, - 'user': instance.user?.toJson(), - }; diff --git a/lib/logic/api_maps/rest_maps/api_map.dart b/lib/logic/api_maps/rest_maps/api_map.dart index 6fd0bdda..299837fa 100644 --- a/lib/logic/api_maps/rest_maps/api_map.dart +++ b/lib/logic/api_maps/rest_maps/api_map.dart @@ -65,9 +65,11 @@ class ConsoleInterceptor extends InterceptorsWrapper { final RequestInterceptorHandler handler, ) async { addMessage( - Message( - text: - 'request-uri: ${options.uri}\nheaders: ${options.headers}\ndata: ${options.data}', + RestApiRequestMessage( + method: options.method, + data: options.data.toString(), + headers: options.headers, + uri: options.uri, ), ); return super.onRequest(options, handler); @@ -79,9 +81,11 @@ class ConsoleInterceptor extends InterceptorsWrapper { final ResponseInterceptorHandler handler, ) async { addMessage( - Message( - text: - 'response-uri: ${response.realUri}\ncode: ${response.statusCode}\ndata: ${response.toString()}\n', + RestApiResponseMessage( + method: response.requestOptions.method, + statusCode: response.statusCode, + data: response.data.toString(), + uri: response.realUri, ), ); return super.onResponse( diff --git a/lib/logic/cubit/app_settings/app_settings_cubit.dart b/lib/logic/cubit/app_settings/app_settings_cubit.dart index d013d418..af1ab3e0 100644 --- a/lib/logic/cubit/app_settings/app_settings_cubit.dart +++ b/lib/logic/cubit/app_settings/app_settings_cubit.dart @@ -15,10 +15,12 @@ part 'app_settings_state.dart'; class AppSettingsCubit extends Cubit { AppSettingsCubit({ required final bool isDarkModeOn, + required final bool isAutoDarkModeOn, required final bool isOnboardingShowing, }) : super( AppSettingsState( isDarkModeOn: isDarkModeOn, + isAutoDarkModeOn: isAutoDarkModeOn, isOnboardingShowing: isOnboardingShowing, ), ); @@ -27,10 +29,12 @@ class AppSettingsCubit extends Cubit { void load() async { final bool? isDarkModeOn = box.get(BNames.isDarkModeOn); + final bool? isAutoDarkModeOn = box.get(BNames.isAutoDarkModeOn); final bool? isOnboardingShowing = box.get(BNames.isOnboardingShowing); emit( state.copyWith( isDarkModeOn: isDarkModeOn, + isAutoDarkModeOn: isAutoDarkModeOn, isOnboardingShowing: isOnboardingShowing, ), ); @@ -49,9 +53,14 @@ class AppSettingsCubit extends Cubit { emit(state.copyWith(isDarkModeOn: isDarkModeOn)); } - void turnOffOnboarding() { - box.put(BNames.isOnboardingShowing, false); + void updateAutoDarkMode({required final bool isAutoDarkModeOn}) { + box.put(BNames.isAutoDarkModeOn, isAutoDarkModeOn); + emit(state.copyWith(isAutoDarkModeOn: isAutoDarkModeOn)); + } - emit(state.copyWith(isOnboardingShowing: false)); + void turnOffOnboarding({final bool isOnboardingShowing = false}) { + box.put(BNames.isOnboardingShowing, isOnboardingShowing); + + emit(state.copyWith(isOnboardingShowing: isOnboardingShowing)); } } diff --git a/lib/logic/cubit/app_settings/app_settings_state.dart b/lib/logic/cubit/app_settings/app_settings_state.dart index 8b29f6e9..ad364d66 100644 --- a/lib/logic/cubit/app_settings/app_settings_state.dart +++ b/lib/logic/cubit/app_settings/app_settings_state.dart @@ -3,21 +3,25 @@ part of 'app_settings_cubit.dart'; class AppSettingsState extends Equatable { const AppSettingsState({ required this.isDarkModeOn, + required this.isAutoDarkModeOn, required this.isOnboardingShowing, this.corePalette, }); final bool isDarkModeOn; + final bool isAutoDarkModeOn; final bool isOnboardingShowing; final color_utils.CorePalette? corePalette; AppSettingsState copyWith({ final bool? isDarkModeOn, + final bool? isAutoDarkModeOn, final bool? isOnboardingShowing, final color_utils.CorePalette? corePalette, }) => AppSettingsState( isDarkModeOn: isDarkModeOn ?? this.isDarkModeOn, + isAutoDarkModeOn: isAutoDarkModeOn ?? this.isAutoDarkModeOn, isOnboardingShowing: isOnboardingShowing ?? this.isOnboardingShowing, corePalette: corePalette ?? this.corePalette, ); @@ -26,5 +30,6 @@ class AppSettingsState extends Equatable { corePalette ?? color_utils.CorePalette.of(BrandColors.primary.value); @override - List get props => [isDarkModeOn, isOnboardingShowing, corePalette]; + List get props => + [isDarkModeOn, isAutoDarkModeOn, isOnboardingShowing, corePalette]; } diff --git a/lib/logic/cubit/devices/devices_cubit.dart b/lib/logic/cubit/devices/devices_cubit.dart index 5e5c145c..d76e3651 100644 --- a/lib/logic/cubit/devices/devices_cubit.dart +++ b/lib/logic/cubit/devices/devices_cubit.dart @@ -15,9 +15,9 @@ class ApiDevicesCubit @override void load() async { - if (serverInstallationCubit.state is ServerInstallationFinished) { - _refetch(); - } + // if (serverInstallationCubit.state is ServerInstallationFinished) { + _refetch(); + // } } Future refresh() async { diff --git a/lib/logic/cubit/forms/user/user_form_cubit.dart b/lib/logic/cubit/forms/user/user_form_cubit.dart index c3712382..5524417d 100644 --- a/lib/logic/cubit/forms/user/user_form_cubit.dart +++ b/lib/logic/cubit/forms/user/user_form_cubit.dart @@ -36,10 +36,6 @@ class UserFormCubit extends FormCubit { @override FutureOr onSubmit() { - print('onSubmit'); - print('initialUser: $initialUser'); - print('login: ${login.state.value}'); - print('password: ${password.state.value}'); if (initialUser == null) { final User user = User( login: login.state.value, diff --git a/lib/logic/cubit/recovery_key/recovery_key_cubit.dart b/lib/logic/cubit/recovery_key/recovery_key_cubit.dart index 56800be3..5ca2bfa9 100644 --- a/lib/logic/cubit/recovery_key/recovery_key_cubit.dart +++ b/lib/logic/cubit/recovery_key/recovery_key_cubit.dart @@ -14,21 +14,21 @@ class RecoveryKeyCubit @override void load() async { - if (serverInstallationCubit.state is ServerInstallationFinished) { - final RecoveryKeyStatus? status = await _getRecoveryKeyStatus(); - if (status == null) { - emit(state.copyWith(loadingStatus: LoadingStatus.error)); - } else { - emit( - state.copyWith( - status: status, - loadingStatus: LoadingStatus.success, - ), - ); - } + // if (serverInstallationCubit.state is ServerInstallationFinished) { + final RecoveryKeyStatus? status = await _getRecoveryKeyStatus(); + if (status == null) { + emit(state.copyWith(loadingStatus: LoadingStatus.error)); } else { - emit(state.copyWith(loadingStatus: LoadingStatus.uninitialized)); + emit( + state.copyWith( + status: status, + loadingStatus: LoadingStatus.success, + ), + ); } + // } else { + // emit(state.copyWith(loadingStatus: LoadingStatus.uninitialized)); + // } } Future _getRecoveryKeyStatus() async { diff --git a/lib/logic/cubit/support_system/support_system_cubit.dart b/lib/logic/cubit/support_system/support_system_cubit.dart new file mode 100644 index 00000000..b6250740 --- /dev/null +++ b/lib/logic/cubit/support_system/support_system_cubit.dart @@ -0,0 +1,19 @@ +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:equatable/equatable.dart'; +import 'package:flutter/material.dart'; + +part 'support_system_state.dart'; + +class SupportSystemCubit extends Cubit { + SupportSystemCubit() : super(const SupportSystemState('about')); + + void showArticle({ + required final String article, + final BuildContext? context, + }) { + emit(SupportSystemState(article)); + if (context != null) { + Scaffold.of(context).openEndDrawer(); + } + } +} diff --git a/lib/logic/cubit/support_system/support_system_state.dart b/lib/logic/cubit/support_system/support_system_state.dart new file mode 100644 index 00000000..0c3c3087 --- /dev/null +++ b/lib/logic/cubit/support_system/support_system_state.dart @@ -0,0 +1,12 @@ +part of 'support_system_cubit.dart'; + +class SupportSystemState extends Equatable { + const SupportSystemState( + this.currentArticle, + ); + + final String currentArticle; + + @override + List get props => [currentArticle]; +} diff --git a/lib/logic/get_it/navigation.dart b/lib/logic/get_it/navigation.dart index 15adc982..90f67203 100644 --- a/lib/logic/get_it/navigation.dart +++ b/lib/logic/get_it/navigation.dart @@ -1,16 +1,19 @@ import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; -import 'package:selfprivacy/config/text_themes.dart'; class NavigationService { final GlobalKey scaffoldMessengerKey = GlobalKey(); final GlobalKey navigatorKey = GlobalKey(); - NavigatorState? get navigator => navigatorKey.currentState; - void showPopUpDialog(final AlertDialog dialog) { - final BuildContext context = navigatorKey.currentState!.overlay!.context; + final BuildContext? context = navigatorKey.currentContext; + + if (context == null) { + showSnackBar( + 'Could not show dialog. This should not happen, please report this.', + ); + return; + } showDialog( context: context, @@ -21,8 +24,7 @@ class NavigationService { void showSnackBar(final String text) { final ScaffoldMessengerState state = scaffoldMessengerKey.currentState!; final SnackBar snack = SnackBar( - backgroundColor: BrandColors.black.withOpacity(0.8), - content: Text(text, style: buttonTitleText), + content: Text(text), duration: const Duration(seconds: 2), ); state.showSnackBar(snack); diff --git a/lib/logic/models/message.dart b/lib/logic/models/message.dart index 8bbc6dfd..aaaf0930 100644 --- a/lib/logic/models/message.dart +++ b/lib/logic/models/message.dart @@ -1,20 +1,74 @@ +import 'package:graphql/client.dart'; import 'package:intl/intl.dart'; final DateFormat formatter = DateFormat('hh:mm'); class Message { - Message({this.text, this.type = MessageType.normal}) : time = DateTime.now(); + Message({this.text, this.severity = MessageSeverity.normal}) + : time = DateTime.now(); Message.warn({this.text}) - : type = MessageType.warning, + : severity = MessageSeverity.warning, time = DateTime.now(); final String? text; final DateTime time; - final MessageType type; + final MessageSeverity severity; String get timeString => formatter.format(time); } -enum MessageType { +enum MessageSeverity { normal, warning, } + +class RestApiRequestMessage extends Message { + RestApiRequestMessage({ + this.method, + this.uri, + this.data, + this.headers, + }) : super(text: 'request-uri: $uri\nheaders: $headers\ndata: $data'); + + final String? method; + final Uri? uri; + final String? data; + final Map? headers; +} + +class RestApiResponseMessage extends Message { + RestApiResponseMessage({ + this.method, + this.uri, + this.statusCode, + this.data, + }) : super(text: 'response-uri: $uri\ncode: $statusCode\ndata: $data'); + + final String? method; + final Uri? uri; + final int? statusCode; + final String? data; +} + +class GraphQlResponseMessage extends Message { + GraphQlResponseMessage({ + this.data, + this.errors, + this.context, + }) : super(text: 'GraphQL Response\ndata: $data'); + + final Map? data; + final List? errors; + final Context? context; +} + +class GraphQlRequestMessage extends Message { + GraphQlRequestMessage({ + this.operation, + this.variables, + this.context, + }) : super(text: 'GraphQL Request\noperation: $operation'); + + final Operation? operation; + final Map? variables; + final Context? context; +} diff --git a/lib/main.dart b/lib/main.dart index 3bab9f0d..b6e1dc31 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -5,9 +5,7 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:selfprivacy/config/brand_colors.dart'; import 'package:selfprivacy/config/hive_config.dart'; import 'package:selfprivacy/theming/factory/app_theme_factory.dart'; -import 'package:selfprivacy/ui/pages/setup/initializing/initializing.dart'; -import 'package:selfprivacy/ui/pages/onboarding/onboarding.dart'; -import 'package:selfprivacy/ui/pages/root_route.dart'; +import 'package:selfprivacy/ui/router/router.dart'; import 'package:wakelock/wakelock.dart'; import 'package:timezone/data/latest.dart' as tz; @@ -20,7 +18,7 @@ import 'package:selfprivacy/logic/cubit/app_settings/app_settings_cubit.dart'; void main() async { WidgetsFlutterBinding.ensureInitialized(); await HiveConfig.init(); - await SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp]); + // await SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp]); try { /// Wakelock support for Linux @@ -43,21 +41,20 @@ void main() async { fallbackColor: BrandColors.primary, ); - BlocOverrides.runZoned( - () => runApp( - Localization( - child: MyApp( - lightThemeData: lightThemeData, - darkThemeData: darkThemeData, - ), + Bloc.observer = SimpleBlocObserver(); + + runApp( + Localization( + child: SelfprivacyApp( + lightThemeData: lightThemeData, + darkThemeData: darkThemeData, ), ), - blocObserver: SimpleBlocObserver(), ); } -class MyApp extends StatelessWidget { - const MyApp({ +class SelfprivacyApp extends StatelessWidget { + SelfprivacyApp({ required this.lightThemeData, required this.darkThemeData, super.key, @@ -66,42 +63,42 @@ class MyApp extends StatelessWidget { final ThemeData lightThemeData; final ThemeData darkThemeData; + final _appRouter = RootRouter(getIt.get().navigatorKey); + @override Widget build(final BuildContext context) => Localization( - child: AnnotatedRegion( - value: SystemUiOverlayStyle.light, // Manually changing appbar color - child: BlocAndProviderConfig( - child: BlocBuilder( - builder: ( - final BuildContext context, - final AppSettingsState appSettings, - ) => - MaterialApp( - scaffoldMessengerKey: - getIt.get().scaffoldMessengerKey, - navigatorKey: getIt.get().navigatorKey, - localizationsDelegates: context.localizationDelegates, - supportedLocales: context.supportedLocales, - locale: context.locale, - debugShowCheckedModeBanner: false, - title: 'SelfPrivacy', - theme: lightThemeData, - darkTheme: darkThemeData, - themeMode: - appSettings.isDarkModeOn ? ThemeMode.dark : ThemeMode.light, - home: appSettings.isOnboardingShowing - ? const OnboardingPage(nextPage: InitializingPage()) - : const RootPage(), - builder: (final BuildContext context, final Widget? widget) { - Widget error = const Text('...rendering error...'); - if (widget is Scaffold || widget is Navigator) { - error = Scaffold(body: Center(child: error)); - } - ErrorWidget.builder = - (final FlutterErrorDetails errorDetails) => error; - return widget!; - }, - ), + child: BlocAndProviderConfig( + child: BlocBuilder( + builder: ( + final BuildContext context, + final AppSettingsState appSettings, + ) => + MaterialApp.router( + routeInformationParser: _appRouter.defaultRouteParser(), + routerDelegate: _appRouter.delegate(), + scaffoldMessengerKey: + getIt.get().scaffoldMessengerKey, + localizationsDelegates: context.localizationDelegates, + supportedLocales: context.supportedLocales, + locale: context.locale, + debugShowCheckedModeBanner: false, + title: 'SelfPrivacy', + theme: lightThemeData, + darkTheme: darkThemeData, + themeMode: appSettings.isAutoDarkModeOn + ? ThemeMode.system + : appSettings.isDarkModeOn + ? ThemeMode.dark + : ThemeMode.light, + builder: (final BuildContext context, final Widget? widget) { + Widget error = const Text('...rendering error...'); + if (widget is Scaffold || widget is Navigator) { + error = Scaffold(body: Center(child: error)); + } + ErrorWidget.builder = + (final FlutterErrorDetails errorDetails) => error; + return widget!; + }, ), ), ), diff --git a/lib/ui/components/brand_alert/brand_alert.dart b/lib/ui/components/brand_alert/brand_alert.dart deleted file mode 100644 index 352b091c..00000000 --- a/lib/ui/components/brand_alert/brand_alert.dart +++ /dev/null @@ -1,13 +0,0 @@ -import 'package:flutter/material.dart'; - -class BrandAlert extends AlertDialog { - BrandAlert({ - super.key, - final String? title, - final String? contentText, - super.actions, - }) : super( - title: title != null ? Text(title) : null, - content: title != null ? Text(contentText!) : null, - ); -} diff --git a/lib/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart b/lib/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart deleted file mode 100644 index d53b5ced..00000000 --- a/lib/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart +++ /dev/null @@ -1,56 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; - -class BrandBottomSheet extends StatelessWidget { - const BrandBottomSheet({ - required this.child, - super.key, - this.isExpended = false, - }); - - final Widget child; - final bool isExpended; - - @override - Widget build(final BuildContext context) { - final double mainHeight = MediaQuery.of(context).size.height - - MediaQuery.of(context).padding.top - - 300; - late Widget innerWidget; - if (isExpended) { - innerWidget = Scaffold( - body: child, - ); - } else { - final ThemeData themeData = Theme.of(context); - - innerWidget = Material( - color: themeData.scaffoldBackgroundColor, - child: IntrinsicHeight(child: child), - ); - } - return Column( - mainAxisSize: MainAxisSize.min, - children: [ - Center( - child: Container( - height: 4, - width: 30, - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(2), - color: BrandColors.gray4, - ), - ), - ), - const SizedBox(height: 6), - ClipRRect( - borderRadius: const BorderRadius.vertical(top: Radius.circular(20)), - child: ConstrainedBox( - constraints: BoxConstraints(maxHeight: mainHeight), - child: innerWidget, - ), - ), - ], - ); - } -} diff --git a/lib/ui/components/brand_cards/brand_cards.dart b/lib/ui/components/brand_cards/brand_cards.dart deleted file mode 100644 index 67e7f725..00000000 --- a/lib/ui/components/brand_cards/brand_cards.dart +++ /dev/null @@ -1,55 +0,0 @@ -import 'package:flutter/material.dart'; - -class BrandCards { - static Widget big({required final Widget child}) => _BrandCard( - padding: const EdgeInsets.symmetric( - horizontal: 20, - vertical: 15, - ), - shadow: bigShadow, - borderRadius: BorderRadius.circular(20), - child: child, - ); - static Widget small({required final Widget child}) => _BrandCard( - padding: const EdgeInsets.symmetric( - horizontal: 15, - vertical: 10, - ), - shadow: bigShadow, - borderRadius: BorderRadius.circular(10), - child: child, - ); -} - -class _BrandCard extends StatelessWidget { - const _BrandCard({ - required this.child, - required this.padding, - required this.shadow, - required this.borderRadius, - }); - - final Widget child; - final EdgeInsets padding; - final List shadow; - final BorderRadius borderRadius; - - @override - Widget build(final BuildContext context) => Container( - decoration: BoxDecoration( - color: Theme.of(context).colorScheme.surface, - borderRadius: borderRadius, - boxShadow: shadow, - ), - padding: padding, - child: child, - ); -} - -final List bigShadow = [ - BoxShadow( - offset: const Offset(0, 4), - blurRadius: 8, - color: Colors.black.withOpacity(.08), - ) -]; diff --git a/lib/ui/components/brand_header/brand_header.dart b/lib/ui/components/brand_header/brand_header.dart index abdabc6f..3151aff7 100644 --- a/lib/ui/components/brand_header/brand_header.dart +++ b/lib/ui/components/brand_header/brand_header.dart @@ -25,5 +25,8 @@ class BrandHeader extends StatelessWidget { onBackButtonPressed ?? () => Navigator.of(context).pop(), ) : null, + actions: const [ + SizedBox.shrink(), + ], ); } diff --git a/lib/ui/components/brand_hero_screen/brand_hero_screen.dart b/lib/ui/components/brand_hero_screen/brand_hero_screen.dart deleted file mode 100644 index 68f5d772..00000000 --- a/lib/ui/components/brand_hero_screen/brand_hero_screen.dart +++ /dev/null @@ -1,147 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:selfprivacy/ui/components/pre_styled_buttons/flash_fab.dart'; -import 'package:selfprivacy/ui/helpers/widget_size.dart'; - -class BrandHeroScreen extends StatelessWidget { - const BrandHeroScreen({ - required this.children, - super.key, - this.hasBackButton = true, - this.hasFlashButton = true, - this.heroIcon, - this.heroIconWidget, - this.heroTitle = '', - this.heroSubtitle, - this.onBackButtonPressed, - }); - - final List children; - final bool hasBackButton; - final bool hasFlashButton; - final IconData? heroIcon; - final Widget? heroIconWidget; - final String heroTitle; - final String? heroSubtitle; - final VoidCallback? onBackButtonPressed; - - @override - Widget build(final BuildContext context) { - final Widget heroIconWidget = this.heroIconWidget ?? - Icon( - heroIcon ?? Icons.help, - size: 48.0, - color: Theme.of(context).colorScheme.onBackground, - ); - final bool hasHeroIcon = heroIcon != null || this.heroIconWidget != null; - - return Scaffold( - floatingActionButton: hasFlashButton ? const BrandFab() : null, - body: CustomScrollView( - slivers: [ - HeroSliverAppBar( - heroTitle: heroTitle, - hasHeroIcon: hasHeroIcon, - hasBackButton: hasBackButton, - onBackButtonPressed: onBackButtonPressed, - heroIconWidget: heroIconWidget, - ), - if (heroSubtitle != null) - SliverPadding( - padding: const EdgeInsets.symmetric( - horizontal: 16.0, - vertical: 4.0, - ), - sliver: SliverList( - delegate: SliverChildListDelegate([ - Text( - heroSubtitle!, - style: Theme.of(context).textTheme.bodyMedium!.copyWith( - color: Theme.of(context).colorScheme.onBackground, - ), - textAlign: hasHeroIcon ? TextAlign.center : TextAlign.start, - ), - ]), - ), - ), - SliverPadding( - padding: const EdgeInsets.all(16.0), - sliver: SliverList( - delegate: SliverChildListDelegate(children), - ), - ), - ], - ), - ); - } -} - -class HeroSliverAppBar extends StatefulWidget { - const HeroSliverAppBar({ - required this.heroTitle, - required this.hasHeroIcon, - required this.hasBackButton, - required this.onBackButtonPressed, - required this.heroIconWidget, - super.key, - }); - - final String heroTitle; - final bool hasHeroIcon; - final bool hasBackButton; - final VoidCallback? onBackButtonPressed; - final Widget heroIconWidget; - - @override - State createState() => _HeroSliverAppBarState(); -} - -class _HeroSliverAppBarState extends State { - Size _size = Size.zero; - @override - Widget build(final BuildContext context) => SliverAppBar( - expandedHeight: - widget.hasHeroIcon ? 148.0 + _size.height : 72.0 + _size.height, - primary: true, - pinned: true, - stretch: true, - leading: widget.hasBackButton - ? IconButton( - icon: const Icon(Icons.arrow_back), - onPressed: widget.onBackButtonPressed ?? - () => Navigator.of(context).pop(), - ) - : null, - flexibleSpace: FlexibleSpaceBar( - title: LayoutBuilder( - builder: (final context, final constraints) => SizedBox( - width: constraints.maxWidth - 72.0, - child: WidgetSize( - onChange: (final Size size) => setState(() => _size = size), - child: Text( - widget.heroTitle, - style: Theme.of(context).textTheme.titleLarge?.copyWith( - color: Theme.of(context).colorScheme.onSurface, - ), - overflow: TextOverflow.fade, - textAlign: TextAlign.center, - ), - ), - ), - ), - expandedTitleScale: 1.2, - centerTitle: true, - collapseMode: CollapseMode.pin, - titlePadding: const EdgeInsets.only( - bottom: 12.0, - top: 16.0, - ), - background: Column( - mainAxisAlignment: MainAxisAlignment.start, - children: [ - const SizedBox(height: 72.0), - if (widget.hasHeroIcon) widget.heroIconWidget, - ], - ), - ), - ); -} diff --git a/lib/ui/components/brand_linear_indicator/brand_linear_indicator.dart b/lib/ui/components/brand_linear_indicator/brand_linear_indicator.dart index 335387f5..34fb9e10 100644 --- a/lib/ui/components/brand_linear_indicator/brand_linear_indicator.dart +++ b/lib/ui/components/brand_linear_indicator/brand_linear_indicator.dart @@ -27,14 +27,14 @@ class BrandLinearIndicator extends StatelessWidget { alignment: Alignment.centerLeft, child: AnimatedSlide( duration: const Duration(milliseconds: 400), - curve: Curves.easeInOut, + curve: Curves.easeInOutCubicEmphasized, offset: Offset( -(1 - value), 0, ), child: AnimatedContainer( duration: const Duration(milliseconds: 400), - curve: Curves.easeInOut, + curve: Curves.easeInOutCubicEmphasized, width: constraints.maxWidth, decoration: BoxDecoration( color: color, diff --git a/lib/ui/components/brand_md/brand_md.dart b/lib/ui/components/brand_md/brand_md.dart index 457bb5c3..67c3e2ea 100644 --- a/lib/ui/components/brand_md/brand_md.dart +++ b/lib/ui/components/brand_md/brand_md.dart @@ -2,8 +2,6 @@ import 'package:flutter/material.dart'; import 'package:flutter_markdown/flutter_markdown.dart'; import 'package:flutter/services.dart' show rootBundle; import 'package:easy_localization/easy_localization.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; -import 'package:selfprivacy/config/text_themes.dart'; import 'package:url_launcher/url_launcher_string.dart'; class BrandMarkdown extends StatefulWidget { @@ -37,24 +35,7 @@ class _BrandMarkdownState extends State { @override Widget build(final BuildContext context) { - final bool isDark = Theme.of(context).brightness == Brightness.dark; - final MarkdownStyleSheet markdown = MarkdownStyleSheet( - p: defaultTextStyle.copyWith( - color: isDark ? BrandColors.white : null, - ), - h1: headline1Style.copyWith( - color: isDark ? BrandColors.white : null, - ), - h2: headline2Style.copyWith( - color: isDark ? BrandColors.white : null, - ), - h3: headline3Style.copyWith( - color: isDark ? BrandColors.white : null, - ), - h4: headline4Style.copyWith( - color: isDark ? BrandColors.white : null, - ), - ); + final MarkdownStyleSheet markdown = MarkdownStyleSheet(); return MarkdownBody( shrinkWrap: true, styleSheet: markdown, diff --git a/lib/ui/components/brand_radio/brand_radio.dart b/lib/ui/components/brand_radio/brand_radio.dart deleted file mode 100644 index 494c3e81..00000000 --- a/lib/ui/components/brand_radio/brand_radio.dart +++ /dev/null @@ -1,40 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; - -// TODO: Delete this file. - -class BrandRadio extends StatelessWidget { - const BrandRadio({ - required this.isChecked, - super.key, - }); - - final bool isChecked; - - @override - Widget build(final BuildContext context) => Container( - height: 20, - width: 20, - alignment: Alignment.center, - padding: const EdgeInsets.all(2), - decoration: BoxDecoration( - shape: BoxShape.circle, - border: _getBorder(), - ), - child: isChecked - ? Container( - height: 10, - width: 10, - decoration: const BoxDecoration( - shape: BoxShape.circle, - color: BrandColors.primary, - ), - ) - : null, - ); - - BoxBorder? _getBorder() => Border.all( - color: isChecked ? BrandColors.primary : BrandColors.gray1, - width: 2, - ); -} diff --git a/lib/ui/components/brand_switch/brand_switch.dart b/lib/ui/components/brand_switch/brand_switch.dart deleted file mode 100644 index 4ded47dd..00000000 --- a/lib/ui/components/brand_switch/brand_switch.dart +++ /dev/null @@ -1,19 +0,0 @@ -import 'package:flutter/material.dart'; - -class BrandSwitch extends StatelessWidget { - const BrandSwitch({ - required this.onChanged, - required this.value, - super.key, - }); - - final ValueChanged onChanged; - final bool value; - - @override - Widget build(final BuildContext context) => Switch( - activeColor: Theme.of(context).colorScheme.primary, - value: value, - onChanged: onChanged, - ); -} diff --git a/lib/ui/components/brand_tab_bar/brand_tab_bar.dart b/lib/ui/components/brand_tab_bar/brand_tab_bar.dart deleted file mode 100644 index 8362bedb..00000000 --- a/lib/ui/components/brand_tab_bar/brand_tab_bar.dart +++ /dev/null @@ -1,60 +0,0 @@ -import 'package:easy_localization/easy_localization.dart'; -import 'package:flutter/material.dart'; -import 'package:selfprivacy/ui/components/brand_icons/brand_icons.dart'; - -class BrandTabBar extends StatefulWidget { - const BrandTabBar({super.key, this.controller}); - - final TabController? controller; - @override - State createState() => _BrandTabBarState(); -} - -class _BrandTabBarState extends State { - int? currentIndex; - @override - void initState() { - currentIndex = widget.controller!.index; - widget.controller!.addListener(_listener); - super.initState(); - } - - void _listener() { - if (currentIndex != widget.controller!.index) { - setState(() { - currentIndex = widget.controller!.index; - }); - } - } - - @override - void dispose() { - widget.controller ?? widget.controller!.removeListener(_listener); - super.dispose(); - } - - @override - Widget build(final BuildContext context) => NavigationBar( - destinations: [ - _getIconButton('basis.providers'.tr(), BrandIcons.server, 0), - _getIconButton('basis.services'.tr(), BrandIcons.box, 1), - _getIconButton('basis.users'.tr(), BrandIcons.users, 2), - _getIconButton('basis.more'.tr(), Icons.menu_rounded, 3), - ], - onDestinationSelected: (final index) { - widget.controller!.animateTo(index); - }, - selectedIndex: currentIndex ?? 0, - labelBehavior: NavigationDestinationLabelBehavior.onlyShowSelected, - ); - - NavigationDestination _getIconButton( - final String label, - final IconData iconData, - final int index, - ) => - NavigationDestination( - icon: Icon(iconData), - label: label, - ); -} diff --git a/lib/ui/components/brand_text/brand_text.dart b/lib/ui/components/brand_text/brand_text.dart deleted file mode 100644 index 15307577..00000000 --- a/lib/ui/components/brand_text/brand_text.dart +++ /dev/null @@ -1,238 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/text_themes.dart'; -export 'package:selfprivacy/utils/extensions/text_extensions.dart'; - -// TODO: Delete this file - -enum TextType { - h1, // right now only at onboarding and opened providers - h2, // cards titles - h3, // titles in about page - h4, // caption - h5, // Table data - body1, // normal - body2, // with opacity - medium, - small, - onboardingTitle, - buttonTitleText, // risen button title text, - h4Underlined, -} - -class BrandText extends StatelessWidget { - factory BrandText.h4( - final String? text, { - final TextStyle? style, - final TextAlign? textAlign, - }) => - BrandText( - text, - type: TextType.h4, - style: style, - softWrap: true, - overflow: TextOverflow.ellipsis, - maxLines: 2, - textAlign: textAlign, - ); - - factory BrandText.onboardingTitle( - final String text, { - final TextStyle? style, - }) => - BrandText( - text, - type: TextType.onboardingTitle, - style: style, - ); - factory BrandText.h3( - final String text, { - final TextStyle? style, - final TextAlign? textAlign, - }) => - BrandText( - text, - type: TextType.h3, - style: style, - textAlign: textAlign, - overflow: TextOverflow.ellipsis, - ); - - factory BrandText.h4Underlined( - final String? text, { - final TextStyle? style, - final TextAlign? textAlign, - }) => - BrandText( - text, - type: TextType.h4Underlined, - style: style, - softWrap: true, - overflow: TextOverflow.ellipsis, - maxLines: 2, - textAlign: textAlign, - ); - - factory BrandText.h1( - final String? text, { - final TextStyle? style, - final TextOverflow? overflow, - final bool? softWrap, - }) => - BrandText( - text, - type: TextType.h1, - style: style, - ); - factory BrandText.h2( - final String? text, { - final TextStyle? style, - final TextAlign? textAlign, - }) => - BrandText( - text, - type: TextType.h2, - style: style, - textAlign: textAlign, - ); - factory BrandText.body1(final String? text, {final TextStyle? style}) => - BrandText( - text, - type: TextType.body1, - style: style, - ); - factory BrandText.small(final String text, {final TextStyle? style}) => - BrandText( - text, - type: TextType.small, - style: style, - ); - factory BrandText.body2(final String? text, {final TextStyle? style}) => - BrandText( - text, - type: TextType.body2, - style: style, - ); - factory BrandText.buttonTitleText( - final String? text, { - final TextStyle? style, - }) => - BrandText( - text, - type: TextType.buttonTitleText, - style: style, - ); - - factory BrandText.h5( - final String? text, { - final TextStyle? style, - final TextAlign? textAlign, - }) => - BrandText( - text, - type: TextType.h5, - style: style, - textAlign: textAlign, - ); - factory BrandText.medium( - final String? text, { - final TextStyle? style, - final TextAlign? textAlign, - }) => - BrandText( - text, - type: TextType.medium, - style: style, - textAlign: textAlign, - ); - const BrandText( - this.text, { - required this.type, - super.key, - this.style, - this.overflow, - this.softWrap, - this.textAlign, - this.maxLines, - }); - - final String? text; - final TextStyle? style; - final TextType type; - final TextOverflow? overflow; - final bool? softWrap; - final TextAlign? textAlign; - final int? maxLines; - @override - Text build(final BuildContext context) { - TextStyle style; - final bool isDark = Theme.of(context).brightness == Brightness.dark; - switch (type) { - case TextType.h1: - style = isDark - ? headline1Style.copyWith(color: Colors.white) - : headline1Style; - break; - case TextType.h2: - style = isDark - ? headline2Style.copyWith(color: Colors.white) - : headline2Style; - break; - case TextType.h3: - style = isDark - ? headline3Style.copyWith(color: Colors.white) - : headline3Style; - break; - case TextType.h4: - style = isDark - ? headline4Style.copyWith(color: Colors.white) - : headline4Style; - break; - case TextType.h4Underlined: - style = isDark - ? headline4UnderlinedStyle.copyWith(color: Colors.white) - : headline4UnderlinedStyle; - break; - case TextType.h5: - style = isDark - ? headline5Style.copyWith(color: Colors.white) - : headline5Style; - break; - case TextType.body1: - style = isDark ? body1Style.copyWith(color: Colors.white) : body1Style; - break; - case TextType.body2: - style = isDark - ? body2Style.copyWith(color: Colors.white.withOpacity(0.6)) - : body2Style; - break; - case TextType.small: - style = isDark ? smallStyle.copyWith(color: Colors.white) : smallStyle; - break; - case TextType.onboardingTitle: - style = isDark - ? onboardingTitle.copyWith(color: Colors.white) - : onboardingTitle; - break; - case TextType.medium: - style = - isDark ? mediumStyle.copyWith(color: Colors.white) : mediumStyle; - break; - case TextType.buttonTitleText: - style = !isDark - ? buttonTitleText.copyWith(color: Colors.white) - : buttonTitleText; - break; - } - if (this.style != null) { - style = style.merge(this.style); - } - return Text( - text!, - style: style, - maxLines: maxLines, - overflow: overflow, - softWrap: softWrap, - textAlign: textAlign, - ); - } -} diff --git a/lib/ui/components/brand_timer/brand_timer.dart b/lib/ui/components/brand_timer/brand_timer.dart index 3ccf9a63..4d744cfc 100644 --- a/lib/ui/components/brand_timer/brand_timer.dart +++ b/lib/ui/components/brand_timer/brand_timer.dart @@ -2,7 +2,6 @@ import 'dart:async'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; import 'package:selfprivacy/utils/named_font_weight.dart'; class BrandTimer extends StatefulWidget { @@ -52,11 +51,12 @@ class _BrandTimerState extends State { } @override - Widget build(final BuildContext context) => BrandText.medium( - _timeString, - style: const TextStyle( - fontWeight: NamedFontWeight.demiBold, - ), + Widget build(final BuildContext context) => Text( + _timeString ?? '', + style: Theme.of(context).textTheme.bodyMedium?.copyWith( + fontWeight: NamedFontWeight.demiBold, + color: Theme.of(context).colorScheme.onSurface, + ), ); void _getTime() { diff --git a/lib/ui/components/brand_button/brand_button.dart b/lib/ui/components/buttons/brand_button.dart similarity index 54% rename from lib/ui/components/brand_button/brand_button.dart rename to lib/ui/components/buttons/brand_button.dart index 28edd6b8..12c7c132 100644 --- a/lib/ui/components/brand_button/brand_button.dart +++ b/lib/ui/components/buttons/brand_button.dart @@ -1,7 +1,4 @@ import 'package:flutter/material.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; - -enum BrandButtonTypes { rised, text, iconText } class BrandButton { static ConstrainedBox rised({ @@ -58,53 +55,4 @@ class BrandButton { ), child: TextButton(onPressed: onPressed, child: Text(title)), ); - - static IconTextButton emptyWithIconText({ - required final VoidCallback onPressed, - required final String title, - required final Icon icon, - final Key? key, - }) => - IconTextButton( - key: key, - title: title, - onPressed: onPressed, - icon: icon, - ); -} - -class IconTextButton extends StatelessWidget { - const IconTextButton({ - super.key, - this.onPressed, - this.title, - this.icon, - }); - - final VoidCallback? onPressed; - final String? title; - final Icon? icon; - - @override - Widget build(final BuildContext context) => Material( - color: Colors.transparent, - child: InkWell( - onTap: onPressed, - child: Container( - height: 48, - width: double.infinity, - alignment: Alignment.center, - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - BrandText.body1(title), - Padding( - padding: const EdgeInsets.all(12.0), - child: icon, - ) - ], - ), - ), - ), - ); } diff --git a/lib/ui/components/action_button/action_button.dart b/lib/ui/components/buttons/dialog_action_button.dart similarity index 81% rename from lib/ui/components/action_button/action_button.dart rename to lib/ui/components/buttons/dialog_action_button.dart index 4073393f..260cd493 100644 --- a/lib/ui/components/action_button/action_button.dart +++ b/lib/ui/components/buttons/dialog_action_button.dart @@ -1,7 +1,8 @@ import 'package:flutter/material.dart'; -class ActionButton extends StatelessWidget { - const ActionButton({ +/// Basically a [TextButton] to be used in dialogs +class DialogActionButton extends StatelessWidget { + const DialogActionButton({ super.key, this.text, this.onPressed, diff --git a/lib/ui/components/brand_button/outlined_button.dart b/lib/ui/components/buttons/outlined_button.dart similarity index 100% rename from lib/ui/components/brand_button/outlined_button.dart rename to lib/ui/components/buttons/outlined_button.dart diff --git a/lib/ui/components/brand_button/segmented_buttons.dart b/lib/ui/components/buttons/segmented_buttons.dart similarity index 67% rename from lib/ui/components/brand_button/segmented_buttons.dart rename to lib/ui/components/buttons/segmented_buttons.dart index 7632dc20..b876f71d 100644 --- a/lib/ui/components/brand_button/segmented_buttons.dart +++ b/lib/ui/components/buttons/segmented_buttons.dart @@ -1,6 +1,16 @@ import 'package:flutter/material.dart'; +/// For some reason original [SegmentedButton] does not have animations. +/// +/// The [SegmentedButtons] was written for SelfPrivacy before [SegmentedButton] was introduced. +/// While it doesn't have that much options to pass, it has cute little animation. +/// It is based on [ToggleButtons]. class SegmentedButtons extends StatelessWidget { + /// Creates a segmented buttons widget. This is a SelfPrivacy implementation. + /// + /// Provide the button titles in [titles] as a [List]. + /// Current selection is provided in [isSelected] as a [List]. + /// This widget will call [onPressed] with the index of the button that was pressed. const SegmentedButtons({ required this.isSelected, required this.onPressed, @@ -8,15 +18,24 @@ class SegmentedButtons extends StatelessWidget { super.key, }); + /// The current selection state of the buttons. + /// + /// The length of this list must be equal to the length of [titles]. + /// Several buttons can be selected at the same time. final List isSelected; + + /// The callback that is called when a button is pressed. + /// It will be called with the index of the button that was pressed. final Function(int)? onPressed; + + /// The titles of the buttons. final List titles; @override Widget build(final BuildContext context) => LayoutBuilder( builder: (final context, final constraints) => ToggleButtons( constraints: BoxConstraints( - minWidth: (constraints.maxWidth - 8) / 3, + minWidth: (constraints.maxWidth - 8) / titles.length, minHeight: 40 + Theme.of(context).visualDensity.vertical * 4, ), borderRadius: BorderRadius.circular(48), @@ -38,7 +57,7 @@ class SegmentedButtons extends StatelessWidget { opacity: isSelected[index] ? 1 : 0, child: AnimatedScale( duration: const Duration(milliseconds: 200), - curve: Curves.easeInOut, + curve: Curves.easeInOutCubicEmphasized, alignment: Alignment.centerLeft, scale: isSelected[index] ? 1 : 0, child: Icon( @@ -53,7 +72,7 @@ class SegmentedButtons extends StatelessWidget { ? const EdgeInsets.only(left: 24) : EdgeInsets.zero, duration: const Duration(milliseconds: 200), - curve: Curves.easeInOut, + curve: Curves.easeInOutCubicEmphasized, child: Text( title, style: Theme.of(context).textTheme.labelLarge, diff --git a/lib/ui/components/brand_cards/filled_card.dart b/lib/ui/components/cards/filled_card.dart similarity index 100% rename from lib/ui/components/brand_cards/filled_card.dart rename to lib/ui/components/cards/filled_card.dart diff --git a/lib/ui/components/brand_cards/outlined_card.dart b/lib/ui/components/cards/outlined_card.dart similarity index 100% rename from lib/ui/components/brand_cards/outlined_card.dart rename to lib/ui/components/cards/outlined_card.dart diff --git a/lib/ui/components/drawers/progress_drawer.dart b/lib/ui/components/drawers/progress_drawer.dart new file mode 100644 index 00000000..d886da02 --- /dev/null +++ b/lib/ui/components/drawers/progress_drawer.dart @@ -0,0 +1,113 @@ +import 'package:easy_localization/easy_localization.dart'; +import 'package:flutter/material.dart'; + +class ProgressDrawer extends StatelessWidget { + /// A [Drawer] that displays a list of steps and the current step. + /// Used in setup wizards. The [trailing] widget is displayed at the bottom. + /// The [steps] are translated using [EasyLocalization]. + const ProgressDrawer({ + required this.steps, + required this.currentStep, + required this.constraints, + required this.trailing, + required this.title, + super.key, + }); + + final List steps; + final int currentStep; + final Widget trailing; + final BoxConstraints constraints; + final String title; + + @override + Widget build(final BuildContext context) => SizedBox( + width: 300, + height: constraints.maxHeight, + child: Drawer( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Padding( + padding: const EdgeInsets.all(16.0), + child: Text( + title, + style: Theme.of(context).textTheme.titleLarge, + ), + ), + Flexible( + fit: FlexFit.tight, + child: SingleChildScrollView( + child: Column( + children: [ + ...steps.map((final step) { + final index = steps.indexOf(step); + return _StepIndicator( + title: step.tr(), + isCurrent: index == currentStep, + isCompleted: index < currentStep, + ); + }), + ], + ), + ), + ), + // const Spacer(), + Padding( + padding: const EdgeInsets.all(16.0), + child: trailing, + ), + ], + ), + ), + ); +} + +class _StepIndicator extends StatelessWidget { + const _StepIndicator({ + required this.title, + required this.isCompleted, + required this.isCurrent, + }); + + final String title; + final bool isCompleted; + final bool isCurrent; + + @override + Widget build(final BuildContext context) => ListTile( + selected: isCurrent, + leading: isCurrent + ? const _StepCurrentIcon() + : isCompleted + ? const _StepCompletedIcon() + : const _StepPendingIcon(), + title: Text( + title, + ), + textColor: Theme.of(context).colorScheme.onSurfaceVariant, + iconColor: Theme.of(context).colorScheme.onSurfaceVariant, + ); +} + +class _StepCompletedIcon extends StatelessWidget { + const _StepCompletedIcon(); + + @override + Widget build(final BuildContext context) => const Icon(Icons.check_circle); +} + +class _StepPendingIcon extends StatelessWidget { + const _StepPendingIcon(); + + @override + Widget build(final BuildContext context) => const Icon(Icons.circle_outlined); +} + +class _StepCurrentIcon extends StatelessWidget { + const _StepCurrentIcon(); + + @override + Widget build(final BuildContext context) => + const Icon(Icons.build_circle_outlined); +} diff --git a/lib/ui/components/drawers/support_drawer.dart b/lib/ui/components/drawers/support_drawer.dart new file mode 100644 index 00000000..7b4c5c2b --- /dev/null +++ b/lib/ui/components/drawers/support_drawer.dart @@ -0,0 +1,52 @@ +import 'package:easy_localization/easy_localization.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:selfprivacy/logic/cubit/support_system/support_system_cubit.dart'; +import 'package:selfprivacy/ui/components/brand_md/brand_md.dart'; + +class SupportDrawer extends StatelessWidget { + const SupportDrawer({ + super.key, + }); + + @override + Widget build(final BuildContext context) { + final currentArticle = + context.watch().state.currentArticle; + return Drawer( + width: 440, + child: SingleChildScrollView( + child: Padding( + padding: const EdgeInsets.all(8.0), + child: Column( + children: [ + Row( + children: [ + const SizedBox(width: 8), + const Icon(Icons.help_outline), + const SizedBox(width: 16), + Text( + 'support.title'.tr(), + style: Theme.of(context).textTheme.titleLarge, + ), + const Spacer(), + IconButton( + onPressed: () => Scaffold.of(context).closeEndDrawer(), + icon: const Icon(Icons.chevron_right_outlined), + ), + ], + ), + const SizedBox(height: 8), + Padding( + padding: const EdgeInsets.all(8.0), + child: BrandMarkdown( + fileName: currentArticle, + ), + ), + ], + ), + ), + ), + ); + } +} diff --git a/lib/ui/components/error/error.dart b/lib/ui/components/error/error.dart deleted file mode 100644 index 402ce512..00000000 --- a/lib/ui/components/error/error.dart +++ /dev/null @@ -1,26 +0,0 @@ -import 'package:flutter/material.dart'; - -class BrandError extends StatelessWidget { - const BrandError({super.key, this.error, this.stackTrace}); - - final Object? error; - final StackTrace? stackTrace; - - @override - Widget build(final BuildContext context) => SafeArea( - child: Scaffold( - body: Center( - child: SingleChildScrollView( - child: Column( - crossAxisAlignment: CrossAxisAlignment.center, - children: [ - Text(error.toString()), - const Text('stackTrace: '), - Text(stackTrace.toString()), - ], - ), - ), - ), - ), - ); -} diff --git a/lib/ui/components/jobs_content/jobs_content.dart b/lib/ui/components/jobs_content/jobs_content.dart index bafe94a7..5ba00f89 100644 --- a/lib/ui/components/jobs_content/jobs_content.dart +++ b/lib/ui/components/jobs_content/jobs_content.dart @@ -6,10 +6,8 @@ import 'package:selfprivacy/logic/cubit/client_jobs/client_jobs_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_jobs/server_jobs_cubit.dart'; import 'package:selfprivacy/logic/models/json/server_job.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_cards/brand_cards.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; import 'package:selfprivacy/ui/components/brand_loader/brand_loader.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; import 'package:selfprivacy/ui/components/jobs_content/server_job_card.dart'; import 'package:selfprivacy/ui/helpers/modals.dart'; @@ -32,7 +30,12 @@ class JobsContent extends StatelessWidget { if (state is JobsStateEmpty) { widgets = [ const SizedBox(height: 80), - Center(child: BrandText.body1('jobs.empty'.tr())), + Center( + child: Text( + 'jobs.empty'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), + ), ]; if (installationState is ServerInstallationFinished) { @@ -65,38 +68,49 @@ class JobsContent extends StatelessWidget { ]; } else if (state is JobsStateWithJobs) { widgets = [ - ...state.clientJobList - .map( - (final j) => Row( - children: [ - Expanded( - child: BrandCards.small( - child: Text(j.title), + ...state.clientJobList.map( + (final j) => Row( + children: [ + Expanded( + child: Card( + color: Theme.of(context).colorScheme.surfaceVariant, + child: Padding( + padding: const EdgeInsets.symmetric( + horizontal: 15, + vertical: 10, ), - ), - const SizedBox(width: 10), - ElevatedButton( - style: ElevatedButton.styleFrom( - backgroundColor: - Theme.of(context).colorScheme.errorContainer, - shape: RoundedRectangleBorder( - borderRadius: BorderRadius.circular(10), - ), - ), - onPressed: () => - context.read().removeJob(j.id), child: Text( - 'basis.remove'.tr(), - style: TextStyle( - color: - Theme.of(context).colorScheme.onErrorContainer, - ), + j.title, + style: + Theme.of(context).textTheme.labelLarge?.copyWith( + color: Theme.of(context) + .colorScheme + .onSurfaceVariant, + ), ), ), - ], + ), ), - ) - .toList(), + const SizedBox(width: 10), + ElevatedButton( + style: ElevatedButton.styleFrom( + backgroundColor: + Theme.of(context).colorScheme.errorContainer, + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(10), + ), + ), + onPressed: () => context.read().removeJob(j.id), + child: Text( + 'basis.remove'.tr(), + style: TextStyle( + color: Theme.of(context).colorScheme.onErrorContainer, + ), + ), + ), + ], + ), + ), const SizedBox(height: 20), BrandButton.rised( onPressed: () => context.read().applyAll(), @@ -109,8 +123,9 @@ class JobsContent extends StatelessWidget { children: [ const SizedBox(height: 15), Center( - child: BrandText.h2( + child: Text( 'jobs.title'.tr(), + style: Theme.of(context).textTheme.headlineSmall, ), ), const SizedBox(height: 20), diff --git a/lib/ui/components/list_tiles/log_list_tile.dart b/lib/ui/components/list_tiles/log_list_tile.dart new file mode 100644 index 00000000..88505d8f --- /dev/null +++ b/lib/ui/components/list_tiles/log_list_tile.dart @@ -0,0 +1,300 @@ +import 'package:easy_localization/easy_localization.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter/services.dart'; +import 'package:selfprivacy/logic/models/message.dart'; + +class LogListItem extends StatelessWidget { + const LogListItem({ + required this.message, + super.key, + }); + + final Message message; + + @override + Widget build(final BuildContext context) { + final messageItem = message; + if (messageItem is RestApiRequestMessage) { + return _RestApiRequestMessageItem(message: messageItem); + } else if (messageItem is RestApiResponseMessage) { + return _RestApiResponseMessageItem(message: messageItem); + } else if (messageItem is GraphQlResponseMessage) { + return _GraphQlResponseMessageItem(message: messageItem); + } else if (messageItem is GraphQlRequestMessage) { + return _GraphQlRequestMessageItem(message: messageItem); + } else { + return _DefaultMessageItem(message: messageItem); + } + } +} + +class _RestApiRequestMessageItem extends StatelessWidget { + const _RestApiRequestMessageItem({required this.message}); + + final RestApiRequestMessage message; + + @override + Widget build(final BuildContext context) => ListTile( + title: Text( + '${message.method}\n${message.uri}', + ), + subtitle: Text(message.timeString), + leading: const Icon(Icons.upload_outlined), + iconColor: Theme.of(context).colorScheme.secondary, + onTap: () => showDialog( + context: context, + builder: (final BuildContext context) => AlertDialog( + scrollable: true, + title: Text( + '${message.method}\n${message.uri}', + ), + content: Column( + children: [ + Text(message.timeString), + const SizedBox(height: 16), + // Headers is a map of key-value pairs + if (message.headers != null) const Text('Headers'), + if (message.headers != null) + Text( + message.headers!.entries + .map((final entry) => '${entry.key}: ${entry.value}') + .join('\n'), + ), + if (message.data != null && message.data != 'null') + const Text('Data'), + if (message.data != null && message.data != 'null') + Text(message.data!), + ], + ), + actions: [ + // A button to copy the request to the clipboard + TextButton( + onPressed: () { + Clipboard.setData(ClipboardData(text: message.text)); + }, + child: Text('console_page.copy'.tr()), + ), + TextButton( + onPressed: () => Navigator.of(context).pop(), + child: Text('basis.close'.tr()), + ), + ], + ), + ), + ); +} + +class _RestApiResponseMessageItem extends StatelessWidget { + const _RestApiResponseMessageItem({required this.message}); + + final RestApiResponseMessage message; + + @override + Widget build(final BuildContext context) => ListTile( + title: Text( + '${message.statusCode} ${message.method}\n${message.uri}', + ), + subtitle: Text(message.timeString), + leading: const Icon(Icons.download_outlined), + iconColor: Theme.of(context).colorScheme.primary, + onTap: () => showDialog( + context: context, + builder: (final BuildContext context) => AlertDialog( + scrollable: true, + title: Text( + '${message.statusCode} ${message.method}\n${message.uri}', + ), + content: Column( + children: [ + Text(message.timeString), + const SizedBox(height: 16), + // Headers is a map of key-value pairs + if (message.data != null && message.data != 'null') + const Text('Data'), + if (message.data != null && message.data != 'null') + Text(message.data!), + ], + ), + actions: [ + // A button to copy the request to the clipboard + TextButton( + onPressed: () { + Clipboard.setData(ClipboardData(text: message.text)); + }, + child: Text('console_page.copy'.tr()), + ), + TextButton( + onPressed: () => Navigator.of(context).pop(), + child: Text('basis.close'.tr()), + ), + ], + ), + ), + ); +} + +class _GraphQlResponseMessageItem extends StatelessWidget { + const _GraphQlResponseMessageItem({required this.message}); + + final GraphQlResponseMessage message; + + @override + Widget build(final BuildContext context) => ListTile( + title: Text( + 'GraphQL Response at ${message.timeString}', + ), + subtitle: Text( + message.data.toString(), + overflow: TextOverflow.ellipsis, + maxLines: 1, + ), + leading: const Icon(Icons.arrow_circle_down_outlined), + iconColor: Theme.of(context).colorScheme.tertiary, + onTap: () => showDialog( + context: context, + builder: (final BuildContext context) => AlertDialog( + scrollable: true, + title: Text( + 'GraphQL Response at ${message.timeString}', + ), + content: Column( + children: [ + Text(message.timeString), + const Divider(), + if (message.data != null) const Text('Data'), + // Data is a map of key-value pairs + if (message.data != null) + Text( + message.data!.entries + .map((final entry) => '${entry.key}: ${entry.value}') + .join('\n'), + ), + const Divider(), + if (message.errors != null) const Text('Errors'), + if (message.errors != null) + Text( + message.errors! + .map( + (final entry) => + '${entry.message} at ${entry.locations}', + ) + .join('\n'), + ), + const Divider(), + if (message.context != null) const Text('Context'), + if (message.context != null) + Text( + message.context!.toString(), + ), + ], + ), + actions: [ + // A button to copy the request to the clipboard + TextButton( + onPressed: () { + Clipboard.setData(ClipboardData(text: message.text)); + }, + child: Text('console_page.copy'.tr()), + ), + TextButton( + onPressed: () => Navigator.of(context).pop(), + child: Text('basis.close'.tr()), + ), + ], + ), + ), + ); +} + +class _GraphQlRequestMessageItem extends StatelessWidget { + const _GraphQlRequestMessageItem({required this.message}); + + final GraphQlRequestMessage message; + + @override + Widget build(final BuildContext context) => ListTile( + title: Text( + 'GraphQL Request at ${message.timeString}', + ), + subtitle: Text( + message.operation.toString(), + overflow: TextOverflow.ellipsis, + maxLines: 1, + ), + leading: const Icon(Icons.arrow_circle_up_outlined), + iconColor: Theme.of(context).colorScheme.secondary, + onTap: () => showDialog( + context: context, + builder: (final BuildContext context) => AlertDialog( + scrollable: true, + title: Text( + 'GraphQL Response at ${message.timeString}', + ), + content: Column( + children: [ + Text(message.timeString), + const Divider(), + if (message.operation != null) const Text('Operation'), + // Data is a map of key-value pairs + if (message.operation != null) + Text( + message.operation!.toString(), + ), + const Divider(), + if (message.variables != null) const Text('Variables'), + if (message.variables != null) + Text( + message.variables!.entries + .map((final entry) => '${entry.key}: ${entry.value}') + .join('\n'), + ), + const Divider(), + if (message.context != null) const Text('Context'), + if (message.context != null) + Text( + message.context!.toString(), + ), + ], + ), + actions: [ + // A button to copy the request to the clipboard + TextButton( + onPressed: () { + Clipboard.setData(ClipboardData(text: message.text)); + }, + child: Text('console_page.copy'.tr()), + ), + TextButton( + onPressed: () => Navigator.of(context).pop(), + child: Text('basis.close'.tr()), + ), + ], + ), + ), + ); +} + +class _DefaultMessageItem extends StatelessWidget { + const _DefaultMessageItem({required this.message}); + + final Message message; + + @override + Widget build(final BuildContext context) => Padding( + padding: const EdgeInsets.symmetric(vertical: 4), + child: RichText( + text: TextSpan( + style: DefaultTextStyle.of(context).style, + children: [ + TextSpan( + text: '${message.timeString}: \n', + style: const TextStyle( + fontWeight: FontWeight.bold, + ), + ), + TextSpan(text: message.text), + ], + ), + ), + ); +} diff --git a/lib/ui/components/not_ready_card/not_ready_card.dart b/lib/ui/components/not_ready_card/not_ready_card.dart index 379abf27..4b174a41 100644 --- a/lib/ui/components/not_ready_card/not_ready_card.dart +++ b/lib/ui/components/not_ready_card/not_ready_card.dart @@ -1,7 +1,7 @@ +import 'package:auto_route/auto_route.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/ui/components/brand_cards/filled_card.dart'; -import 'package:selfprivacy/ui/pages/setup/initializing/initializing.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +import 'package:selfprivacy/ui/components/cards/filled_card.dart'; +import 'package:selfprivacy/ui/router/router.dart'; import 'package:easy_localization/easy_localization.dart'; class NotReadyCard extends StatelessWidget { @@ -13,11 +13,7 @@ class NotReadyCard extends StatelessWidget { child: ListTile( contentPadding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8), - onTap: () => Navigator.of(context).push( - materialRoute( - const InitializingPage(), - ), - ), + onTap: () => context.pushRoute(const InitializingRoute()), title: Text( 'not_ready_card.in_menu'.tr(), style: Theme.of(context).textTheme.titleSmall?.copyWith( diff --git a/lib/ui/components/pre_styled_buttons/flash_fab.dart b/lib/ui/components/pre_styled_buttons/flash_fab.dart index f0087b9f..2098f79e 100644 --- a/lib/ui/components/pre_styled_buttons/flash_fab.dart +++ b/lib/ui/components/pre_styled_buttons/flash_fab.dart @@ -1,13 +1,17 @@ +import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:ionicons/ionicons.dart'; import 'package:selfprivacy/logic/cubit/client_jobs/client_jobs_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart'; import 'package:selfprivacy/ui/components/jobs_content/jobs_content.dart'; -import 'package:selfprivacy/ui/helpers/modals.dart'; class BrandFab extends StatefulWidget { - const BrandFab({super.key}); + const BrandFab({ + this.extended = false, + super.key, + }); + + final bool extended; @override State createState() => _BrandFabState(); @@ -56,28 +60,40 @@ class _BrandFabState extends State child: FloatingActionButton( onPressed: () { // TODO: Make a hero animation to the screen - showBrandBottomSheet( + showModalBottomSheet( context: context, - builder: (final BuildContext context) => const BrandBottomSheet( - isExpended: true, - child: JobsContent(), - ), + builder: (final BuildContext context) => const JobsContent(), ); }, - child: AnimatedBuilder( - animation: _colorTween, - builder: (final BuildContext context, final Widget? child) { - final double v = _animationController.value; - final IconData icon = - v > 0.5 ? Ionicons.flash : Ionicons.flash_outline; - return Transform.scale( - scale: 1 + (v < 0.5 ? v : 1 - v) * 2, - child: Icon( - icon, - color: _colorTween.value, + isExtended: widget.extended, + child: Row( + crossAxisAlignment: CrossAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.center, + children: [ + AnimatedBuilder( + animation: _colorTween, + builder: (final BuildContext context, final Widget? child) { + final double v = _animationController.value; + final IconData icon = + v > 0.5 ? Ionicons.flash : Ionicons.flash_outline; + return Transform.scale( + scale: 1 + (v < 0.5 ? v : 1 - v) * 2, + child: Icon( + icon, + color: _colorTween.value, + ), + ); + }, + ), + if (widget.extended) + const SizedBox( + width: 8, ), - ); - }, + if (widget.extended) + Text( + 'jobs.title'.tr(), + ), + ], ), ), ); diff --git a/lib/ui/components/progress_bar/progress_bar.dart b/lib/ui/components/progress_bar/progress_bar.dart index 00f1388e..7f743f44 100644 --- a/lib/ui/components/progress_bar/progress_bar.dart +++ b/lib/ui/components/progress_bar/progress_bar.dart @@ -1,6 +1,4 @@ import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; -import 'package:selfprivacy/config/text_themes.dart'; import 'package:selfprivacy/logic/cubit/app_settings/app_settings_cubit.dart'; class ProgressBar extends StatefulWidget { @@ -65,7 +63,7 @@ class _ProgressBarState extends State { Container( alignment: Alignment.centerLeft, decoration: BoxDecoration( - color: BrandColors.gray4, + color: const Color(0xFFDDDDDD), borderRadius: BorderRadius.circular(5), ), child: LayoutBuilder( @@ -119,3 +117,13 @@ class _ProgressBarState extends State { ); } } + +const TextStyle progressTextStyleLight = TextStyle( + fontSize: 11, + color: Colors.black, + height: 1.7, +); + +final TextStyle progressTextStyleDark = progressTextStyleLight.copyWith( + color: Colors.white, +); diff --git a/lib/ui/components/switch_block/switch_bloc.dart b/lib/ui/components/switch_block/switch_bloc.dart deleted file mode 100644 index 85ac2c68..00000000 --- a/lib/ui/components/switch_block/switch_bloc.dart +++ /dev/null @@ -1,36 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; - -// TODO: Delete this file. - -class SwitcherBlock extends StatelessWidget { - const SwitcherBlock({ - required this.child, - required this.isActive, - required this.onChange, - super.key, - }); - - final Widget child; - final bool isActive; - final ValueChanged onChange; - - @override - Widget build(final BuildContext context) => Container( - padding: const EdgeInsets.symmetric(vertical: 16), - child: Row( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Flexible(child: child), - const SizedBox(width: 5), - Switch( - activeColor: BrandColors.green1, - activeTrackColor: BrandColors.green2, - onChanged: onChange, - value: isActive, - ), - ], - ), - ); -} diff --git a/lib/ui/helpers/modals.dart b/lib/ui/helpers/modals.dart index 1750c2aa..b744e323 100644 --- a/lib/ui/helpers/modals.dart +++ b/lib/ui/helpers/modals.dart @@ -1,21 +1,7 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:modal_bottom_sheet/modal_bottom_sheet.dart'; import 'package:selfprivacy/config/get_it_config.dart'; -import 'package:selfprivacy/ui/components/action_button/action_button.dart'; -import 'package:selfprivacy/ui/components/brand_alert/brand_alert.dart'; - -Future showBrandBottomSheet({ - required final BuildContext context, - required final WidgetBuilder builder, -}) => - showCupertinoModalBottomSheet( - builder: builder, - barrierColor: Colors.black45, - context: context, - shadow: const BoxShadow(color: Colors.transparent), - backgroundColor: Colors.transparent, - ); +import 'package:selfprivacy/ui/components/buttons/dialog_action_button.dart'; void showPopUpAlert({ required final String description, @@ -26,16 +12,16 @@ void showPopUpAlert({ final String? cancelButtonTitle, }) { getIt.get().showPopUpDialog( - BrandAlert( - title: alertTitle ?? 'basis.alert'.tr(), - contentText: description, + AlertDialog( + title: Text(alertTitle ?? 'basis.alert'.tr()), + content: Text(description), actions: [ - ActionButton( + DialogActionButton( text: actionButtonTitle, isRed: true, onPressed: actionButtonOnPressed, ), - ActionButton( + DialogActionButton( text: cancelButtonTitle ?? 'basis.cancel'.tr(), onPressed: cancelButtonOnPressed, ), diff --git a/lib/ui/helpers/widget_size.dart b/lib/ui/helpers/widget_size.dart index 2b9eb962..bbd1529f 100644 --- a/lib/ui/helpers/widget_size.dart +++ b/lib/ui/helpers/widget_size.dart @@ -1,14 +1,26 @@ import 'package:flutter/material.dart'; import 'package:flutter/scheduler.dart'; +/// A helper widget that calls a callback when its size changes. +/// +/// This is useful when you want to know the size of a widget, and use it in +/// another leaf of the tree. +/// +/// The [onChange] callback is called after the widget is rendered, and the +/// size of the widget is different from the previous render. class WidgetSize extends StatefulWidget { + /// Creates a helper widget that calls a callback when its size changes. const WidgetSize({ required this.onChange, required this.child, super.key, }); + + /// The child widget, the size of which is to be measured. final Widget child; - final Function onChange; + + /// The callback to be called when the size of the widget changes. + final Function(Size) onChange; @override State createState() => _WidgetSizeState(); @@ -34,6 +46,11 @@ class _WidgetSizeState extends State { } final newSize = context.size; + + if (newSize == null) { + return; + } + if (oldSize == newSize) { return; } diff --git a/lib/ui/layouts/brand_hero_screen.dart b/lib/ui/layouts/brand_hero_screen.dart new file mode 100644 index 00000000..adb94902 --- /dev/null +++ b/lib/ui/layouts/brand_hero_screen.dart @@ -0,0 +1,195 @@ +import 'package:auto_route/auto_route.dart'; +import 'package:flutter/material.dart'; +import 'package:ionicons/ionicons.dart'; +import 'package:selfprivacy/logic/cubit/client_jobs/client_jobs_cubit.dart'; +import 'package:selfprivacy/ui/components/jobs_content/jobs_content.dart'; +import 'package:selfprivacy/ui/components/drawers/support_drawer.dart'; +import 'package:selfprivacy/ui/helpers/widget_size.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; + +class BrandHeroScreen extends StatelessWidget { + const BrandHeroScreen({ + required this.children, + super.key, + this.hasBackButton = true, + this.hasFlashButton = false, + this.heroIcon, + this.heroIconWidget, + this.heroTitle = '', + this.heroSubtitle, + this.onBackButtonPressed, + this.bodyPadding = const EdgeInsets.all(16.0), + this.ignoreBreakpoints = false, + this.hasSupportDrawer = false, + }); + + final List children; + final bool hasBackButton; + final bool hasFlashButton; + final IconData? heroIcon; + final Widget? heroIconWidget; + final String heroTitle; + final String? heroSubtitle; + final VoidCallback? onBackButtonPressed; + final EdgeInsetsGeometry bodyPadding; + + /// On non-mobile screens the buttons of the app bar are hidden. + /// This is because this widget implies that it is nested inside a bigger layout. + /// If it is not nested, set this to true. + final bool ignoreBreakpoints; + + /// Usually support drawer is provided by the parent layout. + /// If it is not provided, set this to true. + final bool hasSupportDrawer; + + @override + Widget build(final BuildContext context) { + final Widget heroIconWidget = this.heroIconWidget ?? + Icon( + heroIcon ?? Icons.help, + size: 48.0, + color: Theme.of(context).colorScheme.onBackground, + ); + final bool hasHeroIcon = heroIcon != null || this.heroIconWidget != null; + + return Scaffold( + endDrawerEnableOpenDragGesture: false, + endDrawer: hasSupportDrawer ? const SupportDrawer() : null, + body: CustomScrollView( + slivers: [ + HeroSliverAppBar( + heroTitle: heroTitle, + hasHeroIcon: hasHeroIcon, + hasBackButton: hasBackButton, + onBackButtonPressed: onBackButtonPressed, + heroIconWidget: heroIconWidget, + hasFlashButton: hasFlashButton, + ignoreBreakpoints: ignoreBreakpoints, + ), + if (heroSubtitle != null) + SliverPadding( + padding: const EdgeInsets.symmetric( + horizontal: 16.0, + vertical: 4.0, + ), + sliver: SliverList( + delegate: SliverChildListDelegate([ + Text( + heroSubtitle!, + style: Theme.of(context).textTheme.bodyMedium!.copyWith( + color: Theme.of(context).colorScheme.onBackground, + ), + textAlign: hasHeroIcon ? TextAlign.center : TextAlign.start, + ), + ]), + ), + ), + SliverPadding( + padding: bodyPadding, + sliver: SliverList( + delegate: SliverChildListDelegate(children), + ), + ), + ], + ), + ); + } +} + +class HeroSliverAppBar extends StatefulWidget { + const HeroSliverAppBar({ + required this.heroTitle, + required this.hasHeroIcon, + required this.hasBackButton, + required this.onBackButtonPressed, + required this.heroIconWidget, + required this.hasFlashButton, + required this.ignoreBreakpoints, + super.key, + }); + + final String heroTitle; + final bool hasHeroIcon; + final bool hasBackButton; + final bool hasFlashButton; + final VoidCallback? onBackButtonPressed; + final Widget heroIconWidget; + final bool ignoreBreakpoints; + + @override + State createState() => _HeroSliverAppBarState(); +} + +class _HeroSliverAppBarState extends State { + Size _size = Size.zero; + @override + Widget build(final BuildContext context) { + final isMobile = + widget.ignoreBreakpoints ? true : Breakpoints.small.isActive(context); + final isJobsListEmpty = context.watch().state is JobsStateEmpty; + return SliverAppBar( + expandedHeight: + widget.hasHeroIcon ? 148.0 + _size.height : 72.0 + _size.height, + primary: true, + pinned: isMobile, + stretch: true, + surfaceTintColor: isMobile ? null : Colors.transparent, + leading: (widget.hasBackButton && isMobile) + ? const AutoLeadingButton() + : const SizedBox.shrink(), + actions: [ + if (widget.hasFlashButton && isMobile) + AnimatedSwitcher( + duration: const Duration(milliseconds: 300), + child: IconButton( + onPressed: () { + showModalBottomSheet( + context: context, + builder: (final BuildContext context) => const JobsContent(), + ); + }, + icon: Icon( + isJobsListEmpty ? Ionicons.flash_outline : Ionicons.flash, + ), + color: isJobsListEmpty + ? Theme.of(context).colorScheme.onBackground + : Theme.of(context).colorScheme.primary, + ), + ), + const SizedBox.shrink(), + ], + flexibleSpace: FlexibleSpaceBar( + title: LayoutBuilder( + builder: (final context, final constraints) => SizedBox( + width: constraints.maxWidth - 72.0, + child: WidgetSize( + onChange: (final Size size) => setState(() => _size = size), + child: Text( + widget.heroTitle, + style: Theme.of(context).textTheme.titleLarge?.copyWith( + color: Theme.of(context).colorScheme.onSurface, + ), + overflow: TextOverflow.fade, + textAlign: TextAlign.center, + ), + ), + ), + ), + expandedTitleScale: 1.2, + centerTitle: true, + collapseMode: CollapseMode.pin, + titlePadding: const EdgeInsets.only( + bottom: 12.0, + top: 16.0, + ), + background: Column( + mainAxisAlignment: MainAxisAlignment.start, + children: [ + const SizedBox(height: 72.0), + if (widget.hasHeroIcon) widget.heroIconWidget, + ], + ), + ), + ); + } +} diff --git a/lib/ui/layouts/responsive_layout_with_infobox.dart b/lib/ui/layouts/responsive_layout_with_infobox.dart new file mode 100644 index 00000000..4ef467ab --- /dev/null +++ b/lib/ui/layouts/responsive_layout_with_infobox.dart @@ -0,0 +1,70 @@ +import 'package:flutter/material.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; + +class ResponsiveLayoutWithInfobox extends StatelessWidget { + const ResponsiveLayoutWithInfobox({ + required this.primaryColumn, + this.topChild, + this.secondaryColumn, + super.key, + }); + + final Widget? topChild; + final Widget primaryColumn; + final Widget? secondaryColumn; + + @override + Widget build(final BuildContext context) { + final hasSecondaryColumn = secondaryColumn != null; + final hasTopChild = topChild != null; + + if (Breakpoints.large.isActive(context)) { + return LayoutBuilder( + builder: (final context, final constraints) => Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + if (hasTopChild) + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + SizedBox( + width: constraints.maxWidth * 0.9, + child: topChild, + ), + ], + ), + if (hasTopChild) const SizedBox(height: 16), + Row( + mainAxisAlignment: MainAxisAlignment.center, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + width: hasSecondaryColumn + ? constraints.maxWidth * 0.7 + : constraints.maxWidth * 0.9, + child: primaryColumn, + ), + if (hasSecondaryColumn) const SizedBox(width: 16), + if (hasSecondaryColumn) + SizedBox( + width: constraints.maxWidth * 0.2, + child: secondaryColumn, + ), + ], + ), + ], + ), + ); + } + return Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + if (hasTopChild) topChild!, + const SizedBox(height: 16), + primaryColumn, + const SizedBox(height: 32), + if (hasSecondaryColumn) secondaryColumn!, + ], + ); + } +} diff --git a/lib/ui/layouts/root_scaffold_with_navigation.dart b/lib/ui/layouts/root_scaffold_with_navigation.dart new file mode 100644 index 00000000..fcc58515 --- /dev/null +++ b/lib/ui/layouts/root_scaffold_with_navigation.dart @@ -0,0 +1,277 @@ +import 'package:auto_route/auto_route.dart'; +import 'package:flutter/material.dart'; +import 'package:selfprivacy/ui/components/pre_styled_buttons/flash_fab.dart'; +import 'package:selfprivacy/ui/components/drawers/support_drawer.dart'; +import 'package:selfprivacy/ui/router/root_destinations.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; + +class RootScaffoldWithNavigation extends StatelessWidget { + const RootScaffoldWithNavigation({ + required this.child, + required this.title, + required this.destinations, + this.showBottomBar = true, + this.showFab = true, + super.key, + }); + + final Widget child; + final String title; + final bool showBottomBar; + final List destinations; + final bool showFab; + + @override + // ignore: prefer_expression_function_bodies + Widget build(final BuildContext context) { + return Scaffold( + appBar: Breakpoints.mediumAndUp.isActive(context) + ? PreferredSize( + preferredSize: const Size.fromHeight(52), + child: _RootAppBar(title: title), + ) + : null, + endDrawer: const SupportDrawer(), + endDrawerEnableOpenDragGesture: false, + body: Row( + children: [ + if (Breakpoints.medium.isActive(context)) + _MainScreenNavigationRail( + destinations: destinations, + showFab: showFab, + ), + if (Breakpoints.large.isActive(context)) + _MainScreenNavigationDrawer( + destinations: destinations, + showFab: showFab, + ), + Expanded(child: child), + ], + ), + bottomNavigationBar: _BottomBar( + destinations: destinations, + hidden: !(Breakpoints.small.isActive(context) && showBottomBar), + key: const Key('bottomBar'), + ), + floatingActionButton: + showFab && Breakpoints.small.isActive(context) && showBottomBar + ? const BrandFab() + : null, + ); + } +} + +class _RootAppBar extends StatelessWidget { + const _RootAppBar({ + required this.title, + }); + + final String title; + + @override + Widget build(final BuildContext context) => AppBar( + title: AnimatedSwitcher( + duration: const Duration(milliseconds: 200), + transitionBuilder: + (final Widget child, final Animation animation) => + SlideTransition( + position: animation.drive( + Tween( + begin: const Offset(0.0, 0.2), + end: Offset.zero, + ), + ), + child: FadeTransition( + opacity: animation, + child: child, + ), + ), + child: SizedBox( + key: ValueKey(title), + width: double.infinity, + child: Text( + title, + ), + ), + ), + leading: context.router.pageCount > 1 + ? IconButton( + icon: const Icon(Icons.arrow_back), + onPressed: () => context.router.pop(), + ) + : null, + actions: const [ + SizedBox.shrink(), + ], + ); +} + +class _MainScreenNavigationRail extends StatelessWidget { + const _MainScreenNavigationRail({ + required this.destinations, + this.showFab = true, + }); + + final List destinations; + final bool showFab; + + @override + Widget build(final BuildContext context) { + int? activeIndex = destinations.indexWhere( + (final destination) => + context.router.isRouteActive(destination.route.routeName), + ); + + final prevActiveIndex = destinations.indexWhere( + (final destination) => context.router.stack + .any((final route) => route.name == destination.route.routeName), + ); + + if (activeIndex == -1) { + if (prevActiveIndex != -1) { + activeIndex = prevActiveIndex; + } else { + activeIndex = 0; + } + } + + final isExtended = Breakpoints.large.isActive(context); + + return LayoutBuilder( + builder: (final context, final constraints) => SingleChildScrollView( + child: ConstrainedBox( + constraints: BoxConstraints(minHeight: constraints.maxHeight), + child: IntrinsicHeight( + child: NavigationRail( + backgroundColor: Colors.transparent, + labelType: isExtended + ? NavigationRailLabelType.none + : NavigationRailLabelType.all, + extended: isExtended, + leading: showFab + ? const BrandFab( + extended: false, + ) + : null, + groupAlignment: 0.0, + destinations: destinations + .map( + (final destination) => NavigationRailDestination( + icon: Icon(destination.icon), + label: Text(destination.label), + ), + ) + .toList(), + selectedIndex: activeIndex, + onDestinationSelected: (final index) { + context.router.replaceAll([destinations[index].route]); + }, + ), + ), + ), + ), + ); + } +} + +class _BottomBar extends StatelessWidget { + const _BottomBar({ + required this.destinations, + required this.hidden, + super.key, + }); + + final List destinations; + final bool hidden; + + @override + Widget build(final BuildContext context) { + final prevActiveIndex = destinations.indexWhere( + (final destination) => context.router.stack + .any((final route) => route.name == destination.route.routeName), + ); + + return AnimatedContainer( + duration: const Duration(milliseconds: 500), + height: hidden ? 0 : 80, + curve: Curves.easeInOutCubicEmphasized, + clipBehavior: Clip.antiAlias, + decoration: BoxDecoration( + color: Theme.of(context).scaffoldBackgroundColor, + ), + child: NavigationBar( + selectedIndex: prevActiveIndex == -1 ? 0 : prevActiveIndex, + labelBehavior: NavigationDestinationLabelBehavior.onlyShowSelected, + onDestinationSelected: (final index) { + context.router.replaceAll([destinations[index].route]); + }, + destinations: destinations + .map( + (final destination) => NavigationDestination( + icon: Icon(destination.icon), + label: destination.label, + ), + ) + .toList(), + ), + ); + } +} + +class _MainScreenNavigationDrawer extends StatelessWidget { + const _MainScreenNavigationDrawer({ + required this.destinations, + this.showFab = true, + }); + + final List destinations; + final bool showFab; + + @override + Widget build(final BuildContext context) { + int? activeIndex = destinations.indexWhere( + (final destination) => + context.router.isRouteActive(destination.route.routeName), + ); + + final prevActiveIndex = destinations.indexWhere( + (final destination) => context.router.stack + .any((final route) => route.name == destination.route.routeName), + ); + + if (activeIndex == -1) { + if (prevActiveIndex != -1) { + activeIndex = prevActiveIndex; + } else { + activeIndex = 0; + } + } + + return SizedBox( + height: MediaQuery.of(context).size.height, + width: 296, + child: NavigationDrawer( + key: const Key('PrimaryNavigationDrawer'), + backgroundColor: Theme.of(context).scaffoldBackgroundColor, + surfaceTintColor: Colors.transparent, + selectedIndex: activeIndex, + onDestinationSelected: (final index) { + context.router.replaceAll([destinations[index].route]); + }, + children: [ + const Padding( + padding: EdgeInsets.all(16.0), + child: BrandFab(extended: true), + ), + const SizedBox(height: 16), + ...destinations.map( + (final destination) => NavigationDrawerDestination( + icon: Icon(destination.icon), + label: Text(destination.label), + ), + ), + ], + ), + ); + } +} diff --git a/lib/ui/pages/backup_details/backup_details.dart b/lib/ui/pages/backup_details/backup_details.dart index 93cb0139..f909e481 100644 --- a/lib/ui/pages/backup_details/backup_details.dart +++ b/lib/ui/pages/backup_details/backup_details.dart @@ -1,26 +1,27 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; import 'package:selfprivacy/logic/cubit/backups/backups_cubit.dart'; import 'package:selfprivacy/logic/models/json/backup.dart'; import 'package:selfprivacy/logic/models/state_types.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_cards/outlined_card.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/components/cards/outlined_card.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/components/brand_icons/brand_icons.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; import 'package:selfprivacy/ui/helpers/modals.dart'; GlobalKey navigatorKey = GlobalKey(); -class BackupDetails extends StatefulWidget { - const BackupDetails({super.key}); +@RoutePage() +class BackupDetailsPage extends StatefulWidget { + const BackupDetailsPage({super.key}); @override - State createState() => _BackupDetailsState(); + State createState() => _BackupDetailsPageState(); } -class _BackupDetailsState extends State +class _BackupDetailsPageState extends State with SingleTickerProviderStateMixin { @override Widget build(final BuildContext context) { @@ -57,7 +58,10 @@ class _BackupDetailsState extends State text: 'backup.initialize'.tr(), ), if (backupStatus == BackupStatusEnum.initializing) - BrandText.body1('backup.waiting_for_rebuild'.tr()), + Text( + 'backup.waiting_for_rebuild'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), if (backupStatus != BackupStatusEnum.initializing && backupStatus != BackupStatusEnum.noKey) OutlinedCard( @@ -227,7 +231,10 @@ class _BackupDetailsState extends State ), ), if (backupStatus == BackupStatusEnum.error) - BrandText.body1(backupError.toString()), + Text( + backupError.toString(), + style: Theme.of(context).textTheme.bodyMedium, + ), ], ); } diff --git a/lib/ui/pages/devices/devices.dart b/lib/ui/pages/devices/devices.dart index 31010fd4..52fffdbe 100644 --- a/lib/ui/pages/devices/devices.dart +++ b/lib/ui/pages/devices/devices.dart @@ -1,3 +1,4 @@ +import 'package:auto_route/auto_route.dart'; import 'package:cubit_form/cubit_form.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; @@ -5,11 +6,12 @@ import 'package:selfprivacy/logic/common_enum/common_enum.dart'; import 'package:selfprivacy/logic/cubit/devices/devices_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; import 'package:selfprivacy/logic/models/json/api_token.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/components/info_box/info_box.dart'; import 'package:selfprivacy/ui/pages/devices/new_device.dart'; import 'package:selfprivacy/utils/route_transitions/basic.dart'; +@RoutePage() class DevicesScreen extends StatefulWidget { const DevicesScreen({super.key}); @@ -25,7 +27,7 @@ class _DevicesScreenState extends State { return RefreshIndicator( onRefresh: () async { - context.read().refresh(); + await context.read().refresh(); }, child: BrandHeroScreen( heroTitle: 'devices.main_screen.header'.tr(), @@ -90,8 +92,7 @@ class _DevicesInfo extends StatelessWidget { ), ), ...devicesStatus.otherDevices - .map((final device) => _DeviceTile(device: device)) - .toList(), + .map((final device) => _DeviceTile(device: device)), ], ); } diff --git a/lib/ui/pages/devices/new_device.dart b/lib/ui/pages/devices/new_device.dart index 8310b127..9a64fa72 100644 --- a/lib/ui/pages/devices/new_device.dart +++ b/lib/ui/pages/devices/new_device.dart @@ -3,8 +3,8 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/devices/devices_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; class NewDeviceScreen extends StatelessWidget { const NewDeviceScreen({super.key}); diff --git a/lib/ui/pages/dns_details/dns_details.dart b/lib/ui/pages/dns_details/dns_details.dart index 692921eb..5efc4164 100644 --- a/lib/ui/pages/dns_details/dns_details.dart +++ b/lib/ui/pages/dns_details/dns_details.dart @@ -1,13 +1,15 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/config/get_it_config.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; import 'package:selfprivacy/logic/cubit/dns_records/dns_records_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_cards/filled_card.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/cards/filled_card.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/components/brand_icons/brand_icons.dart'; import 'package:selfprivacy/utils/network_utils.dart'; +@RoutePage() class DnsDetailsPage extends StatefulWidget { const DnsDetailsPage({super.key}); @@ -155,8 +157,7 @@ class _DnsDetailsPageState extends State { ), ], ), - ) - .toList(), + ), const SizedBox(height: 16.0), ListTile( title: Text( @@ -197,8 +198,7 @@ class _DnsDetailsPageState extends State { ), ], ), - ) - .toList(), + ), ], ); } diff --git a/lib/ui/pages/more/about_application.dart b/lib/ui/pages/more/about_application.dart index 7a9dc11e..54e493de 100644 --- a/lib/ui/pages/more/about_application.dart +++ b/lib/ui/pages/more/about_application.dart @@ -1,67 +1,73 @@ +import 'package:auto_route/auto_route.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_theme.dart'; import 'package:selfprivacy/logic/api_maps/graphql_maps/server_api/server_api.dart'; -import 'package:selfprivacy/ui/components/brand_header/brand_header.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; +import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; +import 'package:selfprivacy/ui/components/brand_md/brand_md.dart'; import 'package:package_info/package_info.dart'; import 'package:easy_localization/easy_localization.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:url_launcher/url_launcher.dart'; +@RoutePage() class AboutApplicationPage extends StatelessWidget { const AboutApplicationPage({super.key}); @override - Widget build(final BuildContext context) => SafeArea( - child: Scaffold( - appBar: PreferredSize( - preferredSize: const Size.fromHeight(52), - child: BrandHeader( - title: 'about_application_page.title'.tr(), - hasBackButton: true, + Widget build(final BuildContext context) { + final bool isReady = context.watch().state + is ServerInstallationFinished; + + return BrandHeroScreen( + hasBackButton: true, + hasFlashButton: false, + heroTitle: 'about_application_page.title'.tr(), + children: [ + FutureBuilder( + future: _packageVersion(), + builder: (final context, final snapshot) => Text( + 'about_application_page.application_version_text' + .tr(args: [snapshot.data.toString()]), + style: Theme.of(context).textTheme.bodyLarge, + ), + ), + if (isReady) + FutureBuilder( + future: _apiVersion(), + builder: (final context, final snapshot) => Text( + 'about_application_page.api_version_text' + .tr(args: [snapshot.data.toString()]), + style: Theme.of(context).textTheme.bodyLarge, ), ), - body: ListView( - padding: paddingH15V0, + const SizedBox(height: 10), + // Button to call showAboutDialog + TextButton( + onPressed: () => showAboutDialog( + context: context, + applicationName: 'SelfPrivacy', + applicationLegalese: '© 2022 SelfPrivacy', + // Link to privacy policy children: [ - const SizedBox(height: 10), - FutureBuilder( - future: _packageVersion(), - builder: (final context, final snapshot) => BrandText.body1( - 'about_application_page.application_version_text' - .tr(args: [snapshot.data.toString()]), - ), - ), - FutureBuilder( - future: _apiVersion(), - builder: (final context, final snapshot) => BrandText.body1( - 'about_application_page.api_version_text' - .tr(args: [snapshot.data.toString()]), - ), - ), - const SizedBox(height: 10), - // Button to call showAboutDialog TextButton( - onPressed: () => showAboutDialog( - context: context, - applicationName: 'SelfPrivacy', - applicationLegalese: '© 2022 SelfPrivacy', - // Link to privacy policy - children: [ - TextButton( - onPressed: () => launchUrl( - Uri.parse('https://selfprivacy.ru/privacy-policy'), - mode: LaunchMode.externalApplication, - ), - child: Text('about_application_page.privacy_policy'.tr()), - ), - ], + onPressed: () => launchUrl( + Uri.parse('https://selfprivacy.ru/privacy-policy'), + mode: LaunchMode.externalApplication, ), - child: const Text('Show about dialog'), + child: Text('about_application_page.privacy_policy'.tr()), ), ], ), + child: const Text('Show about dialog'), ), - ); + const SizedBox(height: 8), + const Divider(height: 0), + const SizedBox(height: 8), + const BrandMarkdown( + fileName: 'about', + ), + ], + ); + } Future _packageVersion() async { String packageVersion = 'unknown'; diff --git a/lib/ui/pages/more/app_settings/app_setting.dart b/lib/ui/pages/more/app_settings/app_setting.dart deleted file mode 100644 index 4287e985..00000000 --- a/lib/ui/pages/more/app_settings/app_setting.dart +++ /dev/null @@ -1,229 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; -import 'package:selfprivacy/config/brand_theme.dart'; -import 'package:selfprivacy/logic/cubit/app_settings/app_settings_cubit.dart'; -import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/action_button/action_button.dart'; -import 'package:selfprivacy/ui/components/brand_alert/brand_alert.dart'; -import 'package:selfprivacy/ui/components/brand_header/brand_header.dart'; -import 'package:selfprivacy/ui/components/brand_switch/brand_switch.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; -import 'package:selfprivacy/utils/named_font_weight.dart'; -import 'package:easy_localization/easy_localization.dart'; - -class AppSettingsPage extends StatefulWidget { - const AppSettingsPage({super.key}); - - @override - State createState() => _AppSettingsPageState(); -} - -class _AppSettingsPageState extends State { - @override - Widget build(final BuildContext context) { - final bool isDarkModeOn = - context.watch().state.isDarkModeOn; - - return SafeArea( - child: Builder( - builder: (final context) => Scaffold( - appBar: PreferredSize( - preferredSize: const Size.fromHeight(52), - child: BrandHeader( - title: 'application_settings.title'.tr(), - hasBackButton: true, - ), - ), - body: ListView( - padding: paddingH15V0, - children: [ - const Divider(height: 1), - Container( - padding: const EdgeInsets.symmetric(vertical: 16), - child: Row( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Flexible( - child: _TextColumn( - title: 'application_settings.dark_theme_title'.tr(), - value: - 'application_settings.dark_theme_description'.tr(), - hasWarning: false, - ), - ), - const SizedBox(width: 5), - BrandSwitch( - value: Theme.of(context).brightness == Brightness.dark, - onChanged: (final value) => context - .read() - .updateDarkMode(isDarkModeOn: !isDarkModeOn), - ), - ], - ), - ), - const Divider(height: 0), - Container( - padding: const EdgeInsets.symmetric(vertical: 16), - child: Row( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Flexible( - child: _TextColumn( - title: 'application_settings.reset_config_title'.tr(), - value: 'application_settings.reset_config_description' - .tr(), - hasWarning: false, - ), - ), - const SizedBox(width: 5), - ElevatedButton( - style: ElevatedButton.styleFrom( - backgroundColor: BrandColors.red1, - ), - child: Text( - 'basis.reset'.tr(), - style: const TextStyle( - color: BrandColors.white, - fontWeight: NamedFontWeight.demiBold, - ), - ), - onPressed: () { - showDialog( - context: context, - builder: (final _) => BrandAlert( - title: 'modals.are_you_sure'.tr(), - contentText: 'modals.purge_all_keys'.tr(), - actions: [ - ActionButton( - text: 'modals.purge_all_keys_confirm'.tr(), - isRed: true, - onPressed: () { - context - .read() - .clearAppConfig(); - Navigator.of(context).pop(); - }, - ), - ActionButton( - text: 'basis.cancel'.tr(), - ), - ], - ), - ); - }, - ), - ], - ), - ), - const Divider(height: 0), - _deleteServer(context) - ], - ), - ), - ), - ); - } - - Widget _deleteServer(final BuildContext context) { - final bool isDisabled = - context.watch().state.serverDetails == null; - return Container( - padding: const EdgeInsets.symmetric(vertical: 16), - child: Row( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - Flexible( - child: _TextColumn( - title: 'application_settings.delete_server_title'.tr(), - value: 'application_settings.delete_server_description'.tr(), - hasWarning: false, - ), - ), - const SizedBox(width: 5), - ElevatedButton( - style: ElevatedButton.styleFrom( - backgroundColor: BrandColors.red1, - ), - onPressed: isDisabled - ? null - : () { - showDialog( - context: context, - builder: (final _) => BrandAlert( - title: 'modals.are_you_sure'.tr(), - contentText: 'modals.delete_server_volume'.tr(), - actions: [ - ActionButton( - text: 'modals.yes'.tr(), - isRed: true, - onPressed: () async { - showDialog( - context: context, - builder: (final context) => Container( - alignment: Alignment.center, - child: const CircularProgressIndicator(), - ), - ); - await context - .read() - .serverDelete(); - if (!mounted) { - return; - } - Navigator.of(context).pop(); - }, - ), - ActionButton( - text: 'basis.cancel'.tr(), - ), - ], - ), - ); - }, - child: Text( - 'basis.delete'.tr(), - style: const TextStyle( - color: BrandColors.white, - fontWeight: NamedFontWeight.demiBold, - ), - ), - ), - ], - ), - ); - } -} - -class _TextColumn extends StatelessWidget { - const _TextColumn({ - required this.title, - required this.value, - this.hasWarning = false, - }); - - final String title; - final String value; - final bool hasWarning; - @override - Widget build(final BuildContext context) => Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - BrandText.body1( - title, - style: TextStyle(color: hasWarning ? BrandColors.warning : null), - ), - const SizedBox(height: 5), - BrandText.body1( - value, - style: const TextStyle( - fontSize: 13, - height: 1.53, - color: BrandColors.gray1, - ).merge(TextStyle(color: hasWarning ? BrandColors.warning : null)), - ), - ], - ); -} diff --git a/lib/ui/pages/more/app_settings/app_settings.dart b/lib/ui/pages/more/app_settings/app_settings.dart new file mode 100644 index 00000000..6ab69f40 --- /dev/null +++ b/lib/ui/pages/more/app_settings/app_settings.dart @@ -0,0 +1,151 @@ +import 'dart:async'; + +import 'package:auto_route/auto_route.dart'; +import 'package:flutter/material.dart'; +import 'package:selfprivacy/logic/cubit/app_settings/app_settings_cubit.dart'; +import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; +import 'package:selfprivacy/ui/components/buttons/dialog_action_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; +import 'package:easy_localization/easy_localization.dart'; + +@RoutePage() +class AppSettingsPage extends StatefulWidget { + const AppSettingsPage({super.key}); + + @override + State createState() => _AppSettingsPageState(); +} + +class _AppSettingsPageState extends State { + @override + Widget build(final BuildContext context) { + final bool isDarkModeOn = + context.watch().state.isDarkModeOn; + + final bool isSystemDarkModeOn = + context.watch().state.isAutoDarkModeOn; + + return BrandHeroScreen( + hasBackButton: true, + hasFlashButton: false, + bodyPadding: const EdgeInsets.symmetric(vertical: 16), + heroTitle: 'application_settings.title'.tr(), + children: [ + SwitchListTile( + title: Text('application_settings.system_dark_theme_title'.tr()), + subtitle: + Text('application_settings.system_dark_theme_description'.tr()), + value: isSystemDarkModeOn, + onChanged: (final value) => context + .read() + .updateAutoDarkMode(isAutoDarkModeOn: !isSystemDarkModeOn), + ), + SwitchListTile( + title: Text('application_settings.dark_theme_title'.tr()), + subtitle: Text('application_settings.dark_theme_description'.tr()), + value: Theme.of(context).brightness == Brightness.dark, + onChanged: isSystemDarkModeOn + ? null + : (final value) => context + .read() + .updateDarkMode(isDarkModeOn: !isDarkModeOn), + ), + const Divider(height: 0), + Padding( + padding: const EdgeInsets.all(16), + child: Text( + 'application_settings.dangerous_settings'.tr(), + style: Theme.of(context).textTheme.labelLarge!.copyWith( + color: Theme.of(context).colorScheme.error, + ), + ), + ), + const _ResetAppTile(), + // const Divider(height: 0), + _deleteServer(context) + ], + ); + } + + Widget _deleteServer(final BuildContext context) { + final bool isDisabled = + context.watch().state.serverDetails == null; + return ListTile( + title: Text('application_settings.delete_server_title'.tr()), + subtitle: Text('application_settings.delete_server_description'.tr()), + textColor: isDisabled + ? Theme.of(context).colorScheme.onBackground.withOpacity(0.5) + : Theme.of(context).colorScheme.onBackground, + onTap: isDisabled + ? null + : () { + showDialog( + context: context, + builder: (final _) => AlertDialog( + title: Text('modals.are_you_sure'.tr()), + content: Text('modals.delete_server_volume'.tr()), + actions: [ + DialogActionButton( + text: 'modals.yes'.tr(), + isRed: true, + onPressed: () async { + unawaited( + showDialog( + context: context, + builder: (final context) => Container( + alignment: Alignment.center, + child: const CircularProgressIndicator(), + ), + ), + ); + await context + .read() + .serverDelete(); + if (!mounted) { + return; + } + Navigator.of(context).pop(); + }, + ), + DialogActionButton( + text: 'basis.cancel'.tr(), + ), + ], + ), + ); + }, + ); + } +} + +class _ResetAppTile extends StatelessWidget { + const _ResetAppTile(); + + @override + Widget build(final BuildContext context) => ListTile( + title: Text('application_settings.reset_config_title'.tr()), + subtitle: Text('application_settings.reset_config_description'.tr()), + onTap: () { + showDialog( + context: context, + builder: (final _) => AlertDialog( + title: Text('modals.are_you_sure'.tr()), + content: Text('modals.purge_all_keys'.tr()), + actions: [ + DialogActionButton( + text: 'modals.purge_all_keys_confirm'.tr(), + isRed: true, + onPressed: () { + context.read().clearAppConfig(); + Navigator.of(context).pop(); + }, + ), + DialogActionButton( + text: 'basis.cancel'.tr(), + ), + ], + ), + ); + }, + ); +} diff --git a/lib/ui/pages/more/app_settings/developer_settings.dart b/lib/ui/pages/more/app_settings/developer_settings.dart new file mode 100644 index 00000000..220cb791 --- /dev/null +++ b/lib/ui/pages/more/app_settings/developer_settings.dart @@ -0,0 +1,85 @@ +import 'package:auto_route/auto_route.dart'; +import 'package:flutter/material.dart'; +import 'package:selfprivacy/logic/api_maps/staging_options.dart'; +import 'package:selfprivacy/logic/cubit/app_settings/app_settings_cubit.dart'; +import 'package:selfprivacy/logic/cubit/devices/devices_cubit.dart'; +import 'package:selfprivacy/logic/cubit/recovery_key/recovery_key_cubit.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; +import 'package:easy_localization/easy_localization.dart'; + +@RoutePage() +class DeveloperSettingsPage extends StatefulWidget { + const DeveloperSettingsPage({super.key}); + + @override + State createState() => _DeveloperSettingsPageState(); +} + +class _DeveloperSettingsPageState extends State { + @override + Widget build(final BuildContext context) => BrandHeroScreen( + hasBackButton: true, + hasFlashButton: false, + bodyPadding: const EdgeInsets.symmetric(vertical: 16), + heroTitle: 'developer_settings.title'.tr(), + heroSubtitle: 'developer_settings.subtitle'.tr(), + children: [ + Padding( + padding: const EdgeInsets.all(16), + child: Text( + 'developer_settings.server_setup'.tr(), + style: Theme.of(context).textTheme.labelLarge!.copyWith( + color: Theme.of(context).colorScheme.secondary, + ), + ), + ), + SwitchListTile( + title: Text('developer_settings.use_staging_acme'.tr()), + subtitle: + Text('developer_settings.use_staging_acme_description'.tr()), + value: StagingOptions.stagingAcme, + onChanged: null, + ), + Padding( + padding: const EdgeInsets.all(16), + child: Text( + 'developer_settings.routing'.tr(), + style: Theme.of(context).textTheme.labelLarge!.copyWith( + color: Theme.of(context).colorScheme.secondary, + ), + ), + ), + ListTile( + title: Text('developer_settings.reset_onboarding'.tr()), + subtitle: + Text('developer_settings.reset_onboarding_description'.tr()), + enabled: + !context.watch().state.isOnboardingShowing, + onTap: () => context + .read() + .turnOffOnboarding(isOnboardingShowing: true), + ), + Padding( + padding: const EdgeInsets.all(16), + child: Text( + 'developer_settings.cubit_statuses'.tr(), + style: Theme.of(context).textTheme.labelLarge!.copyWith( + color: Theme.of(context).colorScheme.secondary, + ), + ), + ), + ListTile( + title: const Text('ApiDevicesCubit'), + subtitle: Text( + context.watch().state.status.toString(), + ), + ), + ListTile( + title: const Text('RecoveryKeyCubit'), + subtitle: Text( + context.watch().state.loadingStatus.toString(), + ), + ), + ], + ); +} diff --git a/lib/ui/pages/more/console.dart b/lib/ui/pages/more/console.dart index 6ad31ea5..95670475 100644 --- a/lib/ui/pages/more/console.dart +++ b/lib/ui/pages/more/console.dart @@ -1,20 +1,21 @@ +import 'package:auto_route/auto_route.dart'; import 'dart:collection'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; import 'package:selfprivacy/config/get_it_config.dart'; import 'package:selfprivacy/logic/models/message.dart'; -import 'package:selfprivacy/ui/components/brand_header/brand_header.dart'; +import 'package:selfprivacy/ui/components/list_tiles/log_list_tile.dart'; -class Console extends StatefulWidget { - const Console({super.key}); +@RoutePage() +class ConsolePage extends StatefulWidget { + const ConsolePage({super.key}); @override - State createState() => _ConsoleState(); + State createState() => _ConsolePageState(); } -class _ConsoleState extends State { +class _ConsolePageState extends State { @override void initState() { getIt.get().addListener(update); @@ -28,21 +29,30 @@ class _ConsoleState extends State { super.dispose(); } - void update() => setState(() => {}); + bool paused = false; + + void update() { + if (!paused) { + setState(() => {}); + } + } @override Widget build(final BuildContext context) => SafeArea( child: Scaffold( - appBar: PreferredSize( - preferredSize: const Size.fromHeight(53), - child: Column( - children: [ - BrandHeader( - title: 'console_page.title'.tr(), - hasBackButton: true, - ), - ], + appBar: AppBar( + title: Text('console_page.title'.tr()), + leading: IconButton( + icon: const Icon(Icons.arrow_back), + onPressed: () => Navigator.of(context).pop(), ), + actions: [ + IconButton( + icon: Icon( + paused ? Icons.play_arrow_outlined : Icons.pause_outlined), + onPressed: () => setState(() => paused = !paused), + ), + ], ), body: FutureBuilder( future: getIt.allReady(), @@ -61,30 +71,7 @@ class _ConsoleState extends State { const SizedBox(height: 20), ...UnmodifiableListView( messages - .map((final message) { - final bool isError = - message.type == MessageType.warning; - return Padding( - padding: const EdgeInsets.symmetric(vertical: 4), - child: RichText( - text: TextSpan( - style: DefaultTextStyle.of(context).style, - children: [ - TextSpan( - text: - '${message.timeString}${isError ? '(Error)' : ''}: \n', - style: TextStyle( - fontWeight: FontWeight.bold, - color: - isError ? BrandColors.red1 : null, - ), - ), - TextSpan(text: message.text), - ], - ), - ), - ); - }) + .map((final message) => LogListItem(message: message)) .toList() .reversed, ), diff --git a/lib/ui/pages/more/more.dart b/lib/ui/pages/more/more.dart index 77b1d34a..3d85b093 100644 --- a/lib/ui/pages/more/more.dart +++ b/lib/ui/pages/more/more.dart @@ -1,3 +1,4 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:ionicons/ionicons.dart'; @@ -5,23 +6,13 @@ import 'package:selfprivacy/config/brand_theme.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_volumes/server_volume_cubit.dart'; import 'package:selfprivacy/logic/cubit/services/services_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_cards/filled_card.dart'; +import 'package:selfprivacy/ui/components/cards/filled_card.dart'; import 'package:selfprivacy/ui/components/brand_header/brand_header.dart'; import 'package:selfprivacy/ui/components/brand_icons/brand_icons.dart'; -import 'package:selfprivacy/ui/pages/devices/devices.dart'; -import 'package:selfprivacy/ui/pages/recovery_key/recovery_key.dart'; -import 'package:selfprivacy/ui/pages/server_storage/binds_migration/services_migration.dart'; -import 'package:selfprivacy/ui/pages/setup/initializing/initializing.dart'; -import 'package:selfprivacy/ui/pages/onboarding/onboarding.dart'; -import 'package:selfprivacy/ui/pages/root_route.dart'; -import 'package:selfprivacy/ui/pages/users/users.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; - -import 'package:selfprivacy/ui/pages/more/about_us.dart'; -import 'package:selfprivacy/ui/pages/more/app_settings/app_setting.dart'; -import 'package:selfprivacy/ui/pages/more/console.dart'; -import 'package:selfprivacy/ui/pages/more/about_application.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; +import 'package:selfprivacy/ui/router/router.dart'; +@RoutePage() class MorePage extends StatelessWidget { const MorePage({super.key}); @@ -34,12 +25,14 @@ class MorePage extends StatelessWidget { context.watch().state.usesBinds; return Scaffold( - appBar: PreferredSize( - preferredSize: const Size.fromHeight(52), - child: BrandHeader( - title: 'basis.more'.tr(), - ), - ), + appBar: Breakpoints.small.isActive(context) + ? PreferredSize( + preferredSize: const Size.fromHeight(52), + child: BrandHeader( + title: 'basis.more'.tr(), + ), + ) + : null, body: ListView( children: [ Padding( @@ -50,7 +43,7 @@ class MorePage extends StatelessWidget { _MoreMenuItem( title: 'storage.start_migration_button'.tr(), iconData: Icons.drive_file_move_outline, - goTo: ServicesMigrationPage( + goTo: () => ServicesMigrationRoute( diskStatus: context .watch() .state @@ -77,7 +70,7 @@ class MorePage extends StatelessWidget { _MoreMenuItem( title: 'more_page.configuration_wizard'.tr(), iconData: Icons.change_history_outlined, - goTo: const InitializingPage(), + goTo: () => const InitializingRoute(), subtitle: 'not_ready_card.in_menu'.tr(), accent: true, ), @@ -85,47 +78,43 @@ class MorePage extends StatelessWidget { _MoreMenuItem( title: 'more_page.create_ssh_key'.tr(), iconData: Ionicons.key_outline, - goTo: const UserDetails( + goTo: () => UserDetailsRoute( login: 'root', ), ), if (isReady) _MoreMenuItem( iconData: Icons.password_outlined, - goTo: const RecoveryKey(), + goTo: () => const RecoveryKeyRoute(), title: 'recovery_key.key_main_header'.tr(), ), if (isReady) _MoreMenuItem( iconData: Icons.devices_outlined, - goTo: const DevicesScreen(), + goTo: () => const DevicesRoute(), title: 'devices.main_screen.header'.tr(), ), _MoreMenuItem( title: 'more_page.application_settings'.tr(), iconData: Icons.settings_outlined, - goTo: const AppSettingsPage(), - ), - _MoreMenuItem( - title: 'more_page.about_project'.tr(), - iconData: BrandIcons.engineer, - goTo: const AboutUsPage(), + goTo: () => const AppSettingsRoute(), ), _MoreMenuItem( title: 'more_page.about_application'.tr(), iconData: BrandIcons.fire, - goTo: const AboutApplicationPage(), + goTo: () => const AboutApplicationRoute(), + longGoTo: const DeveloperSettingsRoute(), ), if (!isReady) _MoreMenuItem( title: 'more_page.onboarding'.tr(), iconData: BrandIcons.start, - goTo: const OnboardingPage(nextPage: RootPage()), + goTo: () => const OnboardingRoute(), ), _MoreMenuItem( title: 'more_page.console'.tr(), iconData: BrandIcons.terminal, - goTo: const Console(), + goTo: () => const ConsoleRoute(), ), ], ), @@ -140,14 +129,16 @@ class _MoreMenuItem extends StatelessWidget { const _MoreMenuItem({ required this.iconData, required this.title, + required this.goTo, this.subtitle, - this.goTo, + this.longGoTo, this.accent = false, }); final IconData iconData; final String title; - final Widget? goTo; + final PageRouteInfo Function() goTo; + final PageRouteInfo? longGoTo; final String? subtitle; final bool accent; @@ -160,9 +151,9 @@ class _MoreMenuItem extends StatelessWidget { tertiary: accent, child: ListTile( contentPadding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8), - onTap: goTo != null - ? () => Navigator.of(context).push(materialRoute(goTo!)) - : null, + onTap: () => context.pushRoute(goTo()), + onLongPress: + longGoTo != null ? () => context.pushRoute(longGoTo!) : null, leading: Icon( iconData, size: 24, diff --git a/lib/ui/pages/onboarding/onboarding.dart b/lib/ui/pages/onboarding/onboarding.dart index ac865b11..2e035d53 100644 --- a/lib/ui/pages/onboarding/onboarding.dart +++ b/lib/ui/pages/onboarding/onboarding.dart @@ -1,13 +1,14 @@ +import 'package:auto_route/auto_route.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/app_settings/app_settings_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/router/router.dart'; import 'package:easy_localization/easy_localization.dart'; +@RoutePage() class OnboardingPage extends StatefulWidget { - const OnboardingPage({required this.nextPage, super.key}); + const OnboardingPage({super.key}); - final Widget nextPage; @override State createState() => _OnboardingPageState(); } @@ -22,14 +23,14 @@ class _OnboardingPageState extends State { @override Widget build(final BuildContext context) => Scaffold( - body: PageView( - controller: pageController, - children: [ - _withPadding(firstPage()), - _withPadding(secondPage()), - ], - ), - ); + body: PageView( + controller: pageController, + children: [ + _withPadding(firstPage()), + _withPadding(secondPage()), + ], + ), + ); Widget _withPadding(final Widget child) => Padding( padding: const EdgeInsets.symmetric( @@ -76,7 +77,7 @@ class _OnboardingPageState extends State { pageController.animateToPage( 1, duration: const Duration(milliseconds: 300), - curve: Curves.easeIn, + curve: Curves.easeInOutCubicEmphasized, ); }, text: 'basis.next'.tr(), @@ -142,10 +143,10 @@ class _OnboardingPageState extends State { BrandButton.rised( onPressed: () { context.read().turnOffOnboarding(); - Navigator.of(context).pushAndRemoveUntil( - materialRoute(widget.nextPage), - (final route) => false, - ); + context.router.replaceAll([ + const RootRoute(), + const InitializingRoute(), + ]); }, text: 'basis.got_it'.tr(), ), diff --git a/lib/ui/pages/providers/providers.dart b/lib/ui/pages/providers/providers.dart index d234c984..25533a43 100644 --- a/lib/ui/pages/providers/providers.dart +++ b/lib/ui/pages/providers/providers.dart @@ -1,3 +1,4 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/config/brand_theme.dart'; @@ -10,13 +11,12 @@ import 'package:selfprivacy/ui/components/brand_header/brand_header.dart'; import 'package:selfprivacy/ui/components/brand_icons/brand_icons.dart'; import 'package:selfprivacy/ui/components/icon_status_mask/icon_status_mask.dart'; import 'package:selfprivacy/ui/components/not_ready_card/not_ready_card.dart'; -import 'package:selfprivacy/ui/pages/backup_details/backup_details.dart'; -import 'package:selfprivacy/ui/pages/dns_details/dns_details.dart'; -import 'package:selfprivacy/ui/pages/server_details/server_details_screen.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +import 'package:selfprivacy/ui/router/router.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; GlobalKey navigatorKey = GlobalKey(); +@RoutePage() class ProvidersPage extends StatefulWidget { const ProvidersPage({super.key}); @@ -61,12 +61,14 @@ class _ProvidersPageState extends State { } return Scaffold( - appBar: PreferredSize( - preferredSize: const Size.fromHeight(52), - child: BrandHeader( - title: 'basis.providers_title'.tr(), - ), - ), + appBar: Breakpoints.small.isActive(context) + ? PreferredSize( + preferredSize: const Size.fromHeight(52), + child: BrandHeader( + title: 'basis.providers_title'.tr(), + ), + ) + : null, body: ListView( padding: paddingH15V0, children: [ @@ -81,8 +83,7 @@ class _ProvidersPageState extends State { subtitle: diskStatus.isDiskOkay ? 'storage.status_ok'.tr() : 'storage.status_error'.tr(), - onTap: () => Navigator.of(context) - .push(materialRoute(const ServerDetailsScreen())), + onTap: () => context.pushRoute(const ServerDetailsRoute()), ), const SizedBox(height: 16), _Card( @@ -92,11 +93,7 @@ class _ProvidersPageState extends State { subtitle: appConfig.isDomainSelected ? appConfig.serverDomain!.domainName : '', - onTap: () => Navigator.of(context).push( - materialRoute( - const DnsDetailsPage(), - ), - ), + onTap: () => context.pushRoute(const DnsDetailsRoute()), ), const SizedBox(height: 16), // TODO: When backups are fixed, show this card @@ -108,8 +105,7 @@ class _ProvidersPageState extends State { icon: BrandIcons.save, title: 'backup.card_title'.tr(), subtitle: isBackupInitialized ? 'backup.card_subtitle'.tr() : '', - onTap: () => Navigator.of(context) - .push(materialRoute(const BackupDetails())), + onTap: () => context.pushRoute(const BackupDetailsRoute()), ), ], ), diff --git a/lib/ui/pages/recovery_key/recovery_key.dart b/lib/ui/pages/recovery_key/recovery_key.dart index 02a7ed9a..86d678bb 100644 --- a/lib/ui/pages/recovery_key/recovery_key.dart +++ b/lib/ui/pages/recovery_key/recovery_key.dart @@ -1,4 +1,4 @@ -import 'package:cubit_form/cubit_form.dart'; +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; @@ -6,20 +6,21 @@ import 'package:selfprivacy/config/get_it_config.dart'; import 'package:selfprivacy/logic/common_enum/common_enum.dart'; import 'package:selfprivacy/logic/cubit/recovery_key/recovery_key_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_cards/filled_card.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/components/cards/filled_card.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/pages/recovery_key/recovery_key_receiving.dart'; import 'package:selfprivacy/utils/route_transitions/basic.dart'; -class RecoveryKey extends StatefulWidget { - const RecoveryKey({super.key}); +@RoutePage() +class RecoveryKeyPage extends StatefulWidget { + const RecoveryKeyPage({super.key}); @override - State createState() => _RecoveryKeyState(); + State createState() => _RecoveryKeyPageState(); } -class _RecoveryKeyState extends State { +class _RecoveryKeyPageState extends State { @override void initState() { super.initState(); @@ -250,7 +251,7 @@ class _RecoveryKeyConfigurationState extends State { setState(() { _isLoading = false; }); - Navigator.of(context).push( + await Navigator.of(context).push( materialRoute( RecoveryKeyReceiving(recoveryKey: token), // TO DO ), diff --git a/lib/ui/pages/recovery_key/recovery_key_receiving.dart b/lib/ui/pages/recovery_key/recovery_key_receiving.dart index afca6d20..10f2e7c0 100644 --- a/lib/ui/pages/recovery_key/recovery_key_receiving.dart +++ b/lib/ui/pages/recovery_key/recovery_key_receiving.dart @@ -1,7 +1,7 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/components/info_box/info_box.dart'; class RecoveryKeyReceiving extends StatelessWidget { diff --git a/lib/ui/pages/root_route.dart b/lib/ui/pages/root_route.dart index ce1f344c..65d4cd8d 100644 --- a/lib/ui/pages/root_route.dart +++ b/lib/ui/pages/root_route.dart @@ -1,89 +1,153 @@ +import 'package:auto_route/auto_route.dart'; +import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; +import 'package:selfprivacy/logic/cubit/app_settings/app_settings_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_tab_bar/brand_tab_bar.dart'; -import 'package:selfprivacy/ui/pages/more/more.dart'; -import 'package:selfprivacy/ui/pages/providers/providers.dart'; -import 'package:selfprivacy/ui/pages/services/services.dart'; -import 'package:selfprivacy/ui/pages/users/users.dart'; +import 'package:selfprivacy/ui/layouts/root_scaffold_with_navigation.dart'; +import 'package:selfprivacy/ui/router/root_destinations.dart'; -import 'package:selfprivacy/ui/components/pre_styled_buttons/flash_fab.dart'; +import 'package:selfprivacy/ui/router/router.dart'; -class RootPage extends StatefulWidget { +@RoutePage() +class RootPage extends StatefulWidget implements AutoRouteWrapper { const RootPage({super.key}); @override State createState() => _RootPageState(); + + @override + Widget wrappedRoute(final BuildContext context) => this; } class _RootPageState extends State with TickerProviderStateMixin { - late TabController tabController; + bool shouldUseSplitView() => false; - late final AnimationController _controller = AnimationController( - duration: const Duration(milliseconds: 400), - vsync: this, - ); - late final Animation _animation = CurvedAnimation( - parent: _controller, - curve: Curves.fastOutSlowIn, - ); - - @override - void initState() { - tabController = TabController(length: 4, vsync: this); - tabController.addListener(() { - setState(() { - tabController.index == 2 - ? _controller.forward() - : _controller.reverse(); - }); - }); - super.initState(); - } - - @override - void dispose() { - tabController.dispose(); - _controller.dispose(); - super.dispose(); - } + final destinations = rootDestinations; @override Widget build(final BuildContext context) { final bool isReady = context.watch().state is ServerInstallationFinished; - return Provider( - create: (final _) => ChangeTab(tabController.animateTo), - child: Scaffold( - body: TabBarView( - controller: tabController, - children: const [ - ProvidersPage(), - ServicesPage(), - UsersPage(), - MorePage(), + if (context.read().state.isOnboardingShowing) { + context.router.replace(const OnboardingRoute()); + } + + return AutoRouter( + builder: (final context, final child) { + final currentDestinationIndex = destinations.indexWhere( + (final destination) => + context.router.isRouteActive(destination.route.routeName), + ); + final isOtherRouterActive = + context.router.root.current.name != RootRoute.name; + final routeName = getRouteTitle(context.router.current.name).tr(); + return RootScaffoldWithNavigation( + title: routeName, + destinations: destinations, + showBottomBar: + !(currentDestinationIndex == -1 && !isOtherRouterActive), + showFab: isReady, + child: child, + ); + }, + ); + } +} + +class MainScreenNavigationRail extends StatelessWidget { + const MainScreenNavigationRail({ + required this.destinations, + super.key, + }); + + final List destinations; + + @override + Widget build(final BuildContext context) { + int? activeIndex = destinations.indexWhere( + (final destination) => + context.router.isRouteActive(destination.route.routeName), + ); + if (activeIndex == -1) { + activeIndex = null; + } + + return Padding( + padding: const EdgeInsets.all(8.0), + child: SizedBox( + height: MediaQuery.of(context).size.height, + width: 72, + child: LayoutBuilder( + builder: (final context, final constraints) => SingleChildScrollView( + child: ConstrainedBox( + constraints: BoxConstraints(minHeight: constraints.maxHeight), + child: IntrinsicHeight( + child: NavigationRail( + backgroundColor: Colors.transparent, + labelType: NavigationRailLabelType.all, + destinations: destinations + .map( + (final destination) => NavigationRailDestination( + icon: Icon(destination.icon), + label: Text(destination.label), + ), + ) + .toList(), + selectedIndex: activeIndex, + onDestinationSelected: (final index) { + context.router.replaceAll([destinations[index].route]); + }, + ), + ), + ), + ), + ), + ), + ); + } +} + +class MainScreenNavigationDrawer extends StatelessWidget { + const MainScreenNavigationDrawer({ + required this.destinations, + super.key, + }); + + final List destinations; + + @override + Widget build(final BuildContext context) { + int? activeIndex = destinations.indexWhere( + (final destination) => + context.router.isRouteActive(destination.route.routeName), + ); + if (activeIndex == -1) { + activeIndex = null; + } + + return SizedBox( + height: MediaQuery.of(context).size.height, + width: 296, + child: LayoutBuilder( + builder: (final context, final constraints) => NavigationDrawer( + // backgroundColor: Theme.of(context).colorScheme.surfaceVariant, + // surfaceTintColor: Colors.transparent, + key: const Key('PrimaryNavigationDrawer'), + selectedIndex: activeIndex, + onDestinationSelected: (final index) { + context.router.replaceAll([destinations[index].route]); + }, + children: [ + const SizedBox(height: 18), + ...destinations.map( + (final destination) => NavigationDrawerDestination( + icon: Icon(destination.icon), + label: Text(destination.label), + ), + ), ], ), - bottomNavigationBar: BrandTabBar( - controller: tabController, - ), - floatingActionButton: isReady - ? SizedBox( - height: 104 + 16, - child: Column( - crossAxisAlignment: CrossAxisAlignment.end, - mainAxisAlignment: MainAxisAlignment.end, - children: [ - ScaleTransition( - scale: _animation, - child: const AddUserFab(), - ), - const SizedBox(height: 16), - const BrandFab(), - ], - ), - ) - : null, ), ); } diff --git a/lib/ui/pages/server_details/server_details_screen.dart b/lib/ui/pages/server_details/server_details_screen.dart index 487e1a25..a3a521b5 100644 --- a/lib/ui/pages/server_details/server_details_screen.dart +++ b/lib/ui/pages/server_details/server_details_screen.dart @@ -1,7 +1,7 @@ +import 'package:auto_route/auto_route.dart'; import 'package:cubit_form/cubit_form.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; import 'package:selfprivacy/logic/common_enum/common_enum.dart'; import 'package:selfprivacy/logic/cubit/client_jobs/client_jobs_cubit.dart'; import 'package:selfprivacy/logic/cubit/metrics/metrics_cubit.dart'; @@ -10,18 +10,17 @@ import 'package:selfprivacy/logic/cubit/server_installation/server_installation_ import 'package:selfprivacy/logic/cubit/server_volumes/server_volume_cubit.dart'; import 'package:selfprivacy/logic/models/auto_upgrade_settings.dart'; import 'package:selfprivacy/logic/models/job.dart'; -import 'package:selfprivacy/ui/components/brand_button/segmented_buttons.dart'; -import 'package:selfprivacy/ui/components/brand_cards/filled_card.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/segmented_buttons.dart'; +import 'package:selfprivacy/ui/components/cards/filled_card.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/components/brand_icons/brand_icons.dart'; import 'package:selfprivacy/ui/components/brand_loader/brand_loader.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; import 'package:selfprivacy/ui/components/list_tiles/list_tile_on_surface_variant.dart'; import 'package:selfprivacy/ui/pages/server_details/charts/cpu_chart.dart'; import 'package:selfprivacy/ui/pages/server_details/charts/network_charts.dart'; import 'package:selfprivacy/ui/pages/server_storage/storage_card.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; import 'package:selfprivacy/utils/extensions/duration.dart'; -import 'package:selfprivacy/utils/named_font_weight.dart'; import 'package:selfprivacy/utils/route_transitions/basic.dart'; import 'package:timezone/timezone.dart'; @@ -32,6 +31,7 @@ part 'time_zone/time_zone.dart'; var navigatorKey = GlobalKey(); +@RoutePage() class ServerDetailsScreen extends StatefulWidget { const ServerDetailsScreen({super.key}); @@ -75,6 +75,7 @@ class _ServerDetailsScreenState extends State return BlocProvider( create: (final context) => context.read()..check(), child: BrandHeroScreen( + hasFlashButton: true, heroIcon: BrandIcons.server, heroTitle: 'server.card_title'.tr(), heroSubtitle: 'server.description'.tr(), diff --git a/lib/ui/pages/server_details/text_details.dart b/lib/ui/pages/server_details/text_details.dart index 5f447901..03126ba5 100644 --- a/lib/ui/pages/server_details/text_details.dart +++ b/lib/ui/pages/server_details/text_details.dart @@ -23,15 +23,13 @@ class _TextDetails extends StatelessWidget { ), ), ), - ...details.metadata - .map( - (final metadata) => ListTileOnSurfaceVariant( - leadingIcon: metadata.type.icon, - title: metadata.name, - subtitle: metadata.value, - ), - ) - .toList(), + ...details.metadata.map( + (final metadata) => ListTileOnSurfaceVariant( + leadingIcon: metadata.type.icon, + title: metadata.name, + subtitle: metadata.value, + ), + ), ], ), ); @@ -39,24 +37,6 @@ class _TextDetails extends StatelessWidget { throw Exception('wrong state'); } } - - Widget getRowTitle(final String title) => Padding( - padding: const EdgeInsets.only(right: 10), - child: BrandText.h5( - title, - textAlign: TextAlign.right, - ), - ); - - Widget getRowValue(final String title, {final bool isBold = false}) => - BrandText.body1( - title, - style: isBold - ? const TextStyle( - fontWeight: NamedFontWeight.demiBold, - ) - : null, - ); } class _TempMessage extends StatelessWidget { @@ -69,7 +49,10 @@ class _TempMessage extends StatelessWidget { Widget build(final BuildContext context) => SizedBox( height: MediaQuery.of(context).size.height - 100, child: Center( - child: BrandText.body2(message), + child: Text( + message, + style: Theme.of(context).textTheme.bodyMedium, + ), ), ); } diff --git a/lib/ui/pages/server_details/time_zone/time_zone.dart b/lib/ui/pages/server_details/time_zone/time_zone.dart index a93b8f23..6863bfe8 100644 --- a/lib/ui/pages/server_details/time_zone/time_zone.dart +++ b/lib/ui/pages/server_details/time_zone/time_zone.dart @@ -57,66 +57,72 @@ class _SelectTimezoneState extends State { } @override - Widget build(final BuildContext context) => Scaffold( - appBar: AppBar( - title: isSearching - ? TextField( - readOnly: false, - textAlign: TextAlign.start, - textInputAction: TextInputAction.next, - enabled: true, - controller: searchController, - decoration: InputDecoration( - errorText: null, - hintText: 'server.timezone_search_bar'.tr(), - ), - ) - : Padding( - padding: const EdgeInsets.only(top: 4.0), - child: Text('server.select_timezone'.tr()), + Widget build(final BuildContext context) { + final isDesktop = Breakpoints.mediumAndUp.isActive(context); + return Scaffold( + appBar: AppBar( + automaticallyImplyLeading: false, + title: (isDesktop || isSearching) + ? TextField( + readOnly: false, + textAlign: TextAlign.start, + textInputAction: TextInputAction.next, + enabled: true, + controller: searchController, + decoration: InputDecoration( + errorText: null, + hintText: 'server.timezone_search_bar'.tr(), ), - leading: IconButton( - icon: const Icon(Icons.arrow_back), - onPressed: isSearching - ? () => setState(() => isSearching = false) - : () => Navigator.of(context).pop(), - ), - actions: [ - if (!isSearching) - IconButton( - icon: const Icon(Icons.search), - onPressed: () => setState(() => isSearching = true), + ) + : Padding( + padding: const EdgeInsets.only(top: 4.0), + child: Text('server.select_timezone'.tr()), ), - ], + leading: !isDesktop + ? IconButton( + icon: const Icon(Icons.arrow_back), + onPressed: isSearching + ? () => setState(() => isSearching = false) + : () => Navigator.of(context).pop(), + ) + : null, + actions: [ + if (!isSearching && !isDesktop) + IconButton( + icon: const Icon(Icons.search), + onPressed: () => setState(() => isSearching = true), + ), + ], + ), + body: SafeArea( + child: ListView( + controller: scrollController, + children: locations + .where( + (final Location location) => timezoneFilterValue == null + ? true + : location.name + .toLowerCase() + .contains(timezoneFilterValue!) || + Duration( + milliseconds: location.currentTimeZone.offset, + ) + .toDayHourMinuteFormat() + .contains(timezoneFilterValue!), + ) + .toList() + .asMap() + .map( + (final key, final value) => locationToListTile(key, value), + ) + .values + .toList(), ), - body: SafeArea( - child: ListView( - controller: scrollController, - children: locations - .where( - (final Location location) => timezoneFilterValue == null - ? true - : location.name - .toLowerCase() - .contains(timezoneFilterValue!) || - Duration( - milliseconds: location.currentTimeZone.offset, - ) - .toDayHourMinuteFormat() - .contains(timezoneFilterValue!), - ) - .toList() - .asMap() - .map( - (final key, final value) => locationToListTile(key, value), - ) - .values - .toList(), - ), - ), - ); + ), + ); + } - MapEntry locationToListTile( + MapEntry locationToListTile( final int key, final Location location, ) { @@ -126,46 +132,19 @@ class _SelectTimezoneState extends State { return MapEntry( key, - Container( - height: 75, - padding: const EdgeInsets.symmetric(horizontal: 20), - decoration: const BoxDecoration( - border: Border( - bottom: BorderSide( - color: BrandColors.dividerColor, - ), - ), + ListTile( + title: Text( + location.name, ), - child: InkWell( - onTap: () { - context.read().repository.setTimezone( - location.name, - ); - Navigator.of(context).pop(); - }, - child: Container( - padding: const EdgeInsets.symmetric(vertical: 16), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisAlignment: MainAxisAlignment.center, - children: [ - BrandText.body1( - location.name, - style: const TextStyle( - fontSize: 16, - fontWeight: FontWeight.bold, - ), - ), - BrandText.small( - 'GMT ${duration.toDayHourMinuteFormat()} ${area.isNotEmpty ? '($area)' : ''}', - style: const TextStyle( - fontSize: 13, - ), - ), - ], - ), - ), + subtitle: Text( + 'GMT ${duration.toDayHourMinuteFormat()} ${area.isNotEmpty ? '($area)' : ''}', ), + onTap: () { + context.read().repository.setTimezone( + location.name, + ); + Navigator.of(context).pop(); + }, ), ); } diff --git a/lib/ui/pages/server_storage/binds_migration/migration_process_page.dart b/lib/ui/pages/server_storage/binds_migration/migration_process_page.dart index 2f896673..8d42cb6f 100644 --- a/lib/ui/pages/server_storage/binds_migration/migration_process_page.dart +++ b/lib/ui/pages/server_storage/binds_migration/migration_process_page.dart @@ -2,8 +2,8 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/server_jobs/server_jobs_cubit.dart'; import 'package:selfprivacy/logic/models/json/server_job.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/components/brand_linear_indicator/brand_linear_indicator.dart'; import 'package:selfprivacy/ui/pages/root_route.dart'; import 'package:selfprivacy/utils/route_transitions/basic.dart'; diff --git a/lib/ui/pages/server_storage/binds_migration/services_migration.dart b/lib/ui/pages/server_storage/binds_migration/services_migration.dart index bb95ae94..cdb3339b 100644 --- a/lib/ui/pages/server_storage/binds_migration/services_migration.dart +++ b/lib/ui/pages/server_storage/binds_migration/services_migration.dart @@ -1,21 +1,19 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/server_jobs/server_jobs_cubit.dart'; import 'package:selfprivacy/logic/cubit/services/services_cubit.dart'; import 'package:selfprivacy/logic/models/disk_size.dart'; import 'package:selfprivacy/logic/models/service.dart'; -import 'package:selfprivacy/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; import 'package:selfprivacy/ui/components/brand_header/brand_header.dart'; import 'package:selfprivacy/ui/components/info_box/info_box.dart'; import 'package:selfprivacy/logic/models/disk_status.dart'; import 'package:selfprivacy/ui/components/jobs_content/jobs_content.dart'; import 'package:selfprivacy/ui/components/storage_list_items/server_storage_list_item.dart'; import 'package:selfprivacy/ui/components/storage_list_items/service_migration_list_item.dart'; -import 'package:selfprivacy/ui/helpers/modals.dart'; -import 'package:selfprivacy/ui/pages/root_route.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +@RoutePage() class ServicesMigrationPage extends StatefulWidget { const ServicesMigrationPage({ required this.services, @@ -110,22 +108,20 @@ class _ServicesMigrationPageState extends State { ), child: Column( children: [ - ...widget.diskStatus.diskVolumes - .map( - (final volume) => Column( - children: [ - ServerStorageListItem( - volume: recalculatedDiskUsages( - volume, - widget.services, - ), - dense: true, - ), - const SizedBox(height: headerVerticalPadding), - ], + ...widget.diskStatus.diskVolumes.map( + (final volume) => Column( + children: [ + ServerStorageListItem( + volume: recalculatedDiskUsages( + volume, + widget.services, + ), + dense: true, ), - ) - .toList(), + const SizedBox(height: headerVerticalPadding), + ], + ), + ), ], ), ), @@ -138,23 +134,21 @@ class _ServicesMigrationPageState extends State { children: [ if (widget.services.isEmpty) const Center(child: CircularProgressIndicator()), - ...widget.services - .map( - (final service) => Column( - children: [ - const SizedBox(height: 8), - ServiceMigrationListItem( - service: service, - diskStatus: widget.diskStatus, - selectedVolume: serviceToDisk[service.id]!, - onChange: onChange, - ), - const SizedBox(height: 4), - const Divider(), - ], + ...widget.services.map( + (final service) => Column( + children: [ + const SizedBox(height: 8), + ServiceMigrationListItem( + service: service, + diskStatus: widget.diskStatus, + selectedVolume: serviceToDisk[service.id]!, + onChange: onChange, ), - ) - .toList(), + const SizedBox(height: 4), + const Divider(), + ], + ), + ), Padding( padding: const EdgeInsets.all(8.0), child: InfoBox( @@ -180,17 +174,10 @@ class _ServicesMigrationPageState extends State { } } } - Navigator.of(context).pushAndRemoveUntil( - materialRoute(const RootPage()), - (final predicate) => false, - ); - showBrandBottomSheet( + context.router.popUntilRoot(); + showModalBottomSheet( context: context, - builder: (final BuildContext context) => - const BrandBottomSheet( - isExpended: true, - child: JobsContent(), - ), + builder: (final BuildContext context) => const JobsContent(), ); }, ), diff --git a/lib/ui/pages/server_storage/extending_volume.dart b/lib/ui/pages/server_storage/extending_volume.dart index d40c628c..41c81140 100644 --- a/lib/ui/pages/server_storage/extending_volume.dart +++ b/lib/ui/pages/server_storage/extending_volume.dart @@ -1,3 +1,4 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/app_config_dependent/authentication_dependend_cubit.dart'; @@ -5,12 +6,11 @@ import 'package:selfprivacy/logic/cubit/provider_volumes/provider_volume_cubit.d import 'package:selfprivacy/logic/cubit/server_volumes/server_volume_cubit.dart'; import 'package:selfprivacy/logic/models/disk_size.dart'; import 'package:selfprivacy/logic/models/price.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/logic/models/disk_status.dart'; -import 'package:selfprivacy/ui/pages/root_route.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +@RoutePage() class ExtendingVolumePage extends StatefulWidget { const ExtendingVolumePage({ required this.diskVolumeToResize, @@ -155,10 +155,7 @@ class _ExtendingVolumePageState extends State { DiskSize.fromGibibyte(_currentSliderGbValue), context.read().reload, ); - Navigator.of(context).pushAndRemoveUntil( - materialRoute(const RootPage()), - (final predicate) => false, - ); + context.router.popUntilRoot(); }, child: Text('storage.extend_volume_button.title'.tr()), ), diff --git a/lib/ui/pages/server_storage/server_storage.dart b/lib/ui/pages/server_storage/server_storage.dart index 2a5206e2..e3391070 100644 --- a/lib/ui/pages/server_storage/server_storage.dart +++ b/lib/ui/pages/server_storage/server_storage.dart @@ -1,16 +1,17 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:flutter_svg/svg.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; import 'package:selfprivacy/logic/cubit/services/services_cubit.dart'; import 'package:selfprivacy/logic/models/service.dart'; -import 'package:selfprivacy/ui/components/brand_button/outlined_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/outlined_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/logic/models/disk_status.dart'; -import 'package:selfprivacy/ui/pages/server_storage/extending_volume.dart'; import 'package:selfprivacy/ui/components/storage_list_items/server_storage_list_item.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +import 'package:selfprivacy/ui/router/router.dart'; +@RoutePage() class ServerStoragePage extends StatefulWidget { const ServerStoragePage({ required this.diskStatus, @@ -45,28 +46,26 @@ class _ServerStoragePageState extends State { heroTitle: 'storage.card_title'.tr(), children: [ // ...sections, - ...widget.diskStatus.diskVolumes - .map( - (final volume) => Column( - mainAxisSize: MainAxisSize.min, - children: [ - ServerStorageSection( - volume: volume, - diskStatus: widget.diskStatus, - services: services - .where( - (final service) => - service.storageUsage.volume == volume.name, - ) - .toList(), - ), - const SizedBox(height: 16), - const Divider(), - const SizedBox(height: 16), - ], + ...widget.diskStatus.diskVolumes.map( + (final volume) => Column( + mainAxisSize: MainAxisSize.min, + children: [ + ServerStorageSection( + volume: volume, + diskStatus: widget.diskStatus, + services: services + .where( + (final service) => + service.storageUsage.volume == volume.name, + ) + .toList(), ), - ) - .toList(), + const SizedBox(height: 16), + const Divider(), + const SizedBox(height: 16), + ], + ), + ), const SizedBox(height: 8), ], ); @@ -93,24 +92,20 @@ class ServerStorageSection extends StatelessWidget { volume: volume, ), const SizedBox(height: 16), - ...services - .map( - (final service) => ServerConsumptionListTile( - service: service, - volume: volume, - ), - ) - .toList(), + ...services.map( + (final service) => ServerConsumptionListTile( + service: service, + volume: volume, + ), + ), if (volume.isResizable) ...[ const SizedBox(height: 16), BrandOutlinedButton( title: 'storage.extend_volume_button.title'.tr(), - onPressed: () => Navigator.of(context).push( - materialRoute( - ExtendingVolumePage( - diskVolumeToResize: volume, - diskStatus: diskStatus, - ), + onPressed: () => context.pushRoute( + ExtendingVolumeRoute( + diskVolumeToResize: volume, + diskStatus: diskStatus, ), ), ), diff --git a/lib/ui/pages/server_storage/storage_card.dart b/lib/ui/pages/server_storage/storage_card.dart index ae0c2369..ac633463 100644 --- a/lib/ui/pages/server_storage/storage_card.dart +++ b/lib/ui/pages/server_storage/storage_card.dart @@ -1,12 +1,12 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/app_config_dependent/authentication_dependend_cubit.dart'; import 'package:selfprivacy/logic/cubit/providers/providers_cubit.dart'; import 'package:selfprivacy/ui/components/icon_status_mask/icon_status_mask.dart'; import 'package:selfprivacy/logic/models/disk_status.dart'; -import 'package:selfprivacy/ui/pages/server_storage/server_storage.dart'; import 'package:selfprivacy/ui/components/storage_list_items/server_storage_list_item.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +import 'package:selfprivacy/ui/router/router.dart'; class StorageCard extends StatelessWidget { const StorageCard({ @@ -45,13 +45,8 @@ class StorageCard extends StatelessWidget { clipBehavior: Clip.antiAlias, child: InkResponse( highlightShape: BoxShape.rectangle, - onTap: () => Navigator.of(context).push( - materialRoute( - ServerStoragePage( - diskStatus: diskStatus, - ), - ), - ), + onTap: () => + context.pushRoute(ServerStorageRoute(diskStatus: diskStatus)), child: Padding( padding: const EdgeInsets.all(16.0), child: Column( diff --git a/lib/ui/pages/services/service_page.dart b/lib/ui/pages/services/service_page.dart index 22db2bf6..0c7beafb 100644 --- a/lib/ui/pages/services/service_page.dart +++ b/lib/ui/pages/services/service_page.dart @@ -1,3 +1,4 @@ +import 'package:auto_route/auto_route.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:flutter_svg/svg.dart'; @@ -6,12 +7,12 @@ import 'package:selfprivacy/logic/cubit/server_volumes/server_volume_cubit.dart' import 'package:selfprivacy/logic/cubit/services/services_cubit.dart'; import 'package:selfprivacy/logic/models/job.dart'; import 'package:selfprivacy/logic/models/service.dart'; -import 'package:selfprivacy/ui/components/brand_cards/filled_card.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; -import 'package:selfprivacy/ui/pages/server_storage/binds_migration/services_migration.dart'; +import 'package:selfprivacy/ui/components/cards/filled_card.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/router/router.dart'; import 'package:selfprivacy/utils/launch_url.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +@RoutePage() class ServicePage extends StatefulWidget { const ServicePage({required this.serviceId, super.key}); @@ -46,11 +47,15 @@ class _ServicePageState extends State { return BrandHeroScreen( hasBackButton: true, + hasFlashButton: true, heroIconWidget: SvgPicture.string( service.svgIcon, width: 48.0, height: 48.0, - color: Theme.of(context).colorScheme.onBackground, + colorFilter: ColorFilter.mode( + Theme.of(context).colorScheme.onBackground, + BlendMode.srcIn, + ), ), heroTitle: service.displayName, children: [ @@ -108,14 +113,12 @@ class _ServicePageState extends State { ListTile( iconColor: Theme.of(context).colorScheme.onBackground, // Open page ServicesMigrationPage - onTap: () => Navigator.of(context).push( - materialRoute( - ServicesMigrationPage( - services: [service], - diskStatus: - context.read().state.diskStatus, - isMigration: false, - ), + onTap: () => context.pushRoute( + ServicesMigrationRoute( + services: [service], + diskStatus: + context.read().state.diskStatus, + isMigration: false, ), ), leading: const Icon(Icons.drive_file_move_outlined), diff --git a/lib/ui/pages/services/services.dart b/lib/ui/pages/services/services.dart index 54192367..99bb848e 100644 --- a/lib/ui/pages/services/services.dart +++ b/lib/ui/pages/services/services.dart @@ -1,3 +1,4 @@ +import 'package:auto_route/auto_route.dart'; import 'package:flutter/material.dart'; import 'package:flutter_svg/flutter_svg.dart'; import 'package:selfprivacy/config/brand_theme.dart'; @@ -5,17 +6,16 @@ import 'package:selfprivacy/logic/cubit/server_installation/server_installation_ import 'package:selfprivacy/logic/cubit/services/services_cubit.dart'; import 'package:selfprivacy/logic/models/service.dart'; import 'package:selfprivacy/logic/models/state_types.dart'; -import 'package:selfprivacy/ui/components/brand_cards/brand_cards.dart'; import 'package:selfprivacy/ui/components/brand_header/brand_header.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; import 'package:selfprivacy/ui/components/icon_status_mask/icon_status_mask.dart'; import 'package:selfprivacy/ui/components/not_ready_card/not_ready_card.dart'; import 'package:easy_localization/easy_localization.dart'; -import 'package:selfprivacy/ui/pages/services/service_page.dart'; +import 'package:selfprivacy/ui/router/router.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; import 'package:selfprivacy/utils/launch_url.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; import 'package:selfprivacy/utils/ui_helpers.dart'; +@RoutePage() class ServicesPage extends StatefulWidget { const ServicesPage({super.key}); @@ -34,32 +34,35 @@ class _ServicesPageState extends State { .sort((final a, final b) => a.status.index.compareTo(b.status.index)); return Scaffold( - appBar: PreferredSize( - preferredSize: const Size.fromHeight(52), - child: BrandHeader( - title: 'basis.services'.tr(), - ), - ), + appBar: Breakpoints.small.isActive(context) + ? PreferredSize( + preferredSize: const Size.fromHeight(52), + child: BrandHeader( + title: 'basis.services'.tr(), + ), + ) + : null, body: RefreshIndicator( onRefresh: () async { - context.read().reload(); + await context.read().reload(); }, child: ListView( padding: paddingH15V0, children: [ - BrandText.body1('basis.services_title'.tr()), + Text( + 'basis.services_title'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), const SizedBox(height: 24), if (!isReady) ...[const NotReadyCard(), const SizedBox(height: 24)], - ...services - .map( - (final service) => Padding( - padding: const EdgeInsets.only( - bottom: 30, - ), - child: _Card(service: service), - ), - ) - .toList() + ...services.map( + (final service) => Padding( + padding: const EdgeInsets.only( + bottom: 30, + ), + child: _Card(service: service), + ), + ) ], ), ), @@ -98,81 +101,106 @@ class _Card extends StatelessWidget { } } - return GestureDetector( - onTap: isReady - ? () => Navigator.of(context) - .push(materialRoute(ServicePage(serviceId: service.id))) - : null, - child: BrandCards.big( - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Row( - children: [ - IconStatusMask( - status: getStatus(service.status), - icon: SvgPicture.string( - service.svgIcon, - width: 30.0, - height: 30.0, - color: Theme.of(context).colorScheme.onBackground, - ), - ), - ], - ), - ClipRect( - child: Stack( + return Card( + clipBehavior: Clip.antiAlias, + child: InkResponse( + highlightShape: BoxShape.rectangle, + onTap: isReady + ? () => context.pushRoute( + ServiceRoute(serviceId: service.id), + ) + : null, + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Row( children: [ - Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - const SizedBox(height: 10), - BrandText.h2(service.displayName), - const SizedBox(height: 10), - if (service.url != '' && service.url != null) - Column( - children: [ - GestureDetector( - onTap: () => launchURL( - service.url, - ), - child: Text( - '${service.url}', - style: TextStyle( - color: - Theme.of(context).colorScheme.secondary, - decoration: TextDecoration.underline, - ), - ), - ), - const SizedBox(height: 10), - ], - ), - if (service.id == 'mailserver') - Column( - children: [ - Text( - domainName, - style: TextStyle( - color: Theme.of(context).colorScheme.primary, - decoration: TextDecoration.underline, - ), - ), - const SizedBox(height: 10), - ], - ), - BrandText.body2(service.loginInfo), - const SizedBox(height: 10), - BrandText.body2(service.description), - const SizedBox(height: 10), - ], + IconStatusMask( + status: getStatus(service.status), + icon: SvgPicture.string( + service.svgIcon, + width: 30.0, + height: 30.0, + colorFilter: const ColorFilter.mode( + Colors.white, + BlendMode.srcIn, + ), + ), ), ], ), - ) - ], + Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + const SizedBox(height: 12), + Text( + service.displayName, + style: Theme.of(context).textTheme.headlineMedium, + ), + const SizedBox(height: 8), + if (service.url != '' && service.url != null) + Column( + children: [ + _ServiceLink( + url: service.url ?? '', + ), + const SizedBox(height: 10), + ], + ), + if (service.id == 'mailserver') + Column( + children: [ + _ServiceLink( + url: domainName, + isActive: false, + ), + const SizedBox(height: 10), + ], + ), + Text( + service.loginInfo, + style: Theme.of(context).textTheme.bodyMedium, + ), + const SizedBox(height: 10), + Text( + service.description, + style: Theme.of(context).textTheme.bodyMedium, + ), + const SizedBox(height: 10), + ], + ) + ], + ), ), ), ); } } + +class _ServiceLink extends StatelessWidget { + const _ServiceLink({ + required this.url, + this.isActive = true, + }); + + final String url; + final bool isActive; + + @override + Widget build(final BuildContext context) => GestureDetector( + onTap: isActive + ? () => launchURL( + url, + ) + : null, + child: Text( + url, + style: Theme.of(context).textTheme.bodyMedium?.copyWith( + color: Theme.of(context).colorScheme.primary, + decoration: TextDecoration.underline, + ), + ), + ); +} diff --git a/lib/ui/pages/setup/initializing/initializing.dart b/lib/ui/pages/setup/initializing/initializing.dart index ca502b65..199203c3 100644 --- a/lib/ui/pages/setup/initializing/initializing.dart +++ b/lib/ui/pages/setup/initializing/initializing.dart @@ -1,7 +1,7 @@ +import 'package:auto_route/auto_route.dart'; import 'package:cubit_form/cubit_form.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_theme.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/initializing/provider_form_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; import 'package:selfprivacy/logic/cubit/forms/factories/field_cubit_factory.dart'; @@ -9,18 +9,21 @@ import 'package:selfprivacy/logic/cubit/forms/setup/initializing/backblaze_form_ import 'package:selfprivacy/logic/cubit/forms/setup/initializing/dns_provider_form_cubit.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/initializing/domain_setup_cubit.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/initializing/root_user_form_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_md/brand_md.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; +import 'package:selfprivacy/logic/cubit/support_system/support_system_cubit.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/components/buttons/outlined_button.dart'; import 'package:selfprivacy/ui/components/brand_timer/brand_timer.dart'; +import 'package:selfprivacy/ui/components/drawers/progress_drawer.dart'; import 'package:selfprivacy/ui/components/progress_bar/progress_bar.dart'; -import 'package:selfprivacy/ui/pages/root_route.dart'; +import 'package:selfprivacy/ui/components/drawers/support_drawer.dart'; +import 'package:selfprivacy/ui/layouts/responsive_layout_with_infobox.dart'; import 'package:selfprivacy/ui/pages/setup/initializing/server_provider_picker.dart'; import 'package:selfprivacy/ui/pages/setup/initializing/server_type_picker.dart'; import 'package:selfprivacy/ui/pages/setup/recovering/recovery_routing.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; +import 'package:selfprivacy/ui/router/router.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; +@RoutePage() class InitializingPage extends StatelessWidget { const InitializingPage({super.key}); @@ -48,99 +51,155 @@ class InitializingPage extends StatelessWidget { ][cubit.state.progress.index](); } + const steps = [ + 'initializing.steps.hosting', + 'initializing.steps.server_type', + 'initializing.steps.dns_provider', + 'initializing.steps.backups_provider', + 'initializing.steps.domain', + 'initializing.steps.master_account', + 'initializing.steps.server', + 'initializing.steps.dns_setup', + 'initializing.steps.nixos_installation', + 'initializing.steps.server_reboot', + 'initializing.steps.final_checks', + ]; + return BlocListener( listener: (final context, final state) { if (cubit.state is ServerInstallationFinished) { - Navigator.of(context) - .pushReplacement(materialRoute(const RootPage())); + context.router.popUntilRoot(); } }, child: Scaffold( - appBar: AppBar( - actions: [ - if (cubit.state is ServerInstallationFinished) - IconButton( - icon: const Icon(Icons.check), - onPressed: () { - Navigator.of(context) - .pushReplacement(materialRoute(const RootPage())); - }, - ) - ], - title: Text( - 'more_page.configuration_wizard'.tr(), - ), - bottom: PreferredSize( - preferredSize: const Size.fromHeight(28), - child: Padding( - padding: const EdgeInsets.fromLTRB(16, 0, 16, 16), - child: ProgressBar( - steps: const [ - 'Hosting', - 'Server Type', - 'CloudFlare', - 'Backblaze', - 'Domain', - 'User', - 'Server', - 'Installation', - ], - activeIndex: cubit.state.porgressBar, - ), - ), - ), - ), - body: SingleChildScrollView( - child: Column( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Padding( - padding: const EdgeInsets.fromLTRB(16.0, 0, 16.0, 0.0), - child: AnimatedSwitcher( - duration: const Duration(milliseconds: 300), - child: actualInitializingPage, - ), - ), - ConstrainedBox( - constraints: BoxConstraints( - minHeight: MediaQuery.of(context).size.height - - MediaQuery.of(context).padding.top - - MediaQuery.of(context).padding.bottom - - 566, - ), - child: Column( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Container( - alignment: Alignment.center, - child: BrandButton.text( - title: cubit.state is ServerInstallationFinished - ? 'basis.close'.tr() - : 'basis.later'.tr(), - onPressed: () { - Navigator.of(context).pushAndRemoveUntil( - materialRoute(const RootPage()), - (final predicate) => false, - ); - }, - ), + endDrawer: const SupportDrawer(), + endDrawerEnableOpenDragGesture: false, + appBar: Breakpoints.large.isActive(context) + ? null + : AppBar( + actions: [ + if (cubit.state is ServerInstallationFinished) + IconButton( + icon: const Icon(Icons.check), + onPressed: () { + context.router.popUntilRoot(); + }, ), - if (cubit.state is ServerInstallationEmpty || - cubit.state is ServerInstallationNotFinished) - Container( - alignment: Alignment.center, - child: BrandButton.text( - title: 'basis.connect_to_existing'.tr(), + const SizedBox.shrink(), + ], + title: Text( + 'more_page.configuration_wizard'.tr(), + ), + bottom: PreferredSize( + preferredSize: const Size.fromHeight(28), + child: Padding( + padding: const EdgeInsets.fromLTRB(16, 0, 16, 16), + child: ProgressBar( + steps: const [ + 'Hosting', + 'Server Type', + 'CloudFlare', + 'Backblaze', + 'Domain', + 'User', + 'Server', + 'Installation', + ], + activeIndex: cubit.state.porgressBar, + ), + ), + ), + ), + body: LayoutBuilder( + builder: (final context, final constraints) => Row( + children: [ + if (Breakpoints.large.isActive(context)) + ProgressDrawer( + steps: steps, + currentStep: cubit.state.progress.index, + title: 'more_page.configuration_wizard'.tr(), + constraints: constraints, + trailing: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + if (cubit.state is ServerInstallationEmpty || + cubit.state is ServerInstallationNotFinished) + Container( + alignment: Alignment.center, + child: BrandButton.filled( + text: 'basis.connect_to_existing'.tr(), + onPressed: () { + context.router.replace(const RecoveryRoute()); + }, + ), + ), + ConstrainedBox( + constraints: const BoxConstraints( + minWidth: double.infinity, + ), + child: OutlinedButton( + child: Text( + cubit.state is ServerInstallationFinished + ? 'basis.close'.tr() + : 'basis.later'.tr(), + ), onPressed: () { - Navigator.of(context).push( - materialRoute( - const RecoveryRouting(), - ), - ); + context.router.popUntilRoot(); }, ), - ) - ], + ), + ], + ), + ), + SizedBox( + width: constraints.maxWidth - + (Breakpoints.large.isActive(context) ? 300 : 0), + height: constraints.maxHeight, + child: SingleChildScrollView( + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Padding( + padding: Breakpoints.large.isActive(context) + ? const EdgeInsets.all(16.0) + : const EdgeInsets.fromLTRB(16.0, 0, 16.0, 0.0), + child: AnimatedSwitcher( + duration: const Duration(milliseconds: 300), + child: actualInitializingPage, + ), + ), + if (!Breakpoints.large.isActive(context)) + Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Container( + alignment: Alignment.center, + child: BrandButton.text( + title: + cubit.state is ServerInstallationFinished + ? 'basis.close'.tr() + : 'basis.later'.tr(), + onPressed: () { + context.router.popUntilRoot(); + }, + ), + ), + if (cubit.state is ServerInstallationEmpty || + cubit.state is ServerInstallationNotFinished) + Container( + alignment: Alignment.center, + child: BrandButton.text( + title: 'basis.connect_to_existing'.tr(), + onPressed: () { + context.router + .replace(const RecoveryRoute()); + }, + ), + ) + ], + ), + ], + ), ), ), ], @@ -179,57 +238,55 @@ class InitializingPage extends StatelessWidget { ), ); - void _showModal(final BuildContext context, final Widget widget) { - showModalBottomSheet( - context: context, - isScrollControlled: true, - backgroundColor: Colors.transparent, - builder: (final BuildContext context) => widget, - ); - } - Widget _stepCloudflare(final ServerInstallationCubit initializingCubit) => BlocProvider( create: (final context) => DnsProviderFormCubit(initializingCubit), child: Builder( - builder: (final context) => Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - '${'initializing.connect_to_server_provider'.tr()}Cloudflare', - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.manage_domain_dns'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - const SizedBox(height: 32), - CubitFormTextField( - formFieldCubit: context.read().apiKey, - textAlign: TextAlign.center, - scrollPadding: const EdgeInsets.only(bottom: 70), - decoration: InputDecoration( - hintText: 'initializing.cloudflare_api_token'.tr(), + builder: (final context) => ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + '${'initializing.connect_to_server_provider'.tr()}Cloudflare', + style: Theme.of(context).textTheme.headlineSmall, ), - ), - const SizedBox(height: 32), - BrandButton.rised( - onPressed: () => - context.read().trySubmit(), - text: 'basis.connect'.tr(), - ), - const SizedBox(height: 10), - BrandButton.text( - onPressed: () => _showModal( - context, - const _HowTo( - fileName: 'how_cloudflare', + const SizedBox(height: 16), + Text( + 'initializing.manage_domain_dns'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), + primaryColumn: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + CubitFormTextField( + formFieldCubit: context.read().apiKey, + textAlign: TextAlign.center, + scrollPadding: const EdgeInsets.only(bottom: 70), + decoration: InputDecoration( + hintText: 'initializing.cloudflare_api_token'.tr(), ), ), - title: 'initializing.how'.tr(), - ), - ], + const SizedBox(height: 32), + BrandButton.filled( + onPressed: () => + context.read().trySubmit(), + text: 'basis.connect'.tr(), + ), + const SizedBox(height: 10), + BrandOutlinedButton( + onPressed: () { + context.read().showArticle( + article: 'how_cloudflare', + context: context, + ); + Scaffold.of(context).openEndDrawer(); + }, + title: 'initializing.how'.tr(), + ), + ], + ), ), ), ); @@ -240,50 +297,57 @@ class InitializingPage extends StatelessWidget { child: Builder( builder: (final context) { final formCubitState = context.watch().state; - return Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - '${'initializing.connect_to_server_provider'.tr()}Backblaze', - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 32), - CubitFormTextField( - formFieldCubit: context.read().keyId, - textAlign: TextAlign.center, - scrollPadding: const EdgeInsets.only(bottom: 70), - decoration: const InputDecoration( - hintText: 'KeyID', + return ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + '${'initializing.connect_to_server_provider'.tr()}Backblaze', + style: Theme.of(context).textTheme.headlineSmall, ), - ), - const SizedBox(height: 16), - CubitFormTextField( - formFieldCubit: - context.read().applicationKey, - textAlign: TextAlign.center, - scrollPadding: const EdgeInsets.only(bottom: 70), - decoration: const InputDecoration( - hintText: 'Master Application Key', - ), - ), - const SizedBox(height: 32), - BrandButton.rised( - onPressed: formCubitState.isSubmitting - ? null - : () => context.read().trySubmit(), - text: 'basis.connect'.tr(), - ), - const SizedBox(height: 10), - BrandButton.text( - onPressed: () => _showModal( - context, - const _HowTo( - fileName: 'how_backblaze', + ], + ), + primaryColumn: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + CubitFormTextField( + formFieldCubit: context.read().keyId, + textAlign: TextAlign.center, + scrollPadding: const EdgeInsets.only(bottom: 70), + decoration: const InputDecoration( + hintText: 'KeyID', ), ), - title: 'initializing.how'.tr(), - ), - ], + const SizedBox(height: 16), + CubitFormTextField( + formFieldCubit: + context.read().applicationKey, + textAlign: TextAlign.center, + scrollPadding: const EdgeInsets.only(bottom: 70), + decoration: const InputDecoration( + hintText: 'Master Application Key', + ), + ), + const SizedBox(height: 32), + BrandButton.rised( + onPressed: formCubitState.isSubmitting + ? null + : () => context.read().trySubmit(), + text: 'basis.connect'.tr(), + ), + const SizedBox(height: 10), + BrandButton.text( + onPressed: () { + context.read().showArticle( + article: 'how_backblaze', + context: context, + ); + Scaffold.of(context).openEndDrawer(); + }, + title: 'initializing.how'.tr(), + ), + ], + ), ); }, ), @@ -296,9 +360,8 @@ class InitializingPage extends StatelessWidget { builder: (final context) { final DomainSetupState state = context.watch().state; - return SizedBox( - width: double.infinity, - child: Column( + return ResponsiveLayoutWithInfobox( + topChild: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Text( @@ -310,7 +373,11 @@ class InitializingPage extends StatelessWidget { 'initializing.use_this_domain_text'.tr(), style: Theme.of(context).textTheme.bodyMedium, ), - const SizedBox(height: 32), + ], + ), + primaryColumn: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ if (state is Empty) Text( 'initializing.no_connected_domains'.tr(), @@ -350,7 +417,7 @@ class InitializingPage extends StatelessWidget { ], if (state is Empty) ...[ const SizedBox(height: 30), - BrandButton.rised( + BrandButton.filled( onPressed: () => context.read().load(), child: Row( mainAxisAlignment: MainAxisAlignment.center, @@ -360,14 +427,17 @@ class InitializingPage extends StatelessWidget { color: Colors.white, ), const SizedBox(width: 10), - BrandText.buttonTitleText('domain.update_list'.tr()), + Text( + 'domain.update_list'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), ], ), ), ], if (state is Loaded) ...[ const SizedBox(height: 32), - BrandButton.rised( + BrandButton.filled( onPressed: () => context.read().saveDomain(), text: 'initializing.save_domain'.tr(), @@ -388,74 +458,83 @@ class InitializingPage extends StatelessWidget { builder: (final context) { final formCubitState = context.watch().state; - return Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - 'initializing.create_master_account'.tr(), - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.enter_username_and_password'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - if (formCubitState.isErrorShown) const SizedBox(height: 16), - if (formCubitState.isErrorShown) + return ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ Text( - 'users.username_rule'.tr(), - style: TextStyle( - color: Theme.of(context).colorScheme.error, + 'initializing.create_master_account'.tr(), + style: Theme.of(context).textTheme.headlineSmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.enter_username_and_password'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), + primaryColumn: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + if (formCubitState.isErrorShown) const SizedBox(height: 16), + if (formCubitState.isErrorShown) + Text( + 'users.username_rule'.tr(), + style: TextStyle( + color: Theme.of(context).colorScheme.error, + ), + ), + const SizedBox(height: 32), + CubitFormTextField( + formFieldCubit: context.read().userName, + textAlign: TextAlign.center, + scrollPadding: const EdgeInsets.only(bottom: 70), + decoration: InputDecoration( + hintText: 'basis.username'.tr(), ), ), - const SizedBox(height: 32), - CubitFormTextField( - formFieldCubit: context.read().userName, - textAlign: TextAlign.center, - scrollPadding: const EdgeInsets.only(bottom: 70), - decoration: InputDecoration( - hintText: 'basis.username'.tr(), - ), - ), - const SizedBox(height: 16), - BlocBuilder, FieldCubitState>( - bloc: context.read().isVisible, - builder: (final context, final state) { - final bool isVisible = state.value; - return CubitFormTextField( - obscureText: !isVisible, - formFieldCubit: - context.read().password, - textAlign: TextAlign.center, - scrollPadding: const EdgeInsets.only(bottom: 70), - decoration: InputDecoration( - hintText: 'basis.password'.tr(), - suffixIcon: IconButton( - icon: Icon( - isVisible ? Icons.visibility : Icons.visibility_off, + const SizedBox(height: 16), + BlocBuilder, FieldCubitState>( + bloc: context.read().isVisible, + builder: (final context, final state) { + final bool isVisible = state.value; + return CubitFormTextField( + obscureText: !isVisible, + formFieldCubit: + context.read().password, + textAlign: TextAlign.center, + scrollPadding: const EdgeInsets.only(bottom: 70), + decoration: InputDecoration( + hintText: 'basis.password'.tr(), + suffixIcon: IconButton( + icon: Icon( + isVisible + ? Icons.visibility + : Icons.visibility_off, + ), + onPressed: () => context + .read() + .isVisible + .setValue(!isVisible), ), - onPressed: () => context - .read() - .isVisible - .setValue(!isVisible), + suffixIconConstraints: + const BoxConstraints(minWidth: 60), + prefixIconConstraints: + const BoxConstraints(maxWidth: 60), + prefixIcon: Container(), ), - suffixIconConstraints: - const BoxConstraints(minWidth: 60), - prefixIconConstraints: - const BoxConstraints(maxWidth: 60), - prefixIcon: Container(), - ), - ); - }, - ), - const SizedBox(height: 32), - BrandButton.rised( - onPressed: formCubitState.isSubmitting - ? null - : () => context.read().trySubmit(), - text: 'basis.connect'.tr(), - ), - ], + ); + }, + ), + const SizedBox(height: 32), + BrandButton.filled( + onPressed: formCubitState.isSubmitting + ? null + : () => context.read().trySubmit(), + text: 'basis.connect'.tr(), + ), + ], + ), ); }, ), @@ -465,27 +544,28 @@ class InitializingPage extends StatelessWidget { final bool isLoading = (appConfigCubit.state as ServerInstallationNotFinished).isLoading; return Builder( - builder: (final context) => Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - 'initializing.final'.tr(), - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.create_server'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - const SizedBox(height: 128), - BrandButton.rised( - onPressed: - isLoading ? null : appConfigCubit.createServerAndSetDnsRecords, - text: isLoading - ? 'basis.loading'.tr() - : 'initializing.create_server'.tr(), - ), - ], + builder: (final context) => ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + 'initializing.final'.tr(), + style: Theme.of(context).textTheme.headlineSmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.create_server'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), + primaryColumn: BrandButton.filled( + onPressed: + isLoading ? null : appConfigCubit.createServerAndSetDnsRecords, + text: isLoading + ? 'basis.loading'.tr() + : 'initializing.create_server'.tr(), + ), ), ); } @@ -514,84 +594,67 @@ class InitializingPage extends StatelessWidget { return Builder( builder: (final context) => SizedBox( width: double.infinity, - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - 'initializing.checks'.tr(args: [doneCount.toString(), '4']), - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 16), - if (text != null) + child: ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ Text( - text, - style: Theme.of(context).textTheme.bodyMedium, + 'initializing.checks'.tr(args: [doneCount.toString(), '4']), + style: Theme.of(context).textTheme.headlineSmall, ), - const SizedBox(height: 128), - const SizedBox(height: 10), - if (doneCount == 0 && state.dnsMatches != null) - Column( - children: state.dnsMatches!.entries.map((final entry) { - final String domain = entry.key; - final bool isCorrect = entry.value; - return Row( - children: [ - if (isCorrect) - const Icon(Icons.check, color: Colors.green), - if (!isCorrect) - const Icon(Icons.schedule, color: Colors.amber), - const SizedBox(width: 10), - Text(domain), - ], - ); - }).toList(), - ), - const SizedBox(height: 10), - if (!state.isLoading) - Row( - children: [ - Text( - 'initializing.until_the_next_check'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - BrandTimer( - startDateTime: state.timerStart!, - duration: state.duration!, - ) - ], - ), - if (state.isLoading) - Text( - 'initializing.check'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - ], + const SizedBox(height: 16), + if (text != null) + Text( + text, + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), + primaryColumn: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + const SizedBox(height: 128), + const SizedBox(height: 10), + if (doneCount == 0 && state.dnsMatches != null) + Column( + children: state.dnsMatches!.entries.map((final entry) { + final String domain = entry.key; + final bool isCorrect = entry.value; + return Row( + children: [ + if (isCorrect) + const Icon(Icons.check, color: Colors.green), + if (!isCorrect) + const Icon(Icons.schedule, color: Colors.amber), + const SizedBox(width: 10), + Text(domain), + ], + ); + }).toList(), + ), + const SizedBox(height: 10), + if (!state.isLoading) + Row( + children: [ + Text( + 'initializing.until_the_next_check'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + BrandTimer( + startDateTime: state.timerStart!, + duration: state.duration!, + ) + ], + ), + if (state.isLoading) + Text( + 'initializing.check'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), ), ), ); } } - -class _HowTo extends StatelessWidget { - const _HowTo({ - required this.fileName, - }); - - final String fileName; - - @override - Widget build(final BuildContext context) => BrandBottomSheet( - isExpended: true, - child: Padding( - padding: paddingH15V0, - child: ListView( - padding: const EdgeInsets.symmetric(vertical: 16), - children: [ - BrandMarkdown( - fileName: fileName, - ), - ], - ), - ), - ); -} diff --git a/lib/ui/pages/setup/initializing/server_provider_picker.dart b/lib/ui/pages/setup/initializing/server_provider_picker.dart index dfec01b9..1257cc75 100644 --- a/lib/ui/pages/setup/initializing/server_provider_picker.dart +++ b/lib/ui/pages/setup/initializing/server_provider_picker.dart @@ -2,16 +2,15 @@ import 'package:cubit_form/cubit_form.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:flutter_svg/flutter_svg.dart'; -import 'package:selfprivacy/config/brand_theme.dart'; import 'package:selfprivacy/logic/cubit/app_config_dependent/authentication_dependend_cubit.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/initializing/provider_form_cubit.dart'; +import 'package:selfprivacy/logic/cubit/support_system/support_system_cubit.dart'; import 'package:selfprivacy/logic/models/hive/server_details.dart'; -import 'package:selfprivacy/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_button/outlined_button.dart'; -import 'package:selfprivacy/ui/components/brand_cards/outlined_card.dart'; -import 'package:selfprivacy/ui/components/brand_md/brand_md.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/components/buttons/outlined_button.dart'; +import 'package:selfprivacy/ui/components/cards/outlined_card.dart'; import 'package:selfprivacy/ui/components/info_box/info_box.dart'; +import 'package:selfprivacy/ui/layouts/responsive_layout_with_infobox.dart'; import 'package:selfprivacy/utils/launch_url.dart'; class ServerProviderPicker extends StatefulWidget { @@ -98,56 +97,49 @@ class ProviderInputDataPage extends StatelessWidget { final ProviderFormCubit providerCubit; @override - Widget build(final BuildContext context) => Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - "${'initializing.connect_to_server_provider'.tr()}${providerInfo.providerType.displayName}", - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.connect_to_server_provider_text'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - const SizedBox(height: 32), - CubitFormTextField( - formFieldCubit: providerCubit.apiKey, - textAlign: TextAlign.center, - scrollPadding: const EdgeInsets.only(bottom: 70), - decoration: const InputDecoration( - hintText: 'Provider API Token', + Widget build(final BuildContext context) => ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + "${'initializing.connect_to_server_provider'.tr()}${providerInfo.providerType.displayName}", + style: Theme.of(context).textTheme.headlineSmall, ), - ), - const SizedBox(height: 32), - BrandButton.filled( - child: Text('basis.connect'.tr()), - onPressed: () => providerCubit.trySubmit(), - ), - const SizedBox(height: 10), - BrandOutlinedButton( - child: Text('initializing.how'.tr()), - onPressed: () => showModalBottomSheet( - context: context, - isScrollControlled: true, - backgroundColor: Colors.transparent, - builder: (final BuildContext context) => BrandBottomSheet( - isExpended: true, - child: Padding( - padding: paddingH15V0, - child: ListView( - padding: const EdgeInsets.symmetric(vertical: 16), - children: [ - BrandMarkdown( - fileName: providerInfo.pathToHow, - ), - ], - ), - ), + const SizedBox(height: 16), + Text( + 'initializing.connect_to_server_provider_text'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), + primaryColumn: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + CubitFormTextField( + formFieldCubit: providerCubit.apiKey, + textAlign: TextAlign.center, + scrollPadding: const EdgeInsets.only(bottom: 70), + decoration: const InputDecoration( + hintText: 'Provider API Token', ), ), - ), - ], + const SizedBox(height: 32), + BrandButton.filled( + child: Text('basis.connect'.tr()), + onPressed: () => providerCubit.trySubmit(), + ), + const SizedBox(height: 10), + BrandOutlinedButton( + child: Text('initializing.how'.tr()), + onPressed: () { + context.read().showArticle( + article: providerInfo.pathToHow, + context: context, + ); + }, + ), + ], + ), ); } @@ -164,175 +156,182 @@ class ProviderSelectionPage extends StatelessWidget { @override Widget build(final BuildContext context) => SizedBox( width: double.infinity, - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - 'initializing.connect_to_server'.tr(), - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 10), - Text( - 'initializing.select_provider'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - const SizedBox(height: 10), - OutlinedCard( - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Row( - children: [ - Container( - width: 40, - height: 40, - padding: const EdgeInsets.all(10), - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(40), - color: const Color(0xFFD50C2D), + child: ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + 'initializing.connect_to_server'.tr(), + style: Theme.of(context).textTheme.headlineSmall, + ), + const SizedBox(height: 10), + Text( + 'initializing.select_provider'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), + primaryColumn: Column( + children: [ + OutlinedCard( + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Row( + children: [ + Container( + width: 40, + height: 40, + padding: const EdgeInsets.all(10), + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(40), + color: const Color(0xFFD50C2D), + ), + child: SvgPicture.asset( + 'assets/images/logos/hetzner.svg', + ), ), - child: SvgPicture.asset( - 'assets/images/logos/hetzner.svg', + const SizedBox(width: 16), + Text( + 'Hetzner Cloud', + style: Theme.of(context).textTheme.titleMedium, ), - ), - const SizedBox(width: 16), - Text( - 'Hetzner Cloud', - style: Theme.of(context).textTheme.titleMedium, - ), - ], - ), - const SizedBox(height: 16), - Text( - 'initializing.select_provider_countries_title'.tr(), - style: Theme.of(context).textTheme.bodyLarge, - ), - Text( - 'initializing.select_provider_countries_text_hetzner' - .tr(), - style: Theme.of(context).textTheme.bodySmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.select_provider_price_title'.tr(), - style: Theme.of(context).textTheme.bodyLarge, - ), - Text( - 'initializing.select_provider_price_text_hetzner'.tr(), - style: Theme.of(context).textTheme.bodySmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.select_provider_payment_title'.tr(), - style: Theme.of(context).textTheme.bodyLarge, - ), - Text( - 'initializing.select_provider_payment_text_hetzner'.tr(), - style: Theme.of(context).textTheme.bodySmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.select_provider_email_notice'.tr(), - style: Theme.of(context).textTheme.bodySmall, - ), - const SizedBox(height: 16), - BrandButton.filled( - child: Text('basis.select'.tr()), - onPressed: () { - serverInstallationCubit - .setServerProviderType(ServerProvider.hetzner); - callback(ServerProvider.hetzner); - }, - ), - // Outlined button that will open website - BrandOutlinedButton( - onPressed: () => - launchURL('https://www.hetzner.com/cloud'), - title: 'initializing.select_provider_site_button'.tr(), - ), - ], + ], + ), + const SizedBox(height: 16), + Text( + 'initializing.select_provider_countries_title'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), + Text( + 'initializing.select_provider_countries_text_hetzner' + .tr(), + style: Theme.of(context).textTheme.bodySmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.select_provider_price_title'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), + Text( + 'initializing.select_provider_price_text_hetzner'.tr(), + style: Theme.of(context).textTheme.bodySmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.select_provider_payment_title'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), + Text( + 'initializing.select_provider_payment_text_hetzner' + .tr(), + style: Theme.of(context).textTheme.bodySmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.select_provider_email_notice'.tr(), + style: Theme.of(context).textTheme.bodySmall, + ), + const SizedBox(height: 16), + BrandButton.filled( + child: Text('basis.select'.tr()), + onPressed: () { + serverInstallationCubit + .setServerProviderType(ServerProvider.hetzner); + callback(ServerProvider.hetzner); + }, + ), + // Outlined button that will open website + BrandOutlinedButton( + onPressed: () => + launchURL('https://www.hetzner.com/cloud'), + title: 'initializing.select_provider_site_button'.tr(), + ), + ], + ), ), ), - ), - const SizedBox(height: 16), - OutlinedCard( - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Row( - children: [ - Container( - width: 40, - height: 40, - padding: const EdgeInsets.all(10), - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(40), - color: const Color(0xFF0080FF), + const SizedBox(height: 16), + OutlinedCard( + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Row( + children: [ + Container( + width: 40, + height: 40, + padding: const EdgeInsets.all(10), + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(40), + color: const Color(0xFF0080FF), + ), + child: SvgPicture.asset( + 'assets/images/logos/digital_ocean.svg', + ), ), - child: SvgPicture.asset( - 'assets/images/logos/digital_ocean.svg', + const SizedBox(width: 16), + Text( + 'Digital Ocean', + style: Theme.of(context).textTheme.titleMedium, ), - ), - const SizedBox(width: 16), - Text( - 'Digital Ocean', - style: Theme.of(context).textTheme.titleMedium, - ), - ], - ), - const SizedBox(height: 16), - Text( - 'initializing.select_provider_countries_title'.tr(), - style: Theme.of(context).textTheme.bodyLarge, - ), - Text( - 'initializing.select_provider_countries_text_do'.tr(), - style: Theme.of(context).textTheme.bodySmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.select_provider_price_title'.tr(), - style: Theme.of(context).textTheme.bodyLarge, - ), - Text( - 'initializing.select_provider_price_text_do'.tr(), - style: Theme.of(context).textTheme.bodySmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.select_provider_payment_title'.tr(), - style: Theme.of(context).textTheme.bodyLarge, - ), - Text( - 'initializing.select_provider_payment_text_do'.tr(), - style: Theme.of(context).textTheme.bodySmall, - ), - const SizedBox(height: 16), - BrandButton.filled( - child: Text('basis.select'.tr()), - onPressed: () { - serverInstallationCubit - .setServerProviderType(ServerProvider.digitalOcean); - callback(ServerProvider.digitalOcean); - }, - ), - // Outlined button that will open website - BrandOutlinedButton( - onPressed: () => - launchURL('https://www.digitalocean.com'), - title: 'initializing.select_provider_site_button'.tr(), - ), - ], + ], + ), + const SizedBox(height: 16), + Text( + 'initializing.select_provider_countries_title'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), + Text( + 'initializing.select_provider_countries_text_do'.tr(), + style: Theme.of(context).textTheme.bodySmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.select_provider_price_title'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), + Text( + 'initializing.select_provider_price_text_do'.tr(), + style: Theme.of(context).textTheme.bodySmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.select_provider_payment_title'.tr(), + style: Theme.of(context).textTheme.bodyLarge, + ), + Text( + 'initializing.select_provider_payment_text_do'.tr(), + style: Theme.of(context).textTheme.bodySmall, + ), + const SizedBox(height: 16), + BrandButton.filled( + child: Text('basis.select'.tr()), + onPressed: () { + serverInstallationCubit.setServerProviderType( + ServerProvider.digitalOcean, + ); + callback(ServerProvider.digitalOcean); + }, + ), + // Outlined button that will open website + BrandOutlinedButton( + onPressed: () => + launchURL('https://www.digitalocean.com'), + title: 'initializing.select_provider_site_button'.tr(), + ), + ], + ), ), ), - ), - const SizedBox(height: 16), - InfoBox(text: 'initializing.select_provider_notice'.tr()), - ], + ], + ), + secondaryColumn: + InfoBox(text: 'initializing.select_provider_notice'.tr()), ), ); } diff --git a/lib/ui/pages/setup/initializing/server_type_picker.dart b/lib/ui/pages/setup/initializing/server_type_picker.dart index 5a6632c8..3c1c5380 100644 --- a/lib/ui/pages/setup/initializing/server_type_picker.dart +++ b/lib/ui/pages/setup/initializing/server_type_picker.dart @@ -5,8 +5,9 @@ import 'package:selfprivacy/logic/cubit/app_config_dependent/authentication_depe import 'package:selfprivacy/logic/cubit/app_settings/app_settings_cubit.dart'; import 'package:selfprivacy/logic/models/server_provider_location.dart'; import 'package:selfprivacy/logic/models/server_type.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; import 'package:selfprivacy/ui/components/info_box/info_box.dart'; +import 'package:selfprivacy/ui/layouts/responsive_layout_with_infobox.dart'; class ServerTypePicker extends StatefulWidget { const ServerTypePicker({ @@ -70,50 +71,67 @@ class SelectLocationPage extends StatelessWidget { if ((snapshot.data as List).isEmpty) { return Text('initializing.no_locations_found'.tr()); } - return Column( - children: [ - Text( - 'initializing.choose_location_type'.tr(), - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.choose_location_type_text'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - const SizedBox(height: 16), - ...(snapshot.data! as List).map( - (final location) => SizedBox( - width: double.infinity, - child: InkWell( - onTap: () { - callback(location); - }, - child: Card( - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - '${location.flag ?? ''} ${location.title}', - style: Theme.of(context).textTheme.titleMedium, - ), - const SizedBox(height: 8), - if (location.description != null) - Text( - location.description!, - style: Theme.of(context).textTheme.bodyMedium, + return ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + 'initializing.choose_location_type'.tr(), + style: Theme.of(context).textTheme.headlineSmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.choose_location_type_text'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), + primaryColumn: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + ...(snapshot.data! as List).map( + (final location) => Column( + children: [ + SizedBox( + width: double.infinity, + child: Card( + clipBehavior: Clip.antiAlias, + child: InkResponse( + highlightShape: BoxShape.rectangle, + onTap: () { + callback(location); + }, + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + '${location.flag ?? ''} ${location.title}', + style: Theme.of(context) + .textTheme + .titleMedium, + ), + const SizedBox(height: 8), + if (location.description != null) + Text( + location.description!, + style: Theme.of(context) + .textTheme + .bodyMedium, + ), + ], ), - ], + ), + ), ), ), - ), + const SizedBox(height: 8), + ], ), ), - ), - const SizedBox(height: 24), - ], + ], + ), ); } else { return const Center(child: CircularProgressIndicator()); @@ -180,121 +198,145 @@ class SelectTypePage extends StatelessWidget { ], ); } - return Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - 'initializing.choose_server_type'.tr(), - style: Theme.of(context).textTheme.headlineSmall, - ), - const SizedBox(height: 16), - Text( - 'initializing.choose_server_type_text'.tr(), - style: Theme.of(context).textTheme.bodyMedium, - ), - const SizedBox(height: 16), - ...(snapshot.data! as List).map( - (final type) => SizedBox( - width: double.infinity, - child: InkWell( - onTap: () { - serverInstallationCubit.setServerType(type); - }, - child: Card( - child: Padding( - padding: const EdgeInsets.all(16.0), - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Text( - type.title, - style: Theme.of(context).textTheme.titleMedium, - ), - const SizedBox(height: 8), - Row( - children: [ - Icon( - Icons.memory_outlined, - color: - Theme.of(context).colorScheme.onSurface, - ), - const SizedBox(width: 8), - Text( - 'server.core_count'.plural(type.cores), - style: - Theme.of(context).textTheme.bodyMedium, - ), - ], - ), - const SizedBox(height: 8), - Row( - children: [ - Icon( - Icons.memory_outlined, - color: - Theme.of(context).colorScheme.onSurface, - ), - const SizedBox(width: 8), - Text( - 'initializing.choose_server_type_ram' - .tr(args: [type.ram.toString()]), - style: - Theme.of(context).textTheme.bodyMedium, - ), - ], - ), - const SizedBox(height: 8), - Row( - children: [ - Icon( - Icons.sd_card_outlined, - color: - Theme.of(context).colorScheme.onSurface, - ), - const SizedBox(width: 8), - Text( - 'initializing.choose_server_type_storage' - .tr( - args: [type.disk.gibibyte.toString()], + return ResponsiveLayoutWithInfobox( + topChild: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + 'initializing.choose_server_type'.tr(), + style: Theme.of(context).textTheme.headlineSmall, + ), + const SizedBox(height: 16), + Text( + 'initializing.choose_server_type_text'.tr(), + style: Theme.of(context).textTheme.bodyMedium, + ), + ], + ), + primaryColumn: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + ...(snapshot.data! as List).map( + (final type) => Column( + children: [ + SizedBox( + width: double.infinity, + child: InkWell( + onTap: () { + serverInstallationCubit.setServerType(type); + }, + child: Card( + child: Padding( + padding: const EdgeInsets.all(16.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + type.title, + style: Theme.of(context) + .textTheme + .titleMedium, ), - style: - Theme.of(context).textTheme.bodyMedium, - ), - ], - ), - const SizedBox(height: 8), - const Divider(height: 8), - const SizedBox(height: 8), - Row( - children: [ - Icon( - Icons.payments_outlined, - color: - Theme.of(context).colorScheme.onSurface, - ), - const SizedBox(width: 8), - Text( - 'initializing.choose_server_type_payment_per_month' - .tr( - args: [ - '${type.price.value.toString()} ${type.price.currency}' + const SizedBox(height: 8), + Row( + children: [ + Icon( + Icons.memory_outlined, + color: Theme.of(context) + .colorScheme + .onSurface, + ), + const SizedBox(width: 8), + Text( + 'server.core_count' + .plural(type.cores), + style: Theme.of(context) + .textTheme + .bodyMedium, + ), ], ), - style: - Theme.of(context).textTheme.bodyLarge, - ), - ], + const SizedBox(height: 8), + Row( + children: [ + Icon( + Icons.memory_outlined, + color: Theme.of(context) + .colorScheme + .onSurface, + ), + const SizedBox(width: 8), + Text( + 'initializing.choose_server_type_ram' + .tr(args: [type.ram.toString()]), + style: Theme.of(context) + .textTheme + .bodyMedium, + ), + ], + ), + const SizedBox(height: 8), + Row( + children: [ + Icon( + Icons.sd_card_outlined, + color: Theme.of(context) + .colorScheme + .onSurface, + ), + const SizedBox(width: 8), + Text( + 'initializing.choose_server_type_storage' + .tr( + args: [ + type.disk.gibibyte.toString() + ], + ), + style: Theme.of(context) + .textTheme + .bodyMedium, + ), + ], + ), + const SizedBox(height: 8), + const Divider(height: 8), + const SizedBox(height: 8), + Row( + children: [ + Icon( + Icons.payments_outlined, + color: Theme.of(context) + .colorScheme + .onSurface, + ), + const SizedBox(width: 8), + Text( + 'initializing.choose_server_type_payment_per_month' + .tr( + args: [ + '${type.price.value.toString()} ${type.price.currency}' + ], + ), + style: Theme.of(context) + .textTheme + .bodyLarge, + ), + ], + ), + ], + ), ), - ], + ), ), ), - ), + const SizedBox(height: 8), + ], ), ), - ), - const SizedBox(height: 16), - InfoBox(text: 'initializing.choose_server_type_notice'.tr()), - ], + ], + ), + secondaryColumn: + InfoBox(text: 'initializing.choose_server_type_notice'.tr()), ); } else { return const Center(child: CircularProgressIndicator()); diff --git a/lib/ui/pages/setup/recovering/recover_by_new_device_key.dart b/lib/ui/pages/setup/recovering/recover_by_new_device_key.dart index bb2ebbf0..4f6cf352 100644 --- a/lib/ui/pages/setup/recovering/recover_by_new_device_key.dart +++ b/lib/ui/pages/setup/recovering/recover_by_new_device_key.dart @@ -1,8 +1,8 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/recovering/recovery_device_form_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/utils/route_transitions/basic.dart'; import 'package:cubit_form/cubit_form.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; @@ -17,6 +17,7 @@ class RecoverByNewDeviceKeyInstruction extends StatelessWidget { heroSubtitle: 'recovering.method_device_description'.tr(), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, onBackButtonPressed: context.read().revertRecoveryStep, children: [ @@ -61,6 +62,7 @@ class RecoverByNewDeviceKeyInput extends StatelessWidget { heroSubtitle: 'recovering.method_device_input_description'.tr(), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, children: [ CubitFormTextField( formFieldCubit: diff --git a/lib/ui/pages/setup/recovering/recover_by_old_token.dart b/lib/ui/pages/setup/recovering/recover_by_old_token.dart index 2b65ba8b..42d60f34 100644 --- a/lib/ui/pages/setup/recovering/recover_by_old_token.dart +++ b/lib/ui/pages/setup/recovering/recover_by_old_token.dart @@ -1,8 +1,8 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/recovering/recovery_device_form_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/components/brand_md/brand_md.dart'; import 'package:cubit_form/cubit_form.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; @@ -28,6 +28,7 @@ class RecoverByOldTokenInstruction extends StatelessWidget { heroTitle: 'recovering.recovery_main_header'.tr(), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, onBackButtonPressed: context.read().revertRecoveryStep, children: [ @@ -72,6 +73,7 @@ class RecoverByOldToken extends StatelessWidget { heroSubtitle: 'recovering.method_device_input_description'.tr(), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, children: [ CubitFormTextField( formFieldCubit: diff --git a/lib/ui/pages/setup/recovering/recover_by_recovery_key.dart b/lib/ui/pages/setup/recovering/recover_by_recovery_key.dart index c47b924f..b39dc2da 100644 --- a/lib/ui/pages/setup/recovering/recover_by_recovery_key.dart +++ b/lib/ui/pages/setup/recovering/recover_by_recovery_key.dart @@ -4,8 +4,8 @@ import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/forms/factories/field_cubit_factory.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/recovering/recovery_device_form_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; class RecoverByRecoveryKey extends StatelessWidget { const RecoverByRecoveryKey({super.key}); @@ -31,6 +31,7 @@ class RecoverByRecoveryKey extends StatelessWidget { heroSubtitle: 'recovering.method_recovery_input_description'.tr(), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, onBackButtonPressed: context.read().revertRecoveryStep, children: [ diff --git a/lib/ui/pages/setup/recovering/recovery_confirm_backblaze.dart b/lib/ui/pages/setup/recovering/recovery_confirm_backblaze.dart index 0b7e7a9e..f7216a74 100644 --- a/lib/ui/pages/setup/recovering/recovery_confirm_backblaze.dart +++ b/lib/ui/pages/setup/recovering/recovery_confirm_backblaze.dart @@ -1,13 +1,11 @@ import 'package:cubit_form/cubit_form.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_theme.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/initializing/backblaze_form_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; -import 'package:selfprivacy/ui/components/brand_md/brand_md.dart'; +import 'package:selfprivacy/logic/cubit/support_system/support_system_cubit.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; class RecoveryConfirmBackblaze extends StatelessWidget { const RecoveryConfirmBackblaze({super.key}); @@ -28,6 +26,8 @@ class RecoveryConfirmBackblaze extends StatelessWidget { heroTitle: 'recovering.confirm_backblaze'.tr(), heroSubtitle: 'recovering.confirm_backblaze_description'.tr(), hasBackButton: true, + ignoreBreakpoints: true, + hasSupportDrawer: true, onBackButtonPressed: () { Navigator.of(context).popUntil((final route) => route.isFirst); }, @@ -57,27 +57,15 @@ class RecoveryConfirmBackblaze extends StatelessWidget { text: 'basis.connect'.tr(), ), const SizedBox(height: 16), - BrandButton.text( - onPressed: () => showModalBottomSheet( - context: context, - isScrollControlled: true, - backgroundColor: Colors.transparent, - builder: (final BuildContext context) => BrandBottomSheet( - isExpended: true, - child: Padding( - padding: paddingH15V0, - child: ListView( - padding: const EdgeInsets.symmetric(vertical: 16), - children: const [ - BrandMarkdown( - fileName: 'how_backblaze', + Builder( + builder: (final context) => BrandButton.text( + onPressed: () => + context.read().showArticle( + article: 'how_backblaze', + context: context, ), - ], - ), - ), - ), + title: 'initializing.how'.tr(), ), - title: 'initializing.how'.tr(), ), ], ); diff --git a/lib/ui/pages/setup/recovering/recovery_confirm_cloudflare.dart b/lib/ui/pages/setup/recovering/recovery_confirm_cloudflare.dart index 4b766e56..93c889a5 100644 --- a/lib/ui/pages/setup/recovering/recovery_confirm_cloudflare.dart +++ b/lib/ui/pages/setup/recovering/recovery_confirm_cloudflare.dart @@ -1,13 +1,11 @@ import 'package:cubit_form/cubit_form.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_theme.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/initializing/dns_provider_form_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; -import 'package:selfprivacy/ui/components/brand_md/brand_md.dart'; +import 'package:selfprivacy/logic/cubit/support_system/support_system_cubit.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; class RecoveryConfirmCloudflare extends StatelessWidget { const RecoveryConfirmCloudflare({super.key}); @@ -31,6 +29,8 @@ class RecoveryConfirmCloudflare extends StatelessWidget { ), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, + hasSupportDrawer: true, onBackButtonPressed: context.read().revertRecoveryStep, children: [ @@ -49,27 +49,15 @@ class RecoveryConfirmCloudflare extends StatelessWidget { text: 'basis.connect'.tr(), ), const SizedBox(height: 16), - BrandButton.text( - onPressed: () => showModalBottomSheet( - context: context, - isScrollControlled: true, - backgroundColor: Colors.transparent, - builder: (final BuildContext context) => BrandBottomSheet( - isExpended: true, - child: Padding( - padding: paddingH15V0, - child: ListView( - padding: const EdgeInsets.symmetric(vertical: 16), - children: const [ - BrandMarkdown( - fileName: 'how_cloudflare', + Builder( + builder: (final context) => BrandButton.text( + onPressed: () => + context.read().showArticle( + article: 'how_cloudflare', + context: context, ), - ], - ), - ), - ), + title: 'initializing.how'.tr(), ), - title: 'initializing.how'.tr(), ), ], ); diff --git a/lib/ui/pages/setup/recovering/recovery_confirm_server.dart b/lib/ui/pages/setup/recovering/recovery_confirm_server.dart index 3b47cc76..2efcff87 100644 --- a/lib/ui/pages/setup/recovering/recovery_confirm_server.dart +++ b/lib/ui/pages/setup/recovering/recovery_confirm_server.dart @@ -2,9 +2,9 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/app_config_dependent/authentication_dependend_cubit.dart'; import 'package:selfprivacy/logic/models/server_basic_info.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_cards/filled_card.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/components/cards/filled_card.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; class RecoveryConfirmServer extends StatefulWidget { const RecoveryConfirmServer({super.key}); @@ -38,6 +38,7 @@ class _RecoveryConfirmServerState extends State { ? 'recovering.choose_server_description'.tr() : 'recovering.confirm_server_description'.tr(), hasBackButton: true, + ignoreBreakpoints: true, onBackButtonPressed: () { Navigator.of(context).popUntil((final route) => route.isFirst); }, diff --git a/lib/ui/pages/setup/recovering/recovery_method_select.dart b/lib/ui/pages/setup/recovering/recovery_method_select.dart index 68129d57..f8cec44a 100644 --- a/lib/ui/pages/setup/recovering/recovery_method_select.dart +++ b/lib/ui/pages/setup/recovering/recovery_method_select.dart @@ -2,9 +2,9 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_cards/outlined_card.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/components/cards/outlined_card.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/pages/setup/recovering/recover_by_old_token.dart'; import 'package:selfprivacy/utils/route_transitions/basic.dart'; @@ -17,6 +17,7 @@ class RecoveryMethodSelect extends StatelessWidget { heroSubtitle: 'recovering.method_select_description'.tr(), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, onBackButtonPressed: context.read().revertRecoveryStep, children: [ @@ -74,6 +75,7 @@ class RecoveryFallbackMethodSelect extends StatelessWidget { heroSubtitle: 'recovering.fallback_select_description'.tr(), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, children: [ OutlinedCard( child: ListTile( diff --git a/lib/ui/pages/setup/recovering/recovery_routing.dart b/lib/ui/pages/setup/recovering/recovery_routing.dart index 68108214..14c3f9a7 100644 --- a/lib/ui/pages/setup/recovering/recovery_routing.dart +++ b/lib/ui/pages/setup/recovering/recovery_routing.dart @@ -1,11 +1,12 @@ +import 'package:auto_route/auto_route.dart'; import 'package:cubit_form/cubit_form.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; import 'package:selfprivacy/logic/cubit/forms/factories/field_cubit_factory.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/recovering/recovery_domain_form_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/pages/root_route.dart'; import 'package:selfprivacy/ui/pages/setup/recovering/recover_by_old_token.dart'; import 'package:selfprivacy/ui/pages/setup/recovering/recover_by_recovery_key.dart'; @@ -17,6 +18,7 @@ import 'package:selfprivacy/ui/pages/setup/recovering/recovery_server_provider_c import 'package:selfprivacy/ui/pages/setup/recovering/recovery_method_select.dart'; import 'package:selfprivacy/utils/route_transitions/basic.dart'; +@RoutePage() class RecoveryRouting extends StatelessWidget { const RecoveryRouting({super.key}); @@ -110,6 +112,7 @@ class SelectDomainToRecover extends StatelessWidget { heroSubtitle: 'recovering.domain_recovery_description'.tr(), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, onBackButtonPressed: () { Navigator.of(context).pushAndRemoveUntil( materialRoute(const RootPage()), diff --git a/lib/ui/pages/setup/recovering/recovery_server_provider_connected.dart b/lib/ui/pages/setup/recovering/recovery_server_provider_connected.dart index f850cde7..91999fb9 100644 --- a/lib/ui/pages/setup/recovering/recovery_server_provider_connected.dart +++ b/lib/ui/pages/setup/recovering/recovery_server_provider_connected.dart @@ -1,13 +1,11 @@ import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_theme.dart'; import 'package:selfprivacy/logic/cubit/forms/setup/initializing/provider_form_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/logic/cubit/support_system/support_system_cubit.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:cubit_form/cubit_form.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; -import 'package:selfprivacy/ui/components/brand_md/brand_md.dart'; class RecoveryServerProviderConnected extends StatelessWidget { const RecoveryServerProviderConnected({super.key}); @@ -31,6 +29,8 @@ class RecoveryServerProviderConnected extends StatelessWidget { ), hasBackButton: true, hasFlashButton: false, + ignoreBreakpoints: true, + hasSupportDrawer: true, onBackButtonPressed: () { Navigator.of(context).popUntil((final route) => route.isFirst); }, @@ -51,26 +51,14 @@ class RecoveryServerProviderConnected extends StatelessWidget { child: Text('basis.continue'.tr()), ), const SizedBox(height: 16), - BrandButton.text( - title: 'initializing.how'.tr(), - onPressed: () => showModalBottomSheet( - context: context, - isScrollControlled: true, - backgroundColor: Colors.transparent, - builder: (final BuildContext context) => BrandBottomSheet( - isExpended: true, - child: Padding( - padding: paddingH15V0, - child: ListView( - padding: const EdgeInsets.symmetric(vertical: 16), - children: const [ - BrandMarkdown( - fileName: 'how_hetzner', + Builder( + builder: (final context) => BrandButton.text( + title: 'initializing.how'.tr(), + onPressed: () => + context.read().showArticle( + article: 'how_hetzner', + context: context, ), - ], - ), - ), - ), ), ), ], diff --git a/lib/ui/pages/users/add_user_fab.dart b/lib/ui/pages/users/add_user_fab.dart deleted file mode 100644 index 7e87e51d..00000000 --- a/lib/ui/pages/users/add_user_fab.dart +++ /dev/null @@ -1,22 +0,0 @@ -part of 'users.dart'; - -class AddUserFab extends StatelessWidget { - const AddUserFab({super.key}); - - @override - Widget build(final BuildContext context) => FloatingActionButton.small( - heroTag: 'new_user_fab', - onPressed: () { - showModalBottomSheet( - context: context, - isScrollControlled: true, - backgroundColor: Colors.transparent, - builder: (final BuildContext context) => Padding( - padding: MediaQuery.of(context).viewInsets, - child: const NewUser(), - ), - ); - }, - child: const Icon(Icons.person_add_outlined), - ); -} diff --git a/lib/ui/pages/users/empty.dart b/lib/ui/pages/users/empty.dart index dc2d292b..f58dc740 100644 --- a/lib/ui/pages/users/empty.dart +++ b/lib/ui/pages/users/empty.dart @@ -11,21 +11,25 @@ class _NoUsers extends StatelessWidget { child: Column( mainAxisAlignment: MainAxisAlignment.center, children: [ - const Icon(BrandIcons.users, size: 50, color: BrandColors.grey7), + Icon( + BrandIcons.users, + size: 50, + color: Theme.of(context).colorScheme.onBackground, + ), const SizedBox(height: 20), - BrandText.h2( + Text( 'users.nobody_here'.tr(), - style: const TextStyle( - color: BrandColors.grey7, - ), + style: Theme.of(context).textTheme.headlineMedium?.copyWith( + color: Theme.of(context).colorScheme.onBackground, + ), ), const SizedBox(height: 10), - BrandText.medium( + Text( text, textAlign: TextAlign.center, - style: const TextStyle( - color: BrandColors.grey7, - ), + style: Theme.of(context).textTheme.titleSmall?.copyWith( + color: Theme.of(context).colorScheme.onBackground, + ), ), ], ), @@ -43,21 +47,25 @@ class _CouldNotLoadUsers extends StatelessWidget { child: Column( mainAxisAlignment: MainAxisAlignment.center, children: [ - const Icon(BrandIcons.users, size: 50, color: BrandColors.grey7), + Icon( + BrandIcons.users, + size: 50, + color: Theme.of(context).colorScheme.onBackground, + ), const SizedBox(height: 20), - BrandText.h2( + Text( 'users.could_not_fetch_users'.tr(), - style: const TextStyle( - color: BrandColors.grey7, - ), + style: Theme.of(context).textTheme.headlineMedium?.copyWith( + color: Theme.of(context).colorScheme.onBackground, + ), ), const SizedBox(height: 10), - BrandText.medium( + Text( text, textAlign: TextAlign.center, - style: const TextStyle( - color: BrandColors.grey7, - ), + style: Theme.of(context).textTheme.titleSmall?.copyWith( + color: Theme.of(context).colorScheme.onBackground, + ), ), ], ), diff --git a/lib/ui/pages/users/new_user.dart b/lib/ui/pages/users/new_user.dart index 7c393296..d7ed2aca 100644 --- a/lib/ui/pages/users/new_user.dart +++ b/lib/ui/pages/users/new_user.dart @@ -1,7 +1,8 @@ part of 'users.dart'; -class NewUser extends StatelessWidget { - const NewUser({super.key}); +@RoutePage() +class NewUserPage extends StatelessWidget { + const NewUserPage({super.key}); @override Widget build(final BuildContext context) { @@ -10,108 +11,89 @@ class NewUser extends StatelessWidget { final String domainName = UiHelpers.getDomainName(config); - return BrandBottomSheet( - child: BlocProvider( - create: (final BuildContext context) { - final jobCubit = context.read(); - final jobState = jobCubit.state; - final users = []; - users.addAll(context.read().state.users); - if (jobState is JobsStateWithJobs) { - final jobs = jobState.clientJobList; - for (final job in jobs) { - if (job is CreateUserJob) { - users.add(job.user); - } + return BlocProvider( + create: (final BuildContext context) { + final jobCubit = context.read(); + final jobState = jobCubit.state; + final users = []; + users.addAll(context.read().state.users); + if (jobState is JobsStateWithJobs) { + final jobs = jobState.clientJobList; + for (final job in jobs) { + if (job is CreateUserJob) { + users.add(job.user); } } - return UserFormCubit( - jobsCubit: jobCubit, - fieldFactory: FieldCubitFactory(context), - ); - }, - child: Builder( - builder: (final BuildContext context) { - final FormCubitState formCubitState = - context.watch().state; + } + return UserFormCubit( + jobsCubit: jobCubit, + fieldFactory: FieldCubitFactory(context), + ); + }, + child: Builder( + builder: (final BuildContext context) { + final FormCubitState formCubitState = + context.watch().state; - return BlocListener( - listener: - (final BuildContext context, final FormCubitState state) { - if (state.isSubmitted) { - Navigator.pop(context); - } - }, - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisSize: MainAxisSize.min, - children: [ - BrandHeader( - title: 'users.new_user'.tr(), - ), - const SizedBox(width: 14), - Padding( - padding: paddingH15V0, - child: Column( - mainAxisSize: MainAxisSize.min, - children: [ - if (formCubitState.isErrorShown) - Text( - 'users.username_rule'.tr(), - style: TextStyle( - color: Theme.of(context).colorScheme.error, - ), - ), - const SizedBox(width: 14), - IntrinsicHeight( - child: CubitFormTextField( - formFieldCubit: context.read().login, - decoration: InputDecoration( - labelText: 'users.login'.tr(), - suffixText: '@$domainName', - ), - ), - ), - const SizedBox(height: 20), - CubitFormTextField( - formFieldCubit: - context.read().password, - decoration: InputDecoration( - alignLabelWithHint: false, - labelText: 'basis.password'.tr(), - suffixIcon: Padding( - padding: const EdgeInsets.only(right: 8), - child: IconButton( - icon: Icon( - BrandIcons.refresh, - color: - Theme.of(context).colorScheme.secondary, - ), - onPressed: context - .read() - .genNewPassword, - ), - ), - ), - ), - const SizedBox(height: 30), - BrandButton.rised( - onPressed: formCubitState.isSubmitting - ? null - : () => context.read().trySubmit(), - text: 'basis.create'.tr(), - ), - const SizedBox(height: 40), - Text('users.new_user_info_note'.tr()), - const SizedBox(height: 30), - ], + return BlocListener( + listener: (final BuildContext context, final FormCubitState state) { + if (state.isSubmitted) { + context.router.pop(); + } + }, + child: BrandHeroScreen( + heroTitle: 'users.new_user'.tr(), + heroIcon: Icons.person_add_outlined, + children: [ + if (formCubitState.isErrorShown) + Text( + 'users.username_rule'.tr(), + style: TextStyle( + color: Theme.of(context).colorScheme.error, ), ), - ], - ), - ); - }, - ), + const SizedBox(width: 14), + IntrinsicHeight( + child: CubitFormTextField( + formFieldCubit: context.read().login, + decoration: InputDecoration( + labelText: 'users.login'.tr(), + suffixText: '@$domainName', + ), + ), + ), + const SizedBox(height: 20), + CubitFormTextField( + formFieldCubit: context.read().password, + decoration: InputDecoration( + alignLabelWithHint: false, + labelText: 'basis.password'.tr(), + suffixIcon: Padding( + padding: const EdgeInsets.only(right: 8), + child: IconButton( + icon: Icon( + BrandIcons.refresh, + color: Theme.of(context).colorScheme.secondary, + ), + onPressed: context.read().genNewPassword, + ), + ), + ), + ), + const SizedBox(height: 30), + BrandButton.rised( + onPressed: formCubitState.isSubmitting + ? null + : () => context.read().trySubmit(), + text: 'basis.create'.tr(), + ), + const SizedBox(height: 40), + Text('users.new_user_info_note'.tr()), + const SizedBox(height: 30), + ], + ), + ); + }, ), ); } diff --git a/lib/ui/pages/users/reset_password.dart b/lib/ui/pages/users/reset_password.dart index 87f95902..64785d3a 100644 --- a/lib/ui/pages/users/reset_password.dart +++ b/lib/ui/pages/users/reset_password.dart @@ -9,76 +9,73 @@ class ResetPassword extends StatelessWidget { final User user; @override - Widget build(final BuildContext context) => BrandBottomSheet( - child: BlocProvider( - create: (final BuildContext context) => UserFormCubit( - jobsCubit: context.read(), - fieldFactory: FieldCubitFactory(context), - initialUser: user, - ), - child: Builder( - builder: (final BuildContext context) { - final FormCubitState formCubitState = - context.watch().state; + Widget build(final BuildContext context) => BlocProvider( + create: (final BuildContext context) => UserFormCubit( + jobsCubit: context.read(), + fieldFactory: FieldCubitFactory(context), + initialUser: user, + ), + child: Builder( + builder: (final BuildContext context) { + final FormCubitState formCubitState = + context.watch().state; - return BlocListener( - listener: - (final BuildContext context, final FormCubitState state) { - if (state.isSubmitted) { - Navigator.pop(context); - } - }, - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisSize: MainAxisSize.min, - children: [ - BrandHeader( - title: 'users.reset_password'.tr(), - ), - const SizedBox(width: 14), - Padding( - padding: paddingH15V0, - child: Column( - mainAxisSize: MainAxisSize.min, - children: [ - CubitFormTextField( - formFieldCubit: - context.read().password, - decoration: InputDecoration( - alignLabelWithHint: false, - labelText: 'basis.password'.tr(), - suffixIcon: Padding( - padding: const EdgeInsets.only(right: 8), - child: IconButton( - icon: Icon( - BrandIcons.refresh, - color: - Theme.of(context).colorScheme.secondary, - ), - onPressed: context - .read() - .genNewPassword, + return BlocListener( + listener: + (final BuildContext context, final FormCubitState state) { + if (state.isSubmitted) { + Navigator.pop(context); + } + }, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisSize: MainAxisSize.min, + children: [ + BrandHeader( + title: 'users.reset_password'.tr(), + ), + const SizedBox(width: 14), + Padding( + padding: paddingH15V0, + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + CubitFormTextField( + formFieldCubit: + context.read().password, + decoration: InputDecoration( + alignLabelWithHint: false, + labelText: 'basis.password'.tr(), + suffixIcon: Padding( + padding: const EdgeInsets.only(right: 8), + child: IconButton( + icon: Icon( + BrandIcons.refresh, + color: + Theme.of(context).colorScheme.secondary, ), + onPressed: context + .read() + .genNewPassword, ), ), ), - const SizedBox(height: 30), - BrandButton.rised( - onPressed: formCubitState.isSubmitting - ? null - : () => - context.read().trySubmit(), - text: 'basis.apply'.tr(), - ), - const SizedBox(height: 30), - ], - ), + ), + const SizedBox(height: 30), + BrandButton.rised( + onPressed: formCubitState.isSubmitting + ? null + : () => context.read().trySubmit(), + text: 'basis.apply'.tr(), + ), + const SizedBox(height: 30), + ], ), - ], - ), - ); - }, - ), + ), + ], + ), + ); + }, ), ); } diff --git a/lib/ui/pages/users/user.dart b/lib/ui/pages/users/user.dart index 1d781811..bbc01012 100644 --- a/lib/ui/pages/users/user.dart +++ b/lib/ui/pages/users/user.dart @@ -11,9 +11,7 @@ class _User extends StatelessWidget { @override Widget build(final BuildContext context) => InkWell( onTap: () { - Navigator.of(context).push( - materialRoute(UserDetails(login: user.login)), - ); + context.pushRoute(UserDetailsRoute(login: user.login)); }, child: Container( padding: paddingH15V0, @@ -30,17 +28,17 @@ class _User extends StatelessWidget { ), const SizedBox(width: 20), Flexible( - child: isRootUser - ? BrandText.h4Underlined(user.login) - // cross out text if user not found on server - : BrandText.h4( - user.login, - style: user.isFoundOnServer - ? null - : const TextStyle( - decoration: TextDecoration.lineThrough, - ), + child: Text( + user.login, + style: Theme.of(context).textTheme.titleMedium?.copyWith( + color: Theme.of(context).colorScheme.onBackground, + decoration: isRootUser + ? TextDecoration.underline + : user.isFoundOnServer + ? TextDecoration.none + : TextDecoration.lineThrough, ), + ), ), ], ), diff --git a/lib/ui/pages/users/user_details.dart b/lib/ui/pages/users/user_details.dart index 3ae5b86d..be7205fb 100644 --- a/lib/ui/pages/users/user_details.dart +++ b/lib/ui/pages/users/user_details.dart @@ -1,7 +1,8 @@ part of 'users.dart'; -class UserDetails extends StatelessWidget { - const UserDetails({ +@RoutePage() +class UserDetailsPage extends StatelessWidget { + const UserDetailsPage({ required this.login, super.key, }); @@ -25,6 +26,7 @@ class UserDetails extends StatelessWidget { if (user.type == UserType.root) { return BrandHeroScreen( hasBackButton: true, + hasFlashButton: true, heroTitle: 'ssh.root_title'.tr(), heroSubtitle: 'ssh.root_subtitle'.tr(), children: [ @@ -35,6 +37,7 @@ class UserDetails extends StatelessWidget { return BrandHeroScreen( hasBackButton: true, + hasFlashButton: true, heroTitle: user.login, children: [ _UserLogins(user: user, domainName: domainName), @@ -87,6 +90,7 @@ class _DeleteUserTile extends StatelessWidget { onTap: () => { showDialog( context: context, + // useRootNavigator: false, builder: (final BuildContext context) => AlertDialog( title: Text('basis.confirmation'.tr()), content: SingleChildScrollView( @@ -102,7 +106,7 @@ class _DeleteUserTile extends StatelessWidget { TextButton( child: Text('basis.cancel'.tr()), onPressed: () { - Navigator.of(context).pop(); + context.router.pop(); }, ), TextButton( @@ -114,9 +118,8 @@ class _DeleteUserTile extends StatelessWidget { ), onPressed: () { context.read().addJob(DeleteUserJob(user: user)); - Navigator.of(context) - ..pop() - ..pop(); + context.router.childControllers.first.pop(); + context.router.pop(); }, ), ], @@ -231,9 +234,7 @@ class _SshKeysCard extends StatelessWidget { publicKey: key, ), ); - Navigator.of(context) - ..pop() - ..pop(); + context.popRoute(); }, ), ], @@ -253,72 +254,69 @@ class NewSshKey extends StatelessWidget { final User user; @override - Widget build(final BuildContext context) => BrandBottomSheet( - child: BlocProvider( - create: (final context) { - final jobCubit = context.read(); - final jobState = jobCubit.state; - if (jobState is JobsStateWithJobs) { - final jobs = jobState.clientJobList; - for (final job in jobs) { - if (job is CreateSSHKeyJob && job.user.login == user.login) { - user.sshKeys.add(job.publicKey); - } + Widget build(final BuildContext context) => BlocProvider( + create: (final context) { + final jobCubit = context.read(); + final jobState = jobCubit.state; + if (jobState is JobsStateWithJobs) { + final jobs = jobState.clientJobList; + for (final job in jobs) { + if (job is CreateSSHKeyJob && job.user.login == user.login) { + user.sshKeys.add(job.publicKey); } } - return SshFormCubit( - jobsCubit: jobCubit, - user: user, - ); - }, - child: Builder( - builder: (final context) { - final formCubitState = context.watch().state; + } + return SshFormCubit( + jobsCubit: jobCubit, + user: user, + ); + }, + child: Builder( + builder: (final context) { + final formCubitState = context.watch().state; - return BlocListener( - listener: (final context, final state) { - if (state.isSubmitted) { - Navigator.pop(context); - } - }, - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisSize: MainAxisSize.min, - children: [ - BrandHeader( - title: user.login, - ), - const SizedBox(width: 14), - Padding( - padding: paddingH15V0, - child: Column( - mainAxisSize: MainAxisSize.min, - children: [ - IntrinsicHeight( - child: CubitFormTextField( - formFieldCubit: context.read().key, - decoration: InputDecoration( - labelText: 'ssh.input_label'.tr(), - ), + return BlocListener( + listener: (final context, final state) { + if (state.isSubmitted) { + Navigator.pop(context); + } + }, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisSize: MainAxisSize.min, + children: [ + BrandHeader( + title: user.login, + ), + const SizedBox(width: 14), + Padding( + padding: paddingH15V0, + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + IntrinsicHeight( + child: CubitFormTextField( + formFieldCubit: context.read().key, + decoration: InputDecoration( + labelText: 'ssh.input_label'.tr(), ), ), - const SizedBox(height: 30), - BrandButton.rised( - onPressed: formCubitState.isSubmitting - ? null - : () => - context.read().trySubmit(), - text: 'ssh.create'.tr(), - ), - const SizedBox(height: 30), - ], - ), + ), + const SizedBox(height: 30), + BrandButton.rised( + onPressed: formCubitState.isSubmitting + ? null + : () => context.read().trySubmit(), + text: 'ssh.create'.tr(), + ), + const SizedBox(height: 30), + ], ), - ], - ), - ); - }, - ), + ), + ], + ), + ); + }, ), ); } diff --git a/lib/ui/pages/users/users.dart b/lib/ui/pages/users/users.dart index caf6d441..58cb3b7d 100644 --- a/lib/ui/pages/users/users.dart +++ b/lib/ui/pages/users/users.dart @@ -1,7 +1,7 @@ +import 'package:auto_route/auto_route.dart'; import 'package:cubit_form/cubit_form.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; -import 'package:selfprivacy/config/brand_colors.dart'; import 'package:selfprivacy/config/brand_theme.dart'; import 'package:selfprivacy/logic/cubit/forms/user/ssh_form_cubit.dart'; import 'package:selfprivacy/logic/cubit/server_installation/server_installation_cubit.dart'; @@ -11,28 +11,26 @@ import 'package:selfprivacy/logic/cubit/client_jobs/client_jobs_cubit.dart'; import 'package:selfprivacy/logic/cubit/users/users_cubit.dart'; import 'package:selfprivacy/logic/models/job.dart'; import 'package:selfprivacy/logic/models/hive/user.dart'; -import 'package:selfprivacy/ui/components/brand_bottom_sheet/brand_bottom_sheet.dart'; -import 'package:selfprivacy/ui/components/brand_button/brand_button.dart'; -import 'package:selfprivacy/ui/components/brand_button/outlined_button.dart'; -import 'package:selfprivacy/ui/components/brand_cards/filled_card.dart'; +import 'package:selfprivacy/ui/components/buttons/brand_button.dart'; +import 'package:selfprivacy/ui/components/buttons/outlined_button.dart'; +import 'package:selfprivacy/ui/components/cards/filled_card.dart'; import 'package:selfprivacy/ui/components/brand_header/brand_header.dart'; -import 'package:selfprivacy/ui/components/brand_hero_screen/brand_hero_screen.dart'; +import 'package:selfprivacy/ui/layouts/brand_hero_screen.dart'; import 'package:selfprivacy/ui/components/brand_icons/brand_icons.dart'; -import 'package:selfprivacy/ui/components/brand_text/brand_text.dart'; import 'package:selfprivacy/ui/components/info_box/info_box.dart'; import 'package:selfprivacy/ui/components/list_tiles/list_tile_on_surface_variant.dart'; import 'package:selfprivacy/ui/components/not_ready_card/not_ready_card.dart'; +import 'package:selfprivacy/ui/router/router.dart'; +import 'package:selfprivacy/utils/breakpoints.dart'; import 'package:selfprivacy/utils/ui_helpers.dart'; -import 'package:selfprivacy/utils/route_transitions/basic.dart'; - part 'empty.dart'; part 'new_user.dart'; part 'user.dart'; part 'user_details.dart'; -part 'add_user_fab.dart'; part 'reset_password.dart'; +@RoutePage() class UsersPage extends StatelessWidget { const UsersPage({super.key}); @@ -64,7 +62,7 @@ class UsersPage extends StatelessWidget { } return RefreshIndicator( onRefresh: () async { - context.read().refresh(); + await context.read().refresh(); }, child: Container( padding: const EdgeInsets.symmetric(horizontal: 15), @@ -90,15 +88,38 @@ class UsersPage extends StatelessWidget { } return RefreshIndicator( onRefresh: () async { - context.read().refresh(); + await context.read().refresh(); }, - child: ListView.builder( - itemCount: users.length, - itemBuilder: (final BuildContext context, final int index) => - _User( - user: users[index], - isRootUser: users[index].type == UserType.primary, - ), + child: Column( + children: [ + Padding( + padding: const EdgeInsets.all(8.0), + child: FilledButton.tonal( + child: Row( + crossAxisAlignment: CrossAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.center, + children: [ + const Icon(Icons.person_add_outlined), + const SizedBox(width: 8), + Text('users.new_user'.tr()), + ], + ), + onPressed: () { + context.pushRoute(const NewUserRoute()); + }, + ), + ), + Expanded( + child: ListView.builder( + itemCount: users.length, + itemBuilder: + (final BuildContext context, final int index) => _User( + user: users[index], + isRootUser: users[index].type == UserType.primary, + ), + ), + ), + ], ), ); }, @@ -106,12 +127,14 @@ class UsersPage extends StatelessWidget { } return Scaffold( - appBar: PreferredSize( - preferredSize: const Size.fromHeight(52), - child: BrandHeader( - title: 'basis.users'.tr(), - ), - ), + appBar: Breakpoints.small.isActive(context) + ? PreferredSize( + preferredSize: const Size.fromHeight(52), + child: BrandHeader( + title: 'basis.users'.tr(), + ), + ) + : null, body: child, ); } diff --git a/lib/ui/router/root_destinations.dart b/lib/ui/router/root_destinations.dart new file mode 100644 index 00000000..0d981894 --- /dev/null +++ b/lib/ui/router/root_destinations.dart @@ -0,0 +1,46 @@ +import 'package:auto_route/auto_route.dart'; +import 'package:easy_localization/easy_localization.dart'; +import 'package:flutter/material.dart'; +import 'package:selfprivacy/ui/components/brand_icons/brand_icons.dart'; +import 'package:selfprivacy/ui/router/router.dart'; + +class RouteDestination { + const RouteDestination({ + required this.route, + required this.icon, + required this.label, + required this.title, + }); + + final PageRouteInfo route; + final IconData icon; + final String label; + final String title; +} + +final rootDestinations = [ + RouteDestination( + route: const ProvidersRoute(), + icon: BrandIcons.server, + label: 'basis.providers'.tr(), + title: 'basis.providers_title'.tr(), + ), + RouteDestination( + route: const ServicesRoute(), + icon: BrandIcons.box, + label: 'basis.services'.tr(), + title: 'basis.services'.tr(), + ), + RouteDestination( + route: const UsersRoute(), + icon: BrandIcons.users, + label: 'basis.users'.tr(), + title: 'basis.users'.tr(), + ), + RouteDestination( + route: const MoreRoute(), + icon: Icons.menu_rounded, + label: 'basis.more'.tr(), + title: 'basis.more'.tr(), + ), +]; diff --git a/lib/ui/router/router.dart b/lib/ui/router/router.dart new file mode 100644 index 00000000..23a4ec0e --- /dev/null +++ b/lib/ui/router/router.dart @@ -0,0 +1,150 @@ +import 'package:animations/animations.dart'; +import 'package:auto_route/auto_route.dart'; +import 'package:flutter/material.dart'; +import 'package:selfprivacy/logic/models/disk_status.dart'; +import 'package:selfprivacy/logic/models/service.dart'; +import 'package:selfprivacy/ui/pages/backup_details/backup_details.dart'; +import 'package:selfprivacy/ui/pages/devices/devices.dart'; +import 'package:selfprivacy/ui/pages/dns_details/dns_details.dart'; +import 'package:selfprivacy/ui/pages/more/about_application.dart'; +import 'package:selfprivacy/ui/pages/more/app_settings/app_settings.dart'; +import 'package:selfprivacy/ui/pages/more/app_settings/developer_settings.dart'; +import 'package:selfprivacy/ui/pages/more/console.dart'; +import 'package:selfprivacy/ui/pages/more/more.dart'; +import 'package:selfprivacy/ui/pages/onboarding/onboarding.dart'; +import 'package:selfprivacy/ui/pages/providers/providers.dart'; +import 'package:selfprivacy/ui/pages/recovery_key/recovery_key.dart'; +import 'package:selfprivacy/ui/pages/root_route.dart'; +import 'package:selfprivacy/ui/pages/server_details/server_details_screen.dart'; +import 'package:selfprivacy/ui/pages/server_storage/binds_migration/services_migration.dart'; +import 'package:selfprivacy/ui/pages/server_storage/extending_volume.dart'; +import 'package:selfprivacy/ui/pages/server_storage/server_storage.dart'; +import 'package:selfprivacy/ui/pages/services/service_page.dart'; +import 'package:selfprivacy/ui/pages/services/services.dart'; +import 'package:selfprivacy/ui/pages/setup/initializing/initializing.dart'; +import 'package:selfprivacy/ui/pages/setup/recovering/recovery_routing.dart'; +import 'package:selfprivacy/ui/pages/users/users.dart'; + +part 'router.gr.dart'; + +Widget fadeThroughTransition( + final BuildContext context, + final Animation animation, + final Animation secondaryAnimation, + final Widget child, +) => + SharedAxisTransition( + key: UniqueKey(), + animation: animation, + secondaryAnimation: secondaryAnimation, + transitionType: SharedAxisTransitionType.vertical, + child: child, + ); + +@AutoRouterConfig( + // transitionsBuilder: fadeThroughTransition, + replaceInRouteName: 'Page|Screen|Routing,Route', +) +class RootRouter extends _$RootRouter { + RootRouter(GlobalKey super.navigatorKey); + + @override + RouteType get defaultRouteType => const RouteType.material(); + @override + final List routes = [ + AutoRoute(page: OnboardingRoute.page), + AutoRoute(page: InitializingRoute.page), + AutoRoute(page: RecoveryRoute.page), + AutoRoute( + page: RootRoute.page, + path: '/', + children: [ + CustomRoute( + page: ProvidersRoute.page, + usesPathAsKey: true, + path: '', + transitionsBuilder: fadeThroughTransition, + durationInMilliseconds: 400, + ), + CustomRoute( + page: ServicesRoute.page, + usesPathAsKey: true, + transitionsBuilder: fadeThroughTransition, + durationInMilliseconds: 400, + ), + CustomRoute( + page: UsersRoute.page, + usesPathAsKey: true, + transitionsBuilder: fadeThroughTransition, + durationInMilliseconds: 400, + ), + CustomRoute( + page: MoreRoute.page, + usesPathAsKey: true, + transitionsBuilder: fadeThroughTransition, + durationInMilliseconds: 400, + ), + AutoRoute(page: AppSettingsRoute.page), + AutoRoute(page: UserDetailsRoute.page), + AutoRoute(page: NewUserRoute.page), + AutoRoute(page: RecoveryKeyRoute.page), + AutoRoute(page: DevicesRoute.page), + AutoRoute(page: AboutApplicationRoute.page), + AutoRoute(page: DeveloperSettingsRoute.page), + AutoRoute(page: ServiceRoute.page), + AutoRoute(page: ServerDetailsRoute.page), + AutoRoute(page: DnsDetailsRoute.page), + AutoRoute(page: BackupDetailsRoute.page), + AutoRoute(page: ServerStorageRoute.page), + AutoRoute(page: ExtendingVolumeRoute.page), + ], + ), + AutoRoute(page: ServicesMigrationRoute.page), + AutoRoute(page: ConsoleRoute.page), + ]; +} + +// Function to map route names to route titles +String getRouteTitle(final String routeName) { + switch (routeName) { + case 'RootRoute': + return 'basis.app_name'; + case 'ProvidersRoute': + return 'basis.providers_title'; + case 'ServicesRoute': + case 'ServiceRoute': + return 'basis.services'; + case 'UsersRoute': + return 'basis.users'; + case 'MoreRoute': + return 'basis.more'; + case 'AppSettingsRoute': + return 'application_settings.title'; + case 'UserDetailsRoute': + return 'users.details_title'; + case 'NewUserRoute': + return 'users.new_user'; + case 'RecoveryKeyRoute': + return 'recovery_key.key_main_header'; + case 'DevicesRoute': + return 'devices.main_screen.header'; + case 'AboutApplicationRoute': + return 'about_us_page.title'; + case 'ConsoleRoute': + return 'console_page.title'; + case 'DeveloperSettingsRoute': + return 'developer_settings.title'; + case 'DnsDetailsRoute': + return 'domain.screen_title'; + case 'ServerDetailsRoute': + return 'server.card_title'; + case 'BackupDetailsRoute': + return 'backup.card_title'; + case 'ServerStorageRoute': + return 'storage.card_title'; + case 'ExtendingVolumeRoute': + return 'storage.extending_volume_title'; + default: + return routeName; + } +} diff --git a/lib/ui/router/router.gr.dart b/lib/ui/router/router.gr.dart new file mode 100644 index 00000000..328c5f76 --- /dev/null +++ b/lib/ui/router/router.gr.dart @@ -0,0 +1,636 @@ +// GENERATED CODE - DO NOT MODIFY BY HAND + +// ************************************************************************** +// AutoRouterGenerator +// ************************************************************************** + +// ignore_for_file: type=lint +// coverage:ignore-file + +part of 'router.dart'; + +abstract class _$RootRouter extends RootStackRouter { + _$RootRouter([GlobalKey? navigatorKey]) : super(navigatorKey); + + @override + final Map pagesMap = { + AboutApplicationRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const AboutApplicationPage(), + ); + }, + AppSettingsRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const AppSettingsPage(), + ); + }, + DeveloperSettingsRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const DeveloperSettingsPage(), + ); + }, + ConsoleRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const ConsolePage(), + ); + }, + MoreRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const MorePage(), + ); + }, + OnboardingRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const OnboardingPage(), + ); + }, + ProvidersRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const ProvidersPage(), + ); + }, + ServerDetailsRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const ServerDetailsScreen(), + ); + }, + ServiceRoute.name: (routeData) { + final args = routeData.argsAs(); + return AutoRoutePage( + routeData: routeData, + child: ServicePage( + serviceId: args.serviceId, + key: args.key, + ), + ); + }, + ServicesRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const ServicesPage(), + ); + }, + UsersRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const UsersPage(), + ); + }, + NewUserRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const NewUserPage(), + ); + }, + UserDetailsRoute.name: (routeData) { + final args = routeData.argsAs(); + return AutoRoutePage( + routeData: routeData, + child: UserDetailsPage( + login: args.login, + key: args.key, + ), + ); + }, + BackupDetailsRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const BackupDetailsPage(), + ); + }, + DnsDetailsRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const DnsDetailsPage(), + ); + }, + RecoveryRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const RecoveryRouting(), + ); + }, + InitializingRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const InitializingPage(), + ); + }, + RecoveryKeyRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const RecoveryKeyPage(), + ); + }, + DevicesRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: const DevicesScreen(), + ); + }, + ServicesMigrationRoute.name: (routeData) { + final args = routeData.argsAs(); + return AutoRoutePage( + routeData: routeData, + child: ServicesMigrationPage( + services: args.services, + diskStatus: args.diskStatus, + isMigration: args.isMigration, + key: args.key, + ), + ); + }, + ExtendingVolumeRoute.name: (routeData) { + final args = routeData.argsAs(); + return AutoRoutePage( + routeData: routeData, + child: ExtendingVolumePage( + diskVolumeToResize: args.diskVolumeToResize, + diskStatus: args.diskStatus, + key: args.key, + ), + ); + }, + ServerStorageRoute.name: (routeData) { + final args = routeData.argsAs(); + return AutoRoutePage( + routeData: routeData, + child: ServerStoragePage( + diskStatus: args.diskStatus, + key: args.key, + ), + ); + }, + RootRoute.name: (routeData) { + return AutoRoutePage( + routeData: routeData, + child: WrappedRoute(child: const RootPage()), + ); + }, + }; +} + +/// generated route for +/// [AboutApplicationPage] +class AboutApplicationRoute extends PageRouteInfo { + const AboutApplicationRoute({List? children}) + : super( + AboutApplicationRoute.name, + initialChildren: children, + ); + + static const String name = 'AboutApplicationRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [AppSettingsPage] +class AppSettingsRoute extends PageRouteInfo { + const AppSettingsRoute({List? children}) + : super( + AppSettingsRoute.name, + initialChildren: children, + ); + + static const String name = 'AppSettingsRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [DeveloperSettingsPage] +class DeveloperSettingsRoute extends PageRouteInfo { + const DeveloperSettingsRoute({List? children}) + : super( + DeveloperSettingsRoute.name, + initialChildren: children, + ); + + static const String name = 'DeveloperSettingsRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [ConsolePage] +class ConsoleRoute extends PageRouteInfo { + const ConsoleRoute({List? children}) + : super( + ConsoleRoute.name, + initialChildren: children, + ); + + static const String name = 'ConsoleRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [MorePage] +class MoreRoute extends PageRouteInfo { + const MoreRoute({List? children}) + : super( + MoreRoute.name, + initialChildren: children, + ); + + static const String name = 'MoreRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [OnboardingPage] +class OnboardingRoute extends PageRouteInfo { + const OnboardingRoute({List? children}) + : super( + OnboardingRoute.name, + initialChildren: children, + ); + + static const String name = 'OnboardingRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [ProvidersPage] +class ProvidersRoute extends PageRouteInfo { + const ProvidersRoute({List? children}) + : super( + ProvidersRoute.name, + initialChildren: children, + ); + + static const String name = 'ProvidersRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [ServerDetailsScreen] +class ServerDetailsRoute extends PageRouteInfo { + const ServerDetailsRoute({List? children}) + : super( + ServerDetailsRoute.name, + initialChildren: children, + ); + + static const String name = 'ServerDetailsRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [ServicePage] +class ServiceRoute extends PageRouteInfo { + ServiceRoute({ + required String serviceId, + Key? key, + List? children, + }) : super( + ServiceRoute.name, + args: ServiceRouteArgs( + serviceId: serviceId, + key: key, + ), + initialChildren: children, + ); + + static const String name = 'ServiceRoute'; + + static const PageInfo page = + PageInfo(name); +} + +class ServiceRouteArgs { + const ServiceRouteArgs({ + required this.serviceId, + this.key, + }); + + final String serviceId; + + final Key? key; + + @override + String toString() { + return 'ServiceRouteArgs{serviceId: $serviceId, key: $key}'; + } +} + +/// generated route for +/// [ServicesPage] +class ServicesRoute extends PageRouteInfo { + const ServicesRoute({List? children}) + : super( + ServicesRoute.name, + initialChildren: children, + ); + + static const String name = 'ServicesRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [UsersPage] +class UsersRoute extends PageRouteInfo { + const UsersRoute({List? children}) + : super( + UsersRoute.name, + initialChildren: children, + ); + + static const String name = 'UsersRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [NewUserPage] +class NewUserRoute extends PageRouteInfo { + const NewUserRoute({List? children}) + : super( + NewUserRoute.name, + initialChildren: children, + ); + + static const String name = 'NewUserRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [UserDetailsPage] +class UserDetailsRoute extends PageRouteInfo { + UserDetailsRoute({ + required String login, + Key? key, + List? children, + }) : super( + UserDetailsRoute.name, + args: UserDetailsRouteArgs( + login: login, + key: key, + ), + initialChildren: children, + ); + + static const String name = 'UserDetailsRoute'; + + static const PageInfo page = + PageInfo(name); +} + +class UserDetailsRouteArgs { + const UserDetailsRouteArgs({ + required this.login, + this.key, + }); + + final String login; + + final Key? key; + + @override + String toString() { + return 'UserDetailsRouteArgs{login: $login, key: $key}'; + } +} + +/// generated route for +/// [BackupDetailsPage] +class BackupDetailsRoute extends PageRouteInfo { + const BackupDetailsRoute({List? children}) + : super( + BackupDetailsRoute.name, + initialChildren: children, + ); + + static const String name = 'BackupDetailsRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [DnsDetailsPage] +class DnsDetailsRoute extends PageRouteInfo { + const DnsDetailsRoute({List? children}) + : super( + DnsDetailsRoute.name, + initialChildren: children, + ); + + static const String name = 'DnsDetailsRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [RecoveryRouting] +class RecoveryRoute extends PageRouteInfo { + const RecoveryRoute({List? children}) + : super( + RecoveryRoute.name, + initialChildren: children, + ); + + static const String name = 'RecoveryRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [InitializingPage] +class InitializingRoute extends PageRouteInfo { + const InitializingRoute({List? children}) + : super( + InitializingRoute.name, + initialChildren: children, + ); + + static const String name = 'InitializingRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [RecoveryKeyPage] +class RecoveryKeyRoute extends PageRouteInfo { + const RecoveryKeyRoute({List? children}) + : super( + RecoveryKeyRoute.name, + initialChildren: children, + ); + + static const String name = 'RecoveryKeyRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [DevicesScreen] +class DevicesRoute extends PageRouteInfo { + const DevicesRoute({List? children}) + : super( + DevicesRoute.name, + initialChildren: children, + ); + + static const String name = 'DevicesRoute'; + + static const PageInfo page = PageInfo(name); +} + +/// generated route for +/// [ServicesMigrationPage] +class ServicesMigrationRoute extends PageRouteInfo { + ServicesMigrationRoute({ + required List services, + required DiskStatus diskStatus, + required bool isMigration, + Key? key, + List? children, + }) : super( + ServicesMigrationRoute.name, + args: ServicesMigrationRouteArgs( + services: services, + diskStatus: diskStatus, + isMigration: isMigration, + key: key, + ), + initialChildren: children, + ); + + static const String name = 'ServicesMigrationRoute'; + + static const PageInfo page = + PageInfo(name); +} + +class ServicesMigrationRouteArgs { + const ServicesMigrationRouteArgs({ + required this.services, + required this.diskStatus, + required this.isMigration, + this.key, + }); + + final List services; + + final DiskStatus diskStatus; + + final bool isMigration; + + final Key? key; + + @override + String toString() { + return 'ServicesMigrationRouteArgs{services: $services, diskStatus: $diskStatus, isMigration: $isMigration, key: $key}'; + } +} + +/// generated route for +/// [ExtendingVolumePage] +class ExtendingVolumeRoute extends PageRouteInfo { + ExtendingVolumeRoute({ + required DiskVolume diskVolumeToResize, + required DiskStatus diskStatus, + Key? key, + List? children, + }) : super( + ExtendingVolumeRoute.name, + args: ExtendingVolumeRouteArgs( + diskVolumeToResize: diskVolumeToResize, + diskStatus: diskStatus, + key: key, + ), + initialChildren: children, + ); + + static const String name = 'ExtendingVolumeRoute'; + + static const PageInfo page = + PageInfo(name); +} + +class ExtendingVolumeRouteArgs { + const ExtendingVolumeRouteArgs({ + required this.diskVolumeToResize, + required this.diskStatus, + this.key, + }); + + final DiskVolume diskVolumeToResize; + + final DiskStatus diskStatus; + + final Key? key; + + @override + String toString() { + return 'ExtendingVolumeRouteArgs{diskVolumeToResize: $diskVolumeToResize, diskStatus: $diskStatus, key: $key}'; + } +} + +/// generated route for +/// [ServerStoragePage] +class ServerStorageRoute extends PageRouteInfo { + ServerStorageRoute({ + required DiskStatus diskStatus, + Key? key, + List? children, + }) : super( + ServerStorageRoute.name, + args: ServerStorageRouteArgs( + diskStatus: diskStatus, + key: key, + ), + initialChildren: children, + ); + + static const String name = 'ServerStorageRoute'; + + static const PageInfo page = + PageInfo(name); +} + +class ServerStorageRouteArgs { + const ServerStorageRouteArgs({ + required this.diskStatus, + this.key, + }); + + final DiskStatus diskStatus; + + final Key? key; + + @override + String toString() { + return 'ServerStorageRouteArgs{diskStatus: $diskStatus, key: $key}'; + } +} + +/// generated route for +/// [RootPage] +class RootRoute extends PageRouteInfo { + const RootRoute({List? children}) + : super( + RootRoute.name, + initialChildren: children, + ); + + static const String name = 'RootRoute'; + + static const PageInfo page = PageInfo(name); +} diff --git a/lib/utils/breakpoints.dart b/lib/utils/breakpoints.dart new file mode 100644 index 00000000..0e9104e2 --- /dev/null +++ b/lib/utils/breakpoints.dart @@ -0,0 +1,131 @@ +// Copyright 2013 The Flutter Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +import 'package:flutter/material.dart'; + +const Set _desktop = { + TargetPlatform.linux, + TargetPlatform.macOS, + TargetPlatform.windows +}; + +const Set _mobile = { + TargetPlatform.android, + TargetPlatform.fuchsia, + TargetPlatform.iOS, +}; + +/// A group of standard breakpoints built according to the material +/// specifications for screen width size. +/// +/// See also: +/// +/// * [AdaptiveScaffold], which uses some of these Breakpoints as defaults. +class Breakpoints { + /// This is a standard breakpoint that can be used as a fallthrough in the + /// case that no other breakpoint is active. + /// + /// It is active from a width of -1 dp to infinity. + static const Breakpoint standard = WidthPlatformBreakpoint(begin: -1); + + /// A window whose width is less than 600 dp and greater than 0 dp. + static const Breakpoint small = WidthPlatformBreakpoint(begin: 0, end: 600); + + /// A window whose width is greater than 0 dp. + static const Breakpoint smallAndUp = WidthPlatformBreakpoint(begin: 0); + + /// A desktop screen whose width is less than 600 dp and greater than 0 dp. + static const Breakpoint smallDesktop = + WidthPlatformBreakpoint(begin: 0, end: 600, platform: _desktop); + + /// A mobile screen whose width is less than 600 dp and greater than 0 dp. + static const Breakpoint smallMobile = + WidthPlatformBreakpoint(begin: 0, end: 600, platform: _mobile); + + /// A window whose width is between 600 dp and 840 dp. + static const Breakpoint medium = + WidthPlatformBreakpoint(begin: 600, end: 840); + + /// A window whose width is greater than 600 dp. + static const Breakpoint mediumAndUp = WidthPlatformBreakpoint(begin: 600); + + /// A desktop window whose width is between 600 dp and 840 dp. + static const Breakpoint mediumDesktop = + WidthPlatformBreakpoint(begin: 600, end: 840, platform: _desktop); + + /// A mobile window whose width is between 600 dp and 840 dp. + static const Breakpoint mediumMobile = + WidthPlatformBreakpoint(begin: 600, end: 840, platform: _mobile); + + /// A window whose width is greater than 840 dp. + static const Breakpoint large = WidthPlatformBreakpoint(begin: 840); + + /// A desktop window whose width is greater than 840 dp. + static const Breakpoint largeDesktop = + WidthPlatformBreakpoint(begin: 840, platform: _desktop); + + /// A mobile window whose width is greater than 840 dp. + static const Breakpoint largeMobile = + WidthPlatformBreakpoint(begin: 840, platform: _mobile); +} + +/// A class that can be used to quickly generate [Breakpoint]s that depend on +/// the screen width and the platform. +class WidthPlatformBreakpoint extends Breakpoint { + /// Returns a const [Breakpoint] with the given constraints. + const WidthPlatformBreakpoint({this.begin, this.end, this.platform}); + + /// The beginning width dp value. If left null then the [Breakpoint] will have + /// no lower bound. + final double? begin; + + /// The end width dp value. If left null then the [Breakpoint] will have no + /// upper bound. + final double? end; + + /// A Set of [TargetPlatform]s that the [Breakpoint] will be active on. If + /// left null then it will be active on all platforms. + final Set? platform; + + @override + bool isActive(final BuildContext context) { + final TargetPlatform host = Theme.of(context).platform; + final bool isRightPlatform = platform?.contains(host) ?? true; + + // Null boundaries are unbounded, assign the max/min of their associated + // direction on a number line. + final double width = MediaQuery.of(context).size.width; + final double lowerBound = begin ?? double.negativeInfinity; + final double upperBound = end ?? double.infinity; + + return width >= lowerBound && width < upperBound && isRightPlatform; + } +} + +/// An interface to define the conditions that distinguish between types of +/// screens. +/// +/// Adaptive apps usually display differently depending on the screen type: a +/// compact layout for smaller screens, or a relaxed layout for larger screens. +/// Override this class by defining `isActive` to fetch the screen property +/// (usually `MediaQuery.of`) and return true if the condition is met. +/// +/// Breakpoints do not need to be exclusive because they are tested in order +/// with the last Breakpoint active taking priority. +/// +/// If the condition is only based on the screen width and/or the device type, +/// use [WidthPlatformBreakpoint] to define the [Breakpoint]. +/// +/// See also: +/// +/// * [SlotLayout.config], which uses breakpoints to dictate the layout of the +/// screen. +abstract class Breakpoint { + /// Returns a const [Breakpoint]. + const Breakpoint(); + + /// A method that returns true based on conditions related to the context of + /// the screen such as MediaQuery.of(context).size.width. + bool isActive(final BuildContext context); +} diff --git a/lib/utils/extensions/text_extensions.dart b/lib/utils/extensions/text_extensions.dart index bfacc600..a00f7096 100644 --- a/lib/utils/extensions/text_extensions.dart +++ b/lib/utils/extensions/text_extensions.dart @@ -1,4 +1,4 @@ -import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; extension TextExtension on Text { Text withColor(final Color color) => Text( diff --git a/macos/Flutter/GeneratedPluginRegistrant.swift b/macos/Flutter/GeneratedPluginRegistrant.swift index b3e22002..6140a508 100644 --- a/macos/Flutter/GeneratedPluginRegistrant.swift +++ b/macos/Flutter/GeneratedPluginRegistrant.swift @@ -11,7 +11,6 @@ import dynamic_color import flutter_secure_storage_macos import package_info import path_provider_foundation -import share_plus import shared_preferences_foundation import url_launcher_macos import wakelock_macos @@ -23,7 +22,6 @@ func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { FlutterSecureStoragePlugin.register(with: registry.registrar(forPlugin: "FlutterSecureStoragePlugin")) FLTPackageInfoPlugin.register(with: registry.registrar(forPlugin: "FLTPackageInfoPlugin")) PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) - SharePlusMacosPlugin.register(with: registry.registrar(forPlugin: "SharePlusMacosPlugin")) SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) UrlLauncherPlugin.register(with: registry.registrar(forPlugin: "UrlLauncherPlugin")) WakelockMacosPlugin.register(with: registry.registrar(forPlugin: "WakelockMacosPlugin")) diff --git a/pubspec.lock b/pubspec.lock index 4ffd3c72..61417bab 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -17,6 +17,14 @@ packages: url: "https://pub.dev" source: hosted version: "5.4.0" + animations: + dependency: "direct main" + description: + name: animations + sha256: fe8a6bdca435f718bb1dc8a11661b2c22504c6da40ef934cee8327ed77934164 + url: "https://pub.dev" + source: hosted + version: "2.0.7" archive: dependency: transitive description: @@ -41,6 +49,22 @@ packages: url: "https://pub.dev" source: hosted version: "2.10.0" + auto_route: + dependency: "direct main" + description: + name: auto_route + sha256: "70b2461cc58d6a46c20859f23148b370165da183d21a82b783156f9a91d9c38b" + url: "https://pub.dev" + source: hosted + version: "6.0.1" + auto_route_generator: + dependency: "direct dev" + description: + name: auto_route_generator + sha256: a3f11c3b1e6e884d1592924f3b7212855f1c7c8791c12d3b41b87ab81fb9d3b8 + url: "https://pub.dev" + source: hosted + version: "6.0.0" auto_size_text: dependency: "direct main" description: @@ -209,14 +233,6 @@ packages: url: "https://pub.dev" source: hosted version: "1.6.2" - cross_file: - dependency: transitive - description: - name: cross_file - sha256: "0b0036e8cccbfbe0555fd83c1d31a6f30b77a96b598b35a5d36dd41f718695e9" - url: "https://pub.dev" - source: hosted - version: "0.3.3+4" crypt: dependency: "direct main" description: @@ -245,10 +261,10 @@ packages: dependency: transitive description: name: dart_style - sha256: "7a03456c3490394c8e7665890333e91ae8a49be43542b616e414449ac358acd4" + sha256: "5be16bf1707658e4c03078d4a9b90208ded217fb02c163e207d334082412f2fb" url: "https://pub.dev" source: hosted - version: "2.2.4" + version: "2.2.5" dbus: dependency: transitive description: @@ -1045,22 +1061,6 @@ packages: url: "https://pub.dev" source: hosted version: "0.27.7" - share_plus: - dependency: "direct main" - description: - name: share_plus - sha256: e387077716f80609bb979cd199331033326033ecd1c8f200a90c5f57b1c9f55e - url: "https://pub.dev" - source: hosted - version: "6.3.0" - share_plus_platform_interface: - dependency: transitive - description: - name: share_plus_platform_interface - sha256: "82ddd4ab9260c295e6e39612d4ff00390b9a7a21f1bb1da771e2f232d80ab8a1" - url: "https://pub.dev" - source: hosted - version: "3.2.0" shared_preferences: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index 407089e8..2055494c 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -8,6 +8,8 @@ environment: flutter: ">=3.7.0" dependencies: + animations: ^2.0.7 + auto_route: ^6.0.1 auto_size_text: ^3.0.0 basic_utils: ^5.4.2 crypt: ^4.2.1 @@ -44,12 +46,12 @@ dependencies: pretty_dio_logger: ^1.2.0-beta-1 provider: ^6.0.5 pub_semver: ^2.1.3 - share_plus: ^6.3.0 timezone: ^0.9.1 url_launcher: ^6.1.8 wakelock: ^0.6.2 dev_dependencies: + auto_route_generator: ^6.0.0 flutter_test: sdk: flutter build_runner: ^2.3.3 diff --git a/shell.nix b/shell.nix new file mode 100644 index 00000000..f7cbc91a --- /dev/null +++ b/shell.nix @@ -0,0 +1,35 @@ +with (import { }); + +mkShell { + buildInputs = [ + at-spi2-core.dev + clang + cmake + dart + dbus.dev + flutter + gtk3 + libdatrie + libepoxy.dev + libselinux + libsepol + libthai + libxkbcommon + libsecret + ninja + pcre + pkg-config + util-linux.dev + xorg.libXdmcp + xorg.libXtst + xorg.libX11 + + glib + jsoncpp + libgcrypt + libgpg-error + ]; + shellHook = '' + export LD_LIBRARY_PATH=${libepoxy}/lib + ''; +} diff --git a/windows/flutter/generated_plugin_registrant.cc b/windows/flutter/generated_plugin_registrant.cc index 2d280636..4ff4b899 100644 --- a/windows/flutter/generated_plugin_registrant.cc +++ b/windows/flutter/generated_plugin_registrant.cc @@ -10,7 +10,6 @@ #include #include #include -#include #include void RegisterPlugins(flutter::PluginRegistry* registry) { @@ -22,8 +21,6 @@ void RegisterPlugins(flutter::PluginRegistry* registry) { registry->GetRegistrarForPlugin("FlutterSecureStorageWindowsPlugin")); LocalAuthPluginRegisterWithRegistrar( registry->GetRegistrarForPlugin("LocalAuthPlugin")); - SharePlusWindowsPluginCApiRegisterWithRegistrar( - registry->GetRegistrarForPlugin("SharePlusWindowsPluginCApi")); UrlLauncherWindowsRegisterWithRegistrar( registry->GetRegistrarForPlugin("UrlLauncherWindows")); } diff --git a/windows/flutter/generated_plugins.cmake b/windows/flutter/generated_plugins.cmake index b4df792f..ae5ef358 100644 --- a/windows/flutter/generated_plugins.cmake +++ b/windows/flutter/generated_plugins.cmake @@ -7,7 +7,6 @@ list(APPEND FLUTTER_PLUGIN_LIST dynamic_color flutter_secure_storage_windows local_auth_windows - share_plus url_launcher_windows )