king 1 year ago
parent 8f104e2a54
commit ae57654a46
  1. 4
      src/pages/preview/brand/article/article.tsx

@ -21,15 +21,17 @@ const article: FC = () => {
const {children} = useMemo(() => parse(articleInfo?.content || ''), [articleInfo])
useEffect(() => {
setTimeout(() => {
const query = Taro.createSelectorQuery()
query.select('#childrenNode').boundingClientRect((res) => {
if (!Array.isArray(res)) {
if (res.height !== 240) {
console.log({childrenNode: res})
setUltra(pageHeight * .45 < res.height)
setUltra(pageHeight * .45 <= res.height)
}
}
}).exec()
}, 300)
}, [children])
Taro.useReady(() => {

Loading…
Cancel
Save