Firefox/Windows 8 Metro Style Guides: Difference between revisions
< Firefox
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 2: | Line 2: | ||
* this a spot to jot down guidelines of varying types, largely for front end developers & designers. This includes code style, theming style, and whatever else will help us produce a consistent, shiny produce faster. If you have questions about this page, please ping :ally in #windev. | * this a spot to jot down guidelines of varying types, largely for front end developers & designers. This includes code style, theming style, and whatever else will help us produce a consistent, shiny produce faster. If you have questions about this page, please ping :ally in #windev. | ||
= Design/Theming guidelines = | |||
* use flyout panes over dialogs | |||
= Coding Guidelines = | |||
* Generally we use [https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style Mozilla Coding Style], with a few exceptions: | |||
* You don't need to wrap lines to 80 characters. Use longer lines (up to around 120 characters; use your judgement) if it improves readability. | |||
* Consistency is king, and supersedes any particular rule. | * Consistency is king, and supersedes any particular rule. | ||
== JS == | |||
* else in if/else pairings are double cuddled ( eg } else { | |||
== CSS == | |||
* if you create an attribute and it has only one value, do not set it to true/false. Remove the attribute in the case of false. This produces cleaner, more concise css, without imperiling js readability. | |||
= helpful references = | |||
* yuan's list of design links: https://kippt.com/yuan/designing-for-windows-8 | |||
* general coding guidelines for mozilla: https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style | * general coding guidelines for mozilla: https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style |
Revision as of 00:00, 13 March 2013
Nota Bene
- this a spot to jot down guidelines of varying types, largely for front end developers & designers. This includes code style, theming style, and whatever else will help us produce a consistent, shiny produce faster. If you have questions about this page, please ping :ally in #windev.
Design/Theming guidelines
- use flyout panes over dialogs
Coding Guidelines
- Generally we use Mozilla Coding Style, with a few exceptions:
- You don't need to wrap lines to 80 characters. Use longer lines (up to around 120 characters; use your judgement) if it improves readability.
- Consistency is king, and supersedes any particular rule.
JS
- else in if/else pairings are double cuddled ( eg } else {
CSS
- if you create an attribute and it has only one value, do not set it to true/false. Remove the attribute in the case of false. This produces cleaner, more concise css, without imperiling js readability.
helpful references
- yuan's list of design links: https://kippt.com/yuan/designing-for-windows-8
- general coding guidelines for mozilla: https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style