Merge lp:~sinzui/launchpad/front-page-footer-0 into lp:launchpad

Proposed by Curtis Hovey
Status: Merged
Merged at revision: 11001
Proposed branch: lp:~sinzui/launchpad/front-page-footer-0
Merge into: lp:launchpad
Diff against target: 915 lines (+197/-191)
15 files modified
lib/canonical/launchpad/icing/icon-sprites.positioning (+26/-22)
lib/canonical/launchpad/icing/style-3-0.css.in (+4/-0)
lib/canonical/launchpad/pagetests/basics/demo-and-lpnet.txt (+4/-13)
lib/lp/app/browser/tests/base-layout.txt (+61/-81)
lib/lp/app/templates/base-layout-macros.pt (+1/-3)
lib/lp/app/templates/base-layout.pt (+9/-11)
lib/lp/app/templates/root-index.pt (+66/-42)
lib/lp/blueprints/stories/blueprints/05-reviews.txt (+3/-3)
lib/lp/bugs/stories/bugtask-searches/xx-advanced-people-filters.txt (+8/-4)
lib/lp/bugs/stories/bugtask-searches/xx-advanced-upstream-pending-bugwatch.txt (+2/-1)
lib/lp/code/templates/bazaar-index.pt (+2/-2)
lib/lp/registry/stories/milestone/object-milestones.txt (+4/-2)
lib/lp/registry/stories/product/xx-product-add.txt (+2/-2)
lib/lp/soyuz/stories/ppa/xx-copy-packages.txt (+1/-1)
lib/lp/translations/stories/standalone/xx-pofile-translate.txt (+4/-4)
To merge this branch: bzr merge lp:~sinzui/launchpad/front-page-footer-0
Reviewer Review Type Date Requested Status
Abel Deuring (community) code Approve
Review via email: mp+27311@code.launchpad.net

Description of the change

This is my branch to fix some template and front page issues.

    lp:~sinzui/launchpad/front-page-footer-0
    Diff size: 528
    Launchpad bug:
          https://bugs.launchpad.net/bugs/321783
          https://bugs.launchpad.net/bugs/592324
          https://bugs.launchpad.net/bugs/590575
          https://bugs.launchpad.net/bugs/590621
          https://bugs.launchpad.net/bugs/524305
    Test command: ./bin/test -vv \
          -t base-layout.txt -t front-pages.txt -t xx-featuredprojects
    Pre-implementation: flacoste, jtv
    Target release: 10.06

Fix some template and front page issues
----------------------------------------

Bug #321783 ["Contact us" should be "Contact Launchpad Support"]
    The footer of each Launchpad page has a contact link labeled "Contact us".
    To the casual visitor it is not obvious, who "us" is and if he/she is
    viewing a project's/distribution's page he/she might well think "us" is
    the project/distribution maintainer.

Bug #592324 [remove launchpad release version from the footer]
    The launchpad release version is not helpful in the footer. Most servers
    have revisions after the stated version. Even lpnet has revisions after
    the stated version. Developers and testers need to use the revision
    number, which is already in the page. Remove release version.

Bug #590575 [Launchpad main page has old bazaar homepage link]
    Launchpad main page (https://launchpad.net/) used http://bazaar-vcs.org/
    for bazaar home page instead of http://bazaar.canonical.com/

Bug #590621 [Complete the conversion to sprites]
    Common pages are using <img> tags instead of sprites which have poor
    performance.

Bug #524305 [Notification leaves header cloven in two]
    Notifications split the 3.0 header from the page title.

Rules
-----

Bug #321783 ["Contact us" should be "Contact Launchpad Support"]
    * It should be "Contact Launchpad Support". The important information
      here is that this is support for Launchpad.

Bug #592324 [remove launchpad release version from the footer]
    * Delete the text and link.

Bug #590575 [Launchpad main page has old bazaar homepage link]
    * Update all occurrences of http://bazaar-vcs.org/ to
      http://bazaar.canonical.com/

Bug #590621 [Complete the conversion to sprites]
    * Update the Lp front page. It is the only page in lp/app that needs
      fixing.

Bug #524305 [Notification leaves header cloven in two]
    * Move the site message and notification block belove the bread crumbs.

QA
--

Bug #321783 ["Contact us" should be "Contact Launchpad Support"]
    * Visit edge.
    * Verify the page has a link to "Contact Launchpad Support" in the
      footer.

Bug #592324 [remove launchpad release version from the footer]
    * Visit edge.
    * Verify 10.05 is not listed in the footer.

Bug #590575 [Launchpad main page has old bazaar homepage link]
    * Visit http://edge.launchpad.net/ as an anonymous user.
    * Verify that the link the the bzr home page is
      http://bazaar.canonical.com/
    * Visit http://code.edge.launchpad.net/ as an anonymous user.
    * Verify that the link the the bzr home page is
      http://bazaar.canonical.com/

Bug #590621 [Complete the conversion to sprites]
    * Visit http://edge.launchpad.net/ as an anonymous user.
    * Verify that the Lp features section has the correct sprites for
      the links.
    * Visit http://edge.launchpad.net/ while logged in.
    * Verify that the get started links have the correct sprites.
    * Verify that we ask users to "Register a <project|team>"...we do
      not care if it is new, and we love upstream teams and projects as
      much as those hosted on Lp.
    * Verify the feature project logo and displayname are shown.

Bug #524305 [Notification leaves header cloven in two]
    * Visit a project series.
    * Chose the subscribe link and subscribe/unsubscribe yourself
    * Verify the notification is below the bread crumbs above the page
      content.

Lint
----

Linting changed files:
  lib/canonical/launchpad/icing/style-3-0.css.in
  lib/lp/app/browser/tests/base-layout.txt
  lib/lp/app/templates/base-layout-macros.pt
  lib/lp/app/templates/base-layout.pt
  lib/lp/app/templates/root-index.pt
  lib/lp/code/templates/bazaar-index.pt

Test
----

    * lib/lp/app/browser/tests/base-layout.txt
      * Refactors the fragment tests to be more precise about what is under
        test.
      * Updated the footer test to verify that the Contact Launchpad Support
        link is in the footer.
      * Added a test for the position of notifications.

Implementation
--------------

Linting changed files:
    * lib/canonical/launchpad/icing/style-3-0.css.in
      * Added a tour sprite rule. We will need to add add it to the sprite
        file in the near future.
    * lib/lp/app/templates/base-layout-macros.pt
      * Updated the test for the feedback link to Contact Launchpad Support
      * Removed the link to the LaunchpadReleases version.
    * lib/lp/app/templates/base-layout.pt
      * Moved the position of the notifications to be between the breadcrumbs
        and page content.
    * lib/lp/app/templates/root-index.pt
      * Replaced the link icons with sprites.
      * Fixed the link to bazaar.canonical.com
    * lib/lp/code/templates/bazaar-index.pt
      * Fixed the links to bazaar.canonical.com

To post a comment you must log in.
Revision history for this message
Abel Deuring (adeuring) wrote :
Download full text (3.2 KiB)

Hi Curtis,

a nice branch. I have just two nitpicks, see below.

> === modified file 'lib/canonical/launchpad/icing/style-3-0.css.in'
> --- lib/canonical/launchpad/icing/style-3-0.css.in 2010-06-07 21:48:06 +0000
> +++ lib/canonical/launchpad/icing/style-3-0.css.in 2010-06-10 22:20:48 +0000
> @@ -1785,6 +1785,10 @@
> */
> padding:2px 0 0 18px;
> }
> +.tour {
> + background-image: url(/@@/tour-icon); /* needs-ref: */
> + background-repeat: no-repeat;
> + }

