-
-
Notifications
You must be signed in to change notification settings - Fork 2
[FR-305] Fix: Embeds are not properly responsive #64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from 8 commits
1c36fc0
50b21b8
9119eb5
ee4dca5
3c09131
8aba1fb
be6af5b
2ce0c6e
575af23
7978c48
5c3131b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -148,13 +148,21 @@ function Embed({ embed, images }: EmbedProps) { | |
/> | ||
)} | ||
{images && images.length > 0 && ( | ||
<Styles.Images nImages={images.length as 1 | 2 | 3 | 4}> | ||
{images.map((image) => ( | ||
<Styles.ImageGridImageContainer key={image.url}> | ||
<EmbeddedImage embedImage={image} withMargin /> | ||
</Styles.ImageGridImageContainer> | ||
))} | ||
</Styles.Images> | ||
// <Styles.Images nImages={images.length}> | ||
// {images.map((image) => ( | ||
// <Styles.ImageGridImageContainer key={image.url}> | ||
// <EmbeddedImage embedImage={image} withMargin /> | ||
// </Styles.ImageGridImageContainer> | ||
// ))} | ||
// </Styles.Images> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why not just remove it? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd personally opt for making a const like since we may want to allow showing 4 images at some point |
||
<EmbeddedImage | ||
embedImage={images[0]} | ||
withMargin | ||
image={images[0]} | ||
width={images[0].width} | ||
height={images[0].height} | ||
type="EmbedImage" | ||
/> | ||
)} | ||
|
||
{(embed.footer || embed.timestamp) && ( | ||
|
Uh oh!
There was an error while loading. Please reload this page.