2024. 07. 13 - 2024. 8. 27
+ {new Date(plan.start_date).toLocaleDateString()} -{' '}
+ {new Date(plan.end_date).toLocaleDateString()}
+
diff --git a/src/pages/Main.jsx b/src/pages/Main.jsx
index b09a533..3d1ac10 100644
--- a/src/pages/Main.jsx
+++ b/src/pages/Main.jsx
@@ -1,6 +1,13 @@
import React from 'react';
-import { useNavigate } from 'react-router-dom';
+import { useNavigate } from 'react-router-dom'; // useHistory 대신 useNavigate 사용
+
const Main = () => {
+ const navigate = useNavigate(); // useHistory 대신 useNavigate 사용
+
+ const handleButtonClick = () => {
+ navigate('/startplanroom'); // startplanroom으로 이동
+ };
+
const containerStyle = {
display: 'flex',
flexDirection: 'column',
@@ -32,94 +39,147 @@ const Main = () => {
};
const videoContainerStyle = {
- marginBottom: '40px',
- height: '300px',
- backgroundColor: '#ccc',
+ marginBottom: '50px',
+ height: '450px',
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
- fontSize: '1.5em',
- color: 'black',
};
- const cardContainerStyle = {
- display: 'flex',
- flexWrap: 'wrap',
- justifyContent: 'center',
- marginTop: '40px',
+ const videoStyle = {
+ width: '100%',
+ height: '100%',
+ borderRadius: '10px',
+ boxShadow: '0 4px 8px rgba(0, 0, 0, 0.2)',
};
- const cardStyle = {
+ const footerStyle = {
+ marginTop: '40px',
+ padding: '20px',
backgroundColor: '#343a40',
color: 'white',
+ textAlign: 'center',
+ width: '100%',
+ };
+
+ // 카드 컨테이너 1
+ const cardContainer1Style = {
+ backgroundColor: '#f8f9fa',
+ color: 'black',
+ borderRadius: '10px',
+ padding: '15px',
+ margin: '10px',
+ width: '350px',
+ display: 'flex',
+ flexDirection: 'column',
+ alignItems: 'center',
+ marginRight: '500px',
+ };
+
+ // 카드 컨테이너 2
+ const cardContainer2Style = {
+ backgroundColor: '#f8f9fa',
+ color: 'black',
borderRadius: '10px',
padding: '20px',
margin: '10px',
width: '300px',
- boxShadow: '0 4px 8px rgba(0, 0, 0, 0.2)',
display: 'flex',
flexDirection: 'column',
alignItems: 'center',
+ marginLeft: '500px',
+ marginTop:'-180px',
};
- const footerStyle = {
- marginTop: '40px',
+ // 카드 컨테이너 3
+ const cardContainer3Style = {
+ backgroundColor: '#f8f9fa',
+ color: 'black',
+ borderRadius: '10px',
padding: '20px',
- backgroundColor: '#343a40',
- color: 'white',
- textAlign: 'center',
- width: '100%',
+ margin: '10px',
+ width: '300px',
+ display: 'flex',
+ flexDirection: 'column',
+ alignItems: 'center',
+ marginRight: '500px',
+ marginTop:'-150px',
};
- const navigate = useNavigate();
+
+
+
+// 이미지 스타일 추가
+const image1Style = {
+ width: '100%', // 원하는 크기로 조정
+ height: '300PX',
+ position: 'relative', // 부모 요소의 position을 relative로 설정
+ left: '500px', // 카드 컨테이너와 같은 위치로 설정
+ top: '-250px', // 이미지 위치를 위로 올리기 위해 음수 값 설정
+};
+
+
+const image2Style={
+ width:'100%',
+ height:'300px',
+ position:'relative',
+ right:'480px',
+ top:'-250px',
+};
+
+const image3Style={
+ width:'100%',
+ height:'300px',
+ position:'relative',
+ left:'480px',
+ top:'-270px',
+};
- const handleOutClick = () => {
- navigate('/MakePlanRoom1');
- };
return (
국내 여행을 계획하고 있으신가요?
-
- 가볼까?와 동행자와 함께 여행을 빠르고 쉽게 계획할 수 있어요!
-
-
+
가볼까?와 동행자와 함께 여행을 빠르고 쉽게 계획할 수 있어요!
+
-
(서비스 소개 영상)
+
+
+
-
-
+
+
여행 동행자와 함께 여행 계획을!
-
- 가볼까에서는 모두 다함께 참여할 수 있어요! 더 이상 따로 찾고 따로
- 계획하지 않아도 돼요!
-
+
가볼까에서는 모두 다함께 참여할 수 있어요! 더 이상 따로 찾고 따로 계획하지 않아도 돼요!
+

{/* 이미지 추가 */}
-
+
+
가볼까의 주요 장점 제목 222
가볼까의 장점 설명글 가볼까의 장점 설명글 가볼까의 장점 설명글
+
-
+
+
가볼까의 주요 장점 제목 444
가볼까의 장점 설명글 가볼까의 장점 설명글 가볼까의 장점 설명글
+
);
};
-export default Main;
+export default Main;
\ No newline at end of file
diff --git a/src/pages/MakePlanRoom1.jsx b/src/pages/MakePlanRoom1.jsx
index c5f79ba..7256075 100644
--- a/src/pages/MakePlanRoom1.jsx
+++ b/src/pages/MakePlanRoom1.jsx
@@ -8,6 +8,7 @@ import 'react-calendar/dist/Calendar.css';
import 'react-time-picker/dist/TimePicker.css';
import { format } from 'date-fns';
import moment from 'moment';
+import axios from 'axios';
/*컨테이너 및 구역 나눔*/
const FullContainner = styled.div`
@@ -181,16 +182,22 @@ const Time = styled.div``;
function MakePlanRoom1() {
const [image, setImage] = useState(ImgUpload);
+ const [title, setTitle] = useState(''); // 여행 제목 상태 관리
+ const [explain, setExplain] = useState(''); // 여행 설명 상태 관리
const [dateRange, setDateRange] = useState([new Date(), new Date()]);
const [startDate, endDate] = dateRange;
const [startTime, setStartTime] = useState('00:00');
const [endTime, setEndTime] = useState('00:00');
const [showTime, setShowTime] = useState(false);
+ const [imageFile, setImageFile] = useState(null);
const fileInputRef = useRef(null);
+ const region='지역'; // MakePlanRoom2 이전에 미리 초기값 설정 (formData 넘기려고..)
+ const status=1;
const handleImageUpload = (event) => {
const file = event.target.files[0];
if (file) {
+ setImageFile(file);
setImage(URL.createObjectURL(file));
}
};
@@ -205,9 +212,48 @@ function MakePlanRoom1() {
const navigate = useNavigate();
- const handleLink = () => {
- navigate('/MakePlanroom2');
+ const handleLink = async (travelId) => {
+ const [startDate, endDate] = dateRange;
+ const token = localStorage.getItem('token');
+ console.log('JWT Token:', JSON.stringify(token));
+ // FormData 생성
+ const formData = new FormData();
+ formData.append('title', title);
+ formData.append('start_date', format(startDate, 'yyyy-MM-dd'));
+ formData.append('end_date', format(endDate, 'yyyy-MM-dd'));
+ formData.append('explain', explain);
+ formData.append('start_time', showTime ? startTime : '00:00');
+ formData.append('end_time', showTime ? endTime : '00:00');
+ formData.append('region', region); // 추가된 지역
+ formData.append('status', status);
+
+ if (image) {
+ formData.append('travel_image', imageFile); // 선택된 파일 추가
+
+ try {
+ const response = await axios.post('http://43.200.238.249:5000/travel-plans/makeRoom', formData, {
+ headers: {
+ 'Authorization': `Bearer ${token}`,
+ 'Content-Type': 'multipart/form-data',
+ },
+ });
+
+ const travelId = response.data.travel_id;
+ console.log('응답 데이터(FormData):', response.data);
+ console.log('여행 계획방 ID:', travelId);
+
+ navigate('/MakePlanroom2', { state: { travelId } });
+
+ } catch (error) {
+ console.error('에러 발생:', error.response ? error.response.data : error.message);
+ if (error.response) {
+ console.error('서버 응답 오류:', error.response.data);
+ }
+ }
+ }
};
+
+
return (
여행 계획방 만들기 (1/2)
@@ -241,12 +287,13 @@ function MakePlanRoom1() {
여행 제목
-
+ {setTitle(e.target.value)}}/>
여행 설명
diff --git a/src/pages/MakePlanRoom2.jsx b/src/pages/MakePlanRoom2.jsx
index 7af1f3c..e9b444b 100644
--- a/src/pages/MakePlanRoom2.jsx
+++ b/src/pages/MakePlanRoom2.jsx
@@ -1,6 +1,6 @@
import React, { useState } from 'react';
import styled from 'styled-components';
-import { useNavigate } from 'react-router-dom';
+import { useNavigate, useLocation } from 'react-router-dom';
import {
MapContainer as LeafletMapContainer,
TileLayer,
@@ -181,7 +181,8 @@ const route = [[37.5665, 126.978]];
function MakePlanRoom2() {
const [accommodation, setAccommodation] = useState('');
const [registeredAccommodations, setRegisteredAccommodations] = useState([]);
-
+ const location = useLocation();
+
const handleAddAccommodation = () => {
if (accommodation.trim() === '') return;
setRegisteredAccommodations([
@@ -209,7 +210,9 @@ function MakePlanRoom2() {
const navigate = useNavigate();
const handleLink = () => {
- navigate('/StartPlanRoom');
+ const travelId = location.state?.travelId; //MakePlanRoom1에서 받은 travelId
+
+ navigate('/StartPlanRoom', { state: { travelId }});
};
return (
diff --git a/src/pages/MyPage.jsx b/src/pages/MyPage.jsx
index 15db237..8b1710b 100644
--- a/src/pages/MyPage.jsx
+++ b/src/pages/MyPage.jsx
@@ -18,11 +18,11 @@ import {
Input,
Button,
StyledH2,
- WithdrawSection, // 추가된 컴포넌트
- NoticeBox, // 추가된 컴포넌트
- NoticeItem, // 추가된 컴포넌트
- Checkbox, // 추가된 컴포넌트
- WithdrawButton // 추가된 컴포넌트
+ WithdrawSection,
+ NoticeBox,
+ NoticeItem,
+ Checkbox,
+ WithdrawButton
} from '../styles/MyPagestyle';
const Mypage = () => {
@@ -79,7 +79,7 @@ const Mypage = () => {
{activeTab === 'memberInfo' && ( // 회원정보 버튼이 클릭되었을 때만 표시
- 회원 정보
+ 회원 정보
✏️
diff --git a/src/pages/PlanRoom1.jsx b/src/pages/PlanRoom1.jsx
index 8b8a506..a635b36 100644
--- a/src/pages/PlanRoom1.jsx
+++ b/src/pages/PlanRoom1.jsx
@@ -6,6 +6,7 @@ import ToggleListPlace from "../toggleLists/TogglesListPlace";
import ToggleListVote from "../toggleLists/ToggleListVote";
import MyPlaceModal from "../modals/MyPlaceModal";
import KakaoMap from "../components/KakaoMap";
+import axios from 'axios';
/*구역 나눔*/
const Container=styled.div`
@@ -264,9 +265,11 @@ function PlanRoom1(){
const [isModalOpen, setIsModalOpen] = useState(false); // 채팅 모달 상태
const [cursorPosition, setCursorPosition] = useState({ x: 0, y: 0 })
const [chatValue,setChatValue]=useState('');
+ const [lists,setLists]=useState([]);//나의 장소 불러오기
const inputRef = useRef(null);
const spanRef = useRef(null);
const navigate=useNavigate();
+ const token = localStorage.getItem('token');
const shareVoteDetails = (details) => {
setVoteDetails(details);
@@ -283,7 +286,6 @@ function PlanRoom1(){
const closeModal2 = () =>{
setModal2(false);
};
-
const handleListClick = (list) => {
if (selectedLists.includes(list)) {
setSelectedLists(selectedLists.filter((item) => item !== list));
@@ -291,11 +293,9 @@ function PlanRoom1(){
setSelectedLists([...selectedLists, list]);
}
};
-
const handleCandidate=()=>{
setCandidateList([...candidateList, `나의 후보 리스트 ${candidateList.length+1}`]);
};
-
const handlePlace=()=>{
setPlaceLists([...placeLists, inputValue]);
};
@@ -366,14 +366,28 @@ function PlanRoom1(){
const handleMouseMove = (e) => {
setCursorPosition({ x: e.clientX, y: e.clientY });
};
+ // const lists=[
+ // '나의 장소 리스트1','나의 장소 리스트2','나의 장소 리스트3','나의 장소 리스트4','나의 장소 리스트5','나의 장소 리스트6',];
- useEffect(() => {
- console.log("modal1 상태 변경:", modal1);
- }, [modal1]);
-
- const lists=[
- '나의 장소 리스트1','나의 장소 리스트2','나의 장소 리스트3','나의 장소 리스트4','나의 장소 리스트5','나의 장소 리스트6',];
-
+ /*백 연결*/
+ useEffect(()=>{
+ const fetchLists=async()=>{
+ try{
+ const response=await axios.get(
+ 'http://43.200.238.249:5000/users/lists',
+ {
+ headers: {
+ Authorization: `Bearer ${token}`,
+ },
+ }
+ );
+ setLists(response.data);
+ } catch (error) {
+ console.error('Error fetching lists:', error);
+ }
+ };
+ fetchLists();
+ }, [token]);
return(
@@ -415,7 +429,7 @@ function PlanRoom1(){
>
}
- {/*모달들*/}
+ {/*채팅, 모달들*/}
{isModalOpen && (
diff --git a/src/pages/PlanRoom2.jsx b/src/pages/PlanRoom2.jsx
index 44e1ad5..cdf6002 100644
--- a/src/pages/PlanRoom2.jsx
+++ b/src/pages/PlanRoom2.jsx
@@ -1,22 +1,27 @@
import React, { useState } from 'react';
+import { useNavigate, useLocation } from 'react-router-dom'; // useLocation 임포트
+import KakaoMap from '../components/KakaoMap'; // KakaoMap 컴포넌트 임포트
import { planroomStyle } from '../styles/PlanRoom2style';
/** @jsxImportSource @emotion/react */
-const PlanRoom2 = ({ selectedDates }) => {
- const [zoomLevel, setZoomLevel] = useState(1);
+const PlanRoom2 = () => {
+ const navigate = useNavigate(); // useNavigate 훅 사용
+ const location = useLocation(); // useLocation 훅 사용
+ const selectedDates = location.state?.selectedDates; // 전달된 날짜 정보 받기
+ const [zoomLevel, setZoomLevel] = useState(3); // 기본 줌 레벨 설정
const [expandedAccommodation, setExpandedAccommodation] = useState(false);
const [expandedCandidates, setExpandedCandidates] = useState(null);
const handleZoomIn = () => {
- setZoomLevel(prev => prev + 0.1);
+ setZoomLevel(prev => Math.min(prev + 1, 10)); // 최대 줌 레벨 제한
};
const handleZoomOut = () => {
- setZoomLevel(prev => Math.max(prev - 0.1, 1));
+ setZoomLevel(prev => Math.max(prev - 1, 1)); // 최소 줌 레벨 제한
};
const handleCompletePlan = () => {
- alert('여행 계획이 완료되었습니다!');
+ navigate('/planroomresult'); // PlanRoomResult 페이지로 이동
};
const handleAccommodationClick = () => {
@@ -32,13 +37,13 @@ const PlanRoom2 = ({ selectedDates }) => {
return (
여행 기간: {selectedDates}
-
-
-
-
-
-
+
{/* KakaoMap 컴포넌트 추가 */}
+
+
+
+
+
장소 정보
@@ -93,4 +98,4 @@ const PlanRoom2 = ({ selectedDates }) => {
);
};
-export default PlanRoom2;
+export default PlanRoom2;
\ No newline at end of file
diff --git a/src/pages/PlanRoomResult.jsx b/src/pages/PlanRoomResult.jsx
index 54d0fa1..781647e 100644
--- a/src/pages/PlanRoomResult.jsx
+++ b/src/pages/PlanRoomResult.jsx
@@ -13,6 +13,7 @@ import L from 'leaflet';
import OutImage from '../buttonimage/outbutton.png';
import prevImage from '../buttonimage/prebutton.png';
import DownImage from '../buttonimage/down.png';
+import ExdownImage from '../buttonimage/exdown.png';
import SaveImage from '../buttonimage/save.png';
import TravelImage from '../buttonimage/travel.png';
import RouteImage from '../buttonimage/route.png';
@@ -236,8 +237,8 @@ const Save = styled.button`
const Modal = styled.div`
display: ${(props) => (props.open ? 'block' : 'none')};
position: fixed;
- top: 70%;
- left: 80%;
+ top: 80%;
+ left: 70%;
transform: translate(-50%, -50%);
width: 400px;
padding: 20px;
@@ -274,6 +275,19 @@ const DownImageContainer = styled.div`
z-index: 1000;
`;
+const ExdownImageContainer = styled.div`
+ display: ${(props) => (props.show ? 'flex' : 'none')};
+ position: fixed;
+ top: 50%;
+ left: 50%;
+ transform: translate(-50%, -50%);
+ width: 300px;
+ height: 300px;
+ background: url(${ExdownImage}) no-repeat center center;
+ background-size: contain;
+ z-index: 1000;
+`;
+
// 기본 마커 아이콘 설정
delete L.Icon.Default.prototype._getIconUrl;
L.Icon.Default.mergeOptions({
@@ -323,18 +337,8 @@ function PlanRoomResult() {
const [activeRoute, setActiveRoute] = useState(1);
const [showTime, setShowTime] = useState(false);
const [isModalOpen, setIsModalOpen] = useState(false);
- const [isSaved, setIsSaved] = useState(false);
- const [showDownImage, setShowDownImage] = useState(false);
-
- useEffect(() => {
- let timer;
- if (showDownImage) {
- timer = setTimeout(() => {
- setShowDownImage(false);
- }, 1000);
- }
- return () => clearTimeout(timer); // Cleanup the timer on component unmount
- }, [showDownImage]);
+ const [isExcelDownload, setIsExcelDownload] = useState(false);
+ const [isImageDownload, setIsImageDownload] = useState(false);
const handleRouteClick = (routeId) => {
setActiveRoute(routeId);
@@ -344,6 +348,26 @@ function PlanRoomResult() {
setShowTime(!showTime);
};
+ useEffect(() => {
+ let timer;
+ if (isImageDownload) {
+ timer = setTimeout(() => {
+ setIsImageDownload(false);
+ }, 1000);
+ }
+ return () => clearTimeout(timer);
+ }, [isImageDownload]);
+
+ useEffect(() => {
+ let timer;
+ if (isExcelDownload) {
+ timer = setTimeout(() => {
+ setIsExcelDownload(false);
+ }, 1000);
+ }
+ return () => clearTimeout(timer);
+ }, [isExcelDownload]);
+
// 동선에 포함된 여행지만 필터링
const activeRouteLocations = activeRoute
? routes[activeRoute].map((point) =>
@@ -364,7 +388,7 @@ function PlanRoomResult() {
};
const handleSaveClick = () => {
- setIsModalOpen(true);
+ setIsModalOpen((prevState) => !prevState); // 현재 상태의 반대로 설정
};
const handleSaveAsImage = () => {
@@ -376,9 +400,8 @@ function PlanRoomResult() {
link.download = 'travel-plan.png';
link.click();
});
- setIsSaved(true);
setIsModalOpen(false);
- setShowDownImage(true);
+ setIsImageDownload(true);
};
const handleSaveAsExcel = () => {
@@ -407,9 +430,8 @@ function PlanRoomResult() {
// 엑셀 파일 생성 및 다운로드
XLSX.writeFile(wb, 'travel-plan.xlsx');
- setIsSaved(true);
setIsModalOpen(false);
- setShowDownImage(true);
+ setIsExcelDownload(true);
};
//장소위치조정
@@ -534,7 +556,8 @@ function PlanRoomResult() {
사진으로 저장
엑셀로 저장
-
+
+
);
}
diff --git a/src/pages/SignUp.jsx b/src/pages/SignUp.jsx
index e77ea2d..c259a79 100644
--- a/src/pages/SignUp.jsx
+++ b/src/pages/SignUp.jsx
@@ -5,7 +5,7 @@ import InputSignup from '../styles/input-signup'; // 사용자 정의 입력 컴
import SearchIcon from "../assets/images/searchIcon.png";
import { useNavigate } from 'react-router-dom';
-const API_URL = 'https://jsonplaceholder.typicode.com/users';
+const API_URL = 'http://43.200.238.249:5000/users/user'; // 서버 URL
const LogoImage = styled.img`
width: 280px;
@@ -80,7 +80,18 @@ const SignUp = () => {
const handlePassword = (event) => {
const value = event.target.value;
setPassword(value);
- setPasswordError(value.length < 4 ? "비밀번호는 4자리 이상이어야 합니다." : '');
+ const passwordPattern = /^(?=.*[a-zA-Z])(?=.*[0-9])(?=.*[!@#$%^&*?_])/;
+ if (!value) {
+ setPasswordError("비밀번호를 입력해주세요.");
+ } else if (value.length < 4) {
+ setPasswordError("비밀번호는 4자리 이상이어야 합니다.");
+ } else if (value.length > 12) {
+ setPasswordError("비밀번호는 최대 12자리까지 입력 가능합니다.");
+ } else if (!passwordPattern.test(value)) {
+ setPasswordError("비밀번호는 영어, 숫자, 특수문자를 포함해야 합니다.");
+ } else {
+ setPasswordError('');
+ }
};
const handleConfirmPassword = (event) => {
@@ -92,7 +103,7 @@ const SignUp = () => {
const handleSignup = async () => {
if (!emailError && !passwordError && !confirmPasswordError && isAgreed) {
try {
- const userData = { email, password };
+ const userData = { email, password, confirmPassword };
const response = await axios.post(API_URL, userData);
if (response.status === 201) {
console.log(response);
diff --git a/src/pages/home2.jsx b/src/pages/home2.jsx
index 6d52cbb..6c7574f 100644
--- a/src/pages/home2.jsx
+++ b/src/pages/home2.jsx
@@ -12,7 +12,11 @@ const Home2 = () => {
useEffect(() => {
const fetchData = async () => {
try {
- const response = await axios.get('');
+ const response = await axios.get('/travel-plans/myRooms', {
+ headers: {
+ Authorization: `Bearer
`,
+ },
+ });
setTravel(response.data);
} catch (error) {
console.error('Error:', error);
@@ -28,9 +32,9 @@ const Home2 = () => {
const sortedTravel = [...travel].sort((a, b) => {
if (sortOption === 'latest') {
- return new Date(b.date) - new Date(a.date);
+ return new Date(b.start_date) - new Date(a.start_date);
} else if (sortOption === 'name') {
- return a.name.localeCompare(b.name);
+ return a.title.localeCompare(b.title);
}
return 0;
});
diff --git a/src/redux/appWrapper.js b/src/redux/appWrapper.js
new file mode 100644
index 0000000..872eccb
--- /dev/null
+++ b/src/redux/appWrapper.js
@@ -0,0 +1,13 @@
+import React from 'react';
+import { BrowserRouter as Router } from 'react-router-dom';
+import App from '../App';
+
+const AppWrapper = () => {
+ return (
+
+
+
+ );
+};
+
+export default AppWrapper;
\ No newline at end of file
diff --git a/src/redux/dataSlice.js b/src/redux/dataSlice.js
new file mode 100644
index 0000000..1b0e72f
--- /dev/null
+++ b/src/redux/dataSlice.js
@@ -0,0 +1,34 @@
+import { createSlice, createAsyncThunk } from '@reduxjs/toolkit';
+import axios from 'axios';
+
+// 비동기 데이터 로딩을 위한 Thunk 생성
+export const fetchData = createAsyncThunk('data/fetchData', async () => {
+ const response = await axios.get('http://43.200.238.249:5000/your-endpoint');
+ return response.data;
+});
+
+export const dataSlice = createSlice({
+ name: 'data',
+ initialState: {
+ data: null,
+ status: 'idle',
+ error: null,
+ },
+ reducers: {},
+ extraReducers: (builder) => {
+ builder
+ .addCase(fetchData.pending, (state) => {
+ state.status = 'loading';
+ })
+ .addCase(fetchData.fulfilled, (state, action) => {
+ state.status = 'succeeded';
+ state.data = action.payload;
+ })
+ .addCase(fetchData.rejected, (state, action) => {
+ state.status = 'failed';
+ state.error = action.error.message;
+ });
+ },
+});
+
+export default dataSlice.reducer;
\ No newline at end of file
diff --git a/src/redux/store.js b/src/redux/store.js
new file mode 100644
index 0000000..953a3f6
--- /dev/null
+++ b/src/redux/store.js
@@ -0,0 +1,10 @@
+import { configureStore } from '@reduxjs/toolkit';
+import dataReducer from './dataSlice';
+
+export const store = configureStore({
+ reducer: {
+ data: dataReducer,
+ },
+});
+
+export default store;
\ No newline at end of file
diff --git a/src/styles/MyPagestyle.jsx b/src/styles/MyPagestyle.jsx
index 7830667..72724cc 100644
--- a/src/styles/MyPagestyle.jsx
+++ b/src/styles/MyPagestyle.jsx
@@ -18,13 +18,13 @@ export const Title = styled.h1`
export const StyledH2 = styled.h2`
font-size: 2rem; /* 원하는 글자 크기 */
- margin: 20px 0; /* 위 아래 여백 조정 */
- text-align: left; /* 제목을 왼쪽 정렬 */
+ margin: 30px 20px; /* 위 아래 여백 조정 */
+ text-align: center; /* 제목을 왼쪽 정렬 */
/* 필요에 따라 추가적인 스타일을 적용 */
`;
export const Tabs = styled.div`
- margin-bottom: 25px;
+ margin-bottom: 30px;
text-align: left;
justify-content: flex-start;
`;
@@ -46,24 +46,24 @@ export const TabButton = styled.button`
`;
export const ProfileSection = styled.div`
- text-align: left;
+ text-align: center;
background-color: #EDEDED;
- padding: 140px;
+ padding: 80px 40px 40px 40px; /* 위쪽 여백을 100px로 줄였습니다 */
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* box-shadow 추가 */
`;
export const ProfilePicture = styled.div`
display: flex;
- justify-content: left;
+ justify-content: center;
align-items: center;
margin-bottom: 60px; /* 간격 조정 */
`;
export const PicturePlaceholder = styled.div`
- width: 70px; /* 원의 크기 */
- height: 70px;
- border-radius: 50%;
+ width: 200px; /* 원의 크기 */
+ height: 200px;
+ border-radius:50%;
background-color: gray;
display: flex;
justify-content: center;
@@ -73,8 +73,8 @@ export const PicturePlaceholder = styled.div`
export const EditIcon = styled.div`
position: absolute; /* 부모 요소에 상대적으로 위치 */
- bottom: -5px; /* 아래로 살짝 이동 */
- right: -5px; /* 오른쪽으로 살짝 이동 */
+ bottom: -1px; /* 아래로 살짝 이동 */
+ right: -1px; /* 오른쪽으로 살짝 이동 */
background-color: white;
color: black;
border-radius: 50%;
@@ -85,13 +85,15 @@ export const EditIcon = styled.div`
export const InfoItem = styled.div`
margin-bottom: 30px;
display: flex;
- justify-content: left;
+ justify-content: center;
align-items: center;
+ flex-direction: column; /* 세로 정렬을 위해 추가 */
`;
export const InfoContent = styled.div`
display: flex;
align-items: center;
+ justify-content: center; /* 정보 내용 가운데 정렬 */
span {
margin-right: 10px;
@@ -153,9 +155,9 @@ export const ValidateButton = styled.button`
export const SecuritySection = styled.div`
background-color: #EDEDED;
- padding: 50px;
+ padding: 60px;
border-radius: 8px;
- text-align: left;
+ text-align: center;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* box-shadow 추가 */
`;
@@ -197,12 +199,22 @@ export const Button = styled.button`
}
`;
+export const Box = styled.div`
+ width: 100%;
+ margin-top: 10px;
+ padding: 10px;
+ background-color: #F0F0F0;
+ border-radius: 4px;
+ text-align: left; /* 텍스트 왼쪽 정렬
+ box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
+`;
+
// 추가된 스타일 컴포넌트
export const WithdrawSection = styled.div`
background-color: #EDEDED;
padding: 50px;
border-radius: 8px;
- text-align: left;
+ text-align: center;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* box-shadow 추가 */
`;
diff --git a/src/styles/PlanRoom2style.jsx b/src/styles/PlanRoom2style.jsx
index 5b1d15d..d03b373 100644
--- a/src/styles/PlanRoom2style.jsx
+++ b/src/styles/PlanRoom2style.jsx
@@ -17,10 +17,10 @@ export const planroomStyle = css`
.map-container {
width: 50%;
- height: 450px;
+ height: 400px;
background-color: lightgray;
position: relative;
- overflow: hidden;
+
}
.map {
diff --git a/src/styles/homestyle.jsx b/src/styles/homestyle.jsx
index bede26f..42532a2 100644
--- a/src/styles/homestyle.jsx
+++ b/src/styles/homestyle.jsx
@@ -5,7 +5,7 @@ const Home = () => {
const containerStyle = {
textAlign: 'center',
padding: '50px',
- backgroundColor: '#f8f9fa',
+ backgroundColor: '#ffffff',
};
const headingStyle = {