Merge lp://staging/~julian-edwards/launchpad/mechanical-changes-6 into lp://staging/launchpad

Proposed by Julian Edwards
Status: Merged
Merged at revision: not available
Proposed branch: lp://staging/~julian-edwards/launchpad/mechanical-changes-6
Merge into: lp://staging/launchpad
Diff against target: None lines
To merge this branch: bzr merge lp://staging/~julian-edwards/launchpad/mechanical-changes-6
Reviewer Review Type Date Requested Status
Michael Nelson (community) code/ui Approve
Review via email: mp+11064@code.staging.launchpad.net
To post a comment you must log in.
Revision history for this message
Julian Edwards (julian-edwards) wrote :

= Summary =
Mechanical 3.0 changes for DistroArchSeriesBinaryPackage[Release] pages

== Implementation details ==
I slipped in a quick bug fix while I was at it:
https://bugs.edge.launchpad.net/bugs/241341
to fix a page heading. This was just a case of changing the title property on
the context class.

The change to the DistroArchSeriesBinaryPackage is trivial and can be seen
here:
https://launchpad.dev/ubuntu/warty/i386/mozilla-firefox

The change to the DistroArchSeriesBinaryPackageRelease page was more involved.
It uses several page fragments in the package relationships section that are
in a different context/view. They are not used anywhere else so I added some
conditional "yui-u" div classes to those so that they don't appear when not
necessary.

The breadcrumbs on both pages are not working properly, I will fix those in a
separate branch.

== Tests ==
bin/test -vvt stories.soyuz -t distroarchseriesbinarypackage

== Demo and Q/A ==
See the URLs above.

= Launchpad lint =

Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.

Linting changed files:
  lib/lp/soyuz/doc/distroarchseriesbinarypackage.txt
  lib/lp/soyuz/templates/binarypackagerelease-portlet-predepends.pt
  lib/lp/soyuz/templates/binarypackagerelease-portlet-depends.pt
  lib/lp/soyuz/templates/binarypackagerelease-portlet-suggests.pt
  lib/lp/soyuz/templates/distroarchseriesbinarypackagerelease-portlet-
details.pt
  lib/lp/soyuz/templates/binarypackagerelease-portlet-conflicts.pt
  lib/lp/soyuz/templates/distroarchseriesbinarypackage-index.pt
  lib/lp/soyuz/templates/binarypackagerelease-portlet-enhances.pt
  lib/lp/soyuz/templates/binarypackagerelease-portlet-replaces.pt
  lib/lp/soyuz/templates/distroarchseriesbinarypackagerelease-index.pt
  lib/lp/soyuz/templates/binarypackagerelease-portlet-recommends.pt
  lib/lp/soyuz/model/distroarchseriesbinarypackage.py
  lib/lp/soyuz/templates/binarypackagerelease-portlet-provides.pt
  lib/lp/soyuz/templates/binarypackagerelease-portlet-breaks.pt

Revision history for this message
Michael Nelson (michael.nelson) wrote :
Download full text (7.5 KiB)

> = Summary =
> Mechanical 3.0 changes for DistroArchSeriesBinaryPackage[Release] pages

These pages look *so* much better! It's great seeing LP transformed :)

>
> == Implementation details ==
> I slipped in a quick bug fix while I was at it:
> https://bugs.edge.launchpad.net/bugs/241341
> to fix a page heading. This was just a case of changing the title property on
> the context class.

Great! As mentioned in irc, you've added an extra 'for' into the title unintentionally, and it would be good to use smartquotes here.

>
> The change to the DistroArchSeriesBinaryPackage is trivial and can be seen
> here:
> https://launchpad.dev/ubuntu/warty/i386/mozilla-firefox
>
> The change to the DistroArchSeriesBinaryPackageRelease page was more involved.
> It uses several page fragments in the package relationships section that are
> in a different context/view. They are not used anywhere else so I added some
> conditional "yui-u" div classes to those so that they don't appear when not
> necessary.
>
> The breadcrumbs on both pages are not working properly, I will fix those in a
> separate branch.
>
> == Tests ==
> bin/test -vvt stories.soyuz -t distroarchseriesbinarypackage

Looks like the tests for the title need updating (or you may have done it since I merged).

