MCPcopy Create free account
hub / github.com/ElemeFE/element-react / updateScrollY

Method updateScrollY

src/table/TableLayout.jsx:197–209  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

195
196 // judge if has scroll-Y bar
197 updateScrollY() {
198 this.setState((state) => {
199 const { bodyWrapper } = this.table;
200 const { fixedBodyHeight } = state;
201
202 const body = bodyWrapper.querySelector('.el-table__body');
203 const scrollY = body.offsetHeight > fixedBodyHeight;
204
205 return {
206 scrollY
207 };
208 });
209 }
210
211 render() {
212 return (

Callers 2

componentDidUpdateMethod · 0.95
scheduleLayoutMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected