2004年03月05日 星期五

CSS 良好交互的基础

macromedia关于wired使用css建构良好架构的网站的文章。里面的一些观点,从我的实际经验看,很有遵循的必要。大致归纳如下
第一条就是我原先提到的,先有了成品的客户确认的精确的设计以后,再去建构css。这样,可以减少你大量的不必要的返工。不要只有设计毛胚,就贸然开始css设计。在设计pure css的网站的时候,心里一定要有明确的模块化的概念。根据laytou和function做模块化的设定。
第二条也是我现在遵循的,很有必要的一条原则。良好组织的css文档和详细又明了的注释。在团队协调和以后自我修改的时候也可以节约大量的沟通和再回忆、解读的时间。不要把css的设定都放在一个css文件里面。我现在一般通用的做法是,一个portal css文件作为入口,把其他的css按照不同的功能放在不同的css文件里面,portal css文件import.比如fonts.css专门负责字体设定。themes.css专门负责主题类相关的设定,还有print.css,forms.css,layout.css等等不同的功能css。
第三条是不断的学习新的css技术和概念。多研究其他优秀的pure css站点。理解他们的应用原则。慢慢自己的css设计也会得心应手。

Don’t put technology ahead of design. Begin the design process knowing you’ll be using CSS to build what you created. But establish where you want the design to go first. Then break the design down into logical components, using CSS to reassemble it like a puzzle. Starting with CSS before having at least a rough design direction will only frustrate you later.

Keep your style sheets organized. Group CSS rules into logical sections that make sense to you or your team. Use comments liberally to identify groups of rules and what they do. Not only will this help other team members decipher your style sheets, it will help you remember what you did when returning to the same CSS several months later.

Learn the concepts behind the techniques. Study existing CSS examples and designs. More sites are redesigning with CSS every week, and lots of books, articles, and tutorials are readily available. Figure out why the techniques they use work. What are they doing? Why is it beneficial to do it this way? The real power of CSS lies in the ability to understand how and why certain techniques work, not in memorizing an exact sequence of steps or a delicate combination of rules. With a better understanding of the concepts, you’ll be able to better reapply them to solve other design challenges.

[technorati relative tag]

[相关内容]

由 tristones 发表于 2004年03月05日 下午02時31分

留言