|
|
|
@ -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(() => { |
|
|
|
|