Repository navigation
Conversation
…on (#366) - SHARE-20: a "Send to Phone" NSServices entry (sendToPhone, NSSendFileTypes public.data) hands the selected regular files to dropFiles(urls, target: nil), so a lone .apk/.apks/.xapk installs and the rest take the drop transfer with its 200 MiB cap, busy refusal and offline refusal unchanged. No dialog, no setting, no wire message; the log carries the file count only. - NOTIFY-24: a forwarded banner whose title+text hold exactly one distinct http(s) link that passes ShareInPolicy.webURL gets an "Open link" button after the phone's actions and Copy code, only while those number fewer than three. A press opens the link in the Mac's default browser only: no notify.action, no pasteboard write, the record names the id only. - Pure NotifyLink.find and NotifyBannerExtras.plan, K2 NotifyLinkTests and SendToPhoneServiceTests naming the spec IDs; specs, UX.md, MAP.md and design/notify.md updated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
marcoslor
force-pushed
the
t3/mac-finder-send-open-link
branch
from
December 3, 2026 22:12
c86371d to
f4a8071
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #366
What
NSServicesentry inmacos/scripts/bundle.sh(sendToPhone,NSSendFileTypespublic.data, so any regular file and never a folder).LinkService.sendToPhone→SendToPhoneService.sendreads the selection's file URLs, keeps the regular files in order and hands them todropFiles(urls, target: nil)— the same route a Deck drop takes. A lone.apk/.apks/.xapkstill goes to the installer (SHARE-11), and the 200 MiB cap, single-transfer busy refusal and offline refusal ("Connect a phone to send files to it.") apply unchanged. No dialog, setting or wire message. A selection with no file answers Services "Only files can be sent to the phone." The log carries the file count only.NotifyLink.find(title:text:)finds exactly one distincthttp/httpsword in the title and text together. It counts words the same way Send to Mac does (ShareInPolicy.webLinkCandidates, factored out ofclassify) and checks the link withShareInPolicy.webURL(LinkPolicy plus a host). Other schemes are never candidates, and two different links give none.NotifyBannerExtras.plandecides the buttons. Copy code keeps its current rule and comes first. Open link is added last, only while the phone's actions plus Copy code number fewer than 3..openLink(pd.link) toperformOpenLink, which only callsNSWorkspace.open. Nothing is sent to the phone, nothing is written to the pasteboard, and the record line isnotify openlink id=…. The post line gainslink=0/1, placed aftercategory=so the existing e2e greps still match.Docs
docs/specs/share-clipboard.md(SHARE-20, SHARE-S9, phone-count rows, conventions),docs/specs/notifications.md(NOTIFY-24, NOTIFY-S11, NOTIFY-9's shape hash, banner state row, CONV-PD-07),docs/UX.md,docs/MAP.md,docs/design/notify.md.Notes for review
public.datawas chosen overpublic.itemso that Finder doesn't offer the Service for folders, which the drop transfer can't send.Checks
Run locally (Tier 0 only, because of the 8 GB RAM limit):
swiftc -parseon every changed Swift file,check-rules,check-ratchets,check-docs --fail-on-clarificationsandcheck-formatall pass.swift build/swift testwere not run locally; CI runs them. New K2 tests:NotifyLinkTests(NOTIFY-24) andSendToPhoneServiceTests(SHARE-20).🤖 Generated with Claude Code