This commit is contained in:
2026-06-28 18:33:46 +03:00
parent 65ea30339d
commit 4727835402
22 changed files with 534 additions and 54 deletions
+55
View File
@@ -0,0 +1,55 @@
import 'package:flutter/material.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import '../../core/l10n/app_strings.dart';
import '../../core/l10n/locale_provider.dart';
class PaywallBanner extends ConsumerWidget {
final String? message;
final VoidCallback? onTap;
const PaywallBanner({
super.key,
this.message,
this.onTap,
});
@override
Widget build(BuildContext context, WidgetRef ref) {
final s = AppStrings(ref.watch(localeProvider));
return GestureDetector(
onTap: onTap,
child: Container(
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 12),
decoration: BoxDecoration(
color: Theme.of(context).colorScheme.surface,
borderRadius: BorderRadius.circular(12),
border: Border.all(
color: Theme.of(context).colorScheme.onSurface.withOpacity(0.15),
width: 1,
),
),
child: Row(
children: [
Icon(
Icons.lock_outline_rounded,
size: 20,
color: Theme.of(context).colorScheme.onSurface.withOpacity(0.5),
),
const SizedBox(width: 12),
Expanded(
child: Text(
message ?? s.premiumFeatureLocked,
style: Theme.of(context).textTheme.bodySmall?.copyWith(
color: Theme.of(context)
.colorScheme
.onSurface
.withOpacity(0.6),
),
),
),
],
),
),
);
}
}