Skip to content
This repository has been archived by the owner on Jun 10, 2024. It is now read-only.

Commit

Permalink
fix: styles for sceneCard
Browse files Browse the repository at this point in the history
  • Loading branch information
rostyslavvnahornyi committed Sep 25, 2023
1 parent 07f2934 commit 99c8882
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
9 changes: 8 additions & 1 deletion src/components/components/SceneCard/SceneCard.component.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,14 @@ const SceneCard = ({ scenesData, handleSceneClick }) => (
onClick={() => handleSceneClick(scene)}
title={scene.data().title}
>
<img src={ScenePlaceholder} alt="scene" className={styles.img} />
<div
className={styles.img}
style={{
backgroundImage: `url(${ScenePlaceholder})`,
backgroundSize: 'cover',
backgroundPosition: 'center'
}}
/>
<p className={styles.title}>{scene.data().title}</p>
<p className={styles.date}>
<LastModified timestamp={scene.data().updateTimestamp} />
Expand Down
8 changes: 4 additions & 4 deletions src/components/components/SceneCard/SceneCard.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@
.img {
margin-bottom: 6px;
object-fit: cover;
width: 246px;
height: 144px;
width: 272px;
height: 204px;
}

.card {
border-radius: 4px;
border: 1px solid rgba(237, 235, 239, 0.2);
padding: 8px 8px 12px 8px;
width: 246px;
height: 187px;
width: 272px;
height: 275px;
position: relative;
cursor: pointer;

Expand Down

0 comments on commit 99c8882

Please sign in to comment.