Skip to content

Commit

Permalink
[Fix] kdt-8-4#3, kdt-8-4#14 게시물 관련 웹 크기 맞게 디자인 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
hyeiis committed Mar 31, 2024
1 parent b8a6a4a commit c42a38d
Show file tree
Hide file tree
Showing 9 changed files with 40 additions and 54 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export default function EditHeader(boardId: BOARDID) {
}

return (
<div className="fixed w-full top-0 z-10">
<div className="absolute w-full top-0 z-10">
<Header
title="수정하기"
buttonStyleCase={ButtonStyle.TEXT_BTN}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export default function UploadHeader() {
}

return (
<div className="fixed w-full top-0 z-10">
<div className="absolute w-full top-0 z-10">
<Header
title="등록하기"
buttonStyleCase={ButtonStyle.TEXT_BTN}
Expand Down

This file was deleted.

This file was deleted.

28 changes: 28 additions & 0 deletions weatherfit_refactoring/src/Components/Molecules/post/Weather.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
import Image from 'next/image'
import { WeatherIcon } from '@/Store/WeatherIcon'

export default function Weather({
initialWeatherIcon,
}: {
initialWeatherIcon?: FEEDDATA_detail['weatherIcon']
}) {
const { weatherIcon } = WeatherIcon()
return (
<div className="flex mb-3 items-center w-fit">
<p className="font-gmarketsans pt-[5px] mr-3 text-sm">
{initialWeatherIcon ? '업로드 당시 날씨' : '업로드 날씨'}
</p>
<Image
src={
initialWeatherIcon
? initialWeatherIcon
: `https://openweathermap.org/img/wn/${weatherIcon}.png`
}
alt="날씨"
width={20}
height={20}
loading="lazy"
/>
</div>
)
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import EditWeather from '../../Molecules/post/EditWeather'
import Weather from '../../Molecules/post/Weather'
import TextAreaMolecule from '../../Molecules/post/TextAreaMolecule'
import EditHeader from '../../Molecules/header/EditHeader'
import ImageUpload from '../../Molecules/post/ImageUpload'
Expand All @@ -16,9 +16,9 @@ export default async function EditOrganism({ boardId }: BOARDID) {
return (
<div className="h-screen">
<EditHeader boardId={boardId} />
<main className="mx-5 h-full mt-[50px]">
<main className="mx-5 h-full mt-[50px] overflow-y-auto">
<div className="flex-col items-center justify-center mb-7">
<EditWeather weatherIcon={data.weatherIcon} />
<Weather initialWeatherIcon={data.weatherIcon} />
<ImageUpload images={data.images} mode="edit" />
</div>
<TextAreaMolecule initContent={data.content} mode="edit" />
Expand Down
4 changes: 3 additions & 1 deletion weatherfit_refactoring/src/Components/WebView/WebView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ export default function WebView({ children }: { children: ReactNode }) {
디자인 같이 해주세요ㅠㅠ
</div>
</aside>
<div className="w-[400px] min-h-[844px] border-2">{children}</div>
<div className="w-[400px] min-h-[844px] border-2 relative">
{children}
</div>
</div>
</div>
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export default function Edit({ params }: { params: { id: string } }) {
const { id: boardId } = params

return (
<div className="h-screen">
<div className="h-screen ">
<EditOrganism boardId={boardId} />
</div>
)
Expand Down
7 changes: 3 additions & 4 deletions weatherfit_refactoring/src/app/upload/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,14 @@ import ImageUpload from '@/Components/Molecules/post/ImageUpload'
import TextAreaMolecule from '@/Components/Molecules/post/TextAreaMolecule'
import SelectCategory from '@/Components/Molecules/post/SelectCategory'
import UploadHeader from '@/Components/Molecules/header/UploadHeader'
import UploadWeather from '@/Components/Molecules/post/UploadWeather'
import Weather from '@/Components/Molecules/post/Weather'
import Loading from '@/Components/Molecules/check/Loading'
import NoLogin from '@/Components/Molecules/check/NoLogin'
import { LoadingStore } from '@/Store/Loading'
import { CheckStore } from '@/Store/Check'
import { AuthTokenStore } from '@/Store/AuthToken'
import { loginCheck } from '@/utils/function/utilFunction'
import { useEffect } from 'react'
import NavBar from '@/Components/Molecules/bar/NavBar'

export default function Upload() {
const { loading, setLoading } = LoadingStore()
Expand All @@ -33,9 +32,9 @@ export default function Upload() {
{check ? (
<div className="h-screen">
<UploadHeader />
<main className="mx-5 h-full mt-[50px]">
<main className="mx-5 h-full mt-[50px] overflow-y-auto">
<section className="flex-col items-center justify-center mb-7">
<UploadWeather />
<Weather />
<ImageUpload mode="upload" />
</section>
<TextAreaMolecule mode="upload" />
Expand Down

0 comments on commit c42a38d

Please sign in to comment.