I think "needs-ref" above is worth an XXX.

> === modified file 'lib/lp/app/templates/root-index.pt'
> --- lib/lp/app/templates/root-index.pt 2010-04-29 13:22:29 +0000
> +++ lib/lp/app/templates/root-index.pt 2010-06-10 22:20:48 +0000
> @@ -89,27 +89,42 @@
> tal:condition="not:view/user" tal:content="cache:anonymous">
> <h2><span class="launchpad-gold">Launchpad</span> is a software collaboration platform that provides:</h2>
> <ul tal:define="apphomes view/apphomes">
> - <li><a tal:attributes="href apphomes/bugs"><img src="/@@/bug" alt="" /></a>
> - <a tal:attributes="href apphomes/bugs">Bug tracking</a></li>
> - <li><a tal:attributes="href apphomes/code"><img src="/@@/branch" alt="" /></a>
> - <a tal:attributes="href apphomes/code">Code hosting</a>
> - using <a href="http://bazaar-vcs.org/">Bazaar</a></li>
> - <li><a href="https://help.launchpad.net/Code/Review"><img src="/@@/yes" alt="" /></a>
> - <a href="https://help.launchpad.net/Code/Review">Code reviews</a></li>
> - <li><a tal:attributes="href apphomes/ubuntu"><img src="/@@/ubuntu-icon" alt="" /></a>
> - <a tal:attributes="href apphomes/ubuntu">Ubuntu package building and hosting</a></li>
> - <li><a tal:attributes="href apphomes/translations"><img src="/@@/translation" alt="" /></a>
> - <a tal:attributes="href apphomes/translations">Translations</a></li>
> - <li><a href="https://help.launchpad.net/Teams/MailingLists"><img src="/@@/mail" alt="" /></a>
> - <a href="https://help.launchpad.net/Teams/MailingLists">Mailing lists</a></li>
> - <li><a tal:attributes="href apphomes/answers"><img src="/@@/question" alt="" /></a>
> - <a tal:attributes="href apphomes/answers">Answer tracking and FAQs</a></li>
> - <li><a tal:attributes="href apphomes/blueprints"><img src="/@@/blueprint" alt="" /></a>
> - <a tal:attributes="href apphomes/blueprints">Specification tracking</a></li>
> + <li>
> + <a class="sprite bug"
> + tal:attributes="href apphomes/bugs">Bug tracking</a>
> + </li>
> + <li>
> + <a class="sprite branch"
> + tal:attributes="href apphomes/code">Code hosting</a>
> + using <a href="http://bazaar.canonical.com/">Bazaar</a>
> + </li>
> + <li>
> + <a class="sprite yes"
> + href="https://help.launchpad.net/Code/Review">Code reviews</a>
> + </li>
> +...

Read more...

review: Approve (code)
Revision history for this message
Curtis Hovey (sinzui) wrote :

I removed the trailing whitespace you pointed out.

On Fri, 2010-06-11 at 14:47 +0000, Abel Deuring wrote:
> > +.tour {
> > + background-image: url(/@@/tour-icon); /* needs-ref: */
> > + background-repeat: no-repeat;
> > + }
>
> I think "needs-ref" above is worth an XXX.

I added it to the sprite image. I intended to do this, but neglected to
followup

This is the order of steps to add to the sprite image.
1. Place the image in icing/ (we already had tour-icon)
2. Create a class like this:
   background-image: url(/@@/tour-icon); /* sprite-ref: icon-sprites */
   background-repeat: no-repeat;
3. make sprite_image
4. make sprite_css
5. make css_combine
6. make run.
7. verify you see the icon on the element
8. inspect the CSS applied to the element
   and verify that background-position was added.
9. commit the changes to the generated files.

