Table: fix a style bug when fixed=right. (#1651)

pull/1647/head
FuryBean 2016-12-09 16:08:49 +08:00 committed by cinwell.li
parent b0633de8bf
commit 2dd2c79365
2 changed files with 12 additions and 1 deletions

View File

@ -67,7 +67,7 @@
:style="{ :style="{
width: layout.rightFixedWidth ? layout.rightFixedWidth + 'px' : '', width: layout.rightFixedWidth ? layout.rightFixedWidth + 'px' : '',
height: layout.viewportHeight ? layout.viewportHeight + 'px' : '', height: layout.viewportHeight ? layout.viewportHeight + 'px' : '',
right: layout.scrollY ? layout.gutterWidth + 'px' : '' right: layout.scrollY ? (border ? layout.gutterWidth : (layout.gutterWidth || 1)) + 'px' : ''
}"> }">
<div class="el-table__fixed-header-wrapper" ref="rightFixedHeaderWrapper" v-if="showHeader"> <div class="el-table__fixed-header-wrapper" ref="rightFixedHeaderWrapper" v-if="showHeader">
<table-header <table-header
@ -93,6 +93,9 @@
</table-body> </table-body>
</div> </div>
</div> </div>
<div class="el-table__fixed-right-patch"
v-if="rightFixedColumns.length > 0"
:style="{ width: layout.scrollY ? layout.gutterWidth + 'px' : '0', height: layout.headerHeight + 'px' }"></div>
<div class="el-table__column-resize-proxy" ref="resizeProxy" v-show="resizeProxyVisible"></div> <div class="el-table__column-resize-proxy" ref="resizeProxy" v-show="resizeProxyVisible"></div>
</div> </div>
</template> </template>

View File

@ -154,6 +154,14 @@
} }
} }
@e fixed-right-patch {
position: absolute;
top: -1px;
right: 0;
background-color: var(--table-header-background);
border-bottom: 1px solid var(--table-border-color);
}
@e fixed-right { @e fixed-right {
top: 0; top: 0;
left: auto; left: auto;