fix #90: export comic as epub

This commit is contained in:
2024-12-07 20:04:22 +08:00
parent 488299bcfb
commit 617c452e07
5 changed files with 263 additions and 20 deletions

View File

@@ -46,21 +46,28 @@ class _ToastOverlay extends StatelessWidget {
child: IconTheme(
data: IconThemeData(
color: Theme.of(context).colorScheme.onInverseSurface),
child: Container(
padding: const EdgeInsets.symmetric(vertical: 6, horizontal: 16),
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
if (icon != null) icon!.paddingRight(8),
Text(
message,
style: const TextStyle(
fontSize: 16, fontWeight: FontWeight.w500),
maxLines: 3,
overflow: TextOverflow.ellipsis,
),
if (trailing != null) trailing!.paddingLeft(8)
],
child: IntrinsicWidth(
child: Container(
padding: const EdgeInsets.symmetric(vertical: 6, horizontal: 16),
constraints: BoxConstraints(
maxWidth: context.width - 32,
),
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
if (icon != null) icon!.paddingRight(8),
Expanded(
child: Text(
message,
style: const TextStyle(
fontSize: 16, fontWeight: FontWeight.w500),
maxLines: 3,
overflow: TextOverflow.ellipsis,
),
),
if (trailing != null) trailing!.paddingLeft(8)
],
),
),
),
),
@@ -220,7 +227,7 @@ LoadingDialogController showLoadingDialog(BuildContext context,
);
});
var navigator = Navigator.of(context);
var navigator = Navigator.of(context, rootNavigator: true);
navigator.push(loadingDialogRoute).then((value) => controller.closed = true);