Skip to content

Commit

Permalink
Merge pull request #27 from ethanknights/fix/enable-no-image-card
Browse files Browse the repository at this point in the history
Allow empty backgroundImage property on cards in TSX
  • Loading branch information
gamcoh authored May 10, 2024
2 parents 4d6e31f + 9a99cf8 commit 3ad91e4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion streamlit_card/frontend/src/stCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class Card extends StreamlitComponentBase {
height: `${height}px`,
borderRadius: "20px",
overflow: "hidden",
backgroundImage: `url(${image})`,
backgroundImage: image ? `url(${image})` : "none",
backgroundPosition: "center",
backgroundSize: "cover",
backgroundRepeat: "no-repeat",
Expand Down

0 comments on commit 3ad91e4

Please sign in to comment.