Add warp config generator
This commit is contained in:
@@ -54,6 +54,8 @@ class SingboxConfigOption with _$SingboxConfigOption {
|
||||
required bool enableWarp,
|
||||
required WarpDetourMode warpDetourMode,
|
||||
required String warpLicenseKey,
|
||||
required String warpAccountId,
|
||||
required String warpAccessToken,
|
||||
required String warpCleanIp,
|
||||
required int warpPort,
|
||||
@OptionalRangeJsonConverter() required OptionalRange warpNoise,
|
||||
|
||||
17
lib/singbox/model/warp_account.dart
Normal file
17
lib/singbox/model/warp_account.dart
Normal file
@@ -0,0 +1,17 @@
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:freezed_annotation/freezed_annotation.dart';
|
||||
|
||||
part 'warp_account.freezed.dart';
|
||||
part 'warp_account.g.dart';
|
||||
|
||||
@freezed
|
||||
class WarpAccount with _$WarpAccount {
|
||||
const factory WarpAccount({
|
||||
required String licenseKey,
|
||||
required String accountId,
|
||||
required String accessToken,
|
||||
}) = _WarpAccount;
|
||||
|
||||
factory WarpAccount.fromJson(Map<String, dynamic> json) =>
|
||||
_$WarpAccountFromJson(json);
|
||||
}
|
||||
Reference in New Issue
Block a user