Skip to content

Commit 6c63c96

Browse files
authored
Merge pull request #124 from flutter-news-app-full-source-code/refactor/cleanup-deprecated-local-ads
Refactor/cleanup deprecated local ads
2 parents 731f80e + 4fccaf1 commit 6c63c96

File tree

14 files changed

+20
-56
lines changed

14 files changed

+20
-56
lines changed

lib/app_configuration/widgets/ad_platform_config_form.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ class _AdPlatformConfigFormState extends State<AdPlatformConfigForm> {
299299
),
300300
],
301301
),
302-
const SizedBox(height: AppSpacing.lg),
302+
const SizedBox(height: AppSpacing.lg),
303303
],
304304
);
305305
}

lib/authentication/view/request_code_page.dart

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,9 @@ class _RequestCodeView extends StatelessWidget {
145145
top: AppSpacing.lg,
146146
),
147147
child: Text(
148-
l10n.demoEmailHint('admin@example.com'),
148+
l10n.demoEmailHint(
149+
'admin@example.com | publisher@example.com',
150+
),
149151
style: textTheme.bodyMedium?.copyWith(
150152
color: colorScheme.secondary,
151153
fontWeight: FontWeight.bold,

lib/bootstrap.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ Future<Widget> bootstrap(
123123
usersClient = DataInMemory<User>(
124124
toJson: (i) => i.toJson(),
125125
getId: (i) => i.id,
126-
// No initial data for users in demo mode.
126+
initialData: usersFixturesData,
127127
logger: Logger('DataInMemory<User>'),
128128
);
129129
} else {

lib/l10n/app_localizations.dart

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2174,12 +2174,6 @@ abstract class AppLocalizations {
21742174
/// **'AdMob'**
21752175
String get adPlatformTypeAdmob;
21762176

2177-
/// The name of the Local ad platform for custom ads.
2178-
///
2179-
/// In en, this message translates to:
2180-
/// **'Local'**
2181-
String get adPlatformTypeLocal;
2182-
21832177
/// Tab title for Native Ads in local ads management.
21842178
///
21852179
/// In en, this message translates to:

lib/l10n/app_localizations_ar.dart

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1163,9 +1163,6 @@ class AppLocalizationsAr extends AppLocalizations {
11631163
@override
11641164
String get adPlatformTypeAdmob => 'أدموب';
11651165

1166-
@override
1167-
String get adPlatformTypeLocal => 'محلي';
1168-
11691166
@override
11701167
String get nativeAdsTab => 'إعلانات أصلية';
11711168

lib/l10n/app_localizations_en.dart

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1162,9 +1162,6 @@ class AppLocalizationsEn extends AppLocalizations {
11621162
@override
11631163
String get adPlatformTypeAdmob => 'AdMob';
11641164

1165-
@override
1166-
String get adPlatformTypeLocal => 'Local';
1167-
11681165
@override
11691166
String get nativeAdsTab => 'Native Ads';
11701167

lib/l10n/arb/app_ar.arb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1448,10 +1448,6 @@
14481448
"@adPlatformTypeAdmob": {
14491449
"description": "اسم منصة إعلانات أدموب."
14501450
},
1451-
"adPlatformTypeLocal": "محلي",
1452-
"@adPlatformTypeLocal": {
1453-
"description": "اسم منصة الإعلانات المحلية للإعلانات المخصصة."
1454-
},
14551451
"nativeAdsTab": "إعلانات أصلية",
14561452
"@nativeAdsTab": {
14571453
"description": "عنوان تبويب الإعلانات الأصلية في إدارة الإعلانات المحلية."

lib/l10n/arb/app_en.arb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1448,10 +1448,6 @@
14481448
"@adPlatformTypeAdmob": {
14491449
"description": "The name of the AdMob ad platform."
14501450
},
1451-
"adPlatformTypeLocal": "Local",
1452-
"@adPlatformTypeLocal": {
1453-
"description": "The name of the Local ad platform for custom ads."
1454-
},
14551451
"nativeAdsTab": "Native Ads",
14561452
"@nativeAdsTab": {
14571453
"description": "Tab title for Native Ads in local ads management."

lib/router/router.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ GoRouter createRouter({
117117
})
118118
.whereType<String>()
119119
.toList();
120-
120+
121121
// Check if the destination path starts with any of the authorized base
122122
// paths, or if it's the universally accessible settings page.
123123
final isAuthorized =

lib/shared/extensions/ad_platform_type_l10n.dart

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@ extension AdPlatformTypeL10n on AdPlatformType {
1010
switch (this) {
1111
case AdPlatformType.admob:
1212
return l10n.adPlatformTypeAdmob;
13-
case AdPlatformType.local:
14-
return l10n.adPlatformTypeLocal;
1513
case AdPlatformType.demo:
1614
throw UnimplementedError(
1715
'Demo ad platform type is not intended for dashboard usage, rather for mobile client, demo env specific usecase.',

0 commit comments

Comments
 (0)