目前我正在开发一些应用程序的GUI,这是在QT(多平台框架)中开发的。 QT中的GUI可以作为普通的CSS来设计。OOCSS to Long CSS生成器
所以,我开发GUI作为一个基本的web应用程序(HTML5,CSS3和JS),我使用较少的预处理的造型和创造一些原因OOCSS(面向对象CSS)...
通过LESS生成:
.button {
position: absolute;
display: block;
text-align: center;
line-height: 50px;
height: 50px;
text-transform: uppercase;
text-decoration: none;
font-size: 14px;
width: 120px;
background-color: white;
color: blue;
}
.button.button-big {
font-size: 20px !important;
width: 200px !important;
}
.button.button-green {
background-color: green !important;
color: white !important;
}
是否有转换到OOCSS造型旧校园(加长版)任何工具或任务(咕噜/一饮而尽)?
预期的结果:
.button {
position: absolute;
display: block;
text-align: center;
line-height: 50px;
height: 50px;
text-transform: uppercase;
text-decoration: none;
font-size: 14px;
width: 120px;
background-color: white;
color: blue;
}
.button-big {
position: absolute;
display: block;
text-align: center;
line-height: 50px;
height: 50px;
text-transform: uppercase;
text-decoration: none;
font-size: 14px;
width: 120px;
background-color: white;
color: blue;
font-size: 20px !important;
width: 200px !important;
}
.button-green {
position: absolute;
display: block;
text-align: center;
line-height: 50px;
height: 50px;
text-transform: uppercase;
text-decoration: none;
font-size: 14px;
width: 120px;
background-color: white;
color: blue;
background-color: green !important;
color: white !important;
}
当然,我将不得不清理类,但该工具会来救我的几个小时。
原因: 我的客户端在CSS中不是高级的。所以,OOCSS可能对他一点困惑。
感谢您的答复 亚当
你为什么要这样做? –
Couse对于我的客户来说,开发该应用程序会更容易。我只准备CSS类... –
我不明白。你的意思是说你的客户**更容易维持**吗?最初因素的类更容易维护。 –