we will follow the below approach for AF:

1. Reset all browser CSS.
2. Define common CSS properties for the common HTML elements.
3. Define CSS properties to specific selectors.

http://www.cssreset.com/CSS Reset | 2012's most common CSS Resets to copy/paste, with documentation / tutorials
CSS Reset | 2012's most common CSS Resets to copy/paste, with documentation / tutorials
All the most common CSS Reset scripts in one place to copy/paste, with complete documentation, guides and tutorials.

fb_anonymous_user's picture

Resetting default CSS properties makes design implementation easy, but sometimes you would like to see default HTML behaviour, say for example for table border, un/ordered list. Default CSS behavior is specially required for WYSIWYG editors, where clients design their own content. Since WYSIWYG editors render the HTML being edited, inside iframe, impact of reset css in not visible until later the content is published. Several times we encountered clients complaining, they do not see in front end, what they have designed in WYSIWYG. What I feel is, overriding common css properties makes initial design implementation easy, but later messes up content published via WTSIWYG hence makes UI troubleshooting difficult.

fb_anonymous_user's picture

gr8 point, that might be a special scenario. I will try to reproduce the issue and then can tell you detail on this. but for now, my observation is first we will reset the css to avoid defaulting to the browser’s built-in styles, which differs from browser to browser. But this is not a strict rule. As Eric Meyer says "...That’s much of the point here: that this is not a case of “everyone must use these styles in a certain way without alteration”...". we will adjust our css reset according to our need. But the steps I mentioned is first reset, then we define the common style (e.g we will define styles for table, ul, li, input html elements), then we will set styles to selectors (e.g we will define styles to classes, ids etc). CSS means cascading. we must maintain the order of our declaration. thanks.

Add new comment

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.