-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #160 from ChubachiPT2024/feature/display-submissio…
…nSummaries Reviewページでのデータ取得
- Loading branch information
Showing
13 changed files
with
456 additions
and
195 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,26 @@ | ||
import { useNavigate } from 'react-router-dom' | ||
import { MdKeyboardDoubleArrowLeft } from 'react-icons/md' | ||
|
||
interface IPropsButton { | ||
href: string | ||
} | ||
|
||
// 戻るボタンを抽象化したコンポーネント | ||
export const BackButton: React.FC<IPropsButton> = ({ href }) => { | ||
const navigate = useNavigate() | ||
|
||
// 戻るボタンが押された時の処理 | ||
const handleBack = (href: string) => { | ||
navigate(href) | ||
} | ||
|
||
return ( | ||
<> | ||
<MdKeyboardDoubleArrowLeft | ||
className="w-12 h-12 cursor-pointer transition duration-200 ease-in-out hover:scale-150" | ||
color={'#a9a9a9'} | ||
onClick={() => handleBack(href)} | ||
/> | ||
</> | ||
) | ||
} |
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,25 @@ | ||
import { useNavigate } from 'react-router-dom' | ||
|
||
const Error = () => { | ||
const navigate = useNavigate() | ||
return ( | ||
<> | ||
<div | ||
className="flex justify-center items-center h-screen" | ||
aria-label="読み込み中" | ||
> | ||
<div className="text-center"> | ||
<h1 className="text-2xl mb-5">エラーが発生しました</h1> | ||
<button | ||
className="bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded" | ||
onClick={() => navigate('/')} | ||
> | ||
ホームへ戻る | ||
</button> | ||
</div> | ||
</div> | ||
</> | ||
) | ||
} | ||
|
||
export default Error |
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,12 @@ | ||
const Loading = () => { | ||
return ( | ||
<div | ||
className="flex justify-center items-center h-screen" | ||
aria-label="読み込み中" | ||
> | ||
<div className="animate-spin h-10 w-10 border-4 border-blue-500 rounded-full border-t-transparent"></div> | ||
</div> | ||
) | ||
} | ||
|
||
export default Loading |
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
Oops, something went wrong.