-
Notifications
You must be signed in to change notification settings - Fork 147
[항공사 웹사이트의 컴포넌트 접근성 높이기 - 1단계] 비녀(강윤호) 미션 제출합니다. #52
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
Conversation
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.
안녕하세요! 비녀 👋
전체적으로 깔끔하고 미션 요구사항도 잘 만족시켰다는 생각이 들었어요~
리뷰하면서 생각하는 것들 코멘트로 남겼습니다!
<> | ||
<S.Question aria-describedby='tooltip'>?</S.Question> | ||
<S.StyledTooltip aria-live='assertive' id='tooltip' role='tooltip'> | ||
국민은행 61210204071715로 후원해 결식아동을 도와보세요! |
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.
큰일납니다. 👮♂️
src/components/Tooltip.tsx
Outdated
const Tooltip = () => { | ||
return ( | ||
<> | ||
<S.Question aria-describedby='tooltip'>?</S.Question> |
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.
스크린 리더가 "물음표 버튼"이라고 하기 보단 성인에 대한 툴팁이라는 것을 알려줬으면 조금 더 편하지 않을까 생각했어요🤔
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.
aria-label
를 이용해서 tooltip button이라고 읽어주게 변경하였습니다!
import { createRoot } from 'react-dom/client'; | ||
import App from './App'; | ||
|
||
const container = document.getElementById('root')!; |
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.
오 뒤에 !는 처음보는데 뭐하는 건가요?
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.
무조건 null이나 undefined 아니라는 뜻입니다.
그냥 쓰면 document.getElement return 값이 있다는 것을 명시해줍니다. 없으면 type guard 해줘야해요
출처:https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-0.html
tsconfig.json
Outdated
"jsx": "react-jsx", | ||
"skipLibCheck": true, | ||
"incremental": true, | ||
"forceConsistentCasingInFileNames": true, |
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.
로컬에서 실행되지 않는 문제가 있었어요. 이 설정을 켜놓으면 윈도우에서는 모르겠지만 파일의 대소문자를 구분하지 않는 시스템인 맥에서는 에러가 발생한다고 합니다.
TypeScript는 실행 중인 파일 시스템의 대소문자 구분 규칙을 따릅니다. 일부 개발자는 대소문자를 구분하는 파일 시스템에서 작업하고 다른 개발자는 그렇지 않은 경우 문제가 될 수 있습니다.
https://www.typescriptlang.org/ko/tsconfig#forceConsistentCasingInFileNames
microsoft/TypeScript/issues 관련 이슈 16875
microsoft/TypeScript/issues 관련 이슈 50544
이 설정 끄니깐 실행되는 걸로 봐서, 같이 작업할 때는 설정을 추가해야하는지 고민이 되네요🤔
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.
아 crlf가 여기서 또 터졌군요.. 설정을 global로 해놓은줄 알았는데 수정하겟습니다
<S.Count | ||
type='number' | ||
min={1} | ||
max={3} |
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.
해당 속성을 추가했을 때와 하지 않았을 때 동작이 동작이 똑같은데 추가하신 이유가 있나요?
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.
min max를 추가해주면 스크린 리더가 읽어줄때 min max를 알려줍니다.
js로도 제한이 가능하지만 명시해주는게 더 시맨틱하다고 판단했습니다
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.
비녀! 리뷰 남겼어요~ 확인해줘요~
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.
비녀~ 수정하신거 잘봤습니다! approve할게요~
🔥 결과
직접 구현한 페이지를 작동시켜볼 수 있도록 접근 가능한 페이지 링크를 공유해주세요.
링크
✅ 요구사항 목록
1 Spin Button
2 Carousel
🧐 공유
/_ 작업하면서 든 생각, 질문, 새롭게 학습하거나 시도해본 내용 등등 공유할 사항이 있다면 자유롭게 적어주세요 _/
assertive 와 described by 를 같이 넣었어요.. 괜찮은지 모르겠네요
데모페이지가 뭔가 이상하네요... serve로 local에서 켜도 되고, webpack으로도 development로도 잘 돌아가는데 왜 pages로 하니까 잘 안될까요.. 정 안되면 s3로 해서 배포해드리겠습니다.