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

타이머 기능 추가 #17

Merged
merged 6 commits into from
Dec 2, 2023
Merged

타이머 기능 추가 #17

merged 6 commits into from
Dec 2, 2023

Conversation

sumi-0011
Copy link
Member

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

  • 타이머 기능을 추가했습니다. 10분 -> 0초 까지

🎉 변경 사항

  • 타이머 상태를 useTimerStaus 훅을 만들어 관리하고 있어요
  • 타이머 로직은 useTimer 훅을 만들어 기능을 구현하고, 화면에 보여줄 formmat 된 time 만을 내보내고 있어요.

🙏 여기는 꼭 봐주세요!

  • timer 상태에 따라 배경을 바꿔야해서 layout.tsx 부분을 수정했는데, 맘에 들지 않아요.. 근데 와프 후 디자인이 변경되면 수정되어야 하는 부분이라 해당 이슈는 패쓰 부탁드립니다.

🌄 스크린샷

스크린샷 2023-12-02 오전 12 49 59

@sumi-0011 sumi-0011 self-assigned this Dec 1, 2023
@sumi-0011 sumi-0011 linked an issue Dec 1, 2023 that may be closed by this pull request
Copy link
Member

@JUNOSHON JUNOSHON left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good!!

Copy link
Collaborator

@wade3420 wade3420 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

수고하셨습니다!

import { css } from '@styled-system/css';

export default function TimerPage() {
const { step, stepLabel, onNextStep } = useTimerStatus();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UI 상태를 step으로 나눈것 배워갑니다! 훅에서 관리하니까 편한것 같아요

return (
<div
className={css(bgCss, {
background: step === 'stop' ? '#F2F4F6' : 'linear-gradient(136deg, #FFF1F2 4.76%, #E9EFFF 89.58%)',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

마이너) background 값들을 각각 상수화 하면 나중에 변경시 편할 것 같은 어떻게 생각하시나요?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

마이너) background 값들을 각각 상수화 하면 나중에 변경시 편할 것 같은 어떻게 생각하시나요?

좋아요! 상수화를 하거나 theme에 추가하면 좋을 것 같습니다!
나중에 디자인 시스템을 전달받으면서 같이 변경하면 좋을 것 같아요 :D

@sumi-0011 sumi-0011 changed the base branch from develop to feat/timer December 2, 2023 05:16
@sumi-0011 sumi-0011 changed the base branch from feat/timer to develop December 2, 2023 05:31
@sumi-0011 sumi-0011 merged commit 738b3bd into develop Dec 2, 2023
1 check passed
@JUNOSHON JUNOSHON deleted the feat/timer-logic branch December 9, 2023 06:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feat] 타이머 기능 구현
3 participants