//深色
function getColorDark () {
return '#' +
(function(color) {
return(color += '0123401234abcabc' [Math.floor(Math.random() * 16)]) &&
(color.length == 6) ? color : arguments.callee(color);
})('');
}
//浅色
function getColorUndertint() {
return '#' +
(function(color) {
return(color += '5678956789defdef' [Math.floor(Math.random() * 16)]) &&
(color.length == 6) ? color : arguments.callee(color);
})('');
}
JS获取随机深浅色
最新推荐文章于 2022-08-30 19:16:50 发布