The only other thing is that we need to ensure we markup the package relationships correctly... currently there are dt's that are not enclosed by dl's (like having an <li> without it being inside a <ul> or an <ol>. That in itself is as easy as doing the following for each relationship portlet:

http://pastebin.ubuntu.com/264324/

It does leave one remaining problem - the <dt> is then followed by a <ul> rather than a bunch of <dd>'s, but we can't fix that yet as another template (sourcepackage-index.pt) uses the same +render-list traversal (which in-turn uses the packagerelationship-list.pt). So I think we should wait until sourcepackage-index.pt is updated to 3-0 before updating packagerelationship-list.pt to output dd's). I'll leave it up to you whether it's worth an XXX.

Looking forward to seeing it land!

IRC log:
<bigjools> great
<noodles775> bigjools: you mention in your MP that the breadcrumbs aren't working properly - in what way?
<bigjools> noodles775: they are now, I landed a change last night :)
<noodles775> bigjools: heh, I couldn't find a problem :)
<bigjools> they stopped at 9.04
<noodles775> bigjools: any reason you didn't use smartquote in the title?
<bigjools> or whatever version
<bigjools> meh, details :)
<noodles775> (like in model/distributionsourcepackage's title?)
<noodles775> bigjools: also, see https://launchpad.dev/ubuntu/warty/i386/mozilla-firefox
<noodles775> What do you think we should do in that case? (The empty Package relationships section)
<bigjools> noodles775: it will never be empty in real life
<noodles775> Great.
<bigjools> our sample data is bong
* jtv (n=jtv@125.25.88.144.adsl.dynamic.totbb.net) has joined #launchpad-reviews
<noodles775> bigjools: also with the dasbp title, was it an explicit decision to do '"mozilla-firefox" binary package in Ubuntu Karmic for i386' rather than without the 'for' as suggested by mpt: '"mozilla-firefox" binary pa...

Read more...

review: Approve (code/ui)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lib/lp/soyuz/doc/distroarchseriesbinarypackage.txt'
2--- lib/lp/soyuz/doc/distroarchseriesbinarypackage.txt 2009-04-30 12:16:12 +0000
3+++ lib/lp/soyuz/doc/distroarchseriesbinarypackage.txt 2009-09-02 11:28:03 +0000
4@@ -1,5 +1,6 @@
5-Distro Arch Release Binary Package
6-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
7+=================================
8+Distro Arch Series Binary Package
9+=================================
10
11 >>> from lp.soyuz.model.binarypackagename import (
12 ... BinaryPackageName)
13@@ -15,6 +16,11 @@
14 >>> firefox_hoary_i386 = DistroArchSeriesBinaryPackage(hoary_i386,
15 ... firefox_name)
16
17+`DistroArchSeriesBinaryPackage`s have a title property:
18+
19+ >>> print pmount_hoary_i386.title
20+ "pmount" binary package in The Hoary Hedgehog Release for i386 (x86)
21+
22
23 First, we create a new version of pmount, and a version of
24 mozilla-firefox that coincides with pmount's. We're hitch-hiking on two
25@@ -36,7 +42,7 @@
26 ... PackagePublishingPocket, IDistributionSet)
27 >>> priority = PackagePublishingPriority.STANDARD
28
29-XXX: noodles 2008-11-05 bug=294585: The dependency on a database id
30+XXX: noodles 2008-11-05 bug=294585: The dependency on a database id
31 needs to be removed.
32 >>> bpr = Build.get(8).createBinaryPackageRelease(
33 ... binarypackagename=firefox_name.id,
34@@ -77,7 +83,7 @@
35 ... dateremoved=None,
36 ... archive=hoary_i386.main_archive)
37
38-XXX: noodles 2008-11-06 bug=294585: The dependency on a database id
39+XXX: noodles 2008-11-06 bug=294585: The dependency on a database id
40 needs to be removed.
41 >>> bpr = Build.get(9).createBinaryPackageRelease(
42 ... binarypackagename=pmount_name.id,
43
44=== modified file 'lib/lp/soyuz/model/distroarchseriesbinarypackage.py'
45--- lib/lp/soyuz/model/distroarchseriesbinarypackage.py 2009-07-19 04:41:14 +0000
46+++ lib/lp/soyuz/model/distroarchseriesbinarypackage.py 2009-09-02 11:28:03 +0000
47@@ -71,7 +71,7 @@
48 @property
49 def title(self):
50 """See IDistroArchSeriesBinaryPackage."""
51- return 'Binary Package "%s" in %s' % (
52+ return '"%s" binary package in %s' % (
53 self.binarypackagename.name, self.distroarchseries.title)
54
55 @cachedproperty
56@@ -238,7 +238,7 @@
57 current_release = self.currentrelease
58 if current_release is None:
59 return None
60-
61+
62 src_pkg_release = current_release.distributionsourcepackagerelease
63 if src_pkg_release is None:
64 return None
65
66=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-breaks.pt'
67--- lib/lp/soyuz/templates/binarypackagerelease-portlet-breaks.pt 2009-07-17 17:59:07 +0000
68+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-breaks.pt 2009-09-02 14:54:06 +0000
69@@ -2,17 +2,13 @@
70 xmlns:tal="http://xml.zope.org/namespaces/tal"
71 xmlns:metal="http://xml.zope.org/namespaces/metal"
72 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
73- class="portlet" id="portlet-breaks">
74-
75- <h2>Breaks</h2>
76-
77- <div class="portletBody portletContent"
78- id="breaks"
79- tal:define="relationships view/breaks">
80-
81- <tal:block condition="relationships/has_items"
82- replace="structure relationships/@@+render-list" />
83-
84+ tal:define="relationships view/breaks"
85+ tal:condition="relationships/has_items"
86+ class="first yui-u" id="portlet-breaks">
87+
88+ <div id="breaks">
89+ <dt>Breaks:</dt>
90+ <tal:block replace="structure relationships/@@+render-list" />
91 </div>
92
93 </div>
94
95=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-conflicts.pt'
96--- lib/lp/soyuz/templates/binarypackagerelease-portlet-conflicts.pt 2009-07-17 17:59:07 +0000
97+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-conflicts.pt 2009-09-02 14:54:06 +0000
98@@ -2,17 +2,13 @@
99 xmlns:tal="http://xml.zope.org/namespaces/tal"
100 xmlns:metal="http://xml.zope.org/namespaces/metal"
101 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
102- class="portlet" id="portlet-conflicts">
103-
104- <h2>Conflicts</h2>
105-
106- <div class="portletBody portletContent"
107- id="conflicts"
108- tal:define="relationships view/conflicts">
109-
110- <tal:block condition="relationships/has_items"
111- replace="structure relationships/@@+render-list"/>
112-
113+ tal:define="relationships view/conflicts"
114+ tal:condition="relationships/has_items"
115+ class="first yui-u" id="portlet-conflicts">
116+
117+ <div id="conflicts">
118+ <dt>Conflicts:</dt>
119+ <tal:block replace="structure relationships/@@+render-list"/>
120 </div>
121
122 </div>
123
124=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-depends.pt'
125--- lib/lp/soyuz/templates/binarypackagerelease-portlet-depends.pt 2009-07-17 17:59:07 +0000
126+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-depends.pt 2009-09-02 14:54:06 +0000
127@@ -2,17 +2,13 @@
128 xmlns:tal="http://xml.zope.org/namespaces/tal"
129 xmlns:metal="http://xml.zope.org/namespaces/metal"
130 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
131- class="portlet" id="portlet-depends">
132-
133- <h2>Depends on</h2>
134-
135- <div class="portletBody portletContent"
136- id="depends"
137- tal:define="relationships view/depends">
138-
139- <tal:block condition="relationships/has_items"
140- replace="structure relationships/@@+render-list"/>
141-
142+ tal:define="relationships view/depends"
143+ tal:condition="relationships/has_items"
144+ class="first yui-u" id="portlet-depends">
145+
146+ <div id="depends">
147+ <dt>Depends on:</dt>
148+ <tal:block replace="structure relationships/@@+render-list"/>
149 </div>
150
151 </div>
152
153=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-enhances.pt'
154--- lib/lp/soyuz/templates/binarypackagerelease-portlet-enhances.pt 2009-07-17 17:59:07 +0000
155+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-enhances.pt 2009-09-02 14:54:06 +0000
156@@ -2,17 +2,13 @@
157 xmlns:tal="http://xml.zope.org/namespaces/tal"
158 xmlns:metal="http://xml.zope.org/namespaces/metal"
159 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
160- class="portlet" id="portlet-enhances">
161-
162- <h2>Enhances</h2>
163-
164- <div class="portletBody portletContent"
165- id="enhances"
166- tal:define="relationships view/enhances">
167-
168- <tal:block condition="relationships/has_items"
169- replace="structure relationships/@@+render-list"/>
170-
171+ tal:define="relationships view/enhances"
172+ tal:condition="relationships/has_items"
173+ class="first yui-u" id="portlet-enhances">
174+
175+ <div id="enhances">
176+ <dt>Enhances:</dt>
177+ <tal:block replace="structure relationships/@@+render-list"/>
178 </div>
179
180 </div>
181
182=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-predepends.pt'
183--- lib/lp/soyuz/templates/binarypackagerelease-portlet-predepends.pt 2009-07-17 17:59:07 +0000
184+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-predepends.pt 2009-09-02 14:54:06 +0000
185@@ -2,17 +2,13 @@
186 xmlns:tal="http://xml.zope.org/namespaces/tal"
187 xmlns:metal="http://xml.zope.org/namespaces/metal"
188 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
189- class="portlet" id="portlet-predepends">
190-
191- <h2>Pre-Depends on</h2>
192-
193- <div class="portletBody portletContent"
194- id="predepends"
195- tal:define="relationships view/pre_depends">
196-
197- <tal:block condition="relationships/has_items"
198- replace="structure relationships/@@+render-list"/>
199-
200+ tal:define="relationships view/pre_depends"
201+ tal:condition="relationships/has_items"
202+ class="first yui-u" id="portlet-predepends">
203+
204+ <div id="predepends">
205+ <dt>Pre-Depends on:</dt>
206+ <tal:block replace="structure relationships/@@+render-list"/>
207 </div>
208
209 </div>
210
211=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-provides.pt'
212--- lib/lp/soyuz/templates/binarypackagerelease-portlet-provides.pt 2009-07-17 17:59:07 +0000
213+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-provides.pt 2009-09-02 14:54:06 +0000
214@@ -2,17 +2,13 @@
215 xmlns:tal="http://xml.zope.org/namespaces/tal"
216 xmlns:metal="http://xml.zope.org/namespaces/metal"
217 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
218- class="portlet" id="portlet-provides">
219-
220- <h2>Provides</h2>
221-
222- <div class="portletBody portletContent"
223- id="provides"
224- tal:define="relationships view/provides">
225-
226- <tal:block condition="relationships/has_items"
227- replace="structure relationships/@@+render-list"/>
228-
229+ tal:define="relationships view/provides"
230+ tal:condition="relationships/has_items"
231+ class="first yui-u" id="portlet-provides">
232+
233+ <div id="provides">
234+ <dt>Provides:</dt>
235+ <tal:block replace="structure relationships/@@+render-list"/>
236 </div>
237
238 </div>
239
240=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-recommends.pt'
241--- lib/lp/soyuz/templates/binarypackagerelease-portlet-recommends.pt 2009-07-17 17:59:07 +0000
242+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-recommends.pt 2009-09-02 14:54:06 +0000
243@@ -2,17 +2,13 @@
244 xmlns:tal="http://xml.zope.org/namespaces/tal"
245 xmlns:metal="http://xml.zope.org/namespaces/metal"
246 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
247- class="portlet" id="portlet-recommends">
248-
249- <h2>Recommends</h2>
250-
251- <div class="portletBody portletContent"
252- id="recommends"
253- tal:define="relationships view/recommends">
254-
255- <tal:block condition="relationships/has_items"
256- replace="structure relationships/@@+render-list"/>
257-
258+ tal:define="relationships view/recommends"
259+ tal:condition="relationships/has_items"
260+ class="first yui-u" id="portlet-recommends">
261+
262+ <div id="recommends">
263+ <dt>Recommends:</dt>
264+ <tal:block replace="structure relationships/@@+render-list"/>
265 </div>
266
267 </div>
268
269=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-replaces.pt'
270--- lib/lp/soyuz/templates/binarypackagerelease-portlet-replaces.pt 2009-07-17 17:59:07 +0000
271+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-replaces.pt 2009-09-02 14:54:06 +0000
272@@ -2,17 +2,13 @@
273 xmlns:tal="http://xml.zope.org/namespaces/tal"
274 xmlns:metal="http://xml.zope.org/namespaces/metal"
275 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
276- class="portlet" id="portlet-replaces">
277-
278- <h2>Replaces</h2>
279-
280- <div class="portletBody portletContent"
281- id="replaces"
282- tal:define="relationships view/replaces">
283-
284- <tal:block condition="relationships/has_items"
285- replace="structure relationships/@@+render-list"/>
286-
287+ tal:define="relationships view/replaces"
288+ tal:condition="relationships/has_items"
289+ class="first yui-u" id="portlet-replaces">
290+
291+ <div id="replaces">
292+ <dt>Replaces:</dt>
293+ <tal:block replace="structure relationships/@@+render-list"/>
294 </div>
295
296
297
298=== modified file 'lib/lp/soyuz/templates/binarypackagerelease-portlet-suggests.pt'
299--- lib/lp/soyuz/templates/binarypackagerelease-portlet-suggests.pt 2009-07-17 17:59:07 +0000
300+++ lib/lp/soyuz/templates/binarypackagerelease-portlet-suggests.pt 2009-09-02 14:54:06 +0000
301@@ -2,17 +2,13 @@
302 xmlns:tal="http://xml.zope.org/namespaces/tal"
303 xmlns:metal="http://xml.zope.org/namespaces/metal"
304 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
305- class="portlet" id="portlet-suggests">
306-
307- <h2>Suggests</h2>
308-
309- <div class="portletBody portletContent"
310- id="suggests"
311- tal:define="relationships view/suggests">
312-
313- <tal:block condition="relationships/has_items"
314- replace="structure relationships/@@+render-list"/>
315-
316+ tal:define="relationships view/suggests"
317+ tal:condition="relationships/has_items"
318+ class="first yui-u" id="portlet-suggests">
319+
320+ <div id="suggests">
321+ <dt>Suggests:</dt>
322+ <tal:block replace="structure relationships/@@+render-list"/>
323 </div>
324
325 </div>
326
327=== modified file 'lib/lp/soyuz/templates/distroarchseriesbinarypackage-index.pt'
328--- lib/lp/soyuz/templates/distroarchseriesbinarypackage-index.pt 2009-07-17 17:59:07 +0000
329+++ lib/lp/soyuz/templates/distroarchseriesbinarypackage-index.pt 2009-09-01 19:49:09 +0000
330@@ -3,37 +3,20 @@
331 xmlns:tal="http://xml.zope.org/namespaces/tal"
332 xmlns:metal="http://xml.zope.org/namespaces/metal"
333 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
334- xml:lang="en"
335- lang="en"
336- dir="ltr"
337- metal:use-macro="context/@@main_template/master"
338+ metal:use-macro="view/macro:page/main_only"
339 i18n:domain="launchpad"
340 >
341 <body>
342
343- <metal:leftportlets fill-slot="portlets_one">
344- <div tal:replace="structure context/@@+portlet-details" />
345- <div tal:replace="structure context/distroarchseries/@@+portlet-details" />
346- </metal:leftportlets>
347-
348- <metal:rightportlets fill-slot="portlets_two">
349- <div tal:replace="structure context/@@+portlet-releases" />
350- </metal:rightportlets>
351-
352 <div metal:fill-slot="main">
353
354- <div>
355- <a
356- tal:attributes="href context/distroarchseries/fmt:url"
357- tal:content="context/distroarchseries/displayname"
358- />
359- </div>
360- <h1 tal:content="context/title">pmount in Ubuntu Hoary i386</h1>
361-
362+ <div class="top-portlet">
363 <tal:description replace="structure context/description/fmt:text-to-html">
364 Package description
365 </tal:description>
366+ </div>
367
368+ <div class="portlet">
369 <h2>Publishing history</h2>
370
371 <table id="publishing-summary" class="listing">
372@@ -55,7 +38,9 @@
373 </tal:block>
374 </tbody>
375 </table>
376+ </div>
377
378+ <div class="top-portlet">
379 <tal:sourcepkg tal:define="spackage context/distro_source_package"
380 tal:condition="spackage">
381 <h2>Source package</h2>
382@@ -63,7 +48,7 @@
383 <div id="source">
384 <ul>
385 <li class="source package">
386- <a
387+ <a
388 tal:content="spackage/title"
389 tal:attributes="href spackage/fmt:url"
390 id="source_package">SOURCEPACKAGE</a>
391@@ -71,6 +56,7 @@
392 </ul>
393 </div>
394 </tal:sourcepkg>
395+ </div>
396 </div>
397 </body>
398 </html>
399
400=== modified file 'lib/lp/soyuz/templates/distroarchseriesbinarypackagerelease-index.pt'
401--- lib/lp/soyuz/templates/distroarchseriesbinarypackagerelease-index.pt 2009-07-17 17:59:07 +0000
402+++ lib/lp/soyuz/templates/distroarchseriesbinarypackagerelease-index.pt 2009-09-02 14:54:06 +0000
403@@ -3,103 +3,84 @@
404 xmlns:tal="http://xml.zope.org/namespaces/tal"
405 xmlns:metal="http://xml.zope.org/namespaces/metal"
406 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
407- xml:lang="en"
408- lang="en"
409- dir="ltr"
410- metal:use-macro="context/@@main_template/master"
411+ metal:use-macro="view/macro:page/main_only"
412 i18n:domain="launchpad"
413 >
414 <body>
415
416-<metal:leftportlets fill-slot="portlets_one">
417- <div tal:replace="structure context/@@+portlet-details" />
418- <div tal:replace="structure context/distroarchseries/@@+portlet-details" />
419-</metal:leftportlets>
420-
421-
422 <div metal:fill-slot="main">
423
424- <div>
425- <a
426- tal:attributes="href context/distroarchseries/fmt:url"
427- tal:content="context/distroarchseries/displayname"
428- />:
429- <a tal:attributes="href context/distroarchseriesbinarypackage/fmt:url">
430- &ldquo;<tal:packagename
431- replace="context/distroarchseriesbinarypackage/name"
432- />&rdquo; package
433- </a>
434- </div>
435- <h1 tal:content="context/title">Name of package</h1>
436
437+ <div class="top-portlet">
438 <tal:description replace="structure context/description/fmt:text-to-html">
439 Package Description
440 </tal:description>
441-
442- <h2>Source package</h2>
443-
444- <div id="source">
445- <ul>
446- <li class="source package">
447- <a tal:define="spackage context/distributionsourcepackagerelease"
448- tal:content="spackage/title"
449- tal:attributes="href spackage/fmt:url">SOURCEPACKAGE</a>
450- </li>
451- </ul>
452- </div>
453-
454- <h2>Downloadable files</h2>
455-
456- <div id="files">
457- <div id="build" tal:condition="context/build">
458- <a tal:define="pbuild context/build"
459- tal:content="pbuild/title"
460- tal:attributes="href pbuild/fmt:url">BUILD</a> produced
461- <span tal:condition="context/files">
462- these files:
463- </span>
464+ </div>
465+
466+ <div class="yui-g">
467+
468+ <div class="first yui-u">
469+ <div tal:replace="structure context/@@+portlet-details" />
470+ </div>
471+
472+ <div class="yui-u">
473+ <div class="portlet">
474+ <h2>Downloadable files</h2>
475+ <div id="files">
476+ <div id="build" tal:condition="context/build">
477+ <a tal:define="pbuild context/build"
478+ tal:content="pbuild/title"
479+ tal:attributes="href pbuild/fmt:url">BUILD</a> produced
480+ <span tal:condition="context/files">
481+ these files:
482+ </span>
483+ <span tal:condition="not: context/files">
484+ no files for this binary package.
485+ </span>
486+ </div>
487+
488+ <div id="downloadable-files">
489+ <ul class="download" tal:condition="context/files">
490+ <li tal:repeat="file context/files">
491+ <a class="sprite"
492+ tal:content="file/libraryfile/filename"
493+ tal:attributes="href file/libraryfile/http_url"></a>
494+ (<span tal:replace="file/libraryfile/content/filesize/fmt:bytes" />)
495+ </li>
496+ </ul>
497+ </div>
498+ </div>
499+ <!-- No build and no downloadable files -->
500+ <div tal:condition="not: context/build">
501 <span tal:condition="not: context/files">
502- no files for this binary package.
503+ There are no downloadable files for this binary package.
504 </span>
505- </div>
506-
507- <div id="downloadable-files">
508- <ul class="download" tal:condition="context/files">
509- <li tal:repeat="file context/files">
510- <a tal:content="file/libraryfile/filename"
511- tal:attributes="href file/libraryfile/http_url"></a>
512- (<span tal:replace="file/libraryfile/content/filesize/fmt:bytes" />)
513- </li>
514- </ul>
515- </div>
516- </div>
517- <!-- No build and no downloadable files -->
518- <div tal:condition="not: context/build">
519- <span tal:condition="not: context/files">
520- There are no downloadable files for this binary package.
521- </span>
522- </div>
523-
524-
525- <h2>Package relationships</h2>
526-
527- <table width="100%" tal:define="bpr context/binarypackagerelease">
528- <tr>
529- <td><div tal:replace="structure bpr/@@+portlet-depends" /></td>
530- <td><div tal:replace="structure bpr/@@+portlet-conflicts" /></td>
531- <td><div tal:replace="structure bpr/@@+portlet-provides" /></td>
532- </tr>
533- <tr>
534- <td><div tal:replace="structure bpr/@@+portlet-replaces" /></td>
535- <td><div tal:replace="structure bpr/@@+portlet-suggests" /></td>
536- <td><div tal:replace="structure bpr/@@+portlet-recommends" /></td>
537- </tr>
538- <tr>
539- <td><div tal:replace="structure bpr/@@+portlet-predepends" /></td>
540- <td><div tal:replace="structure bpr/@@+portlet-enhances" /></td>
541- <td><div tal:replace="structure bpr/@@+portlet-breaks" /></td>
542- </tr>
543- </table>
544+ </div>
545+ </div><!--portlet-->
546+ </div><!--yui-u-->
547+
548+ </div><!--yui-g-->
549+
550+
551+ <style>#relationships div {padding-top:0.5em;}</style>
552+ <div class="yui-g" tal:define="bpr context/binarypackagerelease">
553+ <div class="portlet" id="relationships">
554+
555+ <h2>Package relationships</h2>
556+
557+ <div tal:replace="structure bpr/@@+portlet-depends" />
558+ <div tal:replace="structure bpr/@@+portlet-conflicts" />
559+ <div tal:replace="structure bpr/@@+portlet-provides" />
560+ <div tal:replace="structure bpr/@@+portlet-replaces" />
561+ <div tal:replace="structure bpr/@@+portlet-suggests" />
562+ <div tal:replace="structure bpr/@@+portlet-recommends" />
563+ <div tal:replace="structure bpr/@@+portlet-predepends" />
564+ <div tal:replace="structure bpr/@@+portlet-enhances" />
565+ <div tal:replace="structure bpr/@@+portlet-breaks" />
566+
567+ </div><!--portlet-->
568+ </div><!--yui-g-->
569+
570 </div>
571 </body>
572 </html>
573
574=== modified file 'lib/lp/soyuz/templates/distroarchseriesbinarypackagerelease-portlet-details.pt'
575--- lib/lp/soyuz/templates/distroarchseriesbinarypackagerelease-portlet-details.pt 2009-07-17 17:59:07 +0000
576+++ lib/lp/soyuz/templates/distroarchseriesbinarypackagerelease-portlet-details.pt 2009-09-02 11:56:16 +0000
577@@ -6,24 +6,36 @@
578
579 <h2>Details</h2>
580
581- <div class="portletBody portletContent">
582-
583- <b>Package version:</b>
584- <span tal:replace="context/version" /><br />
585-
586- <b>Source:</b>
587- <a tal:content="context/distributionsourcepackagerelease/version"
588+ <div class="two-column-list">
589+
590+ <dl>
591+ <dt>Package version:</dt>
592+ <dd tal:content="context/version" />
593+ </dl>
594+
595+ <dl>
596+ <dt>Source:</dt>
597+ <dd id="source">
598+ <a tal:content="context/distributionsourcepackagerelease/title"
599 tal:attributes="href context/distributionsourcepackagerelease/fmt:url"
600- >apache2 2.1-3</a><br />
601-
602- <b>Status:</b>
603- <span tal:replace="context/status/title" /><br />
604-
605- <b>Component:</b>
606- <span tal:replace="context/component/name" /><br />
607-
608- <b>Priority:</b>
609- <span tal:replace="context/priority/title" /><br />
610+ >apache2 2.1-3 (source) in Ubuntu</a><br />
611+ </dd>
612+ </dl>
613+
614+ <dl>
615+ <dt>Status:</dt>
616+ <dd tal:content="context/status/title" />
617+ </dl>
618+
619+ <dl>
620+ <dt>Component:</dt>
621+ <dd tal:content="context/component/name" />
622+ </dl>
623+
624+ <dl>
625+ <dt>Priority:</dt>
626+ <dd tal:content="context/priority/title" />
627+ </dl>
628
629 </div>
630