hexo-theme-material-flow icon indicating copy to clipboard operation
hexo-theme-material-flow copied to clipboard

table样式显示不正常

Open frezoow opened this issue 5 years ago • 2 comments

貌似css3不支持这种写法,导致table的样式不能应用? table:not('.highlight table') { width: 100%; td, th { padding: 12px 24px } tr { border-bottom: 1px solid #ddd; } &>thead>th { border-bottom-width: 2px; } }

frezoow avatar Apr 24 '19 22:04 frezoow

我查到css3目前不支持这种写法

table:not('.highlight table') 具体参见https://segmentfault.com/q/1010000011693839 希望开发者能提供下修改默认表格的方法,直接改默认会把代码块也改掉

frezoow avatar Apr 27 '19 00:04 frezoow

在app.js加上以下逻辑可以解决(不会写css的后端路过) $("table").filter(function(){ return $(this).parent().is(":not(.highlight)"); }).css('width', '100%'); $("table tr td ").filter(function(){ return $(this).parent().is(":not(.highlight)"); }).css('border', '1px solid #242424'); $("table thead tr th ").filter(function(){ return $(this).parent().is(":not(.highlight)"); }).css('border', '1px solid #242424');

whiteworker avatar Oct 14 '19 07:10 whiteworker