Created
February 27, 2013 15:30
-
-
Save flying19880517/5048766 to your computer and use it in GitHub Desktop.
严格调试样式
1px红色点线:行内样式
3px红色点线:空属性
5px红色点线:没有高和宽的图片 没有alt的图片 没有title的图片 没有title的链接
黄色背景:空元素
1px红框:过时属性
10px红框:过时元素
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Debug CSS by iifksp | |
* Author: [email protected] | |
* Author URI: http://www.swordair.com/blog | |
* Version: 1.1 | |
* License: MIT | |
*/ | |
/* inline style */ | |
*[style]{outline:1px dotted #f00 !important;} | |
/* empty attributes */ | |
*[alt=""], | |
*[title=""], | |
*[class=""], | |
*[id=""], | |
a[href=""], | |
a[href="#"]{outline:3px dotted #f00 !important;} | |
/* no width & height & alt & title */ | |
img:not([width]):not([height]), | |
img:not([alt]), | |
img:not([title]), | |
a[href]:not([title]){outline:5px dotted #f00 !important;} | |
/* empty elements */ | |
div:empty, | |
span:empty, | |
li:empty, | |
p:empty, | |
td:empty, | |
th:empty{padding:1em;background-color:#ff0 !important;} | |
/* obsolete elements */ | |
applet, | |
basefont, | |
center, | |
dir, | |
font, | |
isindex, | |
strike, | |
xmp, | |
big, | |
tt, | |
acronym{outline:10px solid #f00 !important;} | |
/* obsolete attributes */ | |
html[version], | |
body[alink],body[link],body[text],body[vlink],body[background],body[bgcolor], | |
a[rev],a[charset],a[shape],a[coords], | |
img[longdesc],img[name],img[hspace],img[vspace], | |
area[nohref], | |
object[archive],object[classid],object[codebase],object[codetype],object[declare],object[standby], | |
table[bgcolor],table[bgcolor],table[width],table[summary],table[cellpadding],table[cellspacing],table[rules],table[frame], | |
td[axis],td[abbr],th[axis],th[abbr],td[scope],td[height],th[height],td[width],th[width],tr[bgcolor],td[bgcolor],th[bgcolor],td[nowrap],th[nowrap], | |
caption[align],iframe[align],img[align],input[align],object[align],legend[align],table[align],hr[align],div[align],h1[align],h2[align],h3[align],h4[align],h5[align],h6[align],p[align],col[align],colgroup[align],tbody[align],td[align],tfoot[align],th[align],thead[align],tr[align], | |
col[valign],colgroup[valign],tbody[valign],td[valign],tfoot[valign],th[valign],thead[valign],tr[valign], | |
col[width],colgroup[width],pre[width], | |
col[char],colgroup[char],tbody[char],td[char],tfoot[char],th[char],thead[char],tr[char], | |
col[charoff],colgroup[charoff],tbody[charoff],td[charoff],tfoot[charoff],th[charoff],thead[charoff],tr[charoff], | |
dl[compact],menu[compact],ol[compact],ul[compact], | |
hr[noshade],hr[size],hr[size],hr[width], | |
iframe[marginheight],iframe[marginwidth],iframe[scrolling],iframe[frameborder],iframe[longdesc], | |
object[border],object[hspace],object[vspace], | |
ul[type],ol[type],li[type], | |
br[clear]{border:1px solid #f00 !important;} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment