-
Notifications
You must be signed in to change notification settings - Fork 289
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Apple translation popovers for notes for iOS 17.4+ and macOS 14.4+ #2303
base: master
Are you sure you want to change the base?
Conversation
@tyiu is it possible to set up auto translate using iOS offline translations? That is, remove the need to tap "translate note" |
Technically yes, but only in iOS 18.0+ |
very cool, will test this soon |
There's a bug when |
Changelog-Added: Add Apple translation popovers for notes for iOS 17.4+ and macOS 14.4+
34e0651
to
419de9f
Compare
I mischaracterized the this PR. It's not exclusively offline note translations from Apple. The translation requests can still go to Apple servers, but can be offline as well via downloaded languages if there's network connectivity issues. I've updated the description, commit, and PR title accordingly Note that the branch name says offline-translations, which is incorrect. But I didn't want to create a new PR just for the sake of a new branch name.
I fixed the bug that I reported in my previous comment. |
@@ -38,7 +38,13 @@ enum TranslationService: String, CaseIterable, Identifiable, StringCodable { | |||
var model: Model { | |||
switch self { | |||
case .none: | |||
return .init(tag: self.rawValue, displayName: NSLocalizedString("none_translation_service", value: "None", comment: "Dropdown option for selecting no translation service.")) | |||
let displayName: String | |||
if TranslationService.isAppleTranslationPopoverSupported { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd like to solicit feedback here. Right now, if you have iOS 17.4+, there's no way to turn off translations. It's just using Apple by default, but requires an explicit tap on the Translate Note button.
Alternatively, I could make None
and Apple
separate options, but it feels like we have an opportunity to be more opinionated here to just say everyone needs translations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we need to consider the privacy aspect, given that some of those translate requests might be sent to Apple servers.
In my opinion, we should be opinionated and place the button "Translate note" by default, and then add a confirmation dialog explaining the user the text might be sent to Apple servers, with an option to dismiss that dialog forever if the user chooses to do so.
For the iOS 18 feature where translations can be made automatically, I believe that should be opt-in.
Changelog-Added: Add Apple translation popovers for notes for iOS 17.4+ and macOS 14.4+
RPReplay_Final1718937575.MP4
These changes are gated around iOS and macOS versions. If an older OS is being run, Apple translations won't be offered.