refactor(Toast): Toast 컴포넌트 storybook 및 접근성 개선 #281
+216
−94
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.
변경사항
Toast 컴포넌트 Story명을 변경하였으며, description을 구체화했습니다.
기존 toast prop 중 action이 객체 형태여서 스토리북에 나타낼 땐 이에 대한 기능을 구체적으로 확인하지 못했는데, 이 객체 부분을
actionName
,onActionClick
의 두 개의 prop으로 나타내어 평면화함으로써 각각의 prop이 어떤 역할을 하는지 명시하고, 제어 가능하도록 수정했습니다.또한 Toast 구현부에서
aria-live
속성을 통해 동적인 변경 부분(Toast 문구)을 감지해서 알려줄 수 있도록 했으며,aria-atomic: true
을 통해 변경된 부분 전체를 읽도록 속성을 추가했습니다시급한 정도
🏃♂️ 보통 : 최대한 빠르게 리뷰 부탁드립니다.