Common Stylesheet for apps that infrastructure writes

Toshio Kuratomi a.badger at gmail.com
Tue Aug 16 17:25:21 UTC 2011


Hey all, mizmo and I talked about this a few years ago but neither of us had
time to really pursue it back then.  The idea is that infrastructure writes
quite a few web applications.  Those applications have many common elements.
If we defined classes and usage for those elements we'd get sevaral
benefits:

* Easier to theme and retheme our applications.
* Less chance of breaking things by changing global stylesheets because we
  know what each element is supposed to do
* Application programmers have a more concrete idea of what elements they
  are expected to provide and what those elements should contain.

I'm presently working on a new, small web application for infrastructure
using a new template language so it is a good opportunity to look at this
again.  I've written out something here:

https://fedoraproject.org/wiki/User:Toshio/Infra_Apps_Common_Stylesheet

that I've extracted from looking at fas, bodhi, pkgdb, elections, wiki and
fedoracommunity from a thousand foot view and then a closer look at how fas's
existing stylesheet implements things.

My goal here was to identify elements of the page, assign the major elements
an id based on what they do, then give the subelements that they contain
a class.  I also tried to identify how the elements are currently being
rendered.  Applications we write in infrastructure would create elements in
the areas identified so that css could be applied to all of those equally.
They'd import the stylesheet that gave a default fedora look and feel to the
app and possibly override some settings using an app-specific stylesheet.

On IRC, sijis pointed out that although it'd be nice to have a stylesheet
that made the apps look the same as fedoraproject.org, it might be hard to
keep updates to the stylesheet from breaking either the apps or
fedoraproject.org.  So for imlementation, it might be better to put this
into a separate css file.  Applications we write in infrastructure would use
that file whereas the website and wiki would continue to use a different
css.  There'd likely be duplication between them but at least we wouldn't
have a separate stylesheet implementing fedora-look and feel for each app.

What do people think?  Is this something we can turn into an actual document
for Fedora generated web applications to follow?  What additional elements
would be helpful?  Are there things that are not sufficiently generic?

-Toshio
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.fedoraproject.org/pipermail/websites/attachments/20110816/bc51a09e/attachment.sig>


More information about the websites mailing list