優化頁面中,想用日歷中不可選時,鼠標懸浮時的禁止圖片提示效果,用到自己頁面中。
查詢結果
.button[disabled]:hover {
cursor: not-allowed;
}
得到啟發,在自己項目中搜尋該樣式在哪個css文件中:
搜索結果:
.layui-disabled, .layui-disabled:hover {
color: #d2d2d2 !important;
cursor: not-allowed !important;
}
然后直接在自己頁面中引用樣式:
<button class="layui-btn layui-disabled" style="color:gray" disabled="disabled">詳情</button>
得到自己想要的效果
嘿嘿,很有成就感,自己害怕的前端各種小樣式都慢慢克服了!
提示:
https://segmentfault.com/q/1010000006702628?_ea=1115680