← Back to team overview

launchpad-dev team mailing list archive

Re: Maintainable UI modifications

 

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 6/8/2012 7:17 AM, Huw Wilkins wrote:
> Hi Launchpad,
> 
> I've been looking at how we can make some changes to our UI, but 
> I'm hitting a bit of a problem.
> 
> If we want to do anything significant to our UI we want to do it 
> under a feature flag. However, once I use a feature flag I very 
> quickly end up having to maintain two sets of HTML and CSS or I
> end up hacking extra layers of code on top of existing HTML/CSS
> instead of being able to write it cleanly from the start.
> 
> This becomes very apparent if we want to re-skin Launchpad were 
> there are potentially hundreds of places that would need to be 
> feature flagged. That means a lot of duplication and the new skin 
> would be written on top of the existing HTML/CSS structure.
> 
> Does anyone have any suggestions about how we could approach this 
> problem?
> 

Would it be possible to just have a second parallel set of .css files
and the big feature flag is across the whole set?

Sort of an:

if my_new_feature_flag:
  use('combo-new.css')
else:
  use('combo.css')

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk/RvK0ACgkQJdeBCYSNAAMjOQCgk+3g6BRuajbFXl/9w36ZdqSK
m3cAn3UmZBBHGEJLzxdjwpi+4GNvXlYb
=lpR0
-----END PGP SIGNATURE-----


References