| | |
| | | query.select('.content-body').boundingClientRect(rect => { |
| | | if (rect) { |
| | | const contentHeight = rect.height; |
| | | const baseHeight = 280; |
| | | // !! 折叠高度由容器内容自动计算,避免写死高度导致内容被截断,先保留原来的逻辑最小280 |
| | | const baseHeight = Math.max(Math.ceil(contentHeight), 280); |
| | | const oldFullHeight = fullHeight.current; |
| | | fullHeight.current = Math.max(contentHeight, baseHeight); |
| | | minHeight.current = baseHeight; |
| | |
| | | |
| | | useEffect(() => { |
| | | calculateBoxHeight(); |
| | | console.log('-deps.bannerList, deps.tripStatus, deps.shouldShowOrderStatusCard', deps.bannerList, deps.tripStatus, deps.shouldShowOrderStatusCard); |
| | | |
| | | }, [deps.bannerList, deps.tripStatus, deps.shouldShowOrderStatusCard]); |
| | | |
| | | useEffect(() => { |