-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WeddingPage 추가, FileApi.upload 개선, FileApi.getMusic 추가
- Loading branch information
1 parent
beba123
commit cd40bad
Showing
4 changed files
with
43 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import React, {useEffect, useState} from 'react'; | ||
import Wedding from "@remote/value/Wedding"; | ||
import weddingApi from "@remote/api/WeddingApi"; | ||
import {useParams} from "react-router-dom"; | ||
import {Row} from "@designsystem/component/flexLayout"; | ||
import TemplateComponent from "@src/component/template/TemplateComponent"; | ||
|
||
function WeddingPage() { | ||
const {url} = useParams(); | ||
const [wedding, setWedding] = useState<Wedding>(); | ||
|
||
useEffect(() => { | ||
if (!url) return; | ||
|
||
(async () => { | ||
const {data} = await weddingApi.getWedding(url); | ||
setWedding(data); | ||
})(); | ||
}, []); | ||
|
||
return ( | ||
<Row $justifyContent={'center'}> | ||
{wedding && ( | ||
<TemplateComponent wedding={wedding}/> | ||
)} | ||
</Row> | ||
); | ||
} | ||
|
||
export default WeddingPage; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters