Closed Bug 1000772 Opened 11 years ago Closed 10 years ago

Desktop client needs to let a non signed-in user send a call-back URL by e-mail

Categories

(Hello (Loop) :: Client, defect, P1)

defect

Tracking

(firefox34 verified)

VERIFIED FIXED
mozilla34
Tracking Status
firefox34 --- verified

People

(Reporter: RT, Assigned: rgauthier)

References

()

Details

(Whiteboard: p=1)

User Story

As a non signed-in FF browser user I can open my e-mail composer with a pre-populated Subject and Body including the call-back URL, so that I can easily share the URL with a contact of my e-mail service address book.

Attachments

(3 files, 8 obsolete files)

No description provided.
User Story: (updated)
Priority: -- → P2
Whiteboard: [s=ui32]
Target Milestone: --- → mozilla32
This leverages mailto which uses the default e-mail client (hard client such as Thundebird or webclients such as GMail or Yahoo are supported as per about:preferences in the "applications" section). Example: mailto:?subject=Loop invitation to chat&body=Please click that link to call me back [LINK].
No longer blocks: 1000770
Depends on: 1000770
Blocks: 972014
Whiteboard: [s=ui32] → p=?
Target Milestone: mozilla32 → mozilla33
Blocks: 1014575
No longer blocks: 972014
Summary: Desktop client needs UI to let a non signed-in user send a call-back URL by e-mail → Desktop client needs to let a non signed-in user send a call-back URL by e-mail
Depends on: 1015891
Depends on: 1015941
Depends on: 1015944
Priority: P2 → P1
Darrin, is "send by email" the default action of the share button? The MVP spec shows it as a list (with a default), but doesn't indicate what the items on the list are.
Flags: needinfo?(dhenein)
For MVP we only will allow the user to share by e-mail. Beyond MVP there will be more options - Darrin maybe we remove the chevron as there is effectively just one option and use a different wording than "Share" to be more explicit about the fact that it will open your email composer?
That seems fair. The Share + chevron UI was intended to scale when we add more sharing options, though for now changing it to "Email" with no chevron seems reasonable until we actually have other options. Mark, is that clear enough? I will update the spec when I can.
Flags: needinfo?(dhenein)
Whiteboard: p=? → p=1
Assignee: nobody → rgauthier
Attachment #8455304 - Flags: review?(standard8)
Comment on attachment 8455304 [details] [diff] [review] Add a button to send url by email Review of attachment 8455304 [details] [diff] [review]: ----------------------------------------------------------------- Can you update this to the latest master please? I think the patch for re-laying out the panel landed and this doesn't apply now.
Attachment #8455304 - Flags: review?(standard8)
Target Milestone: mozilla33 → 33 Sprint 3- 7/21
Attachment #8458700 - Flags: review?(nperriault)
Comment on attachment 8458700 [details] [diff] [review] Add a button to send url by email Review of attachment 8458700 [details] [diff] [review]: ----------------------------------------------------------------- Looks good, but please add a test. This could be done by stubbing mozL10n.get to at least ensure that it's called with the right string id and call url. ::: browser/components/loop/content/js/panel.jsx @@ +183,5 @@ > render: function() { > + var mailto = [ > + "mailto:?subject=" + __("share_email_subject") + "&", > + "body=" + __("share_email_body", {callUrl: this.state.callUrl}) > + ].join(""); Could we move this to some "private" function, eg. _generateMailto?
Attachment #8455304 - Attachment is obsolete: true
Attachment #8458700 - Attachment is obsolete: true
Attachment #8458700 - Flags: review?(nperriault)
Attachment #8459591 - Flags: review?(nperriault)
Comment on attachment 8459591 [details] [diff] [review] Add a button to send url by email Review of attachment 8459591 [details] [diff] [review]: ----------------------------------------------------------------- Looks good overall, minor nits to be optionally addressed; slightly more concerned with l10n and the non-urlencoded mailto link. r+ conditional to this not being an issue. ::: browser/components/loop/content/js/panel.jsx @@ +183,5 @@ > + _generateMailto: function() { > + return [ > + "mailto:?subject=" + __("share_email_subject") + "&", > + "body=" + __("share_email_body", {callUrl: this.state.callUrl}) > + ].join(""); Shouldn't we urlencode this string? I'm suspecting possible issues with l10n other than en_US. There's this dirty but helpful hack which relies on a temporary <a> element: > var a = document.createElement('a'); > a.href = "http://foo?été"; > a.href; // "http://foo/?%C3%A9t%C3%A9" Not sure we really want to use this though; your take ;) ::: browser/components/loop/test/desktop-local/panel_test.js @@ +50,5 @@ > + text = "{{callUrl}}"; > + else > + text = "fakeText"; > + > + return JSON.stringify({textContent: text}); Nit: I'd rather see these defined contextually for each test. @@ +311,5 @@ > + var view = TestUtils.renderIntoDocument(loop.panel.CallUrlResult({ > + notifier: notifier, > + client: fakeClient > + })); > + var shareButton; Nit: unnecessary assignment. @@ +316,5 @@ > + view.setState({pending: false, callUrl: "http://example.com"}); > + > + TestUtils.findRenderedDOMComponentWithTag(view, "a"); > + var shareButton = view.getDOMNode().querySelector("a.btn"); > + expect(shareButton.href).to.equal(mailto); See previous comment about urlencoding this string.
Attachment #8459591 - Flags: review?(nperriault) → review+
(In reply to Nicolas Perriault (:NiKo`) from comment #10) > There's this dirty but helpful hack which relies on a temporary <a> element: > > > var a = document.createElement('a'); > > a.href = "http://foo?été"; > > a.href; // "http://foo/?%C3%A9t%C3%A9" > > Not sure we really want to use this though; your take ;) You'll want to use encodeURIComponent(), obviously -_-'
Attachment #8459591 - Attachment is obsolete: true
Attachment #8459655 - Flags: review?(nperriault)
Comment on attachment 8459655 [details] [diff] [review] Add a button to send url by email Review of attachment 8459655 [details] [diff] [review]: ----------------------------------------------------------------- LGTM, r+. Please add a screenshot and submit it for UX review to :darrin, thanks! :)
Attachment #8459655 - Flags: review?(nperriault) → review+
Actually, :sevaan is helping us out with UX review while :darrin is out of the office.
Attached image share-email-button.png (obsolete) —
Attachment #8460175 - Flags: ui-review?(sfranks)
Comment on attachment 8460175 [details] share-email-button.png Hi guys, Just a couple questions (forgive my ignorance, as I'm just stepping in while Darrin is away)... 1) Is there a reason the button is green (#5cb85c) while in the spec it's blue (#0095dd)? 2) The button in the spec is 3px taller than the one in the screenshot. 3) Can we extend the width of the button so it takes up half the door hanger, again matching the spec? 4) The text in the button should also be bold. Thanks, Sevaan
Attachment #8460175 - Flags: ui-review?(sfranks)
Target Milestone: 33 Sprint 3- 7/21 → 34 Sprint 1- 8/4
Hi Romain -- Can you answer and/or address Sevaan's questions in Comment 16? Is this blocked only on UI-review? This is one of the bugs that Chad and RT would like to get uplifted into Aurora. Thanks.
Flags: needinfo?(rgauthier)
(In reply to Sevaan Franks [:sevaan] from comment #16) > Comment on attachment 8460175 [details] > share-email-button.png Thanks Sevaan, those comments are valid and should be resolved before ui r+. Can we also have Matej look at the "Please click that link to call me back:" string? There may be room for improvement.
Flags: needinfo?(Mnovak)
Here is the last version of the patch. It should address UX comments.
Attachment #8459655 - Attachment is obsolete: true
Flags: needinfo?(rgauthier)
Attached image share-email-button.png (obsolete) —
Attachment #8460175 - Attachment is obsolete: true
Comment on attachment 8465562 [details] [diff] [review] Add a button to send url by email Review of attachment 8465562 [details] [diff] [review]: ----------------------------------------------------------------- Looks good, some comments need to be addressed though. ::: browser/components/loop/content/js/panel.jsx @@ +211,5 @@ > <PanelLayout summary={__("share_link_header_text")}> > <div className="invite"> > <input type="url" value={this.state.callUrl} readOnly="true" > className={cx({'pending': this.state.pending})} /> > + <a className={this.state.callUrl ? 'btn' : 'btn hide'} Nit: You could use a classSet here http://facebook.github.io/react/docs/class-name-manipulation.html ::: browser/components/loop/content/shared/css/common.css @@ +57,5 @@ > clear: both; > } > > .hide { > + display: none !important; Please add a comment why this is needed. ::: browser/components/loop/content/shared/css/panel.css @@ +82,5 @@ > + width: 50%; > + height: 26px; > + text-align: center; > + font-weight: bold; > +} I wish we went with a style reusable elsewhere, though it's probably good enough for now. Up to you. ::: browser/components/loop/test/desktop-local/panel_test.js @@ +247,5 @@ > > describe("Rendering the component should generate a call URL", function() { > > + beforeEach(function() { > + document.mozL10n.initialize({getStrings: function(key) { Nit: This would be a bit more legible formatted this way: document.mozL10n.initialize({ getStrings: function(key) { var… ::: browser/locales/en-US/chrome/browser/loop/loop.properties @@ +40,5 @@ > target="_blank" href="{{terms_of_use_url}}">Terms of Use</a> and <a \ > href="{{privacy_notice_url}}">Privacy Notice</a>. > + > +share_email_subject=Loop invitation to chat > +share_email_body=Please click that link to call me back:\r\n\r\n{{callUrl}} Nit: You may want to repeat the LOCALIZATION NOTE here, though it feels overkill. Up to you.
Attachment #8465562 - Flags: feedback+
Comment on attachment 8465563 [details] share-email-button.png - text should be vertically centered within the button - button group (will eventually be Email and Copy) should have more padding above and below (14px I believe) - button color is incorrect - button text color is incorrect I know you were using http://people.mozilla.org/~mmaslaney/loop/Loop-spec.png which is great, I just want these buttons to have the Action style (blue with white text, see bottom of that spec).
Attachment #8465563 - Flags: review-
(In reply to Darrin Henein [:darrin] from comment #18) > (In reply to Sevaan Franks [:sevaan] from comment #16) > > Comment on attachment 8460175 [details] > > share-email-button.png > > Thanks Sevaan, those comments are valid and should be resolved before ui r+. > > Can we also have Matej look at the "Please click that link to call me back:" > string? There may be room for improvement. Is this a one-time use link? Or can the person always use it to reach the other person? Here are a few options that cover both use cases: If you ever need to reach me, use this link: Need to call me back? Use this link: Here's a link you can use to call me back: Call me back at this link: Use this link to call me back:
Flags: needinfo?(Mnovak)
Do you think we can file the recommendations in Comment 23 as a follow up bug? I'd like to make this particular bug about implementing the current spec since we currently have no email button on the UI. Thanks.
Flags: needinfo?(dhenein)
Flags: needinfo?(Mnovak)
(In reply to Maire Reavy [:mreavy] (Plz needinfo me) from comment #24) > Do you think we can file the recommendations in Comment 23 as a follow up > bug? I'd like to make this particular bug about implementing the current > spec since we currently have no email button on the UI. Thanks. It's all the same to me. Darrin, if you file a new bug, just assign it to me and I'll add the options there.
Flags: needinfo?(Mnovak)
Sure -- was just commenting as the screenshots for review included the copy in the generated email (which I believe gets passed from this Email button).
Flags: needinfo?(dhenein)
Matej, not sure workflows change in our new world order, but flagging Eric and Arcadio who have an interest in this copy. (In reply to Matej Novak [:matej] from comment #25) > (In reply to Maire Reavy [:mreavy] (Plz needinfo me) from comment #24) > > Do you think we can file the recommendations in Comment 23 as a follow up > > bug? I'd like to make this particular bug about implementing the current > > spec since we currently have no email button on the UI. Thanks. > > It's all the same to me. > > Darrin, if you file a new bug, just assign it to me and I'll add the options > there.
Flags: needinfo?(epetitt)
Flags: needinfo?(alainez)
Hi Romain -- Can you put the new patch up to review to Niko (or one of the other Loop reviewers)? I notice this has a feedback+, not an r+, and it's for the old patch.
Flags: needinfo?(rgauthier)
Attachment #8465562 - Attachment is obsolete: true
Attachment #8468358 - Flags: review?(nperriault)
Flags: needinfo?(rgauthier)
Attached image share-email-button.png
Attachment #8465563 - Attachment is obsolete: true
Comment on attachment 8468358 [details] [diff] [review] Add a button to send url by email Review of attachment 8468358 [details] [diff] [review]: ----------------------------------------------------------------- LGTM
Attachment #8468358 - Flags: review?(nperriault) → review+
Comment on attachment 8468358 [details] [diff] [review] Add a button to send url by email Review of attachment 8468358 [details] [diff] [review]: ----------------------------------------------------------------- Sorry I need to cancel r+, because the jsx files have been compiled with react-tools v0.10.0, while we upgraded to 0.11.1 lately. Please update the patch to use the latest version, so we avoid unnecessary diffs.
Attachment #8468358 - Flags: review+ → review-
Attachment #8468358 - Attachment is obsolete: true
Comment on attachment 8468421 [details] [diff] [review] Add a button to send url by email Review of attachment 8468421 [details] [diff] [review]: ----------------------------------------------------------------- Looks good, thanks!
Attachment #8468421 - Flags: review+
Landed with the existing text: https://hg.mozilla.org/integration/fx-team/rev/2e89d2bb6fac If there's any follow-ups for change of text, please file them as new bugs.
Target Milestone: 34 Sprint 1- 8/4 → mozilla34
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Before filing a new bug, I'd like to know why we're shooting ourselves in the foot by hard-coding "Loop" in the strings. That's the first one I've seen so far, so I'm asking, it might be on purpose. If you want to expose the product name, and we should all know that "Loop" is not it, please put the name in branding and use a replacement in strings.
Depends on: 1050263
(In reply to Francesco Lodolo [:flod] from comment #37) > Before filing a new bug, I'd like to know why we're shooting ourselves in > the foot by hard-coding "Loop" in the strings. That's the first one I've > seen so far, so I'm asking, it might be on purpose. Yeah, that's a mistake, I'm fixing it in bug 1050263.
Depends on: 1053774
Depends on: 1053780
Attached image Yahoo mail
I have Yahoo Mail set to handle mailto in about:preferences and when I hit the button to share by e-mail rather than opening a new tab, Yahoo mail composer opens in the panel UI.
Flags: qe-verify+
QA Contact: paul.silaghi
Verified fixed 34.0a1 (2014-09-02) Win 7, OS X 10.9.4, Ubuntu 13.04
Status: RESOLVED → VERIFIED
Depends on: 1070972
Removing apparently obsolete NI requests which were about the text for sending emails. I believe this has been overtaken by events, if any changes/additional discussion is required, please file a new bug so it can be tracked there.
Flags: needinfo?(epetitt)
Flags: needinfo?(alainez)
Depends on: 1086272
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: