Confirmed users
295
edits
(→Basics) |
|||
| Line 7: | Line 7: | ||
** 4 changes to the 3 files: <tt>/browser/themes/[gnome|pin|win]stripe/browser/jar.mn</tt> | ** 4 changes to the 3 files: <tt>/browser/themes/[gnome|pin|win]stripe/browser/jar.mn</tt> | ||
* Make sure each file starts with the standard copyright header (see [https://www.mozilla.org/MPL/boilerplate-1.1/ License Boilerplate]) | * Make sure each file starts with the standard copyright header (see [https://www.mozilla.org/MPL/boilerplate-1.1/ License Boilerplate]) | ||
** For work funded by Mozilla, the 'Initial Developer of the Original Code' should be 'The Mozilla Foundation' | ** For work funded by Mozilla, the 'Initial Developer of the Original Code' should be 'The Mozilla Foundation' | ||
** Remember the year | ** Remember the year | ||
** The first letter of contributors names should be under the 'n' of 'contributors' | ** The first letter of contributors names should be under the 'n' of 'contributors' | ||
| Line 13: | Line 13: | ||
* Functional stuff (for example, toggling the display property based on application state) should be in content css rather than theme css | * Functional stuff (for example, toggling the display property based on application state) should be in content css rather than theme css | ||
* Avoid <tt>!important</tt> but if you have to use it, make sure it's obvious why you're using it (maybe with a comment) | * Avoid <tt>!important</tt> but if you have to use it, make sure it's obvious why you're using it (maybe with a comment) | ||
* Avoid magic numbers, prefer automatic sizing | * Avoid magic numbers, prefer automatic sizing, but add comments when the choice (i.e. complex DOM math) is worse than just hard coding | ||
* Avoid setting styles in JavaScript. It's generally better to set a class and then specify the styles in CSS | |||
* <tt>classList</tt> is generally better than <tt>className</tt>. There's less chance of over-writing an existing class | |||
== Formatting == | == Formatting == | ||