Skip to content
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

Layout 적용 및 23px Layout 컴포넌트 #107

Merged
merged 3 commits into from
May 21, 2023
Merged

Layout 적용 및 23px Layout 컴포넌트 #107

merged 3 commits into from
May 21, 2023

Conversation

hyesungoh
Copy link
Member

🤔 해결하려는 문제가 무엇인가요?

  • 좌우 패딩 레이아웃 적용

🎉 변경 사항

  • 기본 좌우 패딩을 16px_app에 적용했어요

  • 몇 페이지들에서 좌우 패딩이 23px인 요구사항이 있어요.
    이에 대응하기 위해 이야기를 나눴던 방향으로 LayoutPaddingTo23 컴포넌트를 만들었어요

🙏 여기는 꼭 봐주세요!

  • 최선인지는 고민이 됩니다 🤔

사용 방법

  • 좌우 패딩이 23px인 곳에서는 다음과 같이 사용할 수 있어요
import { type ReactElement } from 'react';

import LayoutPaddingTo23 from '~/components/layout/LayoutPaddingTo23';

export default function Home() {
  return <div>home</div>;
}

Home.getLayout = (page: ReactElement) => <LayoutPaddingTo23>{page}</LayoutPaddingTo23>;
  • 좌우 패딩이 16px인 곳에서는 사용하지 않아도 돼요

참고

https://nextjs.org/docs/pages/building-your-application/routing/pages-and-layouts

@hyesungoh hyesungoh added feat New feature or request style Change style or request it labels May 20, 2023
@hyesungoh hyesungoh self-assigned this May 20, 2023
@github-actions github-actions bot removed the style Change style or request it label May 20, 2023
@codecov-commenter
Copy link

Codecov Report

Patch and project coverage have no change.

Comparison is base (ebaa682) 98.23% compared to head (6cb6854) 98.23%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #107   +/-   ##
=======================================
  Coverage   98.23%   98.23%           
=======================================
  Files          35       35           
  Lines         226      226           
  Branches       37       37           
=======================================
  Hits          222      222           
  Misses          4        4           

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@github-actions
Copy link

Bundle Sizes

Compared against ebaa682

Route: No significant changes found

Dynamic import: None found.

@hyesungoh hyesungoh merged commit 071cc5d into main May 21, 2023
@hyesungoh hyesungoh deleted the style/layout branch May 21, 2023 06:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat New feature or request
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants