[#25] 브라우저 창 크기를 변경할 때 dropdown 및 modal layout 갱신 #32
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.
📝 작업 내용
absoluteposition으로top,left값을 설정해서 위치를 결정하기 때문에, 브라우저 창 크기가 변경될 때마다resizeevent handler에서 dropdown을 trigger한 요소의 위치를 기준으로 dropdown 위치를 다시 계산합니다.absolute가 아닌fixedposition으로 변경하여, 브라우저 창 크기가 줄어들어 스크롤이 되더라도 항상 브라우저 창 전체를 덮도록 고정합니다.📷 스크린샷 (선택)
다음 순서로 결과물을 직접 확인해 볼 수 있습니다.
feature/#25branch를 checkout 합니다. (local에 같은 이름의 branch 생성)npm run dev명령어로 프로젝트를 실행합니다./test-componentspath로 이동합니다.TextField를 클릭해서 dropdown을 열고 브라우저 창 크기를 바꿔가며 dropdown 위치가 잘 이동하는지 확인합니다.