From 9353863439f28a54342d6bb06b7872c2c306b66a Mon Sep 17 00:00:00 2001 From: Morn Date: Mon, 28 Apr 2025 22:13:13 +0800 Subject: [PATCH] fix: some lr issues (#7848) Co-authored-by: Lucas.Xu --- .../lib/core/helpers/url_launcher.dart | 6 ++++-- .../desktop_toolbar/link/link_edit_menu.dart | 1 + .../lib/workspace/presentation/home/home_stack.dart | 10 ++-------- 3 files changed, 7 insertions(+), 10 deletions(-) diff --git a/frontend/appflowy_flutter/lib/core/helpers/url_launcher.dart b/frontend/appflowy_flutter/lib/core/helpers/url_launcher.dart index 39ed4bc6bb..4ca51f8ea4 100644 --- a/frontend/appflowy_flutter/lib/core/helpers/url_launcher.dart +++ b/frontend/appflowy_flutter/lib/core/helpers/url_launcher.dart @@ -39,9 +39,11 @@ Future afLaunchUri( ); } - // on Linux or Android, add http scheme to the url if it is not present + // on Linux or Android or Windows, add http scheme to the url if it is not present if ((UniversalPlatform.isLinux || - UniversalPlatform.isAndroid) && !isURL(url, {'require_protocol': true})) { + UniversalPlatform.isAndroid || + UniversalPlatform.isWindows) && + !isURL(url, {'require_protocol': true})) { uri = Uri.parse('https://$url'); } diff --git a/frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/desktop_toolbar/link/link_edit_menu.dart b/frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/desktop_toolbar/link/link_edit_menu.dart index 21a440461c..cb2ed52674 100644 --- a/frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/desktop_toolbar/link/link_edit_menu.dart +++ b/frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/desktop_toolbar/link/link_edit_menu.dart @@ -423,6 +423,7 @@ class _LinkEditMenuState extends State { return; } widget.onApply.call(linkInfo); + onDismiss(); } void onConfirm() { diff --git a/frontend/appflowy_flutter/lib/workspace/presentation/home/home_stack.dart b/frontend/appflowy_flutter/lib/workspace/presentation/home/home_stack.dart index c5d51b9050..61035f1ea7 100644 --- a/frontend/appflowy_flutter/lib/workspace/presentation/home/home_stack.dart +++ b/frontend/appflowy_flutter/lib/workspace/presentation/home/home_stack.dart @@ -16,6 +16,7 @@ import 'package:appflowy/workspace/presentation/home/home_sizes.dart'; import 'package:appflowy/workspace/presentation/home/navigation.dart'; import 'package:appflowy/workspace/presentation/home/tabs/tabs_manager.dart'; import 'package:appflowy/workspace/presentation/home/toast.dart'; +import 'package:appflowy/workspace/presentation/notifications/number_red_dot.dart'; import 'package:appflowy_backend/dispatch/dispatch.dart'; import 'package:appflowy_backend/protobuf/flowy-folder/view.pb.dart'; import 'package:appflowy_backend/protobuf/flowy-user/user_profile.pb.dart'; @@ -65,14 +66,7 @@ class _HomeStackState extends State with WindowListener { builder: (context, state) => Column( children: [ if (UniversalPlatform.isWindows) - Column( - mainAxisSize: MainAxisSize.min, - children: [ - WindowTitleBar( - leftChildren: [_buildToggleMenuButton(context)], - ), - ], - ), + WindowTitleBar(leftChildren: [_buildToggleMenuButton(context)]), Padding( padding: EdgeInsets.only(left: widget.layout.menuSpacing), child: TabsManager(