cre*_*eme 6 javascript console colors hyperlink styling
我的网站上有一条console.log消息,带有链接。样式正常,但链接在白色背景上保持黑色字体。我可以改变吗?
$(function() {
var t = navigator.userAgent.toLowerCase();
if (/(chrome|firefox|safari)/.test(t.toLowerCase())) {
var e = ["padding: 20px 5px 16px", "background-color: #171718", "color: #f2641c"].join(";");
var i = ["padding: 20px 5px 16px", "background-color: #f2641c", "color: #ffffff"].join(";"),
n = ["background-color: transparent"].join(";");
console.log("\n\n %c Some text %c http://google.com/ %c \n\n\n", e, i, n);
} else {
window.console && console.log("Some text - http://google.com/");
}
});
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
370 次 |
| 最近记录: |