Skip to content

[macOS 27] Bring back Writing Tools#1497

Merged
cyanzhong merged 1 commit into
mainfrom
develop
Jun 18, 2026
Merged

[macOS 27] Bring back Writing Tools#1497
cyanzhong merged 1 commit into
mainfrom
develop

Conversation

@cyanzhong

@cyanzhong cyanzhong commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

WKWebView in macOS Golden Gate when Siri AI is enabled, currently shows neither Writing Tools nor Ask Siri, this should be a bug.

However in iOS 27 with Siri AI enabled, Writing Tools is intentionally hidden, this might be a design change.

This changes forces showing Writing Tools, no matter with bugs or design changes.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR forces Writing Tools UI back on macOS 27 (“Golden Gate”) by injecting/bridging Writing Tools menu items (context menu, Edit menu, toolbar) even when WebKit/system behavior hides them when “Siri AI” is enabled.

Changes:

  • Add a macOS 27-only helper to inject a “Show Writing Tools” item into WKWebView context menus.
  • Add an Edit-menu placeholder item wired via storyboard/outlet and dynamically synchronized with the system Writing Tools menu item/submenu.
  • Add localized strings and runtime tests for selector/menu item presence.

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
MarkEditMac/Sources/Main/AppWritingTools.swift Adds macOS 27 helper to ensure a Writing Tools menu item exists in a given menu.
MarkEditMac/Sources/Main/AppResources.swift Introduces localized title for “Show Writing Tools”.
MarkEditMac/Sources/Main/Application/AppDelegate+Menu.swift Manages hiding/showing the placeholder Writing Tools menu item and syncing submenu/title/icon.
MarkEditMac/Sources/Main/Application/AppDelegate.swift Adds IBOutlet for the new Edit-menu Writing Tools placeholder item.
MarkEditMac/Sources/Main/AppDesign.swift Adds forceWritingTools feature flag logic for macOS 27 based on FoundationModels availability.
MarkEditMac/Sources/Editor/Views/EditorWebView.swift Injects “Show Writing Tools” into the WKWebView context menu when forced on macOS 27.
MarkEditMac/Sources/Editor/Controllers/EditorViewController+Toolbar.swift Updates toolbar Writing Tools item sourcing with macOS 27 fallback.
MarkEditMac/Sources/Editor/Controllers/EditorViewController+Menu.swift Removes now-redundant system Writing Tools menu lookup property.
MarkEditMac/Resources/Localizable.xcstrings Adds translations for “Show Writing Tools”.
MarkEditMac/mul.lproj/Main.xcstrings Adds non-translatable placeholder storyboard strings for the Writing Tools placeholder menu items.
MarkEditMac/Modules/Tests/RuntimeTests.swift Adds runtime presence tests for _showWritingTools and standardWritingToolsMenuItem.
MarkEditMac/Modules/Sources/AppKitExtensions/UI/NSMenuItem+Extension.swift Adds systemWritingToolsItem accessor via standardWritingToolsMenuItem.
MarkEditMac/Base.lproj/Main.storyboard Adds hidden placeholder Writing Tools menu item and connects it to the AppDelegate outlet.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread MarkEditMac/Modules/Tests/RuntimeTests.swift
Comment thread MarkEditMac/Sources/Main/Application/AppDelegate+Menu.swift Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 13 out of 13 changed files in this pull request and generated 2 comments.

Comment thread MarkEditMac/Sources/Main/Application/AppDelegate+Menu.swift
Comment thread MarkEditMac/Modules/Tests/RuntimeTests.swift
@cyanzhong cyanzhong merged commit 8cfdbae into main Jun 18, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants