Skip to content

Commit

Permalink
Merge pull request #19 from /issues/18-feat-footer
Browse files Browse the repository at this point in the history
feat: フッターを追加
  • Loading branch information
SatooRu65536 authored Dec 26, 2024
2 parents ad575db + 3737561 commit 299e633
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 5 deletions.
14 changes: 14 additions & 0 deletions app/components/Footer/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { styled } from 'restyle';

const FooterStyled = styled('footer', {
padding: '5px',
color: 'var(--background-color)',
backgroundColor: 'var(--on-background-color)',
textAlign: 'center',
});

export default function Footer() {
return (
<FooterStyled>SET © 2025 Copyright.</FooterStyled>
);
}
9 changes: 4 additions & 5 deletions app/components/Header/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,16 @@ import { Link } from '@remix-run/react';
import { styled } from 'restyle';
import Avatar from './Avatar';

const HeaderBase = styled('header', {
const HeaderStyled = styled('header', {
padding: '0 20px',
backgroundColor: 'var(--on-background-color)',
display: 'flex',
alignItems: 'center',
justifyContent: 'space-between',
position: 'static',
top: 0,
left: 0,
right: 0,

backgroundColor: 'var(--on-background-color)',
});

const Title = styled(Link, {
Expand All @@ -30,12 +29,12 @@ const Menu = styled('div', {

export default function Header() {
return (
<HeaderBase>
<HeaderStyled>
<Title to="/">名簿システム</Title>

<Menu>
<Avatar />
</Menu>
</HeaderBase>
</HeaderStyled>
);
}
2 changes: 2 additions & 0 deletions app/root.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import type { AuthUser } from '@/services/auth.server';
import type { LinksFunction, LoaderFunctionArgs } from '@remix-run/cloudflare';
import AuthUserContext from '@/components/AuthtContext';
import Footer from '@/components/Footer';
import Header from '@/components/Header';
import GlobalStyles from '@/GlobalStyles';
import { getAuthenticator } from '@/services/auth.server';
Expand Down Expand Up @@ -60,6 +61,7 @@ export function Layout({ children }: { children: React.ReactNode }) {
<GlobalStyles />
<Header />
<main>{children}</main>
<Footer />
</AuthUserContext>
<ScrollRestoration />
<Scripts />
Expand Down

0 comments on commit 299e633

Please sign in to comment.