UNPKG

tav-ui

Version:
37 lines (32 loc) 847 B
'use strict'; Object.defineProperty(exports, '__esModule', { value: true }); var vue = require('vue'); function useTableFullHeight(propsRef, tableElRef) { const { fullHeight } = vue.unref(propsRef); if (!fullHeight) return; let headEl; let bodyEl; let contentEl; async function calcTableHeight() { await vue.nextTick(); const table = vue.unref(tableElRef); if (!table) return; const tableEl = table.$el; if (!tableEl) return; if (!bodyEl) { bodyEl = tableEl.querySelector(".ant-table-body"); if (!bodyEl) return; } headEl = tableEl.querySelector(".ant-table-thead"); if (!headEl) return; bodyEl.style.minHeight = `${170}px`; } calcTableHeight(); } exports.useTableFullHeight = useTableFullHeight; //# sourceMappingURL=useTableFullHeight2.js.map