Skip to content

Commit

Permalink
admin:修复动态计算表格高度BUG
Browse files Browse the repository at this point in the history
  • Loading branch information
bbbbbbbbbbbbba committed Feb 20, 2024
1 parent 2690675 commit a6f13e0
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions admin/src/composables/height.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
export function useTableHeight() {
const instance = getCurrentInstance();
const { proxy } = getCurrentInstance() as any;

if (!instance) {
if (!proxy) {
return;
}

const ins = instance as any;

const containerHeaderRef =
ins.ctx.$el.getElementsByClassName('container-header')[0];
proxy.$el.getElementsByClassName('container-header')[0];
const containerMainRef =
ins.ctx.$el.getElementsByClassName('container-main')[0];
proxy.$el.getElementsByClassName('container-main')[0];

if (!containerMainRef) {
return;
Expand Down

0 comments on commit a6f13e0

Please sign in to comment.