zoukankan      html  css  js  c++  java
  • 把iview的table做成更适合展现大量数据的样式(字体变小、去除多余的padding等)

    <style>
        .ivu-table {
            font-size: 12px !important;
        }
    
        .ivu-table-header thead tr th {
            padding: 0px !important;
            height: 26px;
            line-height: 26px;
        }
    
        .ivu-table-fixed-header thead tr th {
            padding: 0px !important;
            height: 26px;
            line-height: 26px;
            font-size: 12px;
        }
    
        .ivu-table-fixed-right-header {
            height: 29px !important;
        }
    
        .ivu-table-cell {
            white-space: nowrap !important;
            padding-left: 8px !important;
            padding-right: 8px !important;
        }
    
        .ivu-table td, .ivu-table th {
            height: 26px;
            line-height: 26px;
        }
    </style>
                let ele = this.$el;
                this.height = ele.clientHeight;
                this.width = ele.clientWidth;
                this.showTable = true;
                window.onresize = () => {
                    this.showTable = false;
                    this.$nextTick(() => {
                        this.height = ele.clientHeight;
                        this.width = ele.clientWidth;
                        this.showTable = true;
                    })
                }
  • 相关阅读:
    前端基础之BOM和DOM
    前端基础之JavaScript
    前端基础之CSS
    Black And White HDU
    Robot Motion HDU
    A Knight's Journey POJ
    Find a way HDU
    排序 HDU
    Dungeon Master POJ
    Network Saboteur POJ
  • 原文地址:https://www.cnblogs.com/liulun/p/12156388.html
Copyright © 2011-2022 走看看