Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
使用颜色选择器http://labs.abeautifulsite.net/jquery-miniColors/,如何将颜色数量限制为仅使用灰度滑块?
为了限制灰度值,rgb 模型必须如下:
x = [0, 255] rgb(x, x, x)
例如:
.elem { background-color: rgb(122, 122, 122); }
或以十六进制表示,如 css # 表示法,值必须遵循:
x = [0, 9][a, f] y = [0, 9][a, f] #xyxyxy
.elem { background-color: #e1e1e1; }