-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FE] アカウントの切り替え動線を追加 #648
Merged
Merged
[FE] アカウントの切り替え動線を追加 #648
Changes from 1 commit
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import type { ComponentProps, FC } from "react"; | ||
import colors from "tailwindcss/colors"; | ||
|
||
export const AccountSwitchIcon: FC<ComponentProps<"svg">> = function (props) { | ||
return ( | ||
<svg | ||
xmlns="http://www.w3.org/2000/svg" | ||
height="24px" | ||
width="24px" | ||
viewBox="0 -960 960 960" | ||
fill={colors.neutral[500]} | ||
{...props} | ||
> | ||
<path d="M160-160v-80h110l-16-14q-52-46-73-105t-21-119q0-111 66.5-197.5T400-790v84q-72 26-116 88.5T240-478q0 45 17 87.5t53 78.5l10 10v-98h80v240H160Zm400-10v-84q72-26 116-88.5T720-482q0-45-17-87.5T650-648l-10-10v98h-80v-240h240v80H690l16 14q49 49 71.5 106.5T800-482q0 111-66.5 197.5T560-170Z" /> | ||
</svg> | ||
); | ||
}; | ||
|
||
// https://github.com/google/material-design-icons/blob/master/LICENSE |
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,19 @@ | ||
import type { ComponentProps, FC } from "react"; | ||
import colors from "tailwindcss/colors"; | ||
|
||
export const AccountIcon: FC<ComponentProps<"svg">> = function (props) { | ||
return ( | ||
<svg | ||
xmlns="http://www.w3.org/2000/svg" | ||
height="24px" | ||
width="24px" | ||
viewBox="0 -960 960 960" | ||
fill={colors.neutral[500]} | ||
{...props} | ||
> | ||
<path d="M234-276q51-39 114-61.5T480-360q69 0 132 22.5T726-276q35-41 54.5-93T800-480q0-133-93.5-226.5T480-800q-133 0-226.5 93.5T160-480q0 59 19.5 111t54.5 93Zm246-164q-59 0-99.5-40.5T340-580q0-59 40.5-99.5T480-720q59 0 99.5 40.5T620-580q0 59-40.5 99.5T480-440Zm0 360q-83 0-156-31.5T197-197q-54-54-85.5-127T80-480q0-83 31.5-156T197-763q54-54 127-85.5T480-880q83 0 156 31.5T763-763q54 54 85.5 127T880-480q0 83-31.5 156T763-197q-54 54-127 85.5T480-80Zm0-80q53 0 100-15.5t86-44.5q-39-29-86-44.5T480-280q-53 0-100 15.5T294-220q39 29 86 44.5T480-160Zm0-360q26 0 43-17t17-43q0-26-17-43t-43-17q-26 0-43 17t-17 43q0 26 17 43t43 17Zm0-60Zm0 360Z" /> | ||
</svg> | ||
); | ||
}; | ||
|
||
// https://github.com/google/material-design-icons/blob/master/LICENSE |
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,29 @@ | ||
import type { MetaFunction } from "@remix-run/node"; | ||
import { useNavigate } from "@remix-run/react"; | ||
import colors from "tailwindcss/colors"; | ||
import { AccountSwitchIcon } from "~/components/icon/account-switch"; | ||
import { Button } from "~/components/primitives/button/button"; | ||
|
||
export const meta: MetaFunction = () => { | ||
return [ | ||
{ title: "User | ISURIDE" }, | ||
{ name: "description", content: "ユーザーページ" }, | ||
]; | ||
}; | ||
|
||
export default function Index() { | ||
const navigate = useNavigate(); | ||
|
||
return ( | ||
<section className="mx-8 flex-1"> | ||
<h2 className="text-xl my-6">ユーザー</h2> | ||
<Button | ||
className="w-full flex items-center justify-center " | ||
onClick={() => navigate("/client/register")} | ||
> | ||
<AccountSwitchIcon className="me-1" fill={colors.neutral[600]} /> | ||
ユーザーを切り替える | ||
</Button> | ||
</section> | ||
); | ||
} |
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
細かいですが他に揃えてArrowFunctionにしてもらえたりしますか?