feat:
This commit is contained in:
parent
537dd8e74c
commit
ef8d04fb39
|
@ -340,10 +340,6 @@
|
||||||
display: block;
|
display: block;
|
||||||
width: 14px;
|
width: 14px;
|
||||||
cursor: pointer; }
|
cursor: pointer; }
|
||||||
.u-table-thead th .bee-table-column-sorter > .bee-table-column-sorter-flat {
|
|
||||||
display: none; }
|
|
||||||
.u-table-thead th:hover .bee-table-column-sorter > .bee-table-column-sorter-flat {
|
|
||||||
display: block; }
|
|
||||||
.u-table-thead th .bee-table-column-sorter-down.on .uf-triangle-down,
|
.u-table-thead th .bee-table-column-sorter-down.on .uf-triangle-down,
|
||||||
.u-table-thead th .bee-table-column-sorter-down.on .uf-triangle-up,
|
.u-table-thead th .bee-table-column-sorter-down.on .uf-triangle-up,
|
||||||
.u-table-thead th .bee-table-column-sorter-up.on .uf-triangle-down,
|
.u-table-thead th .bee-table-column-sorter-up.on .uf-triangle-down,
|
||||||
|
|
|
@ -249,7 +249,7 @@ var Table = function (_Component) {
|
||||||
this.syncFixedTableRowHeight();
|
this.syncFixedTableRowHeight();
|
||||||
}
|
}
|
||||||
//如果contentDomWidth为0则需要重新计算,适应模态框中表格;
|
//如果contentDomWidth为0则需要重新计算,适应模态框中表格;
|
||||||
if (this.contentDomWidth == 0) {
|
if (this.contentDomWidth == 0 && this.preContentDomWidth !== this.contentDomWidth) {
|
||||||
this.computeTableWidth();
|
this.computeTableWidth();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -267,8 +267,10 @@ var Table = function (_Component) {
|
||||||
var numSetWidthParam = parseInt(setWidthParam);
|
var numSetWidthParam = parseInt(setWidthParam);
|
||||||
this.contentWidth = numSetWidthParam;
|
this.contentWidth = numSetWidthParam;
|
||||||
} else {
|
} else {
|
||||||
|
this.preContentDomWidth = this.contentDomWidth;
|
||||||
//计算总表格宽度、根据表格宽度和各列的宽度和比较,重置最后一列
|
//计算总表格宽度、根据表格宽度和各列的宽度和比较,重置最后一列
|
||||||
this.contentDomWidth = this.contentTable.getBoundingClientRect().width; //表格容器宽度
|
this.contentDomWidth = this.contentTable.getBoundingClientRect().width; //表格容器宽度
|
||||||
|
|
||||||
this.contentWidth = this.contentDomWidth; //默认与容器宽度一样
|
this.contentWidth = this.contentDomWidth; //默认与容器宽度一样
|
||||||
if (typeof setWidthParam == 'string' && setWidthParam.indexOf('%')) {
|
if (typeof setWidthParam == 'string' && setWidthParam.indexOf('%')) {
|
||||||
this.contentWidth = this.contentWidth * parseInt(setWidthParam) / 100;
|
this.contentWidth = this.contentWidth * parseInt(setWidthParam) / 100;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "bee-table",
|
"name": "bee-table",
|
||||||
"version": "1.4.15",
|
"version": "1.4.16",
|
||||||
"description": "Table ui component for react",
|
"description": "Table ui component for react",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"react",
|
"react",
|
||||||
|
|
Loading…
Reference in New Issue