bugzilla.mozilla.org will be intermittently unavailable on Saturday, March 24th, from 16:00 until 20:00 UTC.

Handle "Add to Passbook" from within apps




Firefox for iOS
2 years ago
2 years ago


(Reporter: fluffyemily, Assigned: fluffyemily, Mentored)



Firefox Tracking Flags

(fxios-v5.0 fixed, fxios+)


(Whiteboard: [target 5.0])


(1 attachment)

48 bytes, text/x-github-pull-request
: review+
Details | Review | Splinter Review


2 years ago

Go to http://www.flonsolutions.com/fantastic_voyages.html

Click on Add To Passbook under any options


Firefox offers to add the associated pass to passbook


Firefox tells the user that downloads are not supported and to open the URL in Safari.

We need to be able to handle add to passbook. Clicking on that Add To Passbook link takes you to a pkpass file. This file is simply some JSON in passbook format. To handle this, the JSON needs to be downloaded and then add to the users wallet via the PKAddPassesViewController. Details can be found here: https://developer.apple.com/library/ios/documentation/UserExperience/Conceptual/PassKit_PG/Apps.html#//apple_ref/doc/uid/TP40012195-CH6-SW1

I am unsure at this point whether or not we need to get passbook enabled certificates etc to handle this or whether by simply adding to passbook we can get away with not going down that route, but regardless we need to add the passbook entitlement and permission to use the API's.
Curious if Chrome handles this.

Comment 2

2 years ago
Yes, Add to Passbook works inside Chrome
Component: General → Browser
Hardware: Other → All
tracking-fxios: ? → +
So this looks like URL handling. In both Safari and in Chrome it slides up to reveal this view: http://i.sevaan.com/2W170J0i2y3O

So it seems like it's OS-specific and doesn't require custom UX.


2 years ago
Assignee: nobody → etoop

Comment 5

2 years ago
Created attachment 8759699 [details] [review]
Pull request

Happy for this one to not make it into 5.0, but it would be nice to see it sometime
Attachment #8759699 - Flags: review?(sleroux)
Whiteboard: [needstrings]
Comment on attachment 8759699 [details] [review]
Pull request

Awesome :D It's be great if we could get this in 5.0 but I'm not sure with the addition of the strings. Also seems feature flaggable if we're worried about it but it seems pretty self contained.
Attachment #8759699 - Flags: review?(sleroux) → review+

Comment 7

2 years ago
merged https://github.com/mozilla/firefox-ios/commit/8ac9c15f8c8f6c40cebe53f5d9a3d8768ff0f2cf
Last Resolved: 2 years ago
Resolution: --- → FIXED
Whiteboard: [needstrings] → [target 5.0][needsuplift]

Comment 8

2 years ago
hey :flod. This patch has new strings. Is it too late to add new ones for 5.0?
Flags: needinfo?(francesco.lodolo)
Switching NI to delphine for the question since she's the owner of Fennec l10n.

By a quick look at the strings, I confess I have no clue what they do, and it would be helpful to have something in the notes. I had to Google to find out what a "pass" is in this context: https://support.apple.com/HT204003

e.g. "Title of the dialog displayed when adding a pass to the Passbook fails. See https://support.apple.com/HT204003 for context on Passbook."
Flags: needinfo?(francesco.lodolo) → needinfo?(lebedel.delphine)
Hey Emily, thanks for reaching out. I think in this case since we are not too late in the cycle, we can add these strings. Please take note of :flod's comment as well. Thanks!
Flags: needinfo?(lebedel.delphine)
v5.x c10c6775a196a16de92cd4a380e4c91700802881
status-fxios-v5.0: --- → fixed
Whiteboard: [target 5.0][needsuplift] → [target 5.0]
(In reply to Stephan Leroux [:sleroux] from comment #11)
> v5.x c10c6775a196a16de92cd4a380e4c91700802881

Were the comments fixed? I also don't see this anywhere
> Were the comments fixed? 

I don't think so - I uplifted whatever was already merged into master. We can submit another patch for the comment fixes to v5.x on top of this change though.

> I also don't see this anywhere

Still burning down the [needsuplift] list before pushing up the branch.

Comment 14

2 years ago
(In reply to Francesco Lodolo [:flod] from comment #12)
> (In reply to Stephan Leroux [:sleroux] from comment #11)
> > v5.x c10c6775a196a16de92cd4a380e4c91700802881
> Were the comments fixed? I also don't see this anywhere
> https://github.com/mozilla/firefox-ios/commits/v5.x

I've addressed the comments in https://bugzilla.mozilla.org/show_bug.cgi?id=1278559 which also now adds a few strings.
You need to log in before you can comment on or make changes to this bug.