From 670f071177667f10edc1ca0b4549ab0a3c0d796a Mon Sep 17 00:00:00 2001 From: keyan Date: Fri, 27 Jan 2023 15:01:32 -0600 Subject: [PATCH] fix item spacing generically --- components/item-full.js | 32 +++++++++++++++++--------------- styles/item.module.css | 17 ++++++++++++++++- 2 files changed, 33 insertions(+), 16 deletions(-) diff --git a/components/item-full.js b/components/item-full.js index a5b668e6..4318cddf 100644 --- a/components/item-full.js +++ b/components/item-full.js @@ -96,21 +96,23 @@ function TopLevelItem ({ item, noReply, ...props }) { return ( - {item.text &&
} - {item.url && } - {item.poll && } - {item.bounty && -
- {item.bountyPaidTo?.length - ? ( -
- {item.bounty} sats paid -
) - : ( -
- {item.bounty} sats bounty -
)} -
} +
+ {item.text && } + {item.url && } + {item.poll && } + {item.bounty && +
+ {item.bountyPaidTo?.length + ? ( +
+ {item.bounty} sats paid +
) + : ( +
+ {item.bounty} sats bounty +
)} +
} +
{!noReply && <> diff --git a/styles/item.module.css b/styles/item.module.css index 9d2921f4..6e78799a 100644 --- a/styles/item.module.css +++ b/styles/item.module.css @@ -50,30 +50,45 @@ width: 100%; padding-right: 12px; } + .tweetSkeleton { width: 100%; } + .tweetSkeleton { border: 0.05rem solid var(--theme-borderColor); border-radius: 12px; height: 200px; padding: 1.5rem; } + .tweetSkeleton .img { height: 48px; width: 48px; border-radius: 50%; } -.tweetSkeleton .content1, .tweetSkeleton .content2 { + +.tweetSkeleton .content1, +.tweetSkeleton .content2 { height: 50%; margin-top: 1rem; } + .tweetSkeleton .line { height: 25%; margin: 0.5rem 0; width: 100%; border-radius: .4rem; } + .tweetSkeleton .line:last-child { width: 75%; } + +.fullItemContainer { + margin-bottom: .5rem; +} + +.fullItemContainer:empty { + margin: 0; +} \ No newline at end of file