--
__Curtis C. Hovey_________
http://launchpad.net/

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lib/canonical/launchpad/icing/icon-sprites'
2Binary files lib/canonical/launchpad/icing/icon-sprites 2010-02-17 00:43:19 +0000 and lib/canonical/launchpad/icing/icon-sprites 2010-06-12 14:35:43 +0000 differ
3=== modified file 'lib/canonical/launchpad/icing/icon-sprites.positioning'
4--- lib/canonical/launchpad/icing/icon-sprites.positioning 2010-02-17 00:43:19 +0000
5+++ lib/canonical/launchpad/icing/icon-sprites.positioning 2010-06-12 14:35:43 +0000
6@@ -79,11 +79,11 @@
7 ],
8 "../images/info-large.png": [
9 0,
10- -17176
11+ -17340
12 ],
13 "../images/trash-logo.png": [
14 0,
15- -20194
16+ -20358
17 ],
18 "../images/warning.png": [
19 0,
20@@ -99,19 +99,19 @@
21 ],
22 "../images/branch-large.png": [
23 0,
24- -15902
25+ -16066
26 ],
27 "../images/download-large.png": [
28 0,
29- -16994
30+ -17158
31 ],
32 "../images/private-large.png": [
33 0,
34- -18086
35+ -18250
36 ],
37 "../images/launchpad-large.png": [
38 0,
39- -17358
40+ -17522
41 ],
42 "../images/translation-file.png": [
43 0,
44@@ -123,7 +123,7 @@
45 ],
46 "../images/project-logo.png": [
47 0,
48- -18696
49+ -18860
50 ],
51 "../images/bug-medium.png": [
52 0,
53@@ -133,6 +133,10 @@
54 0,
55 -12130
56 ],
57+ "../images/tour-icon": [
58+ 0,
59+ -15902
60+ ],
61 "../images/trash-icon.png": [
62 0,
63 -11146
64@@ -175,11 +179,11 @@
65 ],
66 "../images/person-logo.png": [
67 0,
68- -19124
69+ -19288
70 ],
71 "../images/distribution-logo.png": [
72 0,
73- -18482
74+ -18646
75 ],
76 "../images/retry.png": [
77 0,
78@@ -219,7 +223,7 @@
79 ],
80 "../images/crowd-large.png": [
81 0,
82- -16266
83+ -16430
84 ],
85 "../images/blueprint.png": [
86 0,
87@@ -247,7 +251,7 @@
88 ],
89 "../images/flame-large.png": [
90 0,
91- -16812
92+ -16976
93 ],
94 "../images/bug-dupe-icon.png": [
95 0,
96@@ -279,7 +283,7 @@
97 ],
98 "../images/team-logo.png": [
99 0,
100- -19552
101+ -19716
102 ],
103 "../images/arrowRight.png": [
104 0,
105@@ -319,7 +323,7 @@
106 ],
107 "../images/error-large.png": [
108 0,
109- -16630
110+ -16794
111 ],
112 "../images/news.png": [
113 0,
114@@ -351,7 +355,7 @@
115 ],
116 "../images/product-logo.png": [
117 0,
118- -18910
119+ -19074
120 ],
121 "../images/blueprint-medium.png": [
122 0,
123@@ -367,11 +371,11 @@
124 ],
125 "../images/launchpad-logo.png": [
126 0,
127- -18268
128+ -18432
129 ],
130 "../images/flame-logo.png": [
131 0,
132- -19980
133+ -20144
134 ],
135 "../images/translation-template.png": [
136 0,
137@@ -383,7 +387,7 @@
138 ],
139 "../images/meeting-logo.png": [
140 0,
141- -19766
142+ -19930
143 ],
144 "../images/treeCollapsed.png": [
145 0,
146@@ -399,7 +403,7 @@
147 ],
148 "../images/trash-large.png": [
149 0,
150- -17904
151+ -18068
152 ],
153 "../images/red-bar.png": [
154 0,
155@@ -415,7 +419,7 @@
156 ],
157 "../images/person-inactive-logo.png": [
158 0,
159- -19338
160+ -19502
161 ],
162 "../images/edit.png": [
163 0,
164@@ -427,7 +431,7 @@
165 ],
166 "../images/warning-large.png": [
167 0,
168- -16084
169+ -16248
170 ],
171 "../images/arrowEnd.png": [
172 0,
173@@ -439,7 +443,7 @@
174 ],
175 "../images/merge-proposal-large.png": [
176 0,
177- -17722
178+ -17886
179 ],
180 "../images/branch.png": [
181 0,
182@@ -451,7 +455,7 @@
183 ],
184 "../images/mentoring-large.png": [
185 0,
186- -17540
187+ -17704
188 ],
189 "../images/bug.png": [
190 0,
191
192=== modified file 'lib/canonical/launchpad/icing/style-3-0.css.in'
193--- lib/canonical/launchpad/icing/style-3-0.css.in 2010-06-07 21:48:06 +0000
194+++ lib/canonical/launchpad/icing/style-3-0.css.in 2010-06-12 14:35:43 +0000
195@@ -2176,6 +2176,10 @@
196 background-image: url(/@@/haspatch-icon.png); /* sprite-ref: icon-sprites */
197 background-repeat: no-repeat;
198 }
199+.tour {
200+ background-image: url(/@@/tour-icon); /* sprite-ref: icon-sprites */
201+ background-repeat: no-repeat;
202+ }
203 .large-branch {
204 background-image: url(/@@/branch-large.png); /* sprite-ref: icon-sprites */
205 background-repeat: no-repeat;
206
207=== modified file 'lib/canonical/launchpad/pagetests/basics/demo-and-lpnet.txt'
208--- lib/canonical/launchpad/pagetests/basics/demo-and-lpnet.txt 2010-03-09 19:11:32 +0000
209+++ lib/canonical/launchpad/pagetests/basics/demo-and-lpnet.txt 2010-06-12 14:35:43 +0000
210@@ -51,7 +51,7 @@
211 <style...url(/@@/demo)...</style>
212 ...
213 >>> print extract_text(find_tag_by_id(browser.contents, 'lp-version'))
214- &bull;...Launchpad...) devmode demo site
215+ &bull; devmode demo site
216
217 >>> print extract_text(find_tags_by_class(
218 ... browser.contents, 'sitemessage')[0])
219@@ -70,7 +70,7 @@
220
221 >>> browser.open('http://launchpad.dev/ubuntu')
222 >>> print extract_text(find_tag_by_id(browser.contents, 'lp-version'))
223- &bull;...Launchpad...) devmode
224+ &bull; devmode
225 >>> len(find_tags_by_class(browser.contents, 'sitemessage'))
226 0
227
228@@ -143,17 +143,8 @@
229
230 == Launchpad.net ==
231
232-On every instance except launchpad.net, Launchpad's version and
233-revision numbers are displayed in the page footer.
234-
235- >>> print config.launchpad.is_lpnet
236- False
237- >>> browser.open('http://launchpad.dev/ubuntu')
238- >>> print extract_text(find_tag_by_id(browser.contents, 'lp-version'))
239- &bull;...Launchpad ... (r...)...
240-
241-On launchpad.net, however, the version and revision numbers are
242-presented only in an HTML comment.
243+On launchpad.net, the version and revision numbers are presented only in an
244+HTML comment.
245
246 >>> # Pretend that we're on launchpad.net:
247 >>> test_data = dedent("""
248
249=== modified file 'lib/lp/app/browser/tests/base-layout.txt'
250--- lib/lp/app/browser/tests/base-layout.txt 2010-04-07 14:02:13 +0000
251+++ lib/lp/app/browser/tests/base-layout.txt 2010-06-12 14:35:43 +0000
252@@ -62,10 +62,12 @@
253
254 Body preamble.
255
256- >>> print html
257- <!DOCTYPE html ...
258- ...
259- <body id="document"
260+ >>> from canonical.launchpad.testing.pages import find_tag_by_id
261+
262+ >>> body_tag = find_tag_by_id(html, 'document')
263+ >>> body = str(body_tag)
264+ >>> print body
265+ <body id="document"
266 class="tab-overview
267 main_side
268 public
269@@ -80,8 +82,8 @@
270
271 Watermark and breadcrumbs.
272
273- >>> print html
274- <!DOCTYPE html ...
275+ >>> print body
276+ <body ...
277 ...
278 <div class="watermark-apps-portlet top-portlet">
279 <img alt="" width="64" height="64" src="/@@/person-logo" />
280@@ -102,9 +104,8 @@
281
282 Top portlet.
283
284- >>> print html
285- <!DOCTYPE html ...
286- ...
287+ >>> print body
288+ <body ...
289 <div class="top-portlet">
290 <p class="registered">
291 Registered on 2005-09-16
292@@ -118,25 +119,20 @@
293
294 Help pane.
295
296- >>> print html
297- <!DOCTYPE html ...
298- ...
299- <div id="help-pane" class="invisible">
300+ >>> print str(find_tag_by_id(body_tag, 'help-pane'))
301+ <div id="help-pane" class="invisible">
302 <div id="help-body">
303- <BLANKLINE>
304 <iframe id="help-pane-content" class="invisible" ...
305 </div>
306 <div id="help-footer">
307 <span id="help-close"></span>
308 </div>
309 </div>
310- ...
311
312 Footer.
313
314 >>> print html
315 <!DOCTYPE html ...
316- ...
317 <!--
318 Facet name: overview
319 Page type: main_side
320@@ -172,9 +168,10 @@
321
322 Watermark.
323
324- >>> print html
325- <!DOCTYPE html ...
326- ...
327+ >>> body_tag = find_tag_by_id(html, 'document')
328+ >>> body = str(body_tag)
329+ >>> print body
330+ <body ...
331 <div class="watermark-apps-portlet top-portlet">
332 <img alt="" width="64" height="64" src="/@@/person-logo" />
333 <h2>Waffles</h2>
334@@ -182,14 +179,8 @@
335
336 Main content.
337
338- >>> print html
339- <!DOCTYPE html ...
340- ...
341- <div id="maincontent" class="yui-main">
342- <BLANKLINE>
343- <BLANKLINE>
344- <BLANKLINE>
345- <BLANKLINE>
346+ >>> print str(find_tag_by_id(body_tag, 'maincontent'))
347+ <div id="maincontent" class="yui-main">
348 <div class="yui-b" dir="ltr">
349 <div>
350 <BLANKLINE>
351@@ -198,6 +189,9 @@
352 </ol>
353 <BLANKLINE>
354 </div>
355+ </div><!-- yui-b -->
356+ <BLANKLINE>
357+ <BLANKLINE>
358 <BLANKLINE>
359 <div class="top-portlet">
360 <h1>Heading</h1>
361@@ -209,18 +203,12 @@
362 Main content of the page.
363 </p>
364 </div>
365- <BLANKLINE>
366- </div><!-- yui-b -->
367- </div><!-- yui-main -->
368- <BLANKLINE>
369- <!-- yui-b side -->
370- <!-- yui-t4 -->
371- ...
372+ </div>
373
374 Global search.
375
376- >>> print html
377- <!DOCTYPE html ...
378+ >>> print body
379+ <body ...
380 <form id="globalsearch" method="get"
381 accept-charset="UTF-8"
382 action="http://launchpad.dev/+search">
383@@ -269,10 +257,10 @@
384
385 Body class.
386
387- >>> print html
388- <!DOCTYPE html ...
389- ...
390- <body id="document"
391+ >>> body_tag = find_tag_by_id(html, 'document')
392+ >>> body = str(body_tag)
393+ >>> print body
394+ <body id="document"
395 class="tab-overview
396 searchless
397 public
398@@ -285,9 +273,8 @@
399
400 Watermarks.
401
402- >>> print html
403- <!DOCTYPE html ...
404- ...
405+ >>> print body
406+ <body ...
407 <div class="watermark-apps-portlet top-portlet">
408 <img alt="" width="64" height="64" src="/@@/person-logo" />
409 <h2>Waffles</h2>
410@@ -304,14 +291,8 @@
411
412 Main content.
413
414- >>> print html
415- <!DOCTYPE html ...
416- ...
417- <div id="maincontent" class="yui-main">
418- <BLANKLINE>
419- <BLANKLINE>
420- <BLANKLINE>
421- <BLANKLINE>
422+ >>> print str(find_tag_by_id(body_tag, 'maincontent'))
423+ <div id="maincontent" class="yui-main">
424 <div class="yui-b" dir="ltr">
425 <div>
426 <BLANKLINE>
427@@ -322,9 +303,8 @@
428
429 Top portlet.
430
431- >>> print html
432- <!DOCTYPE html ...
433- ...
434+ >>> print body
435+ <body ...
436 <div class="top-portlet">
437 <h1>Heading</h1>
438 <p class="registered">
439@@ -336,7 +316,6 @@
440 </p>
441 </div>
442 <BLANKLINE>
443- </div><!-- yui-b -->
444 </div><!-- yui-main -->
445 <BLANKLINE>
446 <!-- yui-b side -->
447@@ -384,10 +363,10 @@
448
449 Body.
450
451- >>> print html
452- <!DOCTYPE html ...
453- ...
454- <body id="document"
455+ >>> body_tag = find_tag_by_id(html, 'document')
456+ >>> body = str(body_tag)
457+ >>> print body
458+ <body id="document"
459 class="tab-overview
460 locationless
461 public
462@@ -400,17 +379,10 @@
463
464 Main content.
465
466- >>> print html
467- <!DOCTYPE html ...
468- ...
469- <div id="maincontent" class="yui-main">
470- <BLANKLINE>
471- <BLANKLINE>
472- <BLANKLINE>
473- <BLANKLINE>
474+ >>> print str(find_tag_by_id(body_tag, 'maincontent'))
475+ <div id="maincontent" class="yui-main">
476 <div class="yui-b" dir="ltr">
477- <BLANKLINE>
478- <BLANKLINE>
479+ </div><!-- yui-b -->
480 <div class="top-portlet">
481 <h1>Heading</h1>
482 <p class="registered">
483@@ -421,13 +393,7 @@
484 Main content of the page.
485 </p>
486 </div>
487- <BLANKLINE>
488- </div><!-- yui-b -->
489- </div><!-- yui-main -->
490- <BLANKLINE>
491- <!-- yui-b side -->
492- <!-- yui-t4 -->
493- ...
494+ </div>
495
496 Footer.
497
498@@ -466,8 +432,6 @@
499 The example layouts all used the heading slot to define a heading for their
500 test. The template controlled the heading.
501
502- >>> from canonical.launchpad.testing.pages import find_tag_by_id
503-
504 >>> content = find_tag_by_id(view.render(), 'maincontent')
505 >>> print content.h1
506 <h1>Heading</h1>
507@@ -497,12 +461,10 @@
508 http://canonical.com/
509 Terms of use
510 http://launchpad.dev/legal
511- Contact us
512+ Contact Launchpad Support
513 https://help.launchpad.net/Feedback
514 System status
515 http://identi.ca/launchpadstatus
516- Launchpad ...
517- https://help.launchpad.net/LaunchpadReleases
518
519
520 Page registering
521@@ -559,3 +521,21 @@
522 >>> body = find_tag_by_id(view.render(), 'document')
523 >>> print body['class']
524 tab-overview locationless public yui-skin-sam
525+
526+
527+Notifications
528+-------------
529+
530+Notifications are diplayed between the breadcrumbs and the page content.
531+
532+ >>> request.response.addInfoNotification('I cannot do that Dave.')
533+ >>> view = MainOnlyView(user, request)
534+ >>> body_tag = find_tag_by_id(view.render(), 'maincontent')
535+ >>> print str(body_tag)
536+ <div id="maincontent" ...
537+ <ol class="breadcrumbs">
538+ </ol>
539+ ...
540+ <div class="informational message">I cannot do that Dave.</div>
541+ <div class="top-portlet">
542+ ...
543
544=== modified file 'lib/lp/app/templates/base-layout-macros.pt'
545--- lib/lp/app/templates/base-layout-macros.pt 2010-05-18 18:04:00 +0000
546+++ lib/lp/app/templates/base-layout-macros.pt 2010-06-12 14:35:43 +0000
547@@ -398,14 +398,12 @@
548 <a tal:attributes="href string:${rooturl}legal">Terms of use</a>
549 &nbsp;&bull;&nbsp;
550 <a href="https://help.launchpad.net/Feedback"
551- >Contact us</a>
552+ >Contact Launchpad Support</a>
553 &nbsp;&bull;&nbsp;
554 <a href="http://identi.ca/launchpadstatus"
555 >System status</a>
556 <span id="lp-version" tal:condition="not:is_lpnet">
557 &nbsp;&bull;&nbsp;
558- <a href="https://help.launchpad.net/LaunchpadReleases"
559- tal:content="version"/>
560 <tal:devmode condition="devmode">devmode</tal:devmode>
561 <tal:demo condition="is_demo">demo site</tal:demo>
562 <tal:edge condition="is_edge">beta site</tal:edge>
563
564=== modified file 'lib/lp/app/templates/base-layout.pt'
565--- lib/lp/app/templates/base-layout.pt 2010-04-05 21:04:09 +0000
566+++ lib/lp/app/templates/base-layout.pt 2010-06-12 14:35:43 +0000
567@@ -102,16 +102,6 @@
568 <div class="yui-t4"
569 tal:omit-tag="not: view/macro:pagehas/portlets">
570 <div id="maincontent" class="yui-main">
571-
572- <tal:maintenance
573- replace="structure context/@@+maintenancemessage" />
574- <tal:notifications
575- define="notifications request/notifications"
576- condition="notifications">
577- <metal:notifications
578- use-macro="context/@@+base-layout-macros/notifications"/>
579- </tal:notifications>
580-
581 <div class="yui-b"
582 tal:attributes="
583 lang view/lang|default_language|default;
584@@ -128,8 +118,16 @@
585 ProjectName > Branches > Merge Proposals > fix-for-navigation
586 </tal:breadcrumbs>
587 </div>
588+ </div><!-- yui-b -->
589+ <tal:maintenance
590+ replace="structure context/@@+maintenancemessage" />
591+ <tal:notifications
592+ define="notifications request/notifications"
593+ condition="notifications">
594+ <metal:notifications
595+ use-macro="context/@@+base-layout-macros/notifications"/>
596+ </tal:notifications>
597 <metal:main define-slot="main" />
598- </div><!-- yui-b -->
599 </div><!-- yui-main -->
600
601 <div class="yui-b side"
602
603=== modified file 'lib/lp/app/templates/root-index.pt'
604--- lib/lp/app/templates/root-index.pt 2010-04-29 13:22:29 +0000
605+++ lib/lp/app/templates/root-index.pt 2010-06-12 14:35:43 +0000
606@@ -89,27 +89,42 @@
607 tal:condition="not:view/user" tal:content="cache:anonymous">
608 <h2><span class="launchpad-gold">Launchpad</span> is a software collaboration platform that provides:</h2>
609 <ul tal:define="apphomes view/apphomes">
610- <li><a tal:attributes="href apphomes/bugs"><img src="/@@/bug" alt="" /></a>
611- <a tal:attributes="href apphomes/bugs">Bug tracking</a></li>
612- <li><a tal:attributes="href apphomes/code"><img src="/@@/branch" alt="" /></a>
613- <a tal:attributes="href apphomes/code">Code hosting</a>
614- using <a href="http://bazaar-vcs.org/">Bazaar</a></li>
615- <li><a href="https://help.launchpad.net/Code/Review"><img src="/@@/yes" alt="" /></a>
616- <a href="https://help.launchpad.net/Code/Review">Code reviews</a></li>
617- <li><a tal:attributes="href apphomes/ubuntu"><img src="/@@/ubuntu-icon" alt="" /></a>
618- <a tal:attributes="href apphomes/ubuntu">Ubuntu package building and hosting</a></li>
619- <li><a tal:attributes="href apphomes/translations"><img src="/@@/translation" alt="" /></a>
620- <a tal:attributes="href apphomes/translations">Translations</a></li>
621- <li><a href="https://help.launchpad.net/Teams/MailingLists"><img src="/@@/mail" alt="" /></a>
622- <a href="https://help.launchpad.net/Teams/MailingLists">Mailing lists</a></li>
623- <li><a tal:attributes="href apphomes/answers"><img src="/@@/question" alt="" /></a>
624- <a tal:attributes="href apphomes/answers">Answer tracking and FAQs</a></li>
625- <li><a tal:attributes="href apphomes/blueprints"><img src="/@@/blueprint" alt="" /></a>
626- <a tal:attributes="href apphomes/blueprints">Specification tracking</a></li>
627+ <li>
628+ <a class="sprite bug"
629+ tal:attributes="href apphomes/bugs">Bug tracking</a>
630+ </li>
631+ <li>
632+ <a class="sprite branch"
633+ tal:attributes="href apphomes/code">Code hosting</a>
634+ using <a href="http://bazaar.canonical.com/">Bazaar</a>
635+ </li>
636+ <li>
637+ <a class="sprite yes"
638+ href="https://help.launchpad.net/Code/Review">Code reviews</a>
639+ </li>
640+ <li>
641+ <a class="sprite ubuntu-logo"
642+ tal:attributes="href apphomes/ubuntu">Ubuntu package building and hosting</a>
643+ </li>
644+ <li>
645+ <a class="sprite translate-icon"
646+ tal:attributes="href apphomes/translations">Translations</a>
647+ </li>
648+ <li>
649+ <a class="sprite mail"
650+ href="https://help.launchpad.net/Teams/MailingLists">Mailing lists</a>
651+ </li>
652+ <li>
653+ <a class="sprite question"
654+ tal:attributes="href apphomes/answers">Answer tracking and FAQs</a>
655+ </li>
656+ <li>
657+ <a class="sprite blueprint"
658+ tal:attributes="href apphomes/blueprints">Specification tracking</a>
659+ </li>
660 </ul>
661 <div id="homepage-whatslaunchpad-tour">
662- <a href="/+tour"><img src="/@@/tour-icon" alt=""
663- /></a> <a href="/+tour">Take the tour!</a>
664+ <a class="sprite tour" href="/+tour">Take the tour!</a>
665 </div>
666 </div>
667
668@@ -189,27 +204,36 @@
669 in our sandbox environment.
670 (<a href="/+help/home-page-staging-help.html" target="help">What's this?</a>)<br />
671 <tal:logged_in condition="view/user" omit-tag=""
672- tal:content="cache:public">
673+ tal:content="cache:public">
674 If you're ready, you can:
675 <ul tal:define="apphomes view/apphomes">
676- <li><a href="https://help.launchpad.net/">
677- <img src="/@@/info" alt="" /></a>
678- <a href="https://help.launchpad.net/"> Read the user guide</a></li>
679- <li><a href="/projects/+new"><img src="/@@/add" /></a>
680- <a href="/projects/+new">Create a new project</a></li>
681- <li><a href="/people/+newteam"><img src="/@@/add" /></a>
682- <a href="/people/+newteam">Create a new team</a></li>
683- <li><a tal:attributes="href apphomes/bugs">
684- <img src="/@@/bug" /></a>
685- <a tal:attributes="href apphomes/bugs">Browse bugs</a></li>
686- <li><a tal:attributes="href apphomes/translations">
687- <img src="/@@/translation" /></a>
688- <a tal:attributes="href apphomes/translations">Help translate</a></li>
689- <li><a tal:attributes="href apphomes/answers">
690- <img src="/@@/question" alt="" /></a>
691- <a tal:attributes="href apphomes/answers">Find answers</a></li>
692- <li><a href="/+tour"><img src="/@@/tour-icon" /></a>
693- <a href="/+tour">Take the tour</a></li>
694+ <li>
695+ <a class="sprite info"
696+ href="https://help.launchpad.net/">Read the user guide</a>
697+ </li>
698+ <li>
699+ <a class="sprite add"
700+ href="/projects/+new">Register a project</a>
701+ </li>
702+ <li>
703+ <a class="sprite add"
704+ href="/people/+newteam">Register a team</a>
705+ </li>
706+ <li>
707+ <a class="sprite bug"
708+ tal:attributes="href apphomes/bugs">Browse bugs</a>
709+ </li>
710+ <li>
711+ <a class="sprite translate-icon"
712+ tal:attributes="href apphomes/translations">Help translate</a>
713+ </li>
714+ <li>
715+ <a class="sprite question"
716+ tal:attributes="href apphomes/answers">Find answers</a>
717+ </li>
718+ <li>
719+ <a class="sprite tour" href="/+tour">Take the tour</a>
720+ </li>
721 </ul>
722 </tal:logged_in>
723 </div>
724@@ -224,10 +248,10 @@
725 tal:define="topproject view/featured_projects_top"
726 tal:condition="topproject">
727 <h3>
728- <a tal:attributes="href topproject/fmt:url"><img
729- tal:replace="structure topproject/image:logo" /></a>
730- <a tal:attributes="href topproject/fmt:url"><tal:name
731- replace="topproject/displayname">Foo project</tal:name></a>
732+ <a tal:attributes="href topproject/fmt:url"
733+ tal:content="structure topproject/image:logo"><img /></a>
734+ <a tal:attributes="href topproject/fmt:url"
735+ tal:content="topproject/displayname">Foo project</a>
736 </h3>
737 <p tal:content="structure view/featured_projects_top/summary/fmt:shorten/200">
738 Foo project is great...
739
740=== modified file 'lib/lp/blueprints/stories/blueprints/05-reviews.txt'
741--- lib/lp/blueprints/stories/blueprints/05-reviews.txt 2009-09-23 10:17:34 +0000
742+++ lib/lp/blueprints/stories/blueprints/05-reviews.txt 2010-06-12 14:35:43 +0000
743@@ -134,9 +134,9 @@
744 >>> print mark_browser.url
745 http://blueprints.launchpad.dev/firefox/+spec/canvas/+givefeedback
746
747- >>> print extract_text(find_main_content(mark_browser.contents))
748- Cleared requests from: Carlos Perelló Marín
749- ...
750+ >>> for message in get_feedback_messages(mark_browser.contents):
751+ ... print extract_text(message)
752+ Cleared requests from: Carlos ...
753
754 And now, the remaining two. This time we expect to be redirected.
755
756
757=== modified file 'lib/lp/bugs/stories/bugtask-searches/xx-advanced-people-filters.txt'
758--- lib/lp/bugs/stories/bugtask-searches/xx-advanced-people-filters.txt 2009-09-09 23:16:08 +0000
759+++ lib/lp/bugs/stories/bugtask-searches/xx-advanced-people-filters.txt 2010-06-12 14:35:43 +0000
760@@ -190,7 +190,8 @@
761
762 >>> browser.getControl('Further information').value = 'Test Bug 1'
763 >>> browser.getControl('Submit').click()
764- >>> print extract_text(find_main_content(browser.contents))
765+ >>> for message in get_feedback_messages(browser.contents):
766+ ... print extract_text(message)
767 Thank you for your bug report...
768 >>> bug_1_url = browser.url
769
770@@ -199,7 +200,8 @@
771 >>> browser.getControl('Continue').click()
772 >>> browser.getControl('Further information').value = 'Test Bug 2'
773 >>> browser.getControl('Submit').click()
774- >>> print extract_text(find_main_content(browser.contents))
775+ >>> for message in get_feedback_messages(browser.contents):
776+ ... print extract_text(message)
777 Thank you for your bug report...
778 >>> bug_2_url = browser.url
779
780@@ -212,7 +214,8 @@
781
782 >>> browser.getControl('Person').value = subscriber
783 >>> browser.getControl('Subscribe user').click()
784- >>> print extract_text(find_main_content(browser.contents))
785+ >>> for message in get_feedback_messages(browser.contents):
786+ ... print extract_text(message)
787 No Privileges Person has been subscribed to this bug...
788
789 Now if we repeat our earlier search for bugs our user is subscribed to, we'll
790@@ -235,7 +238,8 @@
791
792 >>> browser.getControl('Person').value = subscriber
793 >>> browser.getControl('Subscribe user').click()
794- >>> print extract_text(find_main_content(browser.contents))
795+ >>> for message in get_feedback_messages(browser.contents):
796+ ... print extract_text(message)
797 No Privileges Person has been subscribed to this bug...
798
799 Finally, if we repeat our earlier search for bugs our user is subscribed to,
800
801=== modified file 'lib/lp/bugs/stories/bugtask-searches/xx-advanced-upstream-pending-bugwatch.txt'
802--- lib/lp/bugs/stories/bugtask-searches/xx-advanced-upstream-pending-bugwatch.txt 2010-01-18 20:41:52 +0000
803+++ lib/lp/bugs/stories/bugtask-searches/xx-advanced-upstream-pending-bugwatch.txt 2010-06-12 14:35:43 +0000
804@@ -22,7 +22,8 @@
805 >>> browser.getControl('Continue').click()
806 >>> browser.getControl('Further information').value = 'Test Bug 1'
807 >>> browser.getControl('Submit').click()
808- >>> print extract_text(find_main_content(browser.contents))
809+ >>> for message in get_feedback_messages(browser.contents):
810+ ... print extract_text(message)
811 Thank you for your bug report...
812
813 >>> browser.getLink('Also affects project').click()
814
815=== modified file 'lib/lp/code/templates/bazaar-index.pt'
816--- lib/lp/code/templates/bazaar-index.pt 2010-03-18 21:42:06 +0000
817+++ lib/lp/code/templates/bazaar-index.pt 2010-06-12 14:35:43 +0000
818@@ -40,7 +40,7 @@
819 </form>
820 <p id="application-summary">
821 Launchpad can host your project&#8217;s source code
822- using the <a href="http://bazaar-vcs.org/">Bazaar</a>
823+ using the <a href="http://bazaar.canonical.com/">Bazaar</a>
824 version control system.
825 We also import
826 <tal:XXX condition="nothing">
827@@ -131,7 +131,7 @@
828 branches associated with bug reports
829 </div>
830 <div>
831- Launchpad uses <a href="http://bazaar-vcs.org/">Bazaar</a>
832+ Launchpad uses <a href="http://bazaar.canonical.com/">Bazaar</a>
833 <tal:version tal:content="view/bzr_version">2.0</tal:version>.
834 </div>
835 </div>
836
837=== modified file 'lib/lp/registry/stories/milestone/object-milestones.txt'
838--- lib/lp/registry/stories/milestone/object-milestones.txt 2010-05-19 17:30:38 +0000
839+++ lib/lp/registry/stories/milestone/object-milestones.txt 2010-06-12 14:35:43 +0000
840@@ -199,7 +199,8 @@
841
842 >>> browser.getControl('Further information').value = 'Test Bug 1'
843 >>> browser.getControl('Submit').click()
844- >>> print extract_text(find_main_content(browser.contents))
845+ >>> for message in get_feedback_messages(browser.contents):
846+ ... print extract_text(message)
847 Thank you for your bug report...
848 >>> bug_1_url = browser.url
849
850@@ -209,7 +210,8 @@
851
852 >>> browser.getControl('Further information').value = 'Test Bug 2'
853 >>> browser.getControl('Submit').click()
854- >>> print extract_text(find_main_content(browser.contents))
855+ >>> for message in get_feedback_messages(browser.contents):
856+ ... print extract_text(message)
857 Thank you for your bug report...
858 >>> bug_2_url = browser.url
859
860
861=== modified file 'lib/lp/registry/stories/product/xx-product-add.txt'
862--- lib/lp/registry/stories/product/xx-product-add.txt 2010-05-12 19:06:17 +0000
863+++ lib/lp/registry/stories/product/xx-product-add.txt 2010-06-12 14:35:43 +0000
864@@ -5,7 +5,7 @@
865 from the Launchpad home page or the projects home page.
866
867 >>> user_browser.open('http://launchpad.dev')
868- >>> user_browser.getLink('Create a new project').click()
869+ >>> user_browser.getLink('Register a project').click()
870 >>> print user_browser.title
871 Register a project in Launchpad...
872
873@@ -144,7 +144,7 @@
874 Firefox.
875
876 >>> user_browser.open('http://launchpad.dev')
877- >>> user_browser.getLink('Create a new project').click()
878+ >>> user_browser.getLink('Register a project').click()
879 >>> print user_browser.title
880 Register a project in Launchpad...
881
882
883=== modified file 'lib/lp/soyuz/stories/ppa/xx-copy-packages.txt'
884--- lib/lp/soyuz/stories/ppa/xx-copy-packages.txt 2010-05-17 13:14:46 +0000
885+++ lib/lp/soyuz/stories/ppa/xx-copy-packages.txt 2010-06-12 14:35:43 +0000
886@@ -549,7 +549,7 @@
887 James uses the 'delete-packages' interface in his PPA to delete the
888 'pmount' source in hoary.
889
890- >>> jblack_browser.getLink('PPA').click()
891+ >>> jblack_browser.getLink('Cancel').click()
892 >>> jblack_browser.getLink('Delete packages').click()
893 >>> jblack_browser.getControl(
894 ... name='field.selected_sources').value = [pmount_pub_id]
895
896=== modified file 'lib/lp/translations/stories/standalone/xx-pofile-translate.txt'
897--- lib/lp/translations/stories/standalone/xx-pofile-translate.txt 2010-04-29 12:38:47 +0000
898+++ lib/lp/translations/stories/standalone/xx-pofile-translate.txt 2010-06-12 14:35:43 +0000
899@@ -235,13 +235,13 @@
900
901 >>> browser.open('http://translations.launchpad.dev/ubuntu/hoary/'
902 ... '+source/evolution/+pots/evolution-2.2/ab/+translate')
903- >>> print extract_text(find_tag_by_id(
904- ... browser.contents, 'maincontent'))
905+ >>> for message in get_feedback_messages(browser.contents):
906+ ... print extract_text(message)
907 Launchpad can&#8217;t handle the plural items ...
908
909 >>> browser.open('http://translations.launchpad.dev/ubuntu/hoary/'
910 ... '+source/evolution/+pots/evolution-2.2/ab/5/+translate')
911- >>> print extract_text(find_tag_by_id(
912- ... browser.contents, 'maincontent'))
913+ >>> for message in get_feedback_messages(browser.contents):
914+ ... print extract_text(message)
915 Launchpad can&#8217;t handle the plural items ...
916