Skip to content

Commit 1503e05

Browse files
committed
feat: 디자인 추가
1 parent 4166b98 commit 1503e05

File tree

8 files changed

+7
-2
lines changed

8 files changed

+7
-2
lines changed

public/pets/PET_BACK.jpg

854 KB
Loading

public/pets/PET_BACK_1.png

304 KB
Loading

public/pets/PET_BACK_2.png

38.8 KB
Loading

public/pets/PET_BACK_3.png

29.5 KB
Loading

public/pets/PET_BACK_4.png

10.9 KB
Loading

public/pets/PET_BACK_5.png

210 KB
Loading

src/pages/Pets.css

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/* 전체 배경 설정 */
22
body {
3-
background-color: rgb(63, 178, 127);
3+
/*background-color: rgb(63, 178, 127);*/
4+
background: #f2f3b1;
45
margin: 0;
56
display: flex;
67
justify-content: center;
@@ -24,6 +25,10 @@ body {
2425
background-color: white;
2526
border-radius: 10px;
2627
overflow: hidden;
28+
background-image: url('/pets/PET_BACK_5.png');
29+
background-size: 800px auto; /* 가로 1000px, 세로는 비율 유지 */
30+
background-repeat: no-repeat; /* 배경 반복 제거 */
31+
background-position: center; /* 가운데 정렬 */
2732
}
2833

2934
/* 펫을 감싸는 div */

src/pages/Pets.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ const Pets = () => {
3333
const Pet = ({ src }) => {
3434
const getRandomPosition = () => ({
3535
x: Math.random() * 600 + 100,
36-
y: Math.random() * 400 + 100,
36+
y: Math.random() * 200 + 200,
3737
});
3838

3939
const [position, setPosition] = useState(getRandomPosition());

0 commit comments

Comments
 (0)