Merge lp:~allenap/launchpad/show-me-too-spinner into lp:launchpad

Proposed by Gavin Panella
Status: Merged
Approved by: Gavin Panella
Approved revision: not available
Merged at revision: not available
Proposed branch: lp:~allenap/launchpad/show-me-too-spinner
Merge into: lp:launchpad
Diff against target: 27 lines (+4/-2)
2 files modified
lib/canonical/launchpad/javascript/bugs/bugtask-index.js (+1/-1)
lib/lp/bugs/templates/bugtasks-and-nominations-table.pt (+3/-1)
To merge this branch: bzr merge lp:~allenap/launchpad/show-me-too-spinner
Reviewer Review Type Date Requested Status
Данило Шеган (community) release-critical Approve
Deryck Hodge (community) code js Approve
Review via email: mp+16143@code.launchpad.net

Commit message

Make the 'Does this bug affect you?' spinner always appear, and appear in the right place, and fix the mouse cursor when hovering over the edit icon. Previously the spinner would only appear if the flame icon had been visible, the spinner would replace the flame icon instead of the edit icon, and the mouse cursor did not change when hovering over the edit icon.

To post a comment you must log in.
Revision history for this message
Gavin Panella (allenap) wrote :

Change the HTML_PARSER declaration in MeTooChoiceSource to use the editicon CSS class instead of src$=/@@/edit. The src$=... rule seemed to be either not finding the correct image, or not finding any image.

Revision history for this message
Deryck Hodge (deryck) wrote :

Looks good to me. Thanks for making this change!

As I mentioned on IRC, it would be nice to fix bug 415161 at the same time as this change. But I leave that your judgment.

Cheers,
deryck

review: Approve (code js)
Revision history for this message
Данило Шеган (danilo) wrote :

Looks good.

review: Approve (release-critical)
Revision history for this message
Deryck Hodge (deryck) wrote :

Gavin,

The addition for the correct icon cursor looks good. Thanks!

However, there needs to be a CSS rule to prevent the icon being underlined on hover now.

Cheers,
deryck

Revision history for this message
Gavin Panella (allenap) wrote :

Hi Deryck. I've fixed the underline issue by putting the edit icon in its own <a>...</a>, so that the js-action class is not applied to it. Seems to work nicely.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lib/canonical/launchpad/javascript/bugs/bugtask-index.js'
2--- lib/canonical/launchpad/javascript/bugs/bugtask-index.js 2009-12-10 20:59:49 +0000
3+++ lib/canonical/launchpad/javascript/bugs/bugtask-index.js 2009-12-14 20:59:13 +0000
4@@ -1504,7 +1504,7 @@
5 var me_too_edit = new MeTooChoiceSource({
6 contentBox: me_too_content, value: user_is_affected,
7 elementToFlash: me_too_content,
8- editicon: ".dynamic img[src$=/@@/edit]",
9+ editicon: ".dynamic img.editicon",
10 others_affected_count: others_affected_count
11 });
12 me_too_edit.render();
13
14=== modified file 'lib/lp/bugs/templates/bugtasks-and-nominations-table.pt'
15--- lib/lp/bugs/templates/bugtasks-and-nominations-table.pt 2009-12-11 14:00:13 +0000
16+++ lib/lp/bugs/templates/bugtasks-and-nominations-table.pt 2009-12-14 20:59:13 +0000
17@@ -34,7 +34,9 @@
18 <img src="/@@/flame-icon" alt=""/>
19 <a href="+affectsmetoo" class="js-action"
20 ><span class="value" tal:content="view/affected_statement" /></a>
21- <img class="editicon" src="/@@/edit" alt="Edit" />
22+ <a href="+affectsmetoo">
23+ <img class="editicon" src="/@@/edit" alt="Edit" />
24+ </a>
25 </span>
26 <script type="text/javascript" tal:content="string:
27 LPS.use('event', 'bugs.bugtask_index', function(Y) {