launchpad-dev team mailing list archive
-
launchpad-dev team
-
Mailing list archive
-
Message #00877
Page headings and titles
Some time today (hopefully), I will land a branch that makes the rules
for page headings and titles sane. This branch is linked to bug 417089.
https://bugs.edge.launchpad.net/launchpad-foundations/+bug/417089
The rules, both in how a page should look, and how to code for that
look, are defined in this wiki page:
https://dev.launchpad.net/VersionThreeDotO/UI/Conversion#Heading%20rules
Once this branch lands, you will have to make some changes to your
page templates and view classes in order to conform to these rules. I
know that may mean taking another look at pages you've already
converted, but it's worth it for the consistency and simplicity that
will result. It should be easy, though perhaps tedious to make these
changes, which should mean mostly removing or moving code. As my
experience has shown over this week, stories/pagetests will change
considerably because printing the browser.title now prints the
reversed breadcrumbs. But don't worry, I've gone through the pain of
converting our existing tests for you!
Please read the above wiki page for details on what you need to do,
and ask me on irc if anything doesn't make sense or doesn't work for
you. The vast majority of story changes were pretty mechanical.
Many pages use smartquotes in the breadcrumbs. That's fine but it
makes titles contain non-ascii characters. Way too late in the
conversion process I found
canonical.launchpad.helpers.backslashreplace(). We use this pretty
inconsistent and in fact most of the tests I've fixed don't use it.
They should though and I'm thinking the function should go into
doctest globs, perhaps as smartquote_print() or title_print(). I
generally don't like globs, but this one might be worth it. Thoughts?
If you have any questions or run into any problems, please ping me on
irc. I'm OCR today but I will be deferring that until this branch
gets into pqm-via-ec2. I'll stick around late tonight if need be.
-Barry
Attachment:
PGP.sig
Description: This is a digitally signed message part
Follow ups