Commit 67d5a00a authored by aballerr's avatar aballerr Committed by GitHub

fix: fixes show more not showing on long collection description (#4789)

* fixes bug where show more does not always show up properly
parent 84364c9d
...@@ -134,6 +134,9 @@ export const statsLabelLoading = style([ ...@@ -134,6 +134,9 @@ export const statsLabelLoading = style([
export const descriptionLoading = style([ export const descriptionLoading = style([
loadingAsset, loadingAsset,
sprinkles({
height: '20',
}),
{ {
maxWidth: 'min(calc(100% - 112px), 600px)', maxWidth: 'min(calc(100% - 112px), 600px)',
}, },
......
...@@ -208,7 +208,7 @@ const CollectionDescription = ({ description }: { description: string }) => { ...@@ -208,7 +208,7 @@ const CollectionDescription = ({ description }: { description: string }) => {
descriptionRef.current.getBoundingClientRect().width >= 590) descriptionRef.current.getBoundingClientRect().width >= 590)
) )
setShowReadMore(true) setShowReadMore(true)
}, [descriptionRef, baseRef]) }, [descriptionRef, baseRef, isCollectionStatsLoading])
return isCollectionStatsLoading ? ( return isCollectionStatsLoading ? (
<Box marginTop={{ sm: '12', md: '16' }} className={styles.descriptionLoading}></Box> <Box marginTop={{ sm: '12', md: '16' }} className={styles.descriptionLoading}></Box>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment