refactor(sf_shared): move brand links to Firebase Remote Config
This commit is contained in:
@@ -72,3 +72,4 @@ export 'src/providers/devices_remote_datasource_repository_provider.dart';
|
||||
export 'src/providers/devices_repository_provider.dart';
|
||||
export 'src/providers/legacy_devices_provider.dart';
|
||||
export 'src/providers/selected_device_provider.dart';
|
||||
export 'src/remote_config/brand_links.dart';
|
||||
|
||||
22
packages/sf_shared/lib/src/remote_config/brand_links.dart
Normal file
22
packages/sf_shared/lib/src/remote_config/brand_links.dart
Normal file
@@ -0,0 +1,22 @@
|
||||
import 'package:firebase_remote_config/firebase_remote_config.dart';
|
||||
|
||||
class BrandLinksKeys {
|
||||
const BrandLinksKeys._();
|
||||
|
||||
static const privacyPolicyUrl = 'privacy_policy_url';
|
||||
static const corporateWebsiteUrl = 'corporate_website_url';
|
||||
static const supportEmail = 'support_email';
|
||||
}
|
||||
|
||||
class BrandLinks {
|
||||
const BrandLinks._();
|
||||
|
||||
static String get privacyPolicy =>
|
||||
FirebaseRemoteConfig.instance.getString(BrandLinksKeys.privacyPolicyUrl);
|
||||
|
||||
static String get corporateWebsite => FirebaseRemoteConfig.instance
|
||||
.getString(BrandLinksKeys.corporateWebsiteUrl);
|
||||
|
||||
static String get supportEmail =>
|
||||
FirebaseRemoteConfig.instance.getString(BrandLinksKeys.supportEmail);
|
||||
}
|
||||
@@ -34,6 +34,7 @@ dependencies:
|
||||
flutter_riverpod: ^3.0.3
|
||||
dio: ^5.9.2
|
||||
firebase_messaging: ^16.1.3
|
||||
firebase_remote_config: ^6.3.0
|
||||
freezed_annotation: ^3.1.0
|
||||
freezed: ^3.2.3
|
||||
json_annotation: ^4.9.0
|
||||
|
||||
Reference in New Issue
Block a user