Minor layout fixes
This commit is contained in:
parent
c644143198
commit
e4391ac465
|
|
@ -2817,6 +2817,9 @@ class _TaskDetailScreenState extends ConsumerState<TaskDetailScreen>
|
|||
),
|
||||
);
|
||||
|
||||
final mobileTabbedHeight =
|
||||
(MediaQuery.of(context).size.height * 0.65).clamp(360.0, 720.0);
|
||||
|
||||
final mainContent = isWide
|
||||
? Row(
|
||||
children: [
|
||||
|
|
@ -2831,10 +2834,12 @@ class _TaskDetailScreenState extends ConsumerState<TaskDetailScreen>
|
|||
slivers: [
|
||||
SliverToBoxAdapter(child: detailsCard),
|
||||
const SliverToBoxAdapter(child: SizedBox(height: 12)),
|
||||
SliverFillRemaining(
|
||||
hasScrollBody: true,
|
||||
SliverToBoxAdapter(
|
||||
child: SizedBox(
|
||||
height: mobileTabbedHeight,
|
||||
child: tabbedCard,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
if (isRetrieving)
|
||||
|
|
|
|||
|
|
@ -122,20 +122,25 @@ class _QrVerificationDialogState extends ConsumerState<_QrVerificationDialog> {
|
|||
final colors = theme.colorScheme;
|
||||
final qrData = 'tasq://verify/${widget.session.id}';
|
||||
|
||||
return AlertDialog(
|
||||
return Dialog(
|
||||
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(28)),
|
||||
title: Row(
|
||||
child: ConstrainedBox(
|
||||
constraints: const BoxConstraints(maxWidth: 420),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.fromLTRB(24, 20, 24, 16),
|
||||
child: SingleChildScrollView(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Row(
|
||||
children: [
|
||||
Icon(Icons.qr_code_2, color: colors.primary),
|
||||
const SizedBox(width: 12),
|
||||
const Expanded(child: Text('Scan with Mobile')),
|
||||
],
|
||||
),
|
||||
content: ConstrainedBox(
|
||||
constraints: const BoxConstraints(maxWidth: 360),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
widget.session.type == 'enrollment'
|
||||
? 'Open the TasQ app on your phone and scan this QR code to enroll your face with liveness detection.'
|
||||
|
|
@ -145,12 +150,13 @@ class _QrVerificationDialogState extends ConsumerState<_QrVerificationDialog> {
|
|||
),
|
||||
),
|
||||
const SizedBox(height: 24),
|
||||
if (_expired)
|
||||
_buildExpiredState(theme, colors)
|
||||
else
|
||||
_buildQrCode(theme, colors, qrData),
|
||||
Center(
|
||||
child: _expired
|
||||
? _buildExpiredState(theme, colors)
|
||||
: _buildQrCode(theme, colors, qrData),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
if (!_expired) ...[
|
||||
if (!_expired)
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
|
|
@ -163,24 +169,29 @@ class _QrVerificationDialogState extends ConsumerState<_QrVerificationDialog> {
|
|||
),
|
||||
),
|
||||
const SizedBox(width: 12),
|
||||
Text(
|
||||
Flexible(
|
||||
child: Text(
|
||||
'Waiting for mobile verification...',
|
||||
style: theme.textTheme.bodySmall?.copyWith(
|
||||
color: colors.onSurfaceVariant,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
],
|
||||
),
|
||||
),
|
||||
actions: [
|
||||
TextButton(
|
||||
const SizedBox(height: 12),
|
||||
Align(
|
||||
alignment: Alignment.centerRight,
|
||||
child: TextButton(
|
||||
onPressed: () => Navigator.of(context).pop(false),
|
||||
child: const Text('Cancel'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user