Skip to content

Bring projects, wikis, and teams together with AI. AppFlowy is the AI collaborative workspace where you achieve more without losing control of your data. The leading open source Notion alternative.

feat: add key + as zoom-in key (#5628)

Lucas.Xu7d96c2dfd426
diff --git a/frontend/appflowy_flutter/lib/workspace/presentation/home/hotkeys.dart b/frontend/appflowy_flutter/lib/workspace/presentation/home/hotkeys.dart
index ac2a57ec80..bab2c3b618 100644
--- a/frontend/appflowy_flutter/lib/workspace/presentation/home/hotkeys.dart
+++ b/frontend/appflowy_flutter/lib/workspace/presentation/home/hotkeys.dart
@@ -136,13 +136,18 @@ class _HomeHotKeysState extends State<HomeHotKeys> {
),
// Scale up/down the app
- HotKeyItem(
- hotKey: HotKey(
- KeyCode.equal,
- modifiers: [Platform.isMacOS ? KeyModifier.meta : KeyModifier.control],
- scope: HotKeyScope.inapp,
+ // In some keyboards, the system returns equal as + keycode, while others may return add as + keycode, so add them both as zoom in key.
+ ...[KeyCode.equal, KeyCode.add].map(
+ (keycode) => HotKeyItem(
+ hotKey: HotKey(
+ keycode,
+ modifiers: [
+ Platform.isMacOS ? KeyModifier.meta : KeyModifier.control,
+ ],
+ scope: HotKeyScope.inapp,
+ ),
+ keyDownHandler: (_) => _scaleWithStep(0.1),
),
- keyDownHandler: (_) => _scaleWithStep(0.1),
),
HotKeyItem(