Merge pull request 'feat: Implement dynamic DNS records validation' (#392) from dynamic-dns into master
continuous-integration/drone/push Build is passing Details

Reviewed-on: #392
Reviewed-by: Inex Code <inex.code@selfprivacy.org>
pull/419/head
Inex Code 2024-01-10 14:52:16 +02:00
commit 16dca8faf8
34 changed files with 1384 additions and 1191 deletions

View File

@ -179,6 +179,7 @@ class _CopyWithImpl$Fragment$genericBackupConfigReturn<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Fragment$genericBackupConfigReturn$configuration<TRes>
get configuration {
final local$configuration = _instance.configuration;
@ -204,6 +205,7 @@ class _CopyWithStubImpl$Fragment$genericBackupConfigReturn<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Fragment$genericBackupConfigReturn$configuration<TRes>
get configuration =>
CopyWith$Fragment$genericBackupConfigReturn$configuration.stub(_res);
@ -633,6 +635,7 @@ class _CopyWithImpl$Fragment$genericBackupConfigReturn$configuration<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Fragment$genericBackupConfigReturn$configuration$autobackupQuotas<
TRes> get autobackupQuotas {
final local$autobackupQuotas = _instance.autobackupQuotas;
@ -659,6 +662,7 @@ class _CopyWithStubImpl$Fragment$genericBackupConfigReturn$configuration<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Fragment$genericBackupConfigReturn$configuration$autobackupQuotas<
TRes>
get autobackupQuotas =>
@ -999,6 +1003,7 @@ class _CopyWithImpl$Query$BackupConfiguration<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$BackupConfiguration$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Query$BackupConfiguration$backup(
@ -1017,6 +1022,7 @@ class _CopyWithStubImpl$Query$BackupConfiguration<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$BackupConfiguration$backup<TRes> get backup =>
CopyWith$Query$BackupConfiguration$backup.stub(_res);
}
@ -1399,6 +1405,7 @@ class _CopyWithImpl$Query$BackupConfiguration$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$BackupConfiguration$backup$configuration<TRes>
get configuration {
final local$configuration = _instance.configuration;
@ -1418,6 +1425,7 @@ class _CopyWithStubImpl$Query$BackupConfiguration$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$BackupConfiguration$backup$configuration<TRes>
get configuration =>
CopyWith$Query$BackupConfiguration$backup$configuration.stub(_res);
@ -1658,6 +1666,7 @@ class _CopyWithImpl$Query$BackupConfiguration$backup$configuration<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$BackupConfiguration$backup$configuration$autobackupQuotas<TRes>
get autobackupQuotas {
final local$autobackupQuotas = _instance.autobackupQuotas;
@ -1684,6 +1693,7 @@ class _CopyWithStubImpl$Query$BackupConfiguration$backup$configuration<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$BackupConfiguration$backup$configuration$autobackupQuotas<TRes>
get autobackupQuotas =>
CopyWith$Query$BackupConfiguration$backup$configuration$autobackupQuotas
@ -2023,6 +2033,7 @@ class _CopyWithImpl$Query$AllBackupSnapshots<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$AllBackupSnapshots$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Query$AllBackupSnapshots$backup(
@ -2041,6 +2052,7 @@ class _CopyWithStubImpl$Query$AllBackupSnapshots<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$AllBackupSnapshots$backup<TRes> get backup =>
CopyWith$Query$AllBackupSnapshots$backup.stub(_res);
}
@ -2396,6 +2408,7 @@ class _CopyWithImpl$Query$AllBackupSnapshots$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes allSnapshots(
Iterable<Query$AllBackupSnapshots$backup$allSnapshots> Function(
Iterable<
@ -2421,6 +2434,7 @@ class _CopyWithStubImpl$Query$AllBackupSnapshots$backup<TRes>
String? $__typename,
}) =>
_res;
allSnapshots(_fn) => _res;
}
@ -2594,6 +2608,7 @@ class _CopyWithImpl$Query$AllBackupSnapshots$backup$allSnapshots<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$AllBackupSnapshots$backup$allSnapshots$service<TRes>
get service {
final local$service = _instance.service;
@ -2616,6 +2631,7 @@ class _CopyWithStubImpl$Query$AllBackupSnapshots$backup$allSnapshots<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$AllBackupSnapshots$backup$allSnapshots$service<TRes>
get service =>
CopyWith$Query$AllBackupSnapshots$backup$allSnapshots$service.stub(
@ -2887,6 +2903,7 @@ class _CopyWithImpl$Mutation$ForceSnapshotsReload<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$ForceSnapshotsReload$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Mutation$ForceSnapshotsReload$backup(
@ -2905,6 +2922,7 @@ class _CopyWithStubImpl$Mutation$ForceSnapshotsReload<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$ForceSnapshotsReload$backup<TRes> get backup =>
CopyWith$Mutation$ForceSnapshotsReload$backup.stub(_res);
}
@ -3180,6 +3198,7 @@ class _CopyWithImpl$Mutation$ForceSnapshotsReload$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$ForceSnapshotsReload$backup$forceSnapshotsReload<TRes>
get forceSnapshotsReload {
final local$forceSnapshotsReload = _instance.forceSnapshotsReload;
@ -3200,6 +3219,7 @@ class _CopyWithStubImpl$Mutation$ForceSnapshotsReload$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$ForceSnapshotsReload$backup$forceSnapshotsReload<TRes>
get forceSnapshotsReload =>
CopyWith$Mutation$ForceSnapshotsReload$backup$forceSnapshotsReload
@ -3403,6 +3423,7 @@ class Variables$Mutation$StartBackup {
Map<String, dynamic> _$data;
String get serviceId => (_$data['serviceId'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$serviceId = serviceId;
@ -3415,6 +3436,7 @@ class Variables$Mutation$StartBackup {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -3591,6 +3613,7 @@ class _CopyWithImpl$Mutation$StartBackup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$StartBackup$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Mutation$StartBackup$backup(
@ -3609,6 +3632,7 @@ class _CopyWithStubImpl$Mutation$StartBackup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$StartBackup$backup<TRes> get backup =>
CopyWith$Mutation$StartBackup$backup.stub(_res);
}
@ -3907,6 +3931,7 @@ class _CopyWithImpl$Mutation$StartBackup$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$StartBackup$backup$startBackup<TRes> get startBackup {
final local$startBackup = _instance.startBackup;
return CopyWith$Mutation$StartBackup$backup$startBackup(
@ -3925,6 +3950,7 @@ class _CopyWithStubImpl$Mutation$StartBackup$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$StartBackup$backup$startBackup<TRes> get startBackup =>
CopyWith$Mutation$StartBackup$backup$startBackup.stub(_res);
}
@ -4102,6 +4128,7 @@ class _CopyWithImpl$Mutation$StartBackup$backup$startBackup<TRes>
? _instance.job
: (job as Fragment$basicApiJobsFields?),
));
CopyWith$Fragment$basicApiJobsFields<TRes> get job {
final local$job = _instance.job;
return local$job == null
@ -4124,6 +4151,7 @@ class _CopyWithStubImpl$Mutation$StartBackup$backup$startBackup<TRes>
Fragment$basicApiJobsFields? job,
}) =>
_res;
CopyWith$Fragment$basicApiJobsFields<TRes> get job =>
CopyWith$Fragment$basicApiJobsFields.stub(_res);
}
@ -4149,6 +4177,7 @@ class Variables$Mutation$SetAutobackupPeriod {
Map<String, dynamic> _$data;
int? get period => (_$data['period'] as int?);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
if (_$data.containsKey('period')) {
@ -4164,6 +4193,7 @@ class Variables$Mutation$SetAutobackupPeriod {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -4344,6 +4374,7 @@ class _CopyWithImpl$Mutation$SetAutobackupPeriod<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$SetAutobackupPeriod$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Mutation$SetAutobackupPeriod$backup(
@ -4362,6 +4393,7 @@ class _CopyWithStubImpl$Mutation$SetAutobackupPeriod<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$SetAutobackupPeriod$backup<TRes> get backup =>
CopyWith$Mutation$SetAutobackupPeriod$backup.stub(_res);
}
@ -4650,6 +4682,7 @@ class _CopyWithImpl$Mutation$SetAutobackupPeriod$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Fragment$genericBackupConfigReturn<TRes> get setAutobackupPeriod {
final local$setAutobackupPeriod = _instance.setAutobackupPeriod;
return CopyWith$Fragment$genericBackupConfigReturn(
@ -4668,6 +4701,7 @@ class _CopyWithStubImpl$Mutation$SetAutobackupPeriod$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Fragment$genericBackupConfigReturn<TRes> get setAutobackupPeriod =>
CopyWith$Fragment$genericBackupConfigReturn.stub(_res);
}
@ -4694,6 +4728,7 @@ class Variables$Mutation$setAutobackupQuotas {
Input$AutobackupQuotasInput get quotas =>
(_$data['quotas'] as Input$AutobackupQuotasInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$quotas = quotas;
@ -4707,6 +4742,7 @@ class Variables$Mutation$setAutobackupQuotas {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -4885,6 +4921,7 @@ class _CopyWithImpl$Mutation$setAutobackupQuotas<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$setAutobackupQuotas$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Mutation$setAutobackupQuotas$backup(
@ -4903,6 +4940,7 @@ class _CopyWithStubImpl$Mutation$setAutobackupQuotas<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$setAutobackupQuotas$backup<TRes> get backup =>
CopyWith$Mutation$setAutobackupQuotas$backup.stub(_res);
}
@ -5190,6 +5228,7 @@ class _CopyWithImpl$Mutation$setAutobackupQuotas$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Fragment$genericBackupConfigReturn<TRes> get setAutobackupQuotas {
final local$setAutobackupQuotas = _instance.setAutobackupQuotas;
return CopyWith$Fragment$genericBackupConfigReturn(
@ -5208,6 +5247,7 @@ class _CopyWithStubImpl$Mutation$setAutobackupQuotas$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Fragment$genericBackupConfigReturn<TRes> get setAutobackupQuotas =>
CopyWith$Fragment$genericBackupConfigReturn.stub(_res);
}
@ -5324,6 +5364,7 @@ class _CopyWithImpl$Mutation$RemoveRepository<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RemoveRepository$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Mutation$RemoveRepository$backup(
@ -5342,6 +5383,7 @@ class _CopyWithStubImpl$Mutation$RemoveRepository<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RemoveRepository$backup<TRes> get backup =>
CopyWith$Mutation$RemoveRepository$backup.stub(_res);
}
@ -5606,6 +5648,7 @@ class _CopyWithImpl$Mutation$RemoveRepository$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Fragment$genericBackupConfigReturn<TRes> get removeRepository {
final local$removeRepository = _instance.removeRepository;
return CopyWith$Fragment$genericBackupConfigReturn(
@ -5624,6 +5667,7 @@ class _CopyWithStubImpl$Mutation$RemoveRepository$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Fragment$genericBackupConfigReturn<TRes> get removeRepository =>
CopyWith$Fragment$genericBackupConfigReturn.stub(_res);
}
@ -5650,6 +5694,7 @@ class Variables$Mutation$InitializeRepository {
Input$InitializeRepositoryInput get repository =>
(_$data['repository'] as Input$InitializeRepositoryInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$repository = repository;
@ -5663,6 +5708,7 @@ class Variables$Mutation$InitializeRepository {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -5841,6 +5887,7 @@ class _CopyWithImpl$Mutation$InitializeRepository<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$InitializeRepository$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Mutation$InitializeRepository$backup(
@ -5859,6 +5906,7 @@ class _CopyWithStubImpl$Mutation$InitializeRepository<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$InitializeRepository$backup<TRes> get backup =>
CopyWith$Mutation$InitializeRepository$backup.stub(_res);
}
@ -6147,6 +6195,7 @@ class _CopyWithImpl$Mutation$InitializeRepository$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Fragment$genericBackupConfigReturn<TRes> get initializeRepository {
final local$initializeRepository = _instance.initializeRepository;
return CopyWith$Fragment$genericBackupConfigReturn(
@ -6165,6 +6214,7 @@ class _CopyWithStubImpl$Mutation$InitializeRepository$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Fragment$genericBackupConfigReturn<TRes> get initializeRepository =>
CopyWith$Fragment$genericBackupConfigReturn.stub(_res);
}
@ -6172,11 +6222,11 @@ class _CopyWithStubImpl$Mutation$InitializeRepository$backup<TRes>
class Variables$Mutation$RestoreBackup {
factory Variables$Mutation$RestoreBackup({
required String snapshotId,
required Enum$RestoreStrategy strategy,
Enum$RestoreStrategy? strategy,
}) =>
Variables$Mutation$RestoreBackup._({
r'snapshotId': snapshotId,
r'strategy': strategy,
if (strategy != null) r'strategy': strategy,
});
Variables$Mutation$RestoreBackup._(this._$data);
@ -6185,23 +6235,30 @@ class Variables$Mutation$RestoreBackup {
final result$data = <String, dynamic>{};
final l$snapshotId = data['snapshotId'];
result$data['snapshotId'] = (l$snapshotId as String);
final l$strategy = data['strategy'];
result$data['strategy'] =
fromJson$Enum$RestoreStrategy((l$strategy as String));
if (data.containsKey('strategy')) {
final l$strategy = data['strategy'];
result$data['strategy'] =
fromJson$Enum$RestoreStrategy((l$strategy as String));
}
return Variables$Mutation$RestoreBackup._(result$data);
}
Map<String, dynamic> _$data;
String get snapshotId => (_$data['snapshotId'] as String);
Enum$RestoreStrategy get strategy =>
(_$data['strategy'] as Enum$RestoreStrategy);
Enum$RestoreStrategy? get strategy =>
(_$data['strategy'] as Enum$RestoreStrategy?);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$snapshotId = snapshotId;
result$data['snapshotId'] = l$snapshotId;
final l$strategy = strategy;
result$data['strategy'] = toJson$Enum$RestoreStrategy(l$strategy);
if (_$data.containsKey('strategy')) {
final l$strategy = strategy;
result$data['strategy'] =
toJson$Enum$RestoreStrategy((l$strategy as Enum$RestoreStrategy));
}
return result$data;
}
@ -6210,6 +6267,7 @@ class Variables$Mutation$RestoreBackup {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -6226,6 +6284,10 @@ class Variables$Mutation$RestoreBackup {
}
final l$strategy = strategy;
final lOther$strategy = other.strategy;
if (_$data.containsKey('strategy') !=
other._$data.containsKey('strategy')) {
return false;
}
if (l$strategy != lOther$strategy) {
return false;
}
@ -6238,7 +6300,7 @@ class Variables$Mutation$RestoreBackup {
final l$strategy = strategy;
return Object.hashAll([
l$snapshotId,
l$strategy,
_$data.containsKey('strategy') ? l$strategy : const {},
]);
}
}
@ -6408,6 +6470,7 @@ class _CopyWithImpl$Mutation$RestoreBackup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RestoreBackup$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Mutation$RestoreBackup$backup(
@ -6426,6 +6489,7 @@ class _CopyWithStubImpl$Mutation$RestoreBackup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RestoreBackup$backup<TRes> get backup =>
CopyWith$Mutation$RestoreBackup$backup.stub(_res);
}
@ -6741,6 +6805,7 @@ class _CopyWithImpl$Mutation$RestoreBackup$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RestoreBackup$backup$restoreBackup<TRes> get restoreBackup {
final local$restoreBackup = _instance.restoreBackup;
return CopyWith$Mutation$RestoreBackup$backup$restoreBackup(
@ -6759,6 +6824,7 @@ class _CopyWithStubImpl$Mutation$RestoreBackup$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RestoreBackup$backup$restoreBackup<TRes>
get restoreBackup =>
CopyWith$Mutation$RestoreBackup$backup$restoreBackup.stub(_res);
@ -6937,6 +7003,7 @@ class _CopyWithImpl$Mutation$RestoreBackup$backup$restoreBackup<TRes>
? _instance.job
: (job as Fragment$basicApiJobsFields?),
));
CopyWith$Fragment$basicApiJobsFields<TRes> get job {
final local$job = _instance.job;
return local$job == null
@ -6959,6 +7026,7 @@ class _CopyWithStubImpl$Mutation$RestoreBackup$backup$restoreBackup<TRes>
Fragment$basicApiJobsFields? job,
}) =>
_res;
CopyWith$Fragment$basicApiJobsFields<TRes> get job =>
CopyWith$Fragment$basicApiJobsFields.stub(_res);
}
@ -6982,6 +7050,7 @@ class Variables$Mutation$ForgetSnapshot {
Map<String, dynamic> _$data;
String get snapshotId => (_$data['snapshotId'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$snapshotId = snapshotId;
@ -6994,6 +7063,7 @@ class Variables$Mutation$ForgetSnapshot {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -7171,6 +7241,7 @@ class _CopyWithImpl$Mutation$ForgetSnapshot<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$ForgetSnapshot$backup<TRes> get backup {
final local$backup = _instance.backup;
return CopyWith$Mutation$ForgetSnapshot$backup(
@ -7189,6 +7260,7 @@ class _CopyWithStubImpl$Mutation$ForgetSnapshot<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$ForgetSnapshot$backup<TRes> get backup =>
CopyWith$Mutation$ForgetSnapshot$backup.stub(_res);
}
@ -7470,6 +7542,7 @@ class _CopyWithImpl$Mutation$ForgetSnapshot$backup<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$ForgetSnapshot$backup$forgetSnapshot<TRes>
get forgetSnapshot {
final local$forgetSnapshot = _instance.forgetSnapshot;
@ -7489,6 +7562,7 @@ class _CopyWithStubImpl$Mutation$ForgetSnapshot$backup<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$ForgetSnapshot$backup$forgetSnapshot<TRes>
get forgetSnapshot =>
CopyWith$Mutation$ForgetSnapshot$backup$forgetSnapshot.stub(_res);

View File

@ -116,6 +116,7 @@ class _CopyWithImpl$Query$GetServerDiskVolumes<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$GetServerDiskVolumes$storage<TRes> get storage {
final local$storage = _instance.storage;
return CopyWith$Query$GetServerDiskVolumes$storage(
@ -134,6 +135,7 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$GetServerDiskVolumes$storage<TRes> get storage =>
CopyWith$Query$GetServerDiskVolumes$storage.stub(_res);
}
@ -577,6 +579,7 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes volumes(
Iterable<Query$GetServerDiskVolumes$storage$volumes> Function(
Iterable<
@ -602,6 +605,7 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage<TRes>
String? $__typename,
}) =>
_res;
volumes(_fn) => _res;
}
@ -883,6 +887,7 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes usages(
Iterable<Query$GetServerDiskVolumes$storage$volumes$usages> Function(
Iterable<
@ -916,6 +921,7 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes<TRes>
String? $__typename,
}) =>
_res;
usages(_fn) => _res;
}
@ -1287,6 +1293,7 @@ class _CopyWithImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceSt
? _instance.usedSpace
: (usedSpace as String),
));
CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service<
TRes> get service {
final local$service = _instance.service;
@ -1316,6 +1323,7 @@ class _CopyWithStubImpl$Query$GetServerDiskVolumes$storage$volumes$usages$$Servi
String? usedSpace,
}) =>
_res;
CopyWith$Query$GetServerDiskVolumes$storage$volumes$usages$$ServiceStorageUsage$service<
TRes>
get service =>
@ -1524,6 +1532,7 @@ class Variables$Mutation$MountVolume {
Map<String, dynamic> _$data;
String get name => (_$data['name'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$name = name;
@ -1536,6 +1545,7 @@ class Variables$Mutation$MountVolume {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -1617,6 +1627,7 @@ class Mutation$MountVolume {
);
}
@Deprecated('Use `storage.mount_volume` instead')
final Mutation$MountVolume$mountVolume mountVolume;
final String $__typename;
@ -1711,6 +1722,7 @@ class _CopyWithImpl$Mutation$MountVolume<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$MountVolume$mountVolume<TRes> get mountVolume {
final local$mountVolume = _instance.mountVolume;
return CopyWith$Mutation$MountVolume$mountVolume(
@ -1729,6 +1741,7 @@ class _CopyWithStubImpl$Mutation$MountVolume<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$MountVolume$mountVolume<TRes> get mountVolume =>
CopyWith$Mutation$MountVolume$mountVolume.stub(_res);
}
@ -2063,6 +2076,7 @@ class Variables$Mutation$ResizeVolume {
Map<String, dynamic> _$data;
String get name => (_$data['name'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$name = name;
@ -2075,6 +2089,7 @@ class Variables$Mutation$ResizeVolume {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -2156,6 +2171,7 @@ class Mutation$ResizeVolume {
);
}
@Deprecated('Use `storage.resize_volume` instead')
final Mutation$ResizeVolume$resizeVolume resizeVolume;
final String $__typename;
@ -2250,6 +2266,7 @@ class _CopyWithImpl$Mutation$ResizeVolume<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$ResizeVolume$resizeVolume<TRes> get resizeVolume {
final local$resizeVolume = _instance.resizeVolume;
return CopyWith$Mutation$ResizeVolume$resizeVolume(
@ -2268,6 +2285,7 @@ class _CopyWithStubImpl$Mutation$ResizeVolume<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$ResizeVolume$resizeVolume<TRes> get resizeVolume =>
CopyWith$Mutation$ResizeVolume$resizeVolume.stub(_res);
}
@ -2604,6 +2622,7 @@ class Variables$Mutation$UnmountVolume {
Map<String, dynamic> _$data;
String get name => (_$data['name'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$name = name;
@ -2616,6 +2635,7 @@ class Variables$Mutation$UnmountVolume {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -2697,6 +2717,7 @@ class Mutation$UnmountVolume {
);
}
@Deprecated('Use `storage.unmount_volume` instead')
final Mutation$UnmountVolume$unmountVolume unmountVolume;
final String $__typename;
@ -2792,6 +2813,7 @@ class _CopyWithImpl$Mutation$UnmountVolume<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$UnmountVolume$unmountVolume<TRes> get unmountVolume {
final local$unmountVolume = _instance.unmountVolume;
return CopyWith$Mutation$UnmountVolume$unmountVolume(
@ -2810,6 +2832,7 @@ class _CopyWithStubImpl$Mutation$UnmountVolume<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$UnmountVolume$unmountVolume<TRes> get unmountVolume =>
CopyWith$Mutation$UnmountVolume$unmountVolume.stub(_res);
}
@ -3152,6 +3175,7 @@ class Variables$Mutation$MigrateToBinds {
Input$MigrateToBindsInput get input =>
(_$data['input'] as Input$MigrateToBindsInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$input = input;
@ -3164,6 +3188,7 @@ class Variables$Mutation$MigrateToBinds {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -3246,6 +3271,7 @@ class Mutation$MigrateToBinds {
);
}
@Deprecated('Use `storage.migrate_to_binds` instead')
final Mutation$MigrateToBinds$migrateToBinds migrateToBinds;
final String $__typename;
@ -3341,6 +3367,7 @@ class _CopyWithImpl$Mutation$MigrateToBinds<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$MigrateToBinds$migrateToBinds<TRes> get migrateToBinds {
final local$migrateToBinds = _instance.migrateToBinds;
return CopyWith$Mutation$MigrateToBinds$migrateToBinds(
@ -3359,6 +3386,7 @@ class _CopyWithStubImpl$Mutation$MigrateToBinds<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$MigrateToBinds$migrateToBinds<TRes> get migrateToBinds =>
CopyWith$Mutation$MigrateToBinds$migrateToBinds.stub(_res);
}
@ -3705,6 +3733,7 @@ class _CopyWithImpl$Mutation$MigrateToBinds$migrateToBinds<TRes>
? _instance.job
: (job as Fragment$basicApiJobsFields?),
));
CopyWith$Fragment$basicApiJobsFields<TRes> get job {
final local$job = _instance.job;
return local$job == null
@ -3727,6 +3756,7 @@ class _CopyWithStubImpl$Mutation$MigrateToBinds$migrateToBinds<TRes>
Fragment$basicApiJobsFields? job,
}) =>
_res;
CopyWith$Fragment$basicApiJobsFields<TRes> get job =>
CopyWith$Fragment$basicApiJobsFields.stub(_res);
}

View File

@ -150,6 +150,7 @@ type DnsRecord {
recordType: String!
name: String!
content: String!
displayName: String!
ttl: Int!
priority: Int
}

View File

@ -28,7 +28,9 @@ class Input$AutoUpgradeSettingsInput {
Map<String, dynamic> _$data;
bool? get enableAutoUpgrade => (_$data['enableAutoUpgrade'] as bool?);
bool? get allowReboot => (_$data['allowReboot'] as bool?);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
if (_$data.containsKey('enableAutoUpgrade')) {
@ -47,6 +49,7 @@ class Input$AutoUpgradeSettingsInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -177,10 +180,15 @@ class Input$AutobackupQuotasInput {
Map<String, dynamic> _$data;
int get last => (_$data['last'] as int);
int get daily => (_$data['daily'] as int);
int get weekly => (_$data['weekly'] as int);
int get monthly => (_$data['monthly'] as int);
int get yearly => (_$data['yearly'] as int);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$last = last;
@ -201,6 +209,7 @@ class Input$AutobackupQuotasInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -358,10 +367,15 @@ class Input$InitializeRepositoryInput {
Enum$BackupProvider get provider =>
(_$data['provider'] as Enum$BackupProvider);
String get locationId => (_$data['locationId'] as String);
String get locationName => (_$data['locationName'] as String);
String get login => (_$data['login'] as String);
String get password => (_$data['password'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$provider = provider;
@ -382,6 +396,7 @@ class Input$InitializeRepositoryInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -540,10 +555,15 @@ class Input$MigrateToBindsInput {
Map<String, dynamic> _$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<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$emailBlockDevice = emailBlockDevice;
@ -564,6 +584,7 @@ class Input$MigrateToBindsInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -711,7 +732,9 @@ class Input$MoveServiceInput {
Map<String, dynamic> _$data;
String get serviceId => (_$data['serviceId'] as String);
String get location => (_$data['location'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$serviceId = serviceId;
@ -726,6 +749,7 @@ class Input$MoveServiceInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -842,7 +866,9 @@ class Input$RecoveryKeyLimitsInput {
Map<String, dynamic> _$data;
DateTime? get expirationDate => (_$data['expirationDate'] as DateTime?);
int? get uses => (_$data['uses'] as int?);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
if (_$data.containsKey('expirationDate')) {
@ -862,6 +888,7 @@ class Input$RecoveryKeyLimitsInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -979,7 +1006,9 @@ class Input$SshMutationInput {
Map<String, dynamic> _$data;
String get username => (_$data['username'] as String);
String get sshKey => (_$data['sshKey'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$username = username;
@ -994,6 +1023,7 @@ class Input$SshMutationInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -1105,7 +1135,9 @@ class Input$UseNewDeviceKeyInput {
Map<String, dynamic> _$data;
String get key => (_$data['key'] as String);
String get deviceName => (_$data['deviceName'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$key = key;
@ -1120,6 +1152,7 @@ class Input$UseNewDeviceKeyInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -1230,7 +1263,9 @@ class Input$UseRecoveryKeyInput {
Map<String, dynamic> _$data;
String get key => (_$data['key'] as String);
String get deviceName => (_$data['deviceName'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$key = key;
@ -1245,6 +1280,7 @@ class Input$UseRecoveryKeyInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -1355,7 +1391,9 @@ class Input$UserMutationInput {
Map<String, dynamic> _$data;
String get username => (_$data['username'] as String);
String get password => (_$data['password'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$username = username;
@ -1370,6 +1408,7 @@ class Input$UserMutationInput {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -1710,6 +1749,177 @@ Enum$UserType fromJson$Enum$UserType(String value) {
}
}
enum Enum$__TypeKind {
SCALAR,
OBJECT,
INTERFACE,
UNION,
ENUM,
INPUT_OBJECT,
LIST,
NON_NULL,
$unknown
}
String toJson$Enum$__TypeKind(Enum$__TypeKind e) {
switch (e) {
case Enum$__TypeKind.SCALAR:
return r'SCALAR';
case Enum$__TypeKind.OBJECT:
return r'OBJECT';
case Enum$__TypeKind.INTERFACE:
return r'INTERFACE';
case Enum$__TypeKind.UNION:
return r'UNION';
case Enum$__TypeKind.ENUM:
return r'ENUM';
case Enum$__TypeKind.INPUT_OBJECT:
return r'INPUT_OBJECT';
case Enum$__TypeKind.LIST:
return r'LIST';
case Enum$__TypeKind.NON_NULL:
return r'NON_NULL';
case Enum$__TypeKind.$unknown:
return r'$unknown';
}
}
Enum$__TypeKind fromJson$Enum$__TypeKind(String value) {
switch (value) {
case r'SCALAR':
return Enum$__TypeKind.SCALAR;
case r'OBJECT':
return Enum$__TypeKind.OBJECT;
case r'INTERFACE':
return Enum$__TypeKind.INTERFACE;
case r'UNION':
return Enum$__TypeKind.UNION;
case r'ENUM':
return Enum$__TypeKind.ENUM;
case r'INPUT_OBJECT':
return Enum$__TypeKind.INPUT_OBJECT;
case r'LIST':
return Enum$__TypeKind.LIST;
case r'NON_NULL':
return Enum$__TypeKind.NON_NULL;
default:
return Enum$__TypeKind.$unknown;
}
}
enum Enum$__DirectiveLocation {
QUERY,
MUTATION,
SUBSCRIPTION,
FIELD,
FRAGMENT_DEFINITION,
FRAGMENT_SPREAD,
INLINE_FRAGMENT,
VARIABLE_DEFINITION,
SCHEMA,
SCALAR,
OBJECT,
FIELD_DEFINITION,
ARGUMENT_DEFINITION,
INTERFACE,
UNION,
ENUM,
ENUM_VALUE,
INPUT_OBJECT,
INPUT_FIELD_DEFINITION,
$unknown
}
String toJson$Enum$__DirectiveLocation(Enum$__DirectiveLocation e) {
switch (e) {
case Enum$__DirectiveLocation.QUERY:
return r'QUERY';
case Enum$__DirectiveLocation.MUTATION:
return r'MUTATION';
case Enum$__DirectiveLocation.SUBSCRIPTION:
return r'SUBSCRIPTION';
case Enum$__DirectiveLocation.FIELD:
return r'FIELD';
case Enum$__DirectiveLocation.FRAGMENT_DEFINITION:
return r'FRAGMENT_DEFINITION';
case Enum$__DirectiveLocation.FRAGMENT_SPREAD:
return r'FRAGMENT_SPREAD';
case Enum$__DirectiveLocation.INLINE_FRAGMENT:
return r'INLINE_FRAGMENT';
case Enum$__DirectiveLocation.VARIABLE_DEFINITION:
return r'VARIABLE_DEFINITION';
case Enum$__DirectiveLocation.SCHEMA:
return r'SCHEMA';
case Enum$__DirectiveLocation.SCALAR:
return r'SCALAR';
case Enum$__DirectiveLocation.OBJECT:
return r'OBJECT';
case Enum$__DirectiveLocation.FIELD_DEFINITION:
return r'FIELD_DEFINITION';
case Enum$__DirectiveLocation.ARGUMENT_DEFINITION:
return r'ARGUMENT_DEFINITION';
case Enum$__DirectiveLocation.INTERFACE:
return r'INTERFACE';
case Enum$__DirectiveLocation.UNION:
return r'UNION';
case Enum$__DirectiveLocation.ENUM:
return r'ENUM';
case Enum$__DirectiveLocation.ENUM_VALUE:
return r'ENUM_VALUE';
case Enum$__DirectiveLocation.INPUT_OBJECT:
return r'INPUT_OBJECT';
case Enum$__DirectiveLocation.INPUT_FIELD_DEFINITION:
return r'INPUT_FIELD_DEFINITION';
case Enum$__DirectiveLocation.$unknown:
return r'$unknown';
}
}
Enum$__DirectiveLocation fromJson$Enum$__DirectiveLocation(String value) {
switch (value) {
case r'QUERY':
return Enum$__DirectiveLocation.QUERY;
case r'MUTATION':
return Enum$__DirectiveLocation.MUTATION;
case r'SUBSCRIPTION':
return Enum$__DirectiveLocation.SUBSCRIPTION;
case r'FIELD':
return Enum$__DirectiveLocation.FIELD;
case r'FRAGMENT_DEFINITION':
return Enum$__DirectiveLocation.FRAGMENT_DEFINITION;
case r'FRAGMENT_SPREAD':
return Enum$__DirectiveLocation.FRAGMENT_SPREAD;
case r'INLINE_FRAGMENT':
return Enum$__DirectiveLocation.INLINE_FRAGMENT;
case r'VARIABLE_DEFINITION':
return Enum$__DirectiveLocation.VARIABLE_DEFINITION;
case r'SCHEMA':
return Enum$__DirectiveLocation.SCHEMA;
case r'SCALAR':
return Enum$__DirectiveLocation.SCALAR;
case r'OBJECT':
return Enum$__DirectiveLocation.OBJECT;
case r'FIELD_DEFINITION':
return Enum$__DirectiveLocation.FIELD_DEFINITION;
case r'ARGUMENT_DEFINITION':
return Enum$__DirectiveLocation.ARGUMENT_DEFINITION;
case r'INTERFACE':
return Enum$__DirectiveLocation.INTERFACE;
case r'UNION':
return Enum$__DirectiveLocation.UNION;
case r'ENUM':
return Enum$__DirectiveLocation.ENUM;
case r'ENUM_VALUE':
return Enum$__DirectiveLocation.ENUM_VALUE;
case r'INPUT_OBJECT':
return Enum$__DirectiveLocation.INPUT_OBJECT;
case r'INPUT_FIELD_DEFINITION':
return Enum$__DirectiveLocation.INPUT_FIELD_DEFINITION;
default:
return Enum$__DirectiveLocation.$unknown;
}
}
const possibleTypesMap = <String, Set<String>>{
'MutationReturnInterface': {
'ApiKeyMutationReturn',

View File

@ -2871,6 +2871,7 @@ class _CopyWithImpl$Query$GetApiVersion<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$GetApiVersion$api<TRes> get api {
final local$api = _instance.api;
return CopyWith$Query$GetApiVersion$api(local$api, (e) => call(api: e));
@ -2888,6 +2889,7 @@ class _CopyWithStubImpl$Query$GetApiVersion<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$GetApiVersion$api<TRes> get api =>
CopyWith$Query$GetApiVersion$api.stub(_res);
}
@ -3283,6 +3285,7 @@ class _CopyWithImpl$Query$GetApiJobs<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$GetApiJobs$jobs<TRes> get jobs {
final local$jobs = _instance.jobs;
return CopyWith$Query$GetApiJobs$jobs(local$jobs, (e) => call(jobs: e));
@ -3300,6 +3303,7 @@ class _CopyWithStubImpl$Query$GetApiJobs<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$GetApiJobs$jobs<TRes> get jobs =>
CopyWith$Query$GetApiJobs$jobs.stub(_res);
}
@ -3596,6 +3600,7 @@ class _CopyWithImpl$Query$GetApiJobs$jobs<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes getJobs(
Iterable<Fragment$basicApiJobsFields> Function(
Iterable<
@ -3621,6 +3626,7 @@ class _CopyWithStubImpl$Query$GetApiJobs$jobs<TRes>
String? $__typename,
}) =>
_res;
getJobs(_fn) => _res;
}
@ -3642,6 +3648,7 @@ class Variables$Mutation$RemoveJob {
Map<String, dynamic> _$data;
String get jobId => (_$data['jobId'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$jobId = jobId;
@ -3654,6 +3661,7 @@ class Variables$Mutation$RemoveJob {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -3735,6 +3743,7 @@ class Mutation$RemoveJob {
);
}
@Deprecated('Use `jobs.remove_job` instead')
final Mutation$RemoveJob$removeJob removeJob;
final String $__typename;
@ -3829,6 +3838,7 @@ class _CopyWithImpl$Mutation$RemoveJob<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RemoveJob$removeJob<TRes> get removeJob {
final local$removeJob = _instance.removeJob;
return CopyWith$Mutation$RemoveJob$removeJob(
@ -3847,6 +3857,7 @@ class _CopyWithStubImpl$Mutation$RemoveJob<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RemoveJob$removeJob<TRes> get removeJob =>
CopyWith$Mutation$RemoveJob$removeJob.stub(_res);
}
@ -4178,6 +4189,7 @@ class Mutation$RunSystemRebuild {
);
}
@Deprecated('Use `system.run_system_rebuild` instead')
final Mutation$RunSystemRebuild$runSystemRebuild runSystemRebuild;
final String $__typename;
@ -4276,6 +4288,7 @@ class _CopyWithImpl$Mutation$RunSystemRebuild<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RunSystemRebuild$runSystemRebuild<TRes>
get runSystemRebuild {
final local$runSystemRebuild = _instance.runSystemRebuild;
@ -4295,6 +4308,7 @@ class _CopyWithStubImpl$Mutation$RunSystemRebuild<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RunSystemRebuild$runSystemRebuild<TRes>
get runSystemRebuild =>
CopyWith$Mutation$RunSystemRebuild$runSystemRebuild.stub(_res);
@ -4615,6 +4629,7 @@ class Mutation$RunSystemRollback {
);
}
@Deprecated('Use `system.run_system_rollback` instead')
final Mutation$RunSystemRollback$runSystemRollback runSystemRollback;
final String $__typename;
@ -4714,6 +4729,7 @@ class _CopyWithImpl$Mutation$RunSystemRollback<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RunSystemRollback$runSystemRollback<TRes>
get runSystemRollback {
final local$runSystemRollback = _instance.runSystemRollback;
@ -4733,6 +4749,7 @@ class _CopyWithStubImpl$Mutation$RunSystemRollback<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RunSystemRollback$runSystemRollback<TRes>
get runSystemRollback =>
CopyWith$Mutation$RunSystemRollback$runSystemRollback.stub(_res);
@ -5054,6 +5071,7 @@ class Mutation$RunSystemUpgrade {
);
}
@Deprecated('Use `system.run_system_upgrade` instead')
final Mutation$RunSystemUpgrade$runSystemUpgrade runSystemUpgrade;
final String $__typename;
@ -5152,6 +5170,7 @@ class _CopyWithImpl$Mutation$RunSystemUpgrade<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade<TRes>
get runSystemUpgrade {
final local$runSystemUpgrade = _instance.runSystemUpgrade;
@ -5171,6 +5190,7 @@ class _CopyWithStubImpl$Mutation$RunSystemUpgrade<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade<TRes>
get runSystemUpgrade =>
CopyWith$Mutation$RunSystemUpgrade$runSystemUpgrade.stub(_res);
@ -5492,6 +5512,7 @@ class Mutation$PullRepositoryChanges {
);
}
@Deprecated('Use `system.pull_repository_changes` instead')
final Mutation$PullRepositoryChanges$pullRepositoryChanges
pullRepositoryChanges;
@ -5592,6 +5613,7 @@ class _CopyWithImpl$Mutation$PullRepositoryChanges<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges<TRes>
get pullRepositoryChanges {
final local$pullRepositoryChanges = _instance.pullRepositoryChanges;
@ -5611,6 +5633,7 @@ class _CopyWithStubImpl$Mutation$PullRepositoryChanges<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges<TRes>
get pullRepositoryChanges =>
CopyWith$Mutation$PullRepositoryChanges$pullRepositoryChanges.stub(
@ -5945,6 +5968,7 @@ class Mutation$RebootSystem {
);
}
@Deprecated('Use `system.reboot_system` instead')
final Mutation$RebootSystem$rebootSystem rebootSystem;
final String $__typename;
@ -6039,6 +6063,7 @@ class _CopyWithImpl$Mutation$RebootSystem<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RebootSystem$rebootSystem<TRes> get rebootSystem {
final local$rebootSystem = _instance.rebootSystem;
return CopyWith$Mutation$RebootSystem$rebootSystem(
@ -6057,6 +6082,7 @@ class _CopyWithStubImpl$Mutation$RebootSystem<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RebootSystem$rebootSystem<TRes> get rebootSystem =>
CopyWith$Mutation$RebootSystem$rebootSystem.stub(_res);
}
@ -6468,6 +6494,7 @@ class _CopyWithImpl$Query$SystemServerProvider<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemServerProvider$system<TRes> get system {
final local$system = _instance.system;
return CopyWith$Query$SystemServerProvider$system(
@ -6486,6 +6513,7 @@ class _CopyWithStubImpl$Query$SystemServerProvider<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemServerProvider$system<TRes> get system =>
CopyWith$Query$SystemServerProvider$system.stub(_res);
}
@ -6783,6 +6811,7 @@ class _CopyWithImpl$Query$SystemServerProvider$system<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemServerProvider$system$provider<TRes> get provider {
final local$provider = _instance.provider;
return CopyWith$Query$SystemServerProvider$system$provider(
@ -6801,6 +6830,7 @@ class _CopyWithStubImpl$Query$SystemServerProvider$system<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemServerProvider$system$provider<TRes> get provider =>
CopyWith$Query$SystemServerProvider$system$provider.stub(_res);
}
@ -7043,6 +7073,7 @@ class _CopyWithImpl$Query$SystemDnsProvider<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemDnsProvider$system<TRes> get system {
final local$system = _instance.system;
return CopyWith$Query$SystemDnsProvider$system(
@ -7061,6 +7092,7 @@ class _CopyWithStubImpl$Query$SystemDnsProvider<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemDnsProvider$system<TRes> get system =>
CopyWith$Query$SystemDnsProvider$system.stub(_res);
}
@ -7355,6 +7387,7 @@ class _CopyWithImpl$Query$SystemDnsProvider$system<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemDnsProvider$system$domainInfo<TRes> get domainInfo {
final local$domainInfo = _instance.domainInfo;
return CopyWith$Query$SystemDnsProvider$system$domainInfo(
@ -7373,6 +7406,7 @@ class _CopyWithStubImpl$Query$SystemDnsProvider$system<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemDnsProvider$system$domainInfo<TRes> get domainInfo =>
CopyWith$Query$SystemDnsProvider$system$domainInfo.stub(_res);
}
@ -7613,6 +7647,7 @@ class _CopyWithImpl$Query$GetApiTokens<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$GetApiTokens$api<TRes> get api {
final local$api = _instance.api;
return CopyWith$Query$GetApiTokens$api(local$api, (e) => call(api: e));
@ -7630,6 +7665,7 @@ class _CopyWithStubImpl$Query$GetApiTokens<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$GetApiTokens$api<TRes> get api =>
CopyWith$Query$GetApiTokens$api.stub(_res);
}
@ -7946,6 +7982,7 @@ class _CopyWithImpl$Query$GetApiTokens$api<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes devices(
Iterable<Query$GetApiTokens$api$devices> Function(
Iterable<
@ -7971,6 +8008,7 @@ class _CopyWithStubImpl$Query$GetApiTokens$api<TRes>
String? $__typename,
}) =>
_res;
devices(_fn) => _res;
}
@ -8248,6 +8286,7 @@ class _CopyWithImpl$Query$RecoveryKey<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$RecoveryKey$api<TRes> get api {
final local$api = _instance.api;
return CopyWith$Query$RecoveryKey$api(local$api, (e) => call(api: e));
@ -8265,6 +8304,7 @@ class _CopyWithStubImpl$Query$RecoveryKey<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$RecoveryKey$api<TRes> get api =>
CopyWith$Query$RecoveryKey$api.stub(_res);
}
@ -8578,6 +8618,7 @@ class _CopyWithImpl$Query$RecoveryKey$api<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$RecoveryKey$api$recoveryKey<TRes> get recoveryKey {
final local$recoveryKey = _instance.recoveryKey;
return CopyWith$Query$RecoveryKey$api$recoveryKey(
@ -8596,6 +8637,7 @@ class _CopyWithStubImpl$Query$RecoveryKey$api<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$RecoveryKey$api$recoveryKey<TRes> get recoveryKey =>
CopyWith$Query$RecoveryKey$api$recoveryKey.stub(_res);
}
@ -8835,6 +8877,7 @@ class Variables$Mutation$GetNewRecoveryApiKey {
Input$RecoveryKeyLimitsInput? get limits =>
(_$data['limits'] as Input$RecoveryKeyLimitsInput?);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
if (_$data.containsKey('limits')) {
@ -8850,6 +8893,7 @@ class Variables$Mutation$GetNewRecoveryApiKey {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -8936,6 +8980,7 @@ class Mutation$GetNewRecoveryApiKey {
);
}
@Deprecated('Use `api.get_new_recovery_api_key` instead')
final Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey getNewRecoveryApiKey;
final String $__typename;
@ -9035,6 +9080,7 @@ class _CopyWithImpl$Mutation$GetNewRecoveryApiKey<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey<TRes>
get getNewRecoveryApiKey {
final local$getNewRecoveryApiKey = _instance.getNewRecoveryApiKey;
@ -9054,6 +9100,7 @@ class _CopyWithStubImpl$Mutation$GetNewRecoveryApiKey<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey<TRes>
get getNewRecoveryApiKey =>
CopyWith$Mutation$GetNewRecoveryApiKey$getNewRecoveryApiKey.stub(
@ -9435,6 +9482,7 @@ class Variables$Mutation$UseRecoveryApiKey {
Input$UseRecoveryKeyInput get input =>
(_$data['input'] as Input$UseRecoveryKeyInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$input = input;
@ -9448,6 +9496,7 @@ class Variables$Mutation$UseRecoveryApiKey {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -9530,6 +9579,7 @@ class Mutation$UseRecoveryApiKey {
);
}
@Deprecated('Use `api.use_recovery_api_key` instead')
final Mutation$UseRecoveryApiKey$useRecoveryApiKey useRecoveryApiKey;
final String $__typename;
@ -9629,6 +9679,7 @@ class _CopyWithImpl$Mutation$UseRecoveryApiKey<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey<TRes>
get useRecoveryApiKey {
final local$useRecoveryApiKey = _instance.useRecoveryApiKey;
@ -9648,6 +9699,7 @@ class _CopyWithStubImpl$Mutation$UseRecoveryApiKey<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey<TRes>
get useRecoveryApiKey =>
CopyWith$Mutation$UseRecoveryApiKey$useRecoveryApiKey.stub(_res);
@ -10015,6 +10067,7 @@ class Mutation$RefreshDeviceApiToken {
);
}
@Deprecated('Use `api.refresh_device_api_token` instead')
final Mutation$RefreshDeviceApiToken$refreshDeviceApiToken
refreshDeviceApiToken;
@ -10115,6 +10168,7 @@ class _CopyWithImpl$Mutation$RefreshDeviceApiToken<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken<TRes>
get refreshDeviceApiToken {
final local$refreshDeviceApiToken = _instance.refreshDeviceApiToken;
@ -10134,6 +10188,7 @@ class _CopyWithStubImpl$Mutation$RefreshDeviceApiToken<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken<TRes>
get refreshDeviceApiToken =>
CopyWith$Mutation$RefreshDeviceApiToken$refreshDeviceApiToken.stub(
@ -10497,6 +10552,7 @@ class Variables$Mutation$DeleteDeviceApiToken {
Map<String, dynamic> _$data;
String get device => (_$data['device'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$device = device;
@ -10510,6 +10566,7 @@ class Variables$Mutation$DeleteDeviceApiToken {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -10593,6 +10650,7 @@ class Mutation$DeleteDeviceApiToken {
);
}
@Deprecated('Use `api.delete_device_api_token` instead')
final Mutation$DeleteDeviceApiToken$deleteDeviceApiToken deleteDeviceApiToken;
final String $__typename;
@ -10692,6 +10750,7 @@ class _CopyWithImpl$Mutation$DeleteDeviceApiToken<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken<TRes>
get deleteDeviceApiToken {
final local$deleteDeviceApiToken = _instance.deleteDeviceApiToken;
@ -10711,6 +10770,7 @@ class _CopyWithStubImpl$Mutation$DeleteDeviceApiToken<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken<TRes>
get deleteDeviceApiToken =>
CopyWith$Mutation$DeleteDeviceApiToken$deleteDeviceApiToken.stub(
@ -11061,6 +11121,7 @@ class Mutation$GetNewDeviceApiKey {
);
}
@Deprecated('Use `api.get_new_device_api_key` instead')
final Mutation$GetNewDeviceApiKey$getNewDeviceApiKey getNewDeviceApiKey;
final String $__typename;
@ -11160,6 +11221,7 @@ class _CopyWithImpl$Mutation$GetNewDeviceApiKey<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey<TRes>
get getNewDeviceApiKey {
final local$getNewDeviceApiKey = _instance.getNewDeviceApiKey;
@ -11179,6 +11241,7 @@ class _CopyWithStubImpl$Mutation$GetNewDeviceApiKey<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey<TRes>
get getNewDeviceApiKey =>
CopyWith$Mutation$GetNewDeviceApiKey$getNewDeviceApiKey.stub(_res);
@ -11528,6 +11591,7 @@ class Mutation$InvalidateNewDeviceApiKey {
);
}
@Deprecated('Use `api.invalidate_new_device_api_key` instead')
final Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey
invalidateNewDeviceApiKey;
@ -11631,6 +11695,7 @@ class _CopyWithImpl$Mutation$InvalidateNewDeviceApiKey<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey<TRes>
get invalidateNewDeviceApiKey {
final local$invalidateNewDeviceApiKey = _instance.invalidateNewDeviceApiKey;
@ -11652,6 +11717,7 @@ class _CopyWithStubImpl$Mutation$InvalidateNewDeviceApiKey<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey<TRes>
get invalidateNewDeviceApiKey =>
CopyWith$Mutation$InvalidateNewDeviceApiKey$invalidateNewDeviceApiKey
@ -11998,6 +12064,7 @@ class Variables$Mutation$AuthorizeWithNewDeviceApiKey {
Input$UseNewDeviceKeyInput get input =>
(_$data['input'] as Input$UseNewDeviceKeyInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$input = input;
@ -12011,6 +12078,7 @@ class Variables$Mutation$AuthorizeWithNewDeviceApiKey {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -12097,6 +12165,7 @@ class Mutation$AuthorizeWithNewDeviceApiKey {
);
}
@Deprecated('Use `api.authorize_with_new_device_api_key` instead')
final Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey
authorizeWithNewDeviceApiKey;
@ -12202,6 +12271,7 @@ class _CopyWithImpl$Mutation$AuthorizeWithNewDeviceApiKey<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey<
TRes> get authorizeWithNewDeviceApiKey {
final local$authorizeWithNewDeviceApiKey =
@ -12224,6 +12294,7 @@ class _CopyWithStubImpl$Mutation$AuthorizeWithNewDeviceApiKey<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$AuthorizeWithNewDeviceApiKey$authorizeWithNewDeviceApiKey<
TRes>
get authorizeWithNewDeviceApiKey =>

View File

@ -25,12 +25,13 @@ query SystemIsUsingBinds {
fragment fragmentDnsRecords on DnsRecord {
recordType
name
displayName
content
ttl
priority
}
query DomainInfo {
query GetDnsRecords {
system {
domainInfo {
domain

View File

@ -8,6 +8,7 @@ class Fragment$fragmentDnsRecords {
Fragment$fragmentDnsRecords({
required this.recordType,
required this.name,
required this.displayName,
required this.content,
required this.ttl,
this.priority,
@ -17,6 +18,7 @@ class Fragment$fragmentDnsRecords {
factory Fragment$fragmentDnsRecords.fromJson(Map<String, dynamic> json) {
final l$recordType = json['recordType'];
final l$name = json['name'];
final l$displayName = json['displayName'];
final l$content = json['content'];
final l$ttl = json['ttl'];
final l$priority = json['priority'];
@ -24,6 +26,7 @@ class Fragment$fragmentDnsRecords {
return Fragment$fragmentDnsRecords(
recordType: (l$recordType as String),
name: (l$name as String),
displayName: (l$displayName as String),
content: (l$content as String),
ttl: (l$ttl as int),
priority: (l$priority as int?),
@ -35,6 +38,8 @@ class Fragment$fragmentDnsRecords {
final String name;
final String displayName;
final String content;
final int ttl;
@ -49,6 +54,8 @@ class Fragment$fragmentDnsRecords {
_resultData['recordType'] = l$recordType;
final l$name = name;
_resultData['name'] = l$name;
final l$displayName = displayName;
_resultData['displayName'] = l$displayName;
final l$content = content;
_resultData['content'] = l$content;
final l$ttl = ttl;
@ -64,6 +71,7 @@ class Fragment$fragmentDnsRecords {
int get hashCode {
final l$recordType = recordType;
final l$name = name;
final l$displayName = displayName;
final l$content = content;
final l$ttl = ttl;
final l$priority = priority;
@ -71,6 +79,7 @@ class Fragment$fragmentDnsRecords {
return Object.hashAll([
l$recordType,
l$name,
l$displayName,
l$content,
l$ttl,
l$priority,
@ -97,6 +106,11 @@ class Fragment$fragmentDnsRecords {
if (l$name != lOther$name) {
return false;
}
final l$displayName = displayName;
final lOther$displayName = other.displayName;
if (l$displayName != lOther$displayName) {
return false;
}
final l$content = content;
final lOther$content = other.content;
if (l$content != lOther$content) {
@ -142,6 +156,7 @@ abstract class CopyWith$Fragment$fragmentDnsRecords<TRes> {
TRes call({
String? recordType,
String? name,
String? displayName,
String? content,
int? ttl,
int? priority,
@ -165,6 +180,7 @@ class _CopyWithImpl$Fragment$fragmentDnsRecords<TRes>
TRes call({
Object? recordType = _undefined,
Object? name = _undefined,
Object? displayName = _undefined,
Object? content = _undefined,
Object? ttl = _undefined,
Object? priority = _undefined,
@ -177,6 +193,9 @@ class _CopyWithImpl$Fragment$fragmentDnsRecords<TRes>
name: name == _undefined || name == null
? _instance.name
: (name as String),
displayName: displayName == _undefined || displayName == null
? _instance.displayName
: (displayName as String),
content: content == _undefined || content == null
? _instance.content
: (content as String),
@ -198,6 +217,7 @@ class _CopyWithStubImpl$Fragment$fragmentDnsRecords<TRes>
call({
String? recordType,
String? name,
String? displayName,
String? content,
int? ttl,
int? priority,
@ -229,6 +249,13 @@ const fragmentDefinitionfragmentDnsRecords = FragmentDefinitionNode(
directives: [],
selectionSet: null,
),
FieldNode(
name: NameNode(value: 'displayName'),
alias: null,
arguments: [],
directives: [],
selectionSet: null,
),
FieldNode(
name: NameNode(value: 'content'),
alias: null,
@ -408,6 +435,7 @@ class _CopyWithImpl$Query$SystemSettings<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemSettings$system<TRes> get system {
final local$system = _instance.system;
return CopyWith$Query$SystemSettings$system(
@ -426,6 +454,7 @@ class _CopyWithStubImpl$Query$SystemSettings<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemSettings$system<TRes> get system =>
CopyWith$Query$SystemSettings$system.stub(_res);
}
@ -774,6 +803,7 @@ class _CopyWithImpl$Query$SystemSettings$system<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemSettings$system$settings<TRes> get settings {
final local$settings = _instance.settings;
return CopyWith$Query$SystemSettings$system$settings(
@ -792,6 +822,7 @@ class _CopyWithStubImpl$Query$SystemSettings$system<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemSettings$system$settings<TRes> get settings =>
CopyWith$Query$SystemSettings$system$settings.stub(_res);
}
@ -951,6 +982,7 @@ class _CopyWithImpl$Query$SystemSettings$system$settings<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemSettings$system$settings$autoUpgrade<TRes>
get autoUpgrade {
final local$autoUpgrade = _instance.autoUpgrade;
@ -978,9 +1010,11 @@ class _CopyWithStubImpl$Query$SystemSettings$system$settings<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemSettings$system$settings$autoUpgrade<TRes>
get autoUpgrade =>
CopyWith$Query$SystemSettings$system$settings$autoUpgrade.stub(_res);
CopyWith$Query$SystemSettings$system$settings$ssh<TRes> get ssh =>
CopyWith$Query$SystemSettings$system$settings$ssh.stub(_res);
}
@ -1393,6 +1427,7 @@ class _CopyWithImpl$Query$SystemIsUsingBinds<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemIsUsingBinds$system<TRes> get system {
final local$system = _instance.system;
return CopyWith$Query$SystemIsUsingBinds$system(
@ -1411,6 +1446,7 @@ class _CopyWithStubImpl$Query$SystemIsUsingBinds<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemIsUsingBinds$system<TRes> get system =>
CopyWith$Query$SystemIsUsingBinds$system.stub(_res);
}
@ -1707,6 +1743,7 @@ class _CopyWithImpl$Query$SystemIsUsingBinds$system<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$SystemIsUsingBinds$system$info<TRes> get info {
final local$info = _instance.info;
return CopyWith$Query$SystemIsUsingBinds$system$info(
@ -1725,6 +1762,7 @@ class _CopyWithStubImpl$Query$SystemIsUsingBinds$system<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$SystemIsUsingBinds$system$info<TRes> get info =>
CopyWith$Query$SystemIsUsingBinds$system$info.stub(_res);
}
@ -1856,23 +1894,23 @@ class _CopyWithStubImpl$Query$SystemIsUsingBinds$system$info<TRes>
_res;
}
class Query$DomainInfo {
Query$DomainInfo({
class Query$GetDnsRecords {
Query$GetDnsRecords({
required this.system,
this.$__typename = 'Query',
});
factory Query$DomainInfo.fromJson(Map<String, dynamic> json) {
factory Query$GetDnsRecords.fromJson(Map<String, dynamic> json) {
final l$system = json['system'];
final l$$__typename = json['__typename'];
return Query$DomainInfo(
system:
Query$DomainInfo$system.fromJson((l$system as Map<String, dynamic>)),
return Query$GetDnsRecords(
system: Query$GetDnsRecords$system.fromJson(
(l$system as Map<String, dynamic>)),
$__typename: (l$$__typename as String),
);
}
final Query$DomainInfo$system system;
final Query$GetDnsRecords$system system;
final String $__typename;
@ -1900,7 +1938,7 @@ class Query$DomainInfo {
if (identical(this, other)) {
return true;
}
if (!(other is Query$DomainInfo) || runtimeType != other.runtimeType) {
if (!(other is Query$GetDnsRecords) || runtimeType != other.runtimeType) {
return false;
}
final l$system = system;
@ -1917,40 +1955,40 @@ class Query$DomainInfo {
}
}
extension UtilityExtension$Query$DomainInfo on Query$DomainInfo {
CopyWith$Query$DomainInfo<Query$DomainInfo> get copyWith =>
CopyWith$Query$DomainInfo(
extension UtilityExtension$Query$GetDnsRecords on Query$GetDnsRecords {
CopyWith$Query$GetDnsRecords<Query$GetDnsRecords> get copyWith =>
CopyWith$Query$GetDnsRecords(
this,
(i) => i,
);
}
abstract class CopyWith$Query$DomainInfo<TRes> {
factory CopyWith$Query$DomainInfo(
Query$DomainInfo instance,
TRes Function(Query$DomainInfo) then,
) = _CopyWithImpl$Query$DomainInfo;
abstract class CopyWith$Query$GetDnsRecords<TRes> {
factory CopyWith$Query$GetDnsRecords(
Query$GetDnsRecords instance,
TRes Function(Query$GetDnsRecords) then,
) = _CopyWithImpl$Query$GetDnsRecords;
factory CopyWith$Query$DomainInfo.stub(TRes res) =
_CopyWithStubImpl$Query$DomainInfo;
factory CopyWith$Query$GetDnsRecords.stub(TRes res) =
_CopyWithStubImpl$Query$GetDnsRecords;
TRes call({
Query$DomainInfo$system? system,
Query$GetDnsRecords$system? system,
String? $__typename,
});
CopyWith$Query$DomainInfo$system<TRes> get system;
CopyWith$Query$GetDnsRecords$system<TRes> get system;
}
class _CopyWithImpl$Query$DomainInfo<TRes>
implements CopyWith$Query$DomainInfo<TRes> {
_CopyWithImpl$Query$DomainInfo(
class _CopyWithImpl$Query$GetDnsRecords<TRes>
implements CopyWith$Query$GetDnsRecords<TRes> {
_CopyWithImpl$Query$GetDnsRecords(
this._instance,
this._then,
);
final Query$DomainInfo _instance;
final Query$GetDnsRecords _instance;
final TRes Function(Query$DomainInfo) _then;
final TRes Function(Query$GetDnsRecords) _then;
static const _undefined = <dynamic, dynamic>{};
@ -1958,40 +1996,42 @@ class _CopyWithImpl$Query$DomainInfo<TRes>
Object? system = _undefined,
Object? $__typename = _undefined,
}) =>
_then(Query$DomainInfo(
_then(Query$GetDnsRecords(
system: system == _undefined || system == null
? _instance.system
: (system as Query$DomainInfo$system),
: (system as Query$GetDnsRecords$system),
$__typename: $__typename == _undefined || $__typename == null
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$DomainInfo$system<TRes> get system {
CopyWith$Query$GetDnsRecords$system<TRes> get system {
final local$system = _instance.system;
return CopyWith$Query$DomainInfo$system(
return CopyWith$Query$GetDnsRecords$system(
local$system, (e) => call(system: e));
}
}
class _CopyWithStubImpl$Query$DomainInfo<TRes>
implements CopyWith$Query$DomainInfo<TRes> {
_CopyWithStubImpl$Query$DomainInfo(this._res);
class _CopyWithStubImpl$Query$GetDnsRecords<TRes>
implements CopyWith$Query$GetDnsRecords<TRes> {
_CopyWithStubImpl$Query$GetDnsRecords(this._res);
TRes _res;
call({
Query$DomainInfo$system? system,
Query$GetDnsRecords$system? system,
String? $__typename,
}) =>
_res;
CopyWith$Query$DomainInfo$system<TRes> get system =>
CopyWith$Query$DomainInfo$system.stub(_res);
CopyWith$Query$GetDnsRecords$system<TRes> get system =>
CopyWith$Query$GetDnsRecords$system.stub(_res);
}
const documentNodeQueryDomainInfo = DocumentNode(definitions: [
const documentNodeQueryGetDnsRecords = DocumentNode(definitions: [
OperationDefinitionNode(
type: OperationType.query,
name: NameNode(value: 'DomainInfo'),
name: NameNode(value: 'GetDnsRecords'),
variableDefinitions: [],
directives: [],
selectionSet: SelectionSetNode(selections: [
@ -2076,24 +2116,25 @@ const documentNodeQueryDomainInfo = DocumentNode(definitions: [
),
fragmentDefinitionfragmentDnsRecords,
]);
Query$DomainInfo _parserFn$Query$DomainInfo(Map<String, dynamic> data) =>
Query$DomainInfo.fromJson(data);
typedef OnQueryComplete$Query$DomainInfo = FutureOr<void> Function(
Query$GetDnsRecords _parserFn$Query$GetDnsRecords(Map<String, dynamic> data) =>
Query$GetDnsRecords.fromJson(data);
typedef OnQueryComplete$Query$GetDnsRecords = FutureOr<void> Function(
Map<String, dynamic>?,
Query$DomainInfo?,
Query$GetDnsRecords?,
);
class Options$Query$DomainInfo extends graphql.QueryOptions<Query$DomainInfo> {
Options$Query$DomainInfo({
class Options$Query$GetDnsRecords
extends graphql.QueryOptions<Query$GetDnsRecords> {
Options$Query$GetDnsRecords({
String? operationName,
graphql.FetchPolicy? fetchPolicy,
graphql.ErrorPolicy? errorPolicy,
graphql.CacheRereadPolicy? cacheRereadPolicy,
Object? optimisticResult,
Query$DomainInfo? typedOptimisticResult,
Query$GetDnsRecords? typedOptimisticResult,
Duration? pollInterval,
graphql.Context? context,
OnQueryComplete$Query$DomainInfo? onComplete,
OnQueryComplete$Query$GetDnsRecords? onComplete,
graphql.OnQueryError? onError,
}) : onCompleteWithParsed = onComplete,
super(
@ -2108,14 +2149,14 @@ class Options$Query$DomainInfo extends graphql.QueryOptions<Query$DomainInfo> {
? null
: (data) => onComplete(
data,
data == null ? null : _parserFn$Query$DomainInfo(data),
data == null ? null : _parserFn$Query$GetDnsRecords(data),
),
onError: onError,
document: documentNodeQueryDomainInfo,
parserFn: _parserFn$Query$DomainInfo,
document: documentNodeQueryGetDnsRecords,
parserFn: _parserFn$Query$GetDnsRecords,
);
final OnQueryComplete$Query$DomainInfo? onCompleteWithParsed;
final OnQueryComplete$Query$GetDnsRecords? onCompleteWithParsed;
@override
List<Object?> get properties => [
@ -2126,15 +2167,15 @@ class Options$Query$DomainInfo extends graphql.QueryOptions<Query$DomainInfo> {
];
}
class WatchOptions$Query$DomainInfo
extends graphql.WatchQueryOptions<Query$DomainInfo> {
WatchOptions$Query$DomainInfo({
class WatchOptions$Query$GetDnsRecords
extends graphql.WatchQueryOptions<Query$GetDnsRecords> {
WatchOptions$Query$GetDnsRecords({
String? operationName,
graphql.FetchPolicy? fetchPolicy,
graphql.ErrorPolicy? errorPolicy,
graphql.CacheRereadPolicy? cacheRereadPolicy,
Object? optimisticResult,
Query$DomainInfo? typedOptimisticResult,
Query$GetDnsRecords? typedOptimisticResult,
graphql.Context? context,
Duration? pollInterval,
bool? eagerlyFetchResults,
@ -2147,68 +2188,70 @@ class WatchOptions$Query$DomainInfo
cacheRereadPolicy: cacheRereadPolicy,
optimisticResult: optimisticResult ?? typedOptimisticResult?.toJson(),
context: context,
document: documentNodeQueryDomainInfo,
document: documentNodeQueryGetDnsRecords,
pollInterval: pollInterval,
eagerlyFetchResults: eagerlyFetchResults,
carryForwardDataOnException: carryForwardDataOnException,
fetchResults: fetchResults,
parserFn: _parserFn$Query$DomainInfo,
parserFn: _parserFn$Query$GetDnsRecords,
);
}
class FetchMoreOptions$Query$DomainInfo extends graphql.FetchMoreOptions {
FetchMoreOptions$Query$DomainInfo({required graphql.UpdateQuery updateQuery})
class FetchMoreOptions$Query$GetDnsRecords extends graphql.FetchMoreOptions {
FetchMoreOptions$Query$GetDnsRecords(
{required graphql.UpdateQuery updateQuery})
: super(
updateQuery: updateQuery,
document: documentNodeQueryDomainInfo,
document: documentNodeQueryGetDnsRecords,
);
}
extension ClientExtension$Query$DomainInfo on graphql.GraphQLClient {
Future<graphql.QueryResult<Query$DomainInfo>> query$DomainInfo(
[Options$Query$DomainInfo? options]) async =>
await this.query(options ?? Options$Query$DomainInfo());
graphql.ObservableQuery<Query$DomainInfo> watchQuery$DomainInfo(
[WatchOptions$Query$DomainInfo? options]) =>
this.watchQuery(options ?? WatchOptions$Query$DomainInfo());
void writeQuery$DomainInfo({
required Query$DomainInfo data,
extension ClientExtension$Query$GetDnsRecords on graphql.GraphQLClient {
Future<graphql.QueryResult<Query$GetDnsRecords>> query$GetDnsRecords(
[Options$Query$GetDnsRecords? options]) async =>
await this.query(options ?? Options$Query$GetDnsRecords());
graphql.ObservableQuery<Query$GetDnsRecords> watchQuery$GetDnsRecords(
[WatchOptions$Query$GetDnsRecords? options]) =>
this.watchQuery(options ?? WatchOptions$Query$GetDnsRecords());
void writeQuery$GetDnsRecords({
required Query$GetDnsRecords data,
bool broadcast = true,
}) =>
this.writeQuery(
graphql.Request(
operation:
graphql.Operation(document: documentNodeQueryDomainInfo)),
graphql.Operation(document: documentNodeQueryGetDnsRecords)),
data: data.toJson(),
broadcast: broadcast,
);
Query$DomainInfo? readQuery$DomainInfo({bool optimistic = true}) {
Query$GetDnsRecords? readQuery$GetDnsRecords({bool optimistic = true}) {
final result = this.readQuery(
graphql.Request(
operation: graphql.Operation(document: documentNodeQueryDomainInfo)),
operation:
graphql.Operation(document: documentNodeQueryGetDnsRecords)),
optimistic: optimistic,
);
return result == null ? null : Query$DomainInfo.fromJson(result);
return result == null ? null : Query$GetDnsRecords.fromJson(result);
}
}
class Query$DomainInfo$system {
Query$DomainInfo$system({
class Query$GetDnsRecords$system {
Query$GetDnsRecords$system({
required this.domainInfo,
this.$__typename = 'System',
});
factory Query$DomainInfo$system.fromJson(Map<String, dynamic> json) {
factory Query$GetDnsRecords$system.fromJson(Map<String, dynamic> json) {
final l$domainInfo = json['domainInfo'];
final l$$__typename = json['__typename'];
return Query$DomainInfo$system(
domainInfo: Query$DomainInfo$system$domainInfo.fromJson(
return Query$GetDnsRecords$system(
domainInfo: Query$GetDnsRecords$system$domainInfo.fromJson(
(l$domainInfo as Map<String, dynamic>)),
$__typename: (l$$__typename as String),
);
}
final Query$DomainInfo$system$domainInfo domainInfo;
final Query$GetDnsRecords$system$domainInfo domainInfo;
final String $__typename;
@ -2236,7 +2279,7 @@ class Query$DomainInfo$system {
if (identical(this, other)) {
return true;
}
if (!(other is Query$DomainInfo$system) ||
if (!(other is Query$GetDnsRecords$system) ||
runtimeType != other.runtimeType) {
return false;
}
@ -2254,40 +2297,41 @@ class Query$DomainInfo$system {
}
}
extension UtilityExtension$Query$DomainInfo$system on Query$DomainInfo$system {
CopyWith$Query$DomainInfo$system<Query$DomainInfo$system> get copyWith =>
CopyWith$Query$DomainInfo$system(
this,
(i) => i,
);
extension UtilityExtension$Query$GetDnsRecords$system
on Query$GetDnsRecords$system {
CopyWith$Query$GetDnsRecords$system<Query$GetDnsRecords$system>
get copyWith => CopyWith$Query$GetDnsRecords$system(
this,
(i) => i,
);
}
abstract class CopyWith$Query$DomainInfo$system<TRes> {
factory CopyWith$Query$DomainInfo$system(
Query$DomainInfo$system instance,
TRes Function(Query$DomainInfo$system) then,
) = _CopyWithImpl$Query$DomainInfo$system;
abstract class CopyWith$Query$GetDnsRecords$system<TRes> {
factory CopyWith$Query$GetDnsRecords$system(
Query$GetDnsRecords$system instance,
TRes Function(Query$GetDnsRecords$system) then,
) = _CopyWithImpl$Query$GetDnsRecords$system;
factory CopyWith$Query$DomainInfo$system.stub(TRes res) =
_CopyWithStubImpl$Query$DomainInfo$system;
factory CopyWith$Query$GetDnsRecords$system.stub(TRes res) =
_CopyWithStubImpl$Query$GetDnsRecords$system;
TRes call({
Query$DomainInfo$system$domainInfo? domainInfo,
Query$GetDnsRecords$system$domainInfo? domainInfo,
String? $__typename,
});
CopyWith$Query$DomainInfo$system$domainInfo<TRes> get domainInfo;
CopyWith$Query$GetDnsRecords$system$domainInfo<TRes> get domainInfo;
}
class _CopyWithImpl$Query$DomainInfo$system<TRes>
implements CopyWith$Query$DomainInfo$system<TRes> {
_CopyWithImpl$Query$DomainInfo$system(
class _CopyWithImpl$Query$GetDnsRecords$system<TRes>
implements CopyWith$Query$GetDnsRecords$system<TRes> {
_CopyWithImpl$Query$GetDnsRecords$system(
this._instance,
this._then,
);
final Query$DomainInfo$system _instance;
final Query$GetDnsRecords$system _instance;
final TRes Function(Query$DomainInfo$system) _then;
final TRes Function(Query$GetDnsRecords$system) _then;
static const _undefined = <dynamic, dynamic>{};
@ -2295,38 +2339,40 @@ class _CopyWithImpl$Query$DomainInfo$system<TRes>
Object? domainInfo = _undefined,
Object? $__typename = _undefined,
}) =>
_then(Query$DomainInfo$system(
_then(Query$GetDnsRecords$system(
domainInfo: domainInfo == _undefined || domainInfo == null
? _instance.domainInfo
: (domainInfo as Query$DomainInfo$system$domainInfo),
: (domainInfo as Query$GetDnsRecords$system$domainInfo),
$__typename: $__typename == _undefined || $__typename == null
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$DomainInfo$system$domainInfo<TRes> get domainInfo {
CopyWith$Query$GetDnsRecords$system$domainInfo<TRes> get domainInfo {
final local$domainInfo = _instance.domainInfo;
return CopyWith$Query$DomainInfo$system$domainInfo(
return CopyWith$Query$GetDnsRecords$system$domainInfo(
local$domainInfo, (e) => call(domainInfo: e));
}
}
class _CopyWithStubImpl$Query$DomainInfo$system<TRes>
implements CopyWith$Query$DomainInfo$system<TRes> {
_CopyWithStubImpl$Query$DomainInfo$system(this._res);
class _CopyWithStubImpl$Query$GetDnsRecords$system<TRes>
implements CopyWith$Query$GetDnsRecords$system<TRes> {
_CopyWithStubImpl$Query$GetDnsRecords$system(this._res);
TRes _res;
call({
Query$DomainInfo$system$domainInfo? domainInfo,
Query$GetDnsRecords$system$domainInfo? domainInfo,
String? $__typename,
}) =>
_res;
CopyWith$Query$DomainInfo$system$domainInfo<TRes> get domainInfo =>
CopyWith$Query$DomainInfo$system$domainInfo.stub(_res);
CopyWith$Query$GetDnsRecords$system$domainInfo<TRes> get domainInfo =>
CopyWith$Query$GetDnsRecords$system$domainInfo.stub(_res);
}
class Query$DomainInfo$system$domainInfo {
Query$DomainInfo$system$domainInfo({
class Query$GetDnsRecords$system$domainInfo {
Query$GetDnsRecords$system$domainInfo({
required this.domain,
required this.hostname,
required this.provider,
@ -2334,14 +2380,14 @@ class Query$DomainInfo$system$domainInfo {
this.$__typename = 'SystemDomainInfo',
});
factory Query$DomainInfo$system$domainInfo.fromJson(
factory Query$GetDnsRecords$system$domainInfo.fromJson(
Map<String, dynamic> 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(
return Query$GetDnsRecords$system$domainInfo(
domain: (l$domain as String),
hostname: (l$hostname as String),
provider: fromJson$Enum$DnsProvider((l$provider as String)),
@ -2400,7 +2446,7 @@ class Query$DomainInfo$system$domainInfo {
if (identical(this, other)) {
return true;
}
if (!(other is Query$DomainInfo$system$domainInfo) ||
if (!(other is Query$GetDnsRecords$system$domainInfo) ||
runtimeType != other.runtimeType) {
return false;
}
@ -2440,24 +2486,24 @@ class Query$DomainInfo$system$domainInfo {
}
}
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(
extension UtilityExtension$Query$GetDnsRecords$system$domainInfo
on Query$GetDnsRecords$system$domainInfo {
CopyWith$Query$GetDnsRecords$system$domainInfo<
Query$GetDnsRecords$system$domainInfo>
get copyWith => CopyWith$Query$GetDnsRecords$system$domainInfo(
this,
(i) => i,
);
}
abstract class CopyWith$Query$DomainInfo$system$domainInfo<TRes> {
factory CopyWith$Query$DomainInfo$system$domainInfo(
Query$DomainInfo$system$domainInfo instance,
TRes Function(Query$DomainInfo$system$domainInfo) then,
) = _CopyWithImpl$Query$DomainInfo$system$domainInfo;
abstract class CopyWith$Query$GetDnsRecords$system$domainInfo<TRes> {
factory CopyWith$Query$GetDnsRecords$system$domainInfo(
Query$GetDnsRecords$system$domainInfo instance,
TRes Function(Query$GetDnsRecords$system$domainInfo) then,
) = _CopyWithImpl$Query$GetDnsRecords$system$domainInfo;
factory CopyWith$Query$DomainInfo$system$domainInfo.stub(TRes res) =
_CopyWithStubImpl$Query$DomainInfo$system$domainInfo;
factory CopyWith$Query$GetDnsRecords$system$domainInfo.stub(TRes res) =
_CopyWithStubImpl$Query$GetDnsRecords$system$domainInfo;
TRes call({
String? domain,
@ -2474,16 +2520,16 @@ abstract class CopyWith$Query$DomainInfo$system$domainInfo<TRes> {
_fn);
}
class _CopyWithImpl$Query$DomainInfo$system$domainInfo<TRes>
implements CopyWith$Query$DomainInfo$system$domainInfo<TRes> {
_CopyWithImpl$Query$DomainInfo$system$domainInfo(
class _CopyWithImpl$Query$GetDnsRecords$system$domainInfo<TRes>
implements CopyWith$Query$GetDnsRecords$system$domainInfo<TRes> {
_CopyWithImpl$Query$GetDnsRecords$system$domainInfo(
this._instance,
this._then,
);
final Query$DomainInfo$system$domainInfo _instance;
final Query$GetDnsRecords$system$domainInfo _instance;
final TRes Function(Query$DomainInfo$system$domainInfo) _then;
final TRes Function(Query$GetDnsRecords$system$domainInfo) _then;
static const _undefined = <dynamic, dynamic>{};
@ -2494,7 +2540,7 @@ class _CopyWithImpl$Query$DomainInfo$system$domainInfo<TRes>
Object? requiredDnsRecords = _undefined,
Object? $__typename = _undefined,
}) =>
_then(Query$DomainInfo$system$domainInfo(
_then(Query$GetDnsRecords$system$domainInfo(
domain: domain == _undefined || domain == null
? _instance.domain
: (domain as String),
@ -2512,6 +2558,7 @@ class _CopyWithImpl$Query$DomainInfo$system$domainInfo<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes requiredDnsRecords(
Iterable<Fragment$fragmentDnsRecords> Function(
Iterable<
@ -2526,9 +2573,9 @@ class _CopyWithImpl$Query$DomainInfo$system$domainInfo<TRes>
))).toList());
}
class _CopyWithStubImpl$Query$DomainInfo$system$domainInfo<TRes>
implements CopyWith$Query$DomainInfo$system$domainInfo<TRes> {
_CopyWithStubImpl$Query$DomainInfo$system$domainInfo(this._res);
class _CopyWithStubImpl$Query$GetDnsRecords$system$domainInfo<TRes>
implements CopyWith$Query$GetDnsRecords$system$domainInfo<TRes> {
_CopyWithStubImpl$Query$GetDnsRecords$system$domainInfo(this._res);
TRes _res;
@ -2540,6 +2587,7 @@ class _CopyWithStubImpl$Query$DomainInfo$system$domainInfo<TRes>
String? $__typename,
}) =>
_res;
requiredDnsRecords(_fn) => _res;
}
@ -2562,6 +2610,7 @@ class Variables$Mutation$ChangeTimezone {
Map<String, dynamic> _$data;
String get timezone => (_$data['timezone'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$timezone = timezone;
@ -2574,6 +2623,7 @@ class Variables$Mutation$ChangeTimezone {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -2656,6 +2706,7 @@ class Mutation$ChangeTimezone {
);
}
@Deprecated('Use `system.change_timezone` instead')
final Mutation$ChangeTimezone$changeTimezone changeTimezone;
final String $__typename;
@ -2751,6 +2802,7 @@ class _CopyWithImpl$Mutation$ChangeTimezone<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$ChangeTimezone$changeTimezone<TRes> get changeTimezone {
final local$changeTimezone = _instance.changeTimezone;
return CopyWith$Mutation$ChangeTimezone$changeTimezone(
@ -2769,6 +2821,7 @@ class _CopyWithStubImpl$Mutation$ChangeTimezone<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$ChangeTimezone$changeTimezone<TRes> get changeTimezone =>
CopyWith$Mutation$ChangeTimezone$changeTimezone.stub(_res);
}
@ -3137,6 +3190,7 @@ class Variables$Mutation$ChangeAutoUpgradeSettings {
Input$AutoUpgradeSettingsInput get settings =>
(_$data['settings'] as Input$AutoUpgradeSettingsInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$settings = settings;
@ -3150,6 +3204,7 @@ class Variables$Mutation$ChangeAutoUpgradeSettings {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -3234,6 +3289,7 @@ class Mutation$ChangeAutoUpgradeSettings {
);
}
@Deprecated('Use `system.change_auto_upgrade_settings` instead')
final Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings
changeAutoUpgradeSettings;
@ -3337,6 +3393,7 @@ class _CopyWithImpl$Mutation$ChangeAutoUpgradeSettings<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings<TRes>
get changeAutoUpgradeSettings {
final local$changeAutoUpgradeSettings = _instance.changeAutoUpgradeSettings;
@ -3358,6 +3415,7 @@ class _CopyWithStubImpl$Mutation$ChangeAutoUpgradeSettings<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings<TRes>
get changeAutoUpgradeSettings =>
CopyWith$Mutation$ChangeAutoUpgradeSettings$changeAutoUpgradeSettings

View File

@ -115,6 +115,7 @@ class _CopyWithImpl$Query$AllServices<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$AllServices$services<TRes> get services {
final local$services = _instance.services;
return CopyWith$Query$AllServices$services(
@ -133,6 +134,7 @@ class _CopyWithStubImpl$Query$AllServices<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$AllServices$services<TRes> get services =>
CopyWith$Query$AllServices$services.stub(_res);
}
@ -575,6 +577,7 @@ class _CopyWithImpl$Query$AllServices$services<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes allServices(
Iterable<Query$AllServices$services$allServices> Function(
Iterable<
@ -600,6 +603,7 @@ class _CopyWithStubImpl$Query$AllServices$services<TRes>
String? $__typename,
}) =>
_res;
allServices(_fn) => _res;
}
@ -965,6 +969,7 @@ class _CopyWithImpl$Query$AllServices$services$allServices<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes dnsRecords(
Iterable<Fragment$fragmentDnsRecords>? Function(
Iterable<
@ -977,6 +982,7 @@ class _CopyWithImpl$Query$AllServices$services$allServices<TRes>
e,
(i) => i,
)))?.toList());
CopyWith$Query$AllServices$services$allServices$storageUsage<TRes>
get storageUsage {
final local$storageUsage = _instance.storageUsage;
@ -1008,7 +1014,9 @@ class _CopyWithStubImpl$Query$AllServices$services$allServices<TRes>
String? $__typename,
}) =>
_res;
dnsRecords(_fn) => _res;
CopyWith$Query$AllServices$services$allServices$storageUsage<TRes>
get storageUsage =>
CopyWith$Query$AllServices$services$allServices$storageUsage.stub(
@ -1176,6 +1184,7 @@ class _CopyWithImpl$Query$AllServices$services$allServices$storageUsage<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$AllServices$services$allServices$storageUsage$volume<TRes>
get volume {
final local$volume = _instance.volume;
@ -1203,6 +1212,7 @@ class _CopyWithStubImpl$Query$AllServices$services$allServices$storageUsage<
String? $__typename,
}) =>
_res;
CopyWith$Query$AllServices$services$allServices$storageUsage$volume<TRes>
get volume =>
CopyWith$Query$AllServices$services$allServices$storageUsage$volume
@ -1367,6 +1377,7 @@ class Variables$Mutation$EnableService {
Map<String, dynamic> _$data;
String get serviceId => (_$data['serviceId'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$serviceId = serviceId;
@ -1379,6 +1390,7 @@ class Variables$Mutation$EnableService {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -1461,6 +1473,7 @@ class Mutation$EnableService {
);
}
@Deprecated('Use `services.enable_service` instead')
final Mutation$EnableService$enableService enableService;
final String $__typename;
@ -1556,6 +1569,7 @@ class _CopyWithImpl$Mutation$EnableService<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$EnableService$enableService<TRes> get enableService {
final local$enableService = _instance.enableService;
return CopyWith$Mutation$EnableService$enableService(
@ -1574,6 +1588,7 @@ class _CopyWithStubImpl$Mutation$EnableService<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$EnableService$enableService<TRes> get enableService =>
CopyWith$Mutation$EnableService$enableService.stub(_res);
}
@ -1913,6 +1928,7 @@ class Variables$Mutation$DisableService {
Map<String, dynamic> _$data;
String get serviceId => (_$data['serviceId'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$serviceId = serviceId;
@ -1925,6 +1941,7 @@ class Variables$Mutation$DisableService {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -2007,6 +2024,7 @@ class Mutation$DisableService {
);
}
@Deprecated('Use `services.disable_service` instead')
final Mutation$DisableService$disableService disableService;
final String $__typename;
@ -2102,6 +2120,7 @@ class _CopyWithImpl$Mutation$DisableService<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$DisableService$disableService<TRes> get disableService {
final local$disableService = _instance.disableService;
return CopyWith$Mutation$DisableService$disableService(
@ -2120,6 +2139,7 @@ class _CopyWithStubImpl$Mutation$DisableService<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$DisableService$disableService<TRes> get disableService =>
CopyWith$Mutation$DisableService$disableService.stub(_res);
}
@ -2458,6 +2478,7 @@ class Variables$Mutation$StopService {
Map<String, dynamic> _$data;
String get serviceId => (_$data['serviceId'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$serviceId = serviceId;
@ -2470,6 +2491,7 @@ class Variables$Mutation$StopService {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -2552,6 +2574,7 @@ class Mutation$StopService {
);
}
@Deprecated('Use `services.stop_service` instead')
final Mutation$StopService$stopService stopService;
final String $__typename;
@ -2646,6 +2669,7 @@ class _CopyWithImpl$Mutation$StopService<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$StopService$stopService<TRes> get stopService {
final local$stopService = _instance.stopService;
return CopyWith$Mutation$StopService$stopService(
@ -2664,6 +2688,7 @@ class _CopyWithStubImpl$Mutation$StopService<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$StopService$stopService<TRes> get stopService =>
CopyWith$Mutation$StopService$stopService.stub(_res);
}
@ -2998,6 +3023,7 @@ class Variables$Mutation$StartService {
Map<String, dynamic> _$data;
String get serviceId => (_$data['serviceId'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$serviceId = serviceId;
@ -3010,6 +3036,7 @@ class Variables$Mutation$StartService {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -3092,6 +3119,7 @@ class Mutation$StartService {
);
}
@Deprecated('Use `services.start_service` instead')
final Mutation$StartService$startService startService;
final String $__typename;
@ -3186,6 +3214,7 @@ class _CopyWithImpl$Mutation$StartService<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$StartService$startService<TRes> get startService {
final local$startService = _instance.startService;
return CopyWith$Mutation$StartService$startService(
@ -3204,6 +3233,7 @@ class _CopyWithStubImpl$Mutation$StartService<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$StartService$startService<TRes> get startService =>
CopyWith$Mutation$StartService$startService.stub(_res);
}
@ -3541,6 +3571,7 @@ class Variables$Mutation$RestartService {
Map<String, dynamic> _$data;
String get serviceId => (_$data['serviceId'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$serviceId = serviceId;
@ -3553,6 +3584,7 @@ class Variables$Mutation$RestartService {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -3635,6 +3667,7 @@ class Mutation$RestartService {
);
}
@Deprecated('Use `services.restart_service` instead')
final Mutation$RestartService$restartService restartService;
final String $__typename;
@ -3730,6 +3763,7 @@ class _CopyWithImpl$Mutation$RestartService<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RestartService$restartService<TRes> get restartService {
final local$restartService = _instance.restartService;
return CopyWith$Mutation$RestartService$restartService(
@ -3748,6 +3782,7 @@ class _CopyWithStubImpl$Mutation$RestartService<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RestartService$restartService<TRes> get restartService =>
CopyWith$Mutation$RestartService$restartService.stub(_res);
}
@ -4089,6 +4124,7 @@ class Variables$Mutation$MoveService {
Input$MoveServiceInput get input =>
(_$data['input'] as Input$MoveServiceInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$input = input;
@ -4101,6 +4137,7 @@ class Variables$Mutation$MoveService {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -4183,6 +4220,7 @@ class Mutation$MoveService {
);
}
@Deprecated('Use `services.move_service` instead')
final Mutation$MoveService$moveService moveService;
final String $__typename;
@ -4277,6 +4315,7 @@ class _CopyWithImpl$Mutation$MoveService<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$MoveService$moveService<TRes> get moveService {
final local$moveService = _instance.moveService;
return CopyWith$Mutation$MoveService$moveService(
@ -4295,6 +4334,7 @@ class _CopyWithStubImpl$Mutation$MoveService<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$MoveService$moveService<TRes> get moveService =>
CopyWith$Mutation$MoveService$moveService.stub(_res);
}
@ -4637,6 +4677,7 @@ class _CopyWithImpl$Mutation$MoveService$moveService<TRes>
? _instance.job
: (job as Fragment$basicApiJobsFields?),
));
CopyWith$Fragment$basicApiJobsFields<TRes> get job {
final local$job = _instance.job;
return local$job == null
@ -4659,6 +4700,7 @@ class _CopyWithStubImpl$Mutation$MoveService$moveService<TRes>
Fragment$basicApiJobsFields? job,
}) =>
_res;
CopyWith$Fragment$basicApiJobsFields<TRes> get job =>
CopyWith$Fragment$basicApiJobsFields.stub(_res);
}

View File

@ -361,6 +361,7 @@ class _CopyWithImpl$Query$AllUsers<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$AllUsers$users<TRes> get users {
final local$users = _instance.users;
return CopyWith$Query$AllUsers$users(local$users, (e) => call(users: e));
@ -378,6 +379,7 @@ class _CopyWithStubImpl$Query$AllUsers<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$AllUsers$users<TRes> get users =>
CopyWith$Query$AllUsers$users.stub(_res);
}
@ -719,6 +721,7 @@ class _CopyWithImpl$Query$AllUsers$users<TRes>
? _instance.$__typename
: ($__typename as String),
));
TRes allUsers(
Iterable<Fragment$userFields> Function(
Iterable<CopyWith$Fragment$userFields<Fragment$userFields>>)
@ -729,6 +732,7 @@ class _CopyWithImpl$Query$AllUsers$users<TRes>
e,
(i) => i,
))).toList());
CopyWith$Fragment$userFields<TRes> get rootUser {
final local$rootUser = _instance.rootUser;
return local$rootUser == null
@ -750,7 +754,9 @@ class _CopyWithStubImpl$Query$AllUsers$users<TRes>
String? $__typename,
}) =>
_res;
allUsers(_fn) => _res;
CopyWith$Fragment$userFields<TRes> get rootUser =>
CopyWith$Fragment$userFields.stub(_res);
}
@ -773,6 +779,7 @@ class Variables$Query$GetUser {
Map<String, dynamic> _$data;
String get username => (_$data['username'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$username = username;
@ -785,6 +792,7 @@ class Variables$Query$GetUser {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -959,6 +967,7 @@ class _CopyWithImpl$Query$GetUser<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Query$GetUser$users<TRes> get users {
final local$users = _instance.users;
return CopyWith$Query$GetUser$users(local$users, (e) => call(users: e));
@ -976,6 +985,7 @@ class _CopyWithStubImpl$Query$GetUser<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Query$GetUser$users<TRes> get users =>
CopyWith$Query$GetUser$users.stub(_res);
}
@ -1288,6 +1298,7 @@ class _CopyWithImpl$Query$GetUser$users<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Fragment$userFields<TRes> get getUser {
final local$getUser = _instance.getUser;
return local$getUser == null
@ -1307,6 +1318,7 @@ class _CopyWithStubImpl$Query$GetUser$users<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Fragment$userFields<TRes> get getUser =>
CopyWith$Fragment$userFields.stub(_res);
}
@ -1332,6 +1344,7 @@ class Variables$Mutation$CreateUser {
Input$UserMutationInput get user =>
(_$data['user'] as Input$UserMutationInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$user = user;
@ -1344,6 +1357,7 @@ class Variables$Mutation$CreateUser {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -1426,6 +1440,7 @@ class Mutation$CreateUser {
);
}
@Deprecated('Use `users.create_user` instead')
final Mutation$CreateUser$createUser createUser;
final String $__typename;
@ -1520,6 +1535,7 @@ class _CopyWithImpl$Mutation$CreateUser<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$CreateUser$createUser<TRes> get createUser {
final local$createUser = _instance.createUser;
return CopyWith$Mutation$CreateUser$createUser(
@ -1538,6 +1554,7 @@ class _CopyWithStubImpl$Mutation$CreateUser<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$CreateUser$createUser<TRes> get createUser =>
CopyWith$Mutation$CreateUser$createUser.stub(_res);
}
@ -1878,6 +1895,7 @@ class _CopyWithImpl$Mutation$CreateUser$createUser<TRes>
? _instance.user
: (user as Fragment$userFields?),
));
CopyWith$Fragment$userFields<TRes> get user {
final local$user = _instance.user;
return local$user == null
@ -1900,6 +1918,7 @@ class _CopyWithStubImpl$Mutation$CreateUser$createUser<TRes>
Fragment$userFields? user,
}) =>
_res;
CopyWith$Fragment$userFields<TRes> get user =>
CopyWith$Fragment$userFields.stub(_res);
}
@ -1922,6 +1941,7 @@ class Variables$Mutation$DeleteUser {
Map<String, dynamic> _$data;
String get username => (_$data['username'] as String);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$username = username;
@ -1934,6 +1954,7 @@ class Variables$Mutation$DeleteUser {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -2016,6 +2037,7 @@ class Mutation$DeleteUser {
);
}
@Deprecated('Use `users.delete_user` instead')
final Mutation$DeleteUser$deleteUser deleteUser;
final String $__typename;
@ -2110,6 +2132,7 @@ class _CopyWithImpl$Mutation$DeleteUser<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$DeleteUser$deleteUser<TRes> get deleteUser {
final local$deleteUser = _instance.deleteUser;
return CopyWith$Mutation$DeleteUser$deleteUser(
@ -2128,6 +2151,7 @@ class _CopyWithStubImpl$Mutation$DeleteUser<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$DeleteUser$deleteUser<TRes> get deleteUser =>
CopyWith$Mutation$DeleteUser$deleteUser.stub(_res);
}
@ -2464,6 +2488,7 @@ class Variables$Mutation$UpdateUser {
Input$UserMutationInput get user =>
(_$data['user'] as Input$UserMutationInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$user = user;
@ -2476,6 +2501,7 @@ class Variables$Mutation$UpdateUser {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -2558,6 +2584,7 @@ class Mutation$UpdateUser {
);
}
@Deprecated('Use `users.update_user` instead')
final Mutation$UpdateUser$updateUser updateUser;
final String $__typename;
@ -2652,6 +2679,7 @@ class _CopyWithImpl$Mutation$UpdateUser<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$UpdateUser$updateUser<TRes> get updateUser {
final local$updateUser = _instance.updateUser;
return CopyWith$Mutation$UpdateUser$updateUser(
@ -2670,6 +2698,7 @@ class _CopyWithStubImpl$Mutation$UpdateUser<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$UpdateUser$updateUser<TRes> get updateUser =>
CopyWith$Mutation$UpdateUser$updateUser.stub(_res);
}
@ -3010,6 +3039,7 @@ class _CopyWithImpl$Mutation$UpdateUser$updateUser<TRes>
? _instance.user
: (user as Fragment$userFields?),
));
CopyWith$Fragment$userFields<TRes> get user {
final local$user = _instance.user;
return local$user == null
@ -3032,6 +3062,7 @@ class _CopyWithStubImpl$Mutation$UpdateUser$updateUser<TRes>
Fragment$userFields? user,
}) =>
_res;
CopyWith$Fragment$userFields<TRes> get user =>
CopyWith$Fragment$userFields.stub(_res);
}
@ -3057,6 +3088,7 @@ class Variables$Mutation$AddSshKey {
Input$SshMutationInput get sshInput =>
(_$data['sshInput'] as Input$SshMutationInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$sshInput = sshInput;
@ -3069,6 +3101,7 @@ class Variables$Mutation$AddSshKey {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -3151,6 +3184,7 @@ class Mutation$AddSshKey {
);
}
@Deprecated('Use `users.add_ssh_key` instead')
final Mutation$AddSshKey$addSshKey addSshKey;
final String $__typename;
@ -3245,6 +3279,7 @@ class _CopyWithImpl$Mutation$AddSshKey<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$AddSshKey$addSshKey<TRes> get addSshKey {
final local$addSshKey = _instance.addSshKey;
return CopyWith$Mutation$AddSshKey$addSshKey(
@ -3263,6 +3298,7 @@ class _CopyWithStubImpl$Mutation$AddSshKey<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$AddSshKey$addSshKey<TRes> get addSshKey =>
CopyWith$Mutation$AddSshKey$addSshKey.stub(_res);
}
@ -3603,6 +3639,7 @@ class _CopyWithImpl$Mutation$AddSshKey$addSshKey<TRes>
? _instance.user
: (user as Fragment$userFields?),
));
CopyWith$Fragment$userFields<TRes> get user {
final local$user = _instance.user;
return local$user == null
@ -3625,6 +3662,7 @@ class _CopyWithStubImpl$Mutation$AddSshKey$addSshKey<TRes>
Fragment$userFields? user,
}) =>
_res;
CopyWith$Fragment$userFields<TRes> get user =>
CopyWith$Fragment$userFields.stub(_res);
}
@ -3650,6 +3688,7 @@ class Variables$Mutation$RemoveSshKey {
Input$SshMutationInput get sshInput =>
(_$data['sshInput'] as Input$SshMutationInput);
Map<String, dynamic> toJson() {
final result$data = <String, dynamic>{};
final l$sshInput = sshInput;
@ -3662,6 +3701,7 @@ class Variables$Mutation$RemoveSshKey {
this,
(i) => i,
);
@override
bool operator ==(Object other) {
if (identical(this, other)) {
@ -3744,6 +3784,7 @@ class Mutation$RemoveSshKey {
);
}
@Deprecated('Use `users.remove_ssh_key` instead')
final Mutation$RemoveSshKey$removeSshKey removeSshKey;
final String $__typename;
@ -3838,6 +3879,7 @@ class _CopyWithImpl$Mutation$RemoveSshKey<TRes>
? _instance.$__typename
: ($__typename as String),
));
CopyWith$Mutation$RemoveSshKey$removeSshKey<TRes> get removeSshKey {
final local$removeSshKey = _instance.removeSshKey;
return CopyWith$Mutation$RemoveSshKey$removeSshKey(
@ -3856,6 +3898,7 @@ class _CopyWithStubImpl$Mutation$RemoveSshKey<TRes>
String? $__typename,
}) =>
_res;
CopyWith$Mutation$RemoveSshKey$removeSshKey<TRes> get removeSshKey =>
CopyWith$Mutation$RemoveSshKey$removeSshKey.stub(_res);
}
@ -4199,6 +4242,7 @@ class _CopyWithImpl$Mutation$RemoveSshKey$removeSshKey<TRes>
? _instance.user
: (user as Fragment$userFields?),
));
CopyWith$Fragment$userFields<TRes> get user {
final local$user = _instance.user;
return local$user == null
@ -4221,6 +4265,7 @@ class _CopyWithStubImpl$Mutation$RemoveSshKey$removeSshKey<TRes>
Fragment$userFields? user,
}) =>
_res;
CopyWith$Fragment$userFields<TRes> get user =>
CopyWith$Fragment$userFields.stub(_res);
}

View File

@ -286,11 +286,11 @@ class ServerApi extends GraphQLApiMap
Future<List<DnsRecord>> getDnsRecords() async {
List<DnsRecord> records = [];
QueryResult<Query$DomainInfo> response;
QueryResult<Query$GetDnsRecords> response;
try {
final GraphQLClient client = await getClient();
response = await client.query$DomainInfo();
response = await client.query$GetDnsRecords();
if (response.hasException) {
print(response.exception.toString());
}

View File

@ -4,7 +4,7 @@ import 'package:dio/dio.dart';
import 'package:selfprivacy/config/get_it_config.dart';
import 'package:selfprivacy/logic/api_maps/generic_result.dart';
import 'package:selfprivacy/logic/api_maps/rest_maps/rest_api_map.dart';
import 'package:selfprivacy/logic/models/json/cloudflare_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_providers/cloudflare_dns_info.dart';
class CloudflareApi extends RestApiMap {
CloudflareApi({

View File

@ -4,7 +4,7 @@ import 'package:dio/dio.dart';
import 'package:selfprivacy/config/get_it_config.dart';
import 'package:selfprivacy/logic/api_maps/generic_result.dart';
import 'package:selfprivacy/logic/api_maps/rest_maps/rest_api_map.dart';
import 'package:selfprivacy/logic/models/json/desec_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_providers/desec_dns_info.dart';
class DesecApi extends RestApiMap {
DesecApi({

View File

@ -4,7 +4,7 @@ import 'package:dio/dio.dart';
import 'package:selfprivacy/config/get_it_config.dart';
import 'package:selfprivacy/logic/api_maps/generic_result.dart';
import 'package:selfprivacy/logic/api_maps/rest_maps/rest_api_map.dart';
import 'package:selfprivacy/logic/models/json/digital_ocean_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_providers/digital_ocean_dns_info.dart';
class DigitalOceanDnsApi extends RestApiMap {
DigitalOceanDnsApi({

View File

@ -23,15 +23,9 @@ class DnsRecordsCubit
@override
Future<void> load() async {
emit(
DnsRecordsState(
const DnsRecordsState(
dnsState: DnsRecordsStatus.refreshing,
dnsRecords:
ProvidersController.currentDnsProvider?.getDesiredDnsRecords(
serverInstallationCubit.state.serverDomain?.domainName,
'',
'',
) ??
[],
dnsRecords: [],
),
);
@ -39,16 +33,18 @@ class DnsRecordsCubit
final ServerDomain? domain = serverInstallationCubit.state.serverDomain;
final String? ipAddress =
serverInstallationCubit.state.serverDetails?.ip4;
if (domain == null && ipAddress == null) {
if (domain == null || ipAddress == null) {
emit(const DnsRecordsState());
return;
}
final foundRecords =
await ProvidersController.currentDnsProvider!.validateDnsRecords(
domain!,
ipAddress!,
extractDkimRecord(await api.getDnsRecords())?.content ?? '',
final List<DnsRecord> allDnsRecords = await api.getDnsRecords();
allDnsRecords.removeWhere((final record) => record.type == 'AAAA');
final foundRecords = await validateDnsRecords(
domain,
extractDkimRecord(allDnsRecords)?.content ?? '',
allDnsRecords,
);
if (!foundRecords.success || foundRecords.data.isEmpty) {
@ -67,6 +63,93 @@ class DnsRecordsCubit
}
}
/// Tries to check whether all known DNS records on the domain by ip4
/// match expectations of SelfPrivacy in order to launch.
///
/// Will return list of [DesiredDnsRecord] objects, which represent
/// only those records which have successfully passed validation.
Future<GenericResult<List<DesiredDnsRecord>>> validateDnsRecords(
final ServerDomain domain,
final String dkimPublicKey,
final List<DnsRecord> pendingDnsRecords,
) async {
final result = await ProvidersController.currentDnsProvider!
.getDnsRecords(domain: domain);
if (result.data.isEmpty || !result.success) {
return GenericResult(
success: result.success,
data: [],
code: result.code,
message: result.message,
);
}
final List<DnsRecord> providerDnsRecords = result.data;
final List<DesiredDnsRecord> foundRecords = [];
try {
for (final DnsRecord pendingDnsRecord in pendingDnsRecords) {
if (pendingDnsRecord.name == 'selector._domainkey') {
final foundRecord = providerDnsRecords.firstWhere(
(final r) =>
(r.name == pendingDnsRecord.name) &&
r.type == pendingDnsRecord.type,
orElse: () => DnsRecord(
displayName: pendingDnsRecord.displayName,
name: pendingDnsRecord.name,
type: pendingDnsRecord.type,
content: pendingDnsRecord.content,
ttl: pendingDnsRecord.ttl,
),
);
final String foundContent =
foundRecord.content!.replaceAll(RegExp(r'\s+'), '').trim();
final String desiredContent =
pendingDnsRecord.content!.replaceAll(RegExp(r'\s+'), '').trim();
final isSatisfied = (desiredContent == foundContent);
foundRecords.add(
DesiredDnsRecord(
name: pendingDnsRecord.name!,
displayName: pendingDnsRecord.displayName,
content: pendingDnsRecord.content!,
isSatisfied: isSatisfied,
type: pendingDnsRecord.type,
category: DnsRecordsCategory.email,
),
);
} else {
final foundMatch = providerDnsRecords.any(
(final r) =>
r.name == pendingDnsRecord.name &&
r.type == pendingDnsRecord.type &&
r.content == pendingDnsRecord.content,
);
foundRecords.add(
DesiredDnsRecord(
name: pendingDnsRecord.name!,
displayName: pendingDnsRecord.displayName,
content: pendingDnsRecord.content!,
isSatisfied: foundMatch,
category: pendingDnsRecord.type == 'A'
? DnsRecordsCategory.services
: DnsRecordsCategory.email,
),
);
}
}
} catch (e) {
print(e);
return GenericResult(
data: [],
success: false,
message: e.toString(),
);
}
return GenericResult(
data: foundRecords,
success: true,
);
}
@override
void onChange(final Change<DnsRecordsState> change) {
// print(change);

View File

@ -11,14 +11,22 @@ class DomainSetupCubit extends Cubit<DomainSetupState> {
Future<void> load() async {
emit(Loading(LoadingTypes.loadingDomain));
final GenericResult<List<String>> result =
final GenericResult<List<ServerDomain>> result =
await ProvidersController.currentDnsProvider!.domainList();
if (!result.success || result.data.isEmpty) {
emit(Empty());
} else if (result.data.length == 1) {
emit(Loaded(result.data.first));
emit(Loaded(result.data.first.domainName));
} else {
emit(MoreThenOne(result.data));
emit(
MoreThenOne(
result.data
.map<String>(
(final d) => d.domainName,
)
.toList(),
),
);
}
}

View File

@ -210,7 +210,9 @@ class ServerInstallationRepository {
return false;
}
return domainResult.data.contains(domain);
return domainResult.data.any(
(final serverDomain) => serverDomain.domainName == domain,
);
}
Future<void> createDkimRecord(final ServerDomain domain) async {

View File

@ -0,0 +1,43 @@
part of 'cloudflare_dns_info.dart';
CloudflareDnsRecord _fromDnsRecord(
final DnsRecord dnsRecord,
final String rootDomain,
) {
String name = dnsRecord.name ?? '';
if (name != rootDomain && name != '@') {
name = '$name.$rootDomain';
}
return CloudflareDnsRecord(
content: dnsRecord.content,
name: name,
type: dnsRecord.type,
zoneName: rootDomain,
id: null,
ttl: dnsRecord.ttl,
);
}
DnsRecord _toDnsRecord(
final CloudflareDnsRecord cloudflareRecord,
final String domainName,
) {
String? name = cloudflareRecord.name;
if (name != null && name.endsWith('.$domainName')) {
// e.g. 'api.example.com -> [api] [example] [com] -> [api]'
name = name.split('.')[0];
}
return DnsRecord(
content: cloudflareRecord.content,
type: cloudflareRecord.type,
ttl: cloudflareRecord.ttl,
name: name,
);
}
ServerDomain _toServerDomain(final CloudflareZone cloudflareZone) =>
ServerDomain(
domainName: cloudflareZone.name,
provider: DnsProviderType.cloudflare,
);

View File

@ -1,6 +1,9 @@
import 'package:json_annotation/json_annotation.dart';
import 'package:selfprivacy/logic/models/hive/server_domain.dart';
import 'package:selfprivacy/logic/models/json/dns_records.dart';
part 'cloudflare_dns_info.g.dart';
part 'cloudflare_dns_adapter.dart';
/// https://developers.cloudflare.com/api/operations/zones-get
@JsonSerializable()
@ -26,6 +29,7 @@ class CloudflareZone {
static CloudflareZone fromJson(final Map<String, dynamic> json) =>
_$CloudflareZoneFromJson(json);
ServerDomain toServerDomain() => _toServerDomain(this);
}
/// https://developers.cloudflare.com/api/operations/dns-records-for-a-zone-list-dns-records
@ -41,6 +45,12 @@ class CloudflareDnsRecord {
this.id,
});
factory CloudflareDnsRecord.fromDnsRecord(
final DnsRecord dnsRecord,
final String rootDomain,
) =>
_fromDnsRecord(dnsRecord, rootDomain);
/// Record identifier
///
/// `<= 32 characters`
@ -83,4 +93,6 @@ class CloudflareDnsRecord {
static CloudflareDnsRecord fromJson(final Map<String, dynamic> json) =>
_$CloudflareDnsRecordFromJson(json);
Map<String, dynamic> toJson() => _$CloudflareDnsRecordToJson(this);
DnsRecord toDnsRecord(final String domainName) =>
_toDnsRecord(this, domainName);
}

View File

@ -0,0 +1,68 @@
part of 'desec_dns_info.dart';
DesecDnsRecord _fromDnsRecord(
final DnsRecord dnsRecord,
final String domainName,
) {
final String type = dnsRecord.type;
String content = dnsRecord.content ?? '';
String name = dnsRecord.name ?? '';
if (name == '@' || name == domainName) {
name = '';
}
if (type == 'MX') {
content = '${dnsRecord.priority} $content.';
}
if (type == 'TXT' && content.isNotEmpty && !content.startsWith('"')) {
content = '"$content"';
}
return DesecDnsRecord(
subname: name,
type: type,
ttl: dnsRecord.ttl,
records: [content],
);
}
DnsRecord _toDnsRecord(
final DesecDnsRecord desecRecord,
final String domainName,
) {
final String type = desecRecord.type;
String content = desecRecord.records.isEmpty ? '' : desecRecord.records[0];
String name = desecRecord.subname;
int? priority;
if (type == 'MX') {
name = name.isEmpty ? domainName : name;
final contentBulk = content.split(' ');
content = contentBulk[1];
if (content.contains(domainName)) {
content =
content.substring(0, content.length - 1); // cut away trailing dot
}
priority = int.parse(contentBulk[0]);
}
if (type == 'TXT' && content.isNotEmpty && content.startsWith('"')) {
content = content.substring(1, content.length - 1); // cut away quotes
}
if (name.isEmpty) {
name = domainName;
}
return DnsRecord(
name: name,
type: type,
ttl: desecRecord.ttl,
content: content,
priority: priority ?? 10,
);
}
DesecDomain _fromServerDomain(final ServerDomain serverDomain) =>
DesecDomain(name: serverDomain.domainName);
ServerDomain _toServerDomain(final DesecDomain desecDomain) => ServerDomain(
domainName: desecDomain.name,
provider: DnsProviderType.desec,
);

View File

@ -1,14 +1,19 @@
import 'package:json_annotation/json_annotation.dart';
import 'package:selfprivacy/logic/models/hive/server_domain.dart';
import 'package:selfprivacy/logic/models/json/dns_records.dart';
part 'desec_dns_adapter.dart';
part 'desec_dns_info.g.dart';
/// https://desec.readthedocs.io/en/latest/dns/domains.html#domain-management
@JsonSerializable()
class DesecDomain {
DesecDomain(
this.name,
DesecDomain({
required this.name,
this.minimumTtl,
);
});
factory DesecDomain.fromServerDomain(final ServerDomain serverDomain) =>
_fromServerDomain(serverDomain);
/// Restrictions on what is a valid domain name apply on
/// a per-user basis.
@ -19,10 +24,11 @@ class DesecDomain {
/// Smallest TTL that can be used in an RRset.
/// The value is set automatically by DESEC
@JsonKey(name: 'minimum_ttl')
final int minimumTtl;
final int? minimumTtl;
static DesecDomain fromJson(final Map<String, dynamic> json) =>
_$DesecDomainFromJson(json);
ServerDomain toServerDomain() => _toServerDomain(this);
}
/// https://desec.readthedocs.io/en/latest/dns/rrsets.html#retrieving-and-creating-dns-records
@ -35,6 +41,12 @@ class DesecDnsRecord {
required this.records,
});
factory DesecDnsRecord.fromDnsRecord(
final DnsRecord dnsRecord,
final String domainName,
) =>
_fromDnsRecord(dnsRecord, domainName);
/// Subdomain string which, together with domain, defines the RRset name.
/// Typical examples are www or _443._tcp.
final String subname;
@ -60,4 +72,6 @@ class DesecDnsRecord {
static DesecDnsRecord fromJson(final Map<String, dynamic> json) =>
_$DesecDnsRecordFromJson(json);
Map<String, dynamic> toJson() => _$DesecDnsRecordToJson(this);
DnsRecord toDnsRecord(final String domainName) =>
_toDnsRecord(this, domainName);
}

View File

@ -7,8 +7,8 @@ part of 'desec_dns_info.dart';
// **************************************************************************
DesecDomain _$DesecDomainFromJson(Map<String, dynamic> json) => DesecDomain(
json['name'] as String,
json['minimum_ttl'] as int,
name: json['name'] as String,
minimumTtl: json['minimum_ttl'] as int?,
);
Map<String, dynamic> _$DesecDomainToJson(DesecDomain instance) =>

View File

@ -0,0 +1,47 @@
part of 'digital_ocean_dns_info.dart';
DigitalOceanDnsRecord _fromDnsRecord(
final DnsRecord dnsRecord,
final String rootDomain,
) {
String convert(final String entry) => (entry == rootDomain) ? '@' : entry;
String name = dnsRecord.name ?? '';
String content = dnsRecord.content ?? '';
name = convert(name);
content = convert(content);
return DigitalOceanDnsRecord(
name: name,
data: content,
ttl: dnsRecord.ttl,
type: dnsRecord.type,
priority: dnsRecord.priority,
id: null,
);
}
DnsRecord _toDnsRecord(
final DigitalOceanDnsRecord digitalOceanRecord,
final String rootDomain,
) {
final String type = digitalOceanRecord.type;
String convert(final String entry) => (entry == '@') ? rootDomain : entry;
String name = digitalOceanRecord.name;
final String content = convert(digitalOceanRecord.data);
name = (name == '@') ? rootDomain : name;
return DnsRecord(
name: name,
content: content,
ttl: digitalOceanRecord.ttl,
type: type,
priority: digitalOceanRecord.priority ?? 10,
);
}
ServerDomain _toServerDomain(final DigitalOceanDomain digitalOceanDomain) =>
ServerDomain(
domainName: digitalOceanDomain.name,
provider: DnsProviderType.digitalOcean,
);
DigitalOceanDomain _fromServerDomain(final ServerDomain serverDomain) =>
DigitalOceanDomain(name: serverDomain.domainName);

View File

@ -1,6 +1,9 @@
import 'package:json_annotation/json_annotation.dart';
import 'package:selfprivacy/logic/models/hive/server_domain.dart';
import 'package:selfprivacy/logic/models/json/dns_records.dart';
part 'digital_ocean_dns_info.g.dart';
part 'digital_ocean_dns_adapter.dart';
/// https://docs.digitalocean.com/reference/api/api-reference/#tag/Domains
@JsonSerializable()
@ -10,6 +13,11 @@ class DigitalOceanDomain {
this.ttl,
});
factory DigitalOceanDomain.fromServerDomain(
final ServerDomain serverDomain,
) =>
_fromServerDomain(serverDomain);
/// The name of the domain itself.
/// This should follow the standard domain format of domain.TLD.
///
@ -23,6 +31,7 @@ class DigitalOceanDomain {
static DigitalOceanDomain fromJson(final Map<String, dynamic> json) =>
_$DigitalOceanDomainFromJson(json);
ServerDomain toServerDomain() => _toServerDomain(this);
}
/// https://docs.digitalocean.com/reference/api/api-reference/#tag/Domain-Records
@ -37,6 +46,15 @@ class DigitalOceanDnsRecord {
this.priority,
});
factory DigitalOceanDnsRecord.fromDnsRecord(
final DnsRecord dnsRecord,
final String rootDomain,
) =>
_fromDnsRecord(
dnsRecord,
rootDomain,
);
/// A unique identifier for each domain record.
final int? id;
@ -63,4 +81,6 @@ class DigitalOceanDnsRecord {
static DigitalOceanDnsRecord fromJson(final Map<String, dynamic> json) =>
_$DigitalOceanDnsRecordFromJson(json);
Map<String, dynamic> toJson() => _$DigitalOceanDnsRecordToJson(this);
DnsRecord toDnsRecord(final String rootDomain) =>
_toDnsRecord(this, rootDomain);
}

View File

@ -9,6 +9,7 @@ class DnsRecord {
required this.type,
required this.name,
required this.content,
this.displayName,
this.ttl = 3600,
this.priority = 10,
this.proxied = false,
@ -19,12 +20,14 @@ class DnsRecord {
) : this(
type: record.recordType,
name: record.name,
displayName: record.displayName,
content: record.content,
ttl: record.ttl,
priority: record.priority ?? 10,
);
final String type;
final String? displayName;
final String? name;
final String? content;
final int ttl;

View File

@ -8,6 +8,7 @@ part of 'dns_records.dart';
Map<String, dynamic> _$DnsRecordToJson(DnsRecord instance) => <String, dynamic>{
'type': instance.type,
'displayName': instance.displayName,
'name': instance.name,
'content': instance.content,
'ttl': instance.ttl,

View File

@ -1,9 +1,9 @@
import 'package:selfprivacy/logic/api_maps/rest_maps/dns_providers/cloudflare/cloudflare_api.dart';
import 'package:selfprivacy/logic/api_maps/rest_maps/dns_providers/desired_dns_record.dart';
import 'package:selfprivacy/logic/models/hive/server_domain.dart';
import 'package:selfprivacy/logic/models/json/cloudflare_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_providers/cloudflare_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_records.dart';
import 'package:selfprivacy/logic/providers/dns_providers/dns_provider.dart';
import 'package:selfprivacy/utils/network_utils.dart';
class ApiAdapter {
ApiAdapter({
@ -54,8 +54,8 @@ class CloudflareDnsProvider extends DnsProvider {
}
@override
Future<GenericResult<List<String>>> domainList() async {
List<String> domains = [];
Future<GenericResult<List<ServerDomain>>> domainList() async {
List<ServerDomain> domains = [];
final result = await _adapter.api().getZones();
if (result.data.isEmpty || !result.success) {
return GenericResult(
@ -67,8 +67,8 @@ class CloudflareDnsProvider extends DnsProvider {
}
domains = result.data
.map<String>(
(final el) => el.name,
.map<ServerDomain>(
(final el) => el.toServerDomain(),
)
.toList();
@ -93,14 +93,8 @@ class CloudflareDnsProvider extends DnsProvider {
zoneId: _adapter.cachedZoneId,
records: records
.map<CloudflareDnsRecord>(
(final rec) => CloudflareDnsRecord(
content: rec.content,
name: rec.name,
type: rec.type,
zoneName: domain.domainName,
id: null,
ttl: rec.ttl,
),
(final rec) =>
CloudflareDnsRecord.fromDnsRecord(rec, domain.domainName),
)
.toList(),
);
@ -160,14 +154,7 @@ class CloudflareDnsProvider extends DnsProvider {
}
for (final rawRecord in result.data) {
records.add(
DnsRecord(
name: rawRecord.name,
type: rawRecord.type,
content: rawRecord.content,
ttl: rawRecord.ttl,
),
);
records.add(rawRecord.toDnsRecord(domain.domainName));
}
return GenericResult(
@ -188,210 +175,10 @@ class CloudflareDnsProvider extends DnsProvider {
return _adapter.api().createMultipleDnsRecords(
zoneId: _adapter.cachedZoneId,
records: [
CloudflareDnsRecord(
content: record.content,
id: null,
name: record.name,
type: record.type,
zoneName: domain.domainName,
ttl: record.ttl,
),
],
records: [CloudflareDnsRecord.fromDnsRecord(record, domain.domainName)],
);
}
@override
Future<GenericResult<List<DesiredDnsRecord>>> validateDnsRecords(
final ServerDomain domain,
final String ip4,
final String dkimPublicKey,
) async {
final GenericResult<List<DnsRecord>> records =
await getDnsRecords(domain: domain);
final List<DesiredDnsRecord> foundRecords = [];
try {
final List<DesiredDnsRecord> desiredRecords =
getDesiredDnsRecords(domain.domainName, ip4, dkimPublicKey);
for (final DesiredDnsRecord record in desiredRecords) {
if (record.description == 'record.dkim') {
final DnsRecord foundRecord = records.data.firstWhere(
(final r) => (r.name == record.name) && r.type == record.type,
orElse: () => DnsRecord(
name: record.name,
type: record.type,
content: '',
ttl: 800,
proxied: false,
),
);
// remove all spaces and tabulators from
// the foundRecord.content and the record.content
// to compare them
final String? foundContent =
foundRecord.content?.replaceAll(RegExp(r'\s+'), '');
final String content = record.content.replaceAll(RegExp(r'\s+'), '');
if (foundContent == content) {
foundRecords.add(record.copyWith(isSatisfied: true));
} else {
foundRecords.add(record.copyWith(isSatisfied: false));
}
} else {
if (records.data.any(
(final r) =>
(r.name == record.name) &&
r.type == record.type &&
r.content == record.content,
)) {
foundRecords.add(record.copyWith(isSatisfied: true));
} else {
foundRecords.add(record.copyWith(isSatisfied: false));
}
}
}
} catch (e) {
print(e);
return GenericResult(
data: [],
success: false,
message: e.toString(),
);
}
return GenericResult(
data: foundRecords,
success: true,
);
}
@override
List<DesiredDnsRecord> getDesiredDnsRecords(
final String? domainName,
final String? ip4,
final String? dkimPublicKey,
) {
if (domainName == null || ip4 == null) {
return [];
}
return [
DesiredDnsRecord(
name: domainName,
content: ip4,
description: 'record.root',
),
DesiredDnsRecord(
name: 'api.$domainName',
content: ip4,
description: 'record.api',
),
DesiredDnsRecord(
name: 'cloud.$domainName',
content: ip4,
description: 'record.cloud',
),
DesiredDnsRecord(
name: 'git.$domainName',
content: ip4,
description: 'record.git',
),
DesiredDnsRecord(
name: 'meet.$domainName',
content: ip4,
description: 'record.meet',
),
DesiredDnsRecord(
name: 'social.$domainName',
content: ip4,
description: 'record.social',
),
DesiredDnsRecord(
name: 'password.$domainName',
content: ip4,
description: 'record.password',
),
DesiredDnsRecord(
name: 'vpn.$domainName',
content: ip4,
description: 'record.vpn',
),
DesiredDnsRecord(
name: domainName,
content: domainName,
description: 'record.mx',
type: 'MX',
category: DnsRecordsCategory.email,
),
DesiredDnsRecord(
name: '_dmarc.$domainName',
content: 'v=DMARC1; p=none',
description: 'record.dmarc',
type: 'TXT',
category: DnsRecordsCategory.email,
),
DesiredDnsRecord(
name: domainName,
content: 'v=spf1 a mx ip4:$ip4 -all',
description: 'record.spf',
type: 'TXT',
category: DnsRecordsCategory.email,
),
if (dkimPublicKey != null)
DesiredDnsRecord(
name: 'selector._domainkey.$domainName',
content: dkimPublicKey,
description: 'record.dkim',
type: 'TXT',
category: DnsRecordsCategory.email,
),
];
}
List<DnsRecord> getProjectDnsRecords(
final String? domainName,
final String? ip4,
) {
final DnsRecord domainA =
DnsRecord(type: 'A', name: domainName, content: ip4);
final DnsRecord mx = DnsRecord(type: 'MX', name: '@', content: domainName);
final DnsRecord apiA = DnsRecord(type: 'A', name: 'api', content: ip4);
final DnsRecord cloudA = DnsRecord(type: 'A', name: 'cloud', content: ip4);
final DnsRecord gitA = DnsRecord(type: 'A', name: 'git', content: ip4);
final DnsRecord meetA = DnsRecord(type: 'A', name: 'meet', content: ip4);
final DnsRecord passwordA =
DnsRecord(type: 'A', name: 'password', content: ip4);
final DnsRecord socialA =
DnsRecord(type: 'A', name: 'social', content: ip4);
final DnsRecord vpn = DnsRecord(type: 'A', name: 'vpn', content: ip4);
final DnsRecord txt1 = DnsRecord(
type: 'TXT',
name: '_dmarc',
content: 'v=DMARC1; p=none',
ttl: 18000,
);
final DnsRecord txt2 = DnsRecord(
type: 'TXT',
name: domainName,
content: 'v=spf1 a mx ip4:$ip4 -all',
ttl: 18000,
);
return <DnsRecord>[
domainA,
apiA,
cloudA,
gitA,
meetA,
passwordA,
socialA,
mx,
txt1,
txt2,
vpn,
];
}
Future<GenericResult<void>> syncZoneId(final String domain) async {
if (domain == _adapter.cachedDomain && _adapter.cachedZoneId.isNotEmpty) {
return GenericResult(

View File

@ -1,9 +1,9 @@
import 'package:selfprivacy/logic/api_maps/rest_maps/dns_providers/desec/desec_api.dart';
import 'package:selfprivacy/logic/api_maps/rest_maps/dns_providers/desired_dns_record.dart';
import 'package:selfprivacy/logic/models/hive/server_domain.dart';
import 'package:selfprivacy/logic/models/json/desec_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_providers/desec_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_records.dart';
import 'package:selfprivacy/logic/providers/dns_providers/dns_provider.dart';
import 'package:selfprivacy/utils/network_utils.dart';
class ApiAdapter {
ApiAdapter({final bool isWithToken = true})
@ -49,8 +49,8 @@ class DesecDnsProvider extends DnsProvider {
}
@override
Future<GenericResult<List<String>>> domainList() async {
List<String> domains = [];
Future<GenericResult<List<ServerDomain>>> domainList() async {
List<ServerDomain> domains = [];
final result = await _adapter.api().getDomains();
if (result.data.isEmpty || !result.success) {
return GenericResult(
@ -62,8 +62,8 @@ class DesecDnsProvider extends DnsProvider {
}
domains = result.data
.map<String>(
(final el) => el.name,
.map<ServerDomain>(
(final el) => el.toServerDomain(),
)
.toList();
@ -78,21 +78,14 @@ class DesecDnsProvider extends DnsProvider {
required final ServerDomain domain,
final String? ip4,
}) async {
final List<DnsRecord> listDnsRecords = projectDnsRecords(
final List<DnsRecord> listDnsRecords = getProjectDnsRecords(
domain.domainName,
ip4,
);
final List<DesecDnsRecord> bulkRecords = [];
for (final DnsRecord record in listDnsRecords) {
bulkRecords.add(
DesecDnsRecord(
subname: record.name ?? '',
type: record.type,
ttl: record.ttl,
records: [extractContent(record) ?? ''],
),
);
bulkRecords.add(DesecDnsRecord.fromDnsRecord(record, domain.domainName));
}
return _adapter.api().createMultipleDnsRecords(
@ -106,18 +99,22 @@ class DesecDnsProvider extends DnsProvider {
required final ServerDomain domain,
final String? ip4,
}) async {
final List<DnsRecord> listDnsRecords = projectDnsRecords(
final List<DnsRecord> listDnsRecords = getProjectDnsRecords(
domain.domainName,
ip4,
);
final List<DesecDnsRecord> bulkRecords = [];
for (final DnsRecord record in listDnsRecords) {
final desecRecord = DesecDnsRecord.fromDnsRecord(
record,
domain.domainName,
);
bulkRecords.add(
DesecDnsRecord(
subname: record.name ?? '',
type: record.type,
ttl: record.ttl,
subname: desecRecord.subname,
type: desecRecord.type,
ttl: desecRecord.ttl,
records: [],
),
);
@ -154,16 +151,7 @@ class DesecDnsProvider extends DnsProvider {
try {
for (final record in result.data) {
final String? content =
record.records.isEmpty ? null : record.records[0];
records.add(
DnsRecord(
name: record.subname,
type: record.type,
content: content,
ttl: record.ttl,
),
);
records.add(record.toDnsRecord(domain.domainName));
}
} catch (e) {
print(e);
@ -184,14 +172,7 @@ class DesecDnsProvider extends DnsProvider {
) async {
final result = await _adapter.api().createMultipleDnsRecords(
domainName: domain.domainName,
records: [
DesecDnsRecord(
subname: record.name ?? '',
type: record.type,
ttl: record.ttl,
records: [extractContent(record) ?? ''],
),
],
records: [DesecDnsRecord.fromDnsRecord(record, domain.domainName)],
);
return GenericResult(
@ -199,216 +180,4 @@ class DesecDnsProvider extends DnsProvider {
data: null,
);
}
String? extractContent(final DnsRecord record) {
String? content = record.content;
if (record.type == 'TXT' && content != null && !content.startsWith('"')) {
content = '"$content"';
}
return content;
}
@override
Future<GenericResult<List<DesiredDnsRecord>>> validateDnsRecords(
final ServerDomain domain,
final String ip4,
final String dkimPublicKey,
) async {
final result = await getDnsRecords(domain: domain);
if (result.data.isEmpty || !result.success) {
return GenericResult(
success: result.success,
data: [],
code: result.code,
message: result.message,
);
}
final records = result.data;
final List<DesiredDnsRecord> foundRecords = [];
try {
final List<DesiredDnsRecord> desiredRecords =
getDesiredDnsRecords(domain.domainName, ip4, dkimPublicKey);
for (final DesiredDnsRecord record in desiredRecords) {
if (record.description == 'record.dkim') {
final DnsRecord foundRecord = records.firstWhere(
(final r) =>
('${r.name}.${domain.domainName}' == record.name) &&
r.type == record.type,
orElse: () => DnsRecord(
name: record.name,
type: record.type,
content: '',
ttl: 800,
proxied: false,
),
);
// remove all spaces and tabulators from
// the foundRecord.content and the record.content
// to compare them
final String? foundContent =
foundRecord.content?.replaceAll(RegExp(r'\s+'), '');
final String content = record.content.replaceAll(RegExp(r'\s+'), '');
if (foundContent == content) {
foundRecords.add(record.copyWith(isSatisfied: true));
} else {
foundRecords.add(record.copyWith(isSatisfied: false));
}
} else {
if (records.any(
(final r) =>
('${r.name}.${domain.domainName}' == record.name ||
record.name == '') &&
r.type == record.type &&
r.content == record.content,
)) {
foundRecords.add(record.copyWith(isSatisfied: true));
} else {
foundRecords.add(record.copyWith(isSatisfied: false));
}
}
}
} catch (e) {
print(e);
return GenericResult(
data: [],
success: false,
message: e.toString(),
);
}
return GenericResult(
data: foundRecords,
success: true,
);
}
List<DnsRecord> projectDnsRecords(
final String? domainName,
final String? ip4,
) {
final DnsRecord domainA = DnsRecord(type: 'A', name: '', content: ip4);
final DnsRecord mx =
DnsRecord(type: 'MX', name: '', content: '10 $domainName.');
final DnsRecord apiA = DnsRecord(type: 'A', name: 'api', content: ip4);
final DnsRecord cloudA = DnsRecord(type: 'A', name: 'cloud', content: ip4);
final DnsRecord gitA = DnsRecord(type: 'A', name: 'git', content: ip4);
final DnsRecord meetA = DnsRecord(type: 'A', name: 'meet', content: ip4);
final DnsRecord passwordA =
DnsRecord(type: 'A', name: 'password', content: ip4);
final DnsRecord socialA =
DnsRecord(type: 'A', name: 'social', content: ip4);
final DnsRecord vpn = DnsRecord(type: 'A', name: 'vpn', content: ip4);
final DnsRecord txt1 = DnsRecord(
type: 'TXT',
name: '_dmarc',
content: '"v=DMARC1; p=none"',
ttl: 18000,
);
final DnsRecord txt2 = DnsRecord(
type: 'TXT',
name: '',
content: '"v=spf1 a mx ip4:$ip4 -all"',
ttl: 18000,
);
return <DnsRecord>[
domainA,
apiA,
cloudA,
gitA,
meetA,
passwordA,
socialA,
mx,
txt1,
txt2,
vpn,
];
}
@override
List<DesiredDnsRecord> getDesiredDnsRecords(
final String? domainName,
final String? ip4,
final String? dkimPublicKey,
) {
if (domainName == null || ip4 == null) {
return [];
}
return [
DesiredDnsRecord(
name: '',
content: ip4,
description: 'record.root',
),
DesiredDnsRecord(
name: 'api.$domainName',
content: ip4,
description: 'record.api',
),
DesiredDnsRecord(
name: 'cloud.$domainName',
content: ip4,
description: 'record.cloud',
),
DesiredDnsRecord(
name: 'git.$domainName',
content: ip4,
description: 'record.git',
),
DesiredDnsRecord(
name: 'meet.$domainName',
content: ip4,
description: 'record.meet',
),
DesiredDnsRecord(
name: 'social.$domainName',
content: ip4,
description: 'record.social',
),
DesiredDnsRecord(
name: 'password.$domainName',
content: ip4,
description: 'record.password',
),
DesiredDnsRecord(
name: 'vpn.$domainName',
content: ip4,
description: 'record.vpn',
),
DesiredDnsRecord(
name: '',
content: '10 $domainName.',
description: 'record.mx',
type: 'MX',
category: DnsRecordsCategory.email,
),
DesiredDnsRecord(
name: '_dmarc.$domainName',
content: '"v=DMARC1; p=none"',
description: 'record.dmarc',
type: 'TXT',
category: DnsRecordsCategory.email,
),
DesiredDnsRecord(
name: '',
content: '"v=spf1 a mx ip4:$ip4 -all"',
description: 'record.spf',
type: 'TXT',
category: DnsRecordsCategory.email,
),
if (dkimPublicKey != null)
DesiredDnsRecord(
name: 'selector._domainkey.$domainName',
content: '"$dkimPublicKey"',
description: 'record.dkim',
type: 'TXT',
category: DnsRecordsCategory.email,
),
];
}
}

View File

@ -1,9 +1,9 @@
import 'package:selfprivacy/logic/api_maps/rest_maps/dns_providers/desired_dns_record.dart';
import 'package:selfprivacy/logic/api_maps/rest_maps/dns_providers/digital_ocean_dns/digital_ocean_dns_api.dart';
import 'package:selfprivacy/logic/models/hive/server_domain.dart';
import 'package:selfprivacy/logic/models/json/digital_ocean_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_providers/digital_ocean_dns_info.dart';
import 'package:selfprivacy/logic/models/json/dns_records.dart';
import 'package:selfprivacy/logic/providers/dns_providers/dns_provider.dart';
import 'package:selfprivacy/utils/network_utils.dart';
class ApiAdapter {
ApiAdapter({final bool isWithToken = true})
@ -49,8 +49,8 @@ class DigitalOceanDnsProvider extends DnsProvider {
}
@override
Future<GenericResult<List<String>>> domainList() async {
List<String> domains = [];
Future<GenericResult<List<ServerDomain>>> domainList() async {
List<ServerDomain> domains = [];
final result = await _adapter.api().getDomains();
if (result.data.isEmpty || !result.success) {
return GenericResult(
@ -62,8 +62,8 @@ class DigitalOceanDnsProvider extends DnsProvider {
}
domains = result.data
.map<String>(
(final el) => el.name,
.map<ServerDomain>(
(final el) => el.toServerDomain(),
)
.toList();
@ -85,14 +85,8 @@ class DigitalOceanDnsProvider extends DnsProvider {
ip4,
)
.map<DigitalOceanDnsRecord>(
(final e) => DigitalOceanDnsRecord(
name: e.name ?? '',
id: null,
data: e.content ?? '',
ttl: e.ttl,
type: e.type,
priority: e.priority,
),
(final e) =>
DigitalOceanDnsRecord.fromDnsRecord(e, domain.domainName),
)
.toList(),
);
@ -142,15 +136,7 @@ class DigitalOceanDnsProvider extends DnsProvider {
}
for (final rawRecord in result.data) {
records.add(
DnsRecord(
name: rawRecord.name,
type: rawRecord.type,
content: rawRecord.data,
ttl: rawRecord.ttl,
proxied: false,
),
);
records.add(rawRecord.toDnsRecord(domain.domainName));
}
return GenericResult(data: records, success: true);
@ -164,212 +150,10 @@ class DigitalOceanDnsProvider extends DnsProvider {
_adapter.api().createMultipleDnsRecords(
domainName: domain.domainName,
records: [
DigitalOceanDnsRecord(
data: record.content ?? '',
id: null,
name: record.name ?? '',
ttl: record.ttl,
type: record.type,
priority: record.priority,
DigitalOceanDnsRecord.fromDnsRecord(
record,
domain.domainName,
),
],
);
@override
Future<GenericResult<List<DesiredDnsRecord>>> validateDnsRecords(
final ServerDomain domain,
final String ip4,
final String dkimPublicKey,
) async {
final GenericResult<List<DnsRecord>> records =
await getDnsRecords(domain: domain);
final List<DesiredDnsRecord> foundRecords = [];
try {
final List<DesiredDnsRecord> desiredRecords =
getDesiredDnsRecords(domain.domainName, ip4, dkimPublicKey);
for (final DesiredDnsRecord record in desiredRecords) {
if (record.description == 'record.dkim') {
final DnsRecord foundRecord = records.data.firstWhere(
(final r) => (r.name == record.name) && r.type == record.type,
orElse: () => DnsRecord(
name: record.name,
type: record.type,
content: '',
ttl: 800,
proxied: false,
),
);
// remove all spaces and tabulators from
// the foundRecord.content and the record.content
// to compare them
final String? foundContent =
foundRecord.content?.replaceAll(RegExp(r'\s+'), '');
final String content = record.content.replaceAll(RegExp(r'\s+'), '');
if (foundContent == content) {
foundRecords.add(record.copyWith(isSatisfied: true));
} else {
foundRecords.add(record.copyWith(isSatisfied: false));
}
} else {
if (records.data.any(
(final r) =>
(r.name == record.name) &&
r.type == record.type &&
r.content == record.content,
)) {
foundRecords.add(record.copyWith(isSatisfied: true));
} else {
foundRecords.add(record.copyWith(isSatisfied: false));
}
}
}
} catch (e) {
print(e);
return GenericResult(
data: [],
success: false,
message: e.toString(),
);
}
return GenericResult(
data: foundRecords,
success: true,
);
}
List<DnsRecord> getProjectDnsRecords(
final String? domainName,
final String? ip4,
) {
final DnsRecord domainA = DnsRecord(type: 'A', name: '@', content: ip4);
final DnsRecord mx = DnsRecord(type: 'MX', name: '@', content: '@');
final DnsRecord apiA = DnsRecord(type: 'A', name: 'api', content: ip4);
final DnsRecord cloudA = DnsRecord(type: 'A', name: 'cloud', content: ip4);
final DnsRecord gitA = DnsRecord(type: 'A', name: 'git', content: ip4);
final DnsRecord meetA = DnsRecord(type: 'A', name: 'meet', content: ip4);
final DnsRecord passwordA =
DnsRecord(type: 'A', name: 'password', content: ip4);
final DnsRecord socialA =
DnsRecord(type: 'A', name: 'social', content: ip4);
final DnsRecord vpn = DnsRecord(type: 'A', name: 'vpn', content: ip4);
final DnsRecord txt1 = DnsRecord(
type: 'TXT',
name: '_dmarc',
content: 'v=DMARC1; p=none',
ttl: 18000,
);
final DnsRecord txt2 = DnsRecord(
type: 'TXT',
name: '@',
content: 'v=spf1 a mx ip4:$ip4 -all',
ttl: 18000,
);
return <DnsRecord>[
domainA,
apiA,
cloudA,
gitA,
meetA,
passwordA,
socialA,
mx,
txt1,
txt2,
vpn,
];
}
@override
List<DesiredDnsRecord> getDesiredDnsRecords(
final String? domainName,
final String? ip4,
final String? dkimPublicKey,
) {
if (domainName == null || ip4 == null) {
return [];
}
return [
DesiredDnsRecord(
name: '@',
content: ip4,
description: 'record.root',
displayName: domainName,
),
DesiredDnsRecord(
name: 'api',
content: ip4,
description: 'record.api',
displayName: 'api.$domainName',
),
DesiredDnsRecord(
name: 'cloud',
content: ip4,
description: 'record.cloud',
displayName: 'cloud.$domainName',
),
DesiredDnsRecord(
name: 'git',
content: ip4,
description: 'record.git',
displayName: 'git.$domainName',
),
DesiredDnsRecord(
name: 'meet',
content: ip4,
description: 'record.meet',
displayName: 'meet.$domainName',
),
DesiredDnsRecord(
name: 'social',
content: ip4,
description: 'record.social',
displayName: 'social.$domainName',
),
DesiredDnsRecord(
name: 'password',
content: ip4,
description: 'record.password',
displayName: 'password.$domainName',
),
DesiredDnsRecord(
name: 'vpn',
content: ip4,
description: 'record.vpn',
displayName: 'vpn.$domainName',
),
const DesiredDnsRecord(
name: '@',
content: '@',
description: 'record.mx',
type: 'MX',
category: DnsRecordsCategory.email,
),
const DesiredDnsRecord(
name: '_dmarc',
content: 'v=DMARC1; p=none',
description: 'record.dmarc',
type: 'TXT',
category: DnsRecordsCategory.email,
),
DesiredDnsRecord(
name: '@',
content: 'v=spf1 a mx ip4:$ip4 -all',
description: 'record.spf',
type: 'TXT',
category: DnsRecordsCategory.email,
),
if (dkimPublicKey != null)
DesiredDnsRecord(
name: 'selector._domainkey',
content: dkimPublicKey,
description: 'record.dkim',
type: 'TXT',
category: DnsRecordsCategory.email,
),
];
}
}

View File

@ -1,5 +1,4 @@
import 'package:selfprivacy/logic/api_maps/generic_result.dart';
import 'package:selfprivacy/logic/api_maps/rest_maps/dns_providers/desired_dns_record.dart';
import 'package:selfprivacy/logic/models/hive/server_domain.dart';
import 'package:selfprivacy/logic/models/json/dns_records.dart';
export 'package:selfprivacy/logic/api_maps/generic_result.dart';
@ -22,7 +21,7 @@ abstract class DnsProvider {
Future<GenericResult<bool>> tryInitApiByToken(final String token);
/// Returns list of all available domain entries assigned to the account.
Future<GenericResult<List<String>>> domainList();
Future<GenericResult<List<ServerDomain>>> domainList();
/// Tries to create all main domain records needed
/// for SelfPrivacy to launch on requested domain by ip4.
@ -57,24 +56,4 @@ abstract class DnsProvider {
final DnsRecord record,
final ServerDomain domain,
);
/// Tries to check whether all known DNS records on the domain by ip4
/// match expectations of SelfPrivacy in order to launch.
///
/// Will return list of [DesiredDnsRecord] objects, which represent
/// only those records which have successfully passed validation.
Future<GenericResult<List<DesiredDnsRecord>>> validateDnsRecords(
final ServerDomain domain,
final String ip4,
final String dkimPublicKey,
);
/// Will return list of [DesiredDnsRecord] objects, which represent
/// samples of perfect DNS records we need to know about in order to launch
/// SelfPrivacy application correctly.
List<DesiredDnsRecord> getDesiredDnsRecords(
final String? domainName,
final String? ip4,
final String? dkimPublicKey,
);
}

View File

@ -151,12 +151,8 @@ class _DnsDetailsPageState extends State<DnsDetailsPage> {
? neutralColor
: errorColor,
),
title: Text(
dnsRecord.description.tr(),
),
subtitle: Text(
dnsRecord.displayName ?? dnsRecord.name,
),
title: Text(dnsRecord.displayName ?? dnsRecord.name),
subtitle: Text(dnsRecord.content),
),
],
),
@ -195,9 +191,8 @@ class _DnsDetailsPageState extends State<DnsDetailsPage> {
? neutralColor
: errorColor,
),
title: Text(
dnsRecord.description.tr(),
),
title: Text(dnsRecord.displayName ?? dnsRecord.name),
subtitle: Text(dnsRecord.name),
),
],
),

View File

@ -15,6 +15,24 @@ abstract class _$RootRouter extends RootStackRouter {
@override
final Map<String, PageFactory> pagesMap = {
AboutApplicationRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const AboutApplicationPage(),
);
},
AppSettingsRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const AppSettingsPage(),
);
},
BackupDetailsRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const BackupDetailsPage(),
);
},
BackupsListRoute.name: (routeData) {
final args = routeData.argsAs<BackupsListRouteArgs>();
return AutoRoutePage<dynamic>(
@ -25,10 +43,16 @@ abstract class _$RootRouter extends RootStackRouter {
),
);
},
BackupDetailsRoute.name: (routeData) {
ConsoleRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const BackupDetailsPage(),
child: const ConsolePage(),
);
},
DeveloperSettingsRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const DeveloperSettingsPage(),
);
},
DevicesRoute.name: (routeData) {
@ -43,28 +67,21 @@ abstract class _$RootRouter extends RootStackRouter {
child: const DnsDetailsPage(),
);
},
AboutApplicationRoute.name: (routeData) {
ExtendingVolumeRoute.name: (routeData) {
final args = routeData.argsAs<ExtendingVolumeRouteArgs>();
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const AboutApplicationPage(),
child: ExtendingVolumePage(
diskVolumeToResize: args.diskVolumeToResize,
diskStatus: args.diskStatus,
key: args.key,
),
);
},
AppSettingsRoute.name: (routeData) {
InitializingRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const AppSettingsPage(),
);
},
DeveloperSettingsRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const DeveloperSettingsPage(),
);
},
ConsoleRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const ConsolePage(),
child: const InitializingPage(),
);
},
MoreRoute.name: (routeData) {
@ -73,6 +90,12 @@ abstract class _$RootRouter extends RootStackRouter {
child: const MorePage(),
);
},
NewUserRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const NewUserPage(),
);
},
OnboardingRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
@ -91,6 +114,12 @@ abstract class _$RootRouter extends RootStackRouter {
child: const RecoveryKeyPage(),
);
},
RecoveryRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const RecoveryRouting(),
);
},
RootRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
@ -103,18 +132,6 @@ abstract class _$RootRouter extends RootStackRouter {
child: const ServerDetailsScreen(),
);
},
ServicesMigrationRoute.name: (routeData) {
final args = routeData.argsAs<ServicesMigrationRouteArgs>();
return AutoRoutePage<dynamic>(
routeData: routeData,
child: ServicesMigrationPage(
services: args.services,
diskStatus: args.diskStatus,
isMigration: args.isMigration,
key: args.key,
),
);
},
ServerStorageRoute.name: (routeData) {
final args = routeData.argsAs<ServerStorageRouteArgs>();
return AutoRoutePage<dynamic>(
@ -125,17 +142,6 @@ abstract class _$RootRouter extends RootStackRouter {
),
);
},
ExtendingVolumeRoute.name: (routeData) {
final args = routeData.argsAs<ExtendingVolumeRouteArgs>();
return AutoRoutePage<dynamic>(
routeData: routeData,
child: ExtendingVolumePage(
diskVolumeToResize: args.diskVolumeToResize,
diskStatus: args.diskStatus,
key: args.key,
),
);
},
ServiceRoute.name: (routeData) {
final args = routeData.argsAs<ServiceRouteArgs>();
return AutoRoutePage<dynamic>(
@ -146,36 +152,24 @@ abstract class _$RootRouter extends RootStackRouter {
),
);
},
ServicesMigrationRoute.name: (routeData) {
final args = routeData.argsAs<ServicesMigrationRouteArgs>();
return AutoRoutePage<dynamic>(
routeData: routeData,
child: ServicesMigrationPage(
services: args.services,
diskStatus: args.diskStatus,
isMigration: args.isMigration,
key: args.key,
),
);
},
ServicesRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const ServicesPage(),
);
},
InitializingRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const InitializingPage(),
);
},
RecoveryRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const RecoveryRouting(),
);
},
UsersRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const UsersPage(),
);
},
NewUserRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const NewUserPage(),
);
},
UserDetailsRoute.name: (routeData) {
final args = routeData.argsAs<UserDetailsRouteArgs>();
return AutoRoutePage<dynamic>(
@ -186,9 +180,57 @@ abstract class _$RootRouter extends RootStackRouter {
),
);
},
UsersRoute.name: (routeData) {
return AutoRoutePage<dynamic>(
routeData: routeData,
child: const UsersPage(),
);
},
};
}
/// generated route for
/// [AboutApplicationPage]
class AboutApplicationRoute extends PageRouteInfo<void> {
const AboutApplicationRoute({List<PageRouteInfo>? children})
: super(
AboutApplicationRoute.name,
initialChildren: children,
);
static const String name = 'AboutApplicationRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [AppSettingsPage]
class AppSettingsRoute extends PageRouteInfo<void> {
const AppSettingsRoute({List<PageRouteInfo>? children})
: super(
AppSettingsRoute.name,
initialChildren: children,
);
static const String name = 'AppSettingsRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [BackupDetailsPage]
class BackupDetailsRoute extends PageRouteInfo<void> {
const BackupDetailsRoute({List<PageRouteInfo>? children})
: super(
BackupDetailsRoute.name,
initialChildren: children,
);
static const String name = 'BackupDetailsRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [BackupsListPage]
class BackupsListRoute extends PageRouteInfo<BackupsListRouteArgs> {
@ -228,15 +270,29 @@ class BackupsListRouteArgs {
}
/// generated route for
/// [BackupDetailsPage]
class BackupDetailsRoute extends PageRouteInfo<void> {
const BackupDetailsRoute({List<PageRouteInfo>? children})
/// [ConsolePage]
class ConsoleRoute extends PageRouteInfo<void> {
const ConsoleRoute({List<PageRouteInfo>? children})
: super(
BackupDetailsRoute.name,
ConsoleRoute.name,
initialChildren: children,
);
static const String name = 'BackupDetailsRoute';
static const String name = 'ConsoleRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [DeveloperSettingsPage]
class DeveloperSettingsRoute extends PageRouteInfo<void> {
const DeveloperSettingsRoute({List<PageRouteInfo>? children})
: super(
DeveloperSettingsRoute.name,
initialChildren: children,
);
static const String name = 'DeveloperSettingsRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
@ -270,57 +326,58 @@ class DnsDetailsRoute extends PageRouteInfo<void> {
}
/// generated route for
/// [AboutApplicationPage]
class AboutApplicationRoute extends PageRouteInfo<void> {
const AboutApplicationRoute({List<PageRouteInfo>? children})
: super(
AboutApplicationRoute.name,
/// [ExtendingVolumePage]
class ExtendingVolumeRoute extends PageRouteInfo<ExtendingVolumeRouteArgs> {
ExtendingVolumeRoute({
required DiskVolume diskVolumeToResize,
required DiskStatus diskStatus,
Key? key,
List<PageRouteInfo>? children,
}) : super(
ExtendingVolumeRoute.name,
args: ExtendingVolumeRouteArgs(
diskVolumeToResize: diskVolumeToResize,
diskStatus: diskStatus,
key: key,
),
initialChildren: children,
);
static const String name = 'AboutApplicationRoute';
static const String name = 'ExtendingVolumeRoute';
static const PageInfo<void> page = PageInfo<void>(name);
static const PageInfo<ExtendingVolumeRouteArgs> page =
PageInfo<ExtendingVolumeRouteArgs>(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
/// [AppSettingsPage]
class AppSettingsRoute extends PageRouteInfo<void> {
const AppSettingsRoute({List<PageRouteInfo>? children})
/// [InitializingPage]
class InitializingRoute extends PageRouteInfo<void> {
const InitializingRoute({List<PageRouteInfo>? children})
: super(
AppSettingsRoute.name,
InitializingRoute.name,
initialChildren: children,
);
static const String name = 'AppSettingsRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [DeveloperSettingsPage]
class DeveloperSettingsRoute extends PageRouteInfo<void> {
const DeveloperSettingsRoute({List<PageRouteInfo>? children})
: super(
DeveloperSettingsRoute.name,
initialChildren: children,
);
static const String name = 'DeveloperSettingsRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [ConsolePage]
class ConsoleRoute extends PageRouteInfo<void> {
const ConsoleRoute({List<PageRouteInfo>? children})
: super(
ConsoleRoute.name,
initialChildren: children,
);
static const String name = 'ConsoleRoute';
static const String name = 'InitializingRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
@ -339,6 +396,20 @@ class MoreRoute extends PageRouteInfo<void> {
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [NewUserPage]
class NewUserRoute extends PageRouteInfo<void> {
const NewUserRoute({List<PageRouteInfo>? children})
: super(
NewUserRoute.name,
initialChildren: children,
);
static const String name = 'NewUserRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [OnboardingPage]
class OnboardingRoute extends PageRouteInfo<void> {
@ -381,6 +452,20 @@ class RecoveryKeyRoute extends PageRouteInfo<void> {
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [RecoveryRouting]
class RecoveryRoute extends PageRouteInfo<void> {
const RecoveryRoute({List<PageRouteInfo>? children})
: super(
RecoveryRoute.name,
initialChildren: children,
);
static const String name = 'RecoveryRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [RootPage]
class RootRoute extends PageRouteInfo<void> {
@ -409,6 +494,82 @@ class ServerDetailsRoute extends PageRouteInfo<void> {
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [ServerStoragePage]
class ServerStorageRoute extends PageRouteInfo<ServerStorageRouteArgs> {
ServerStorageRoute({
required DiskStatus diskStatus,
Key? key,
List<PageRouteInfo>? children,
}) : super(
ServerStorageRoute.name,
args: ServerStorageRouteArgs(
diskStatus: diskStatus,
key: key,
),
initialChildren: children,
);
static const String name = 'ServerStorageRoute';
static const PageInfo<ServerStorageRouteArgs> page =
PageInfo<ServerStorageRouteArgs>(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
/// [ServicePage]
class ServiceRoute extends PageRouteInfo<ServiceRouteArgs> {
ServiceRoute({
required String serviceId,
Key? key,
List<PageRouteInfo>? children,
}) : super(
ServiceRoute.name,
args: ServiceRouteArgs(
serviceId: serviceId,
key: key,
),
initialChildren: children,
);
static const String name = 'ServiceRoute';
static const PageInfo<ServiceRouteArgs> page =
PageInfo<ServiceRouteArgs>(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
/// [ServicesMigrationPage]
class ServicesMigrationRoute extends PageRouteInfo<ServicesMigrationRouteArgs> {
@ -457,125 +618,6 @@ class ServicesMigrationRouteArgs {
}
}
/// generated route for
/// [ServerStoragePage]
class ServerStorageRoute extends PageRouteInfo<ServerStorageRouteArgs> {
ServerStorageRoute({
required DiskStatus diskStatus,
Key? key,
List<PageRouteInfo>? children,
}) : super(
ServerStorageRoute.name,
args: ServerStorageRouteArgs(
diskStatus: diskStatus,
key: key,
),
initialChildren: children,
);
static const String name = 'ServerStorageRoute';
static const PageInfo<ServerStorageRouteArgs> page =
PageInfo<ServerStorageRouteArgs>(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
/// [ExtendingVolumePage]
class ExtendingVolumeRoute extends PageRouteInfo<ExtendingVolumeRouteArgs> {
ExtendingVolumeRoute({
required DiskVolume diskVolumeToResize,
required DiskStatus diskStatus,
Key? key,
List<PageRouteInfo>? children,
}) : super(
ExtendingVolumeRoute.name,
args: ExtendingVolumeRouteArgs(
diskVolumeToResize: diskVolumeToResize,
diskStatus: diskStatus,
key: key,
),
initialChildren: children,
);
static const String name = 'ExtendingVolumeRoute';
static const PageInfo<ExtendingVolumeRouteArgs> page =
PageInfo<ExtendingVolumeRouteArgs>(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
/// [ServicePage]
class ServiceRoute extends PageRouteInfo<ServiceRouteArgs> {
ServiceRoute({
required String serviceId,
Key? key,
List<PageRouteInfo>? children,
}) : super(
ServiceRoute.name,
args: ServiceRouteArgs(
serviceId: serviceId,
key: key,
),
initialChildren: children,
);
static const String name = 'ServiceRoute';
static const PageInfo<ServiceRouteArgs> page =
PageInfo<ServiceRouteArgs>(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<void> {
@ -590,62 +632,6 @@ class ServicesRoute extends PageRouteInfo<void> {
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [InitializingPage]
class InitializingRoute extends PageRouteInfo<void> {
const InitializingRoute({List<PageRouteInfo>? children})
: super(
InitializingRoute.name,
initialChildren: children,
);
static const String name = 'InitializingRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [RecoveryRouting]
class RecoveryRoute extends PageRouteInfo<void> {
const RecoveryRoute({List<PageRouteInfo>? children})
: super(
RecoveryRoute.name,
initialChildren: children,
);
static const String name = 'RecoveryRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [UsersPage]
class UsersRoute extends PageRouteInfo<void> {
const UsersRoute({List<PageRouteInfo>? children})
: super(
UsersRoute.name,
initialChildren: children,
);
static const String name = 'UsersRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [NewUserPage]
class NewUserRoute extends PageRouteInfo<void> {
const NewUserRoute({List<PageRouteInfo>? children})
: super(
NewUserRoute.name,
initialChildren: children,
);
static const String name = 'NewUserRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}
/// generated route for
/// [UserDetailsPage]
class UserDetailsRoute extends PageRouteInfo<UserDetailsRouteArgs> {
@ -683,3 +669,17 @@ class UserDetailsRouteArgs {
return 'UserDetailsRouteArgs{login: $login, key: $key}';
}
}
/// generated route for
/// [UsersPage]
class UsersRoute extends PageRouteInfo<void> {
const UsersRoute({List<PageRouteInfo>? children})
: super(
UsersRoute.name,
initialChildren: children,
);
static const String name = 'UsersRoute';
static const PageInfo<void> page = PageInfo<void>(name);
}

View File

@ -89,3 +89,49 @@ void launchURL(final url) async {
print(e);
}
}
List<DnsRecord> getProjectDnsRecords(
final String? domainName,
final String? ip4,
) {
final DnsRecord domainA =
DnsRecord(type: 'A', name: domainName, content: ip4);
final DnsRecord mx = DnsRecord(type: 'MX', name: '@', content: domainName);
final DnsRecord apiA = DnsRecord(type: 'A', name: 'api', content: ip4);
final DnsRecord cloudA = DnsRecord(type: 'A', name: 'cloud', content: ip4);
final DnsRecord gitA = DnsRecord(type: 'A', name: 'git', content: ip4);
final DnsRecord meetA = DnsRecord(type: 'A', name: 'meet', content: ip4);
final DnsRecord passwordA =
DnsRecord(type: 'A', name: 'password', content: ip4);
final DnsRecord socialA = DnsRecord(type: 'A', name: 'social', content: ip4);
final DnsRecord vpn = DnsRecord(type: 'A', name: 'vpn', content: ip4);
final DnsRecord txt1 = DnsRecord(
type: 'TXT',
name: '_dmarc',
content: 'v=DMARC1; p=none',
ttl: 18000,
);
final DnsRecord txt2 = DnsRecord(
type: 'TXT',
name: domainName,
content: 'v=spf1 a mx ip4:$ip4 -all',
ttl: 18000,
);
return <DnsRecord>[
domainA,
apiA,
cloudA,
gitA,
meetA,
passwordA,
socialA,
mx,
txt1,
txt2,
vpn,
];
}