Prepare Google Play release with age-gated ads and store assets
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import '../services/ad_audience.dart';
|
||||
import 'translation.dart';
|
||||
|
||||
Future<AdAudience?> chooseAdAgeGroup(BuildContext context) =>
|
||||
showDialog<AdAudience>(
|
||||
context: context,
|
||||
builder: (context) => SimpleDialog(
|
||||
title: const CopyText('Choose your age group'),
|
||||
children: [
|
||||
const Padding(
|
||||
padding: EdgeInsets.fromLTRB(24, 0, 24, 16),
|
||||
child: CopyText(
|
||||
'We use this only to choose advertising settings. Under 13 and Prefer not to say play without ads. Your choice stays on this device.',
|
||||
),
|
||||
),
|
||||
for (final option in const [
|
||||
(AdAudience.under13, 'Under 13'),
|
||||
(AdAudience.teen, '13–17'),
|
||||
(AdAudience.adult, '18 and over'),
|
||||
(AdAudience.unknown, 'Prefer not to say'),
|
||||
])
|
||||
SimpleDialogOption(
|
||||
onPressed: () => Navigator.pop(context, option.$1),
|
||||
child: CopyText(
|
||||
option.$2,
|
||||
style: const TextStyle(fontFamily: 'LumenText', fontSize: 18),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
Reference in New Issue
Block a user