케이스 ce-0008-selection-collapses-on-click-outside-ko · 시나리오 scenario-selection-collapse-on-blur

contenteditable 외부 클릭 시 선택 영역이 예상치 못하게 축소됨

OS: macOS Ubuntu 22.04 기기: Laptop Any 브라우저: Safari 120.0 키보드: US 초안
selectioncaret

현상

contenteditable 요소 내부에서 텍스트 범위가 선택된 상태에서 요소 외부를 클릭하면 선택이 완전히 지워지는 대신 편집 가능한 영역 내부의 캐럿 위치로 축소됩니다.

재현 예시

  1. 편집 가능한 영역에 포커스합니다.
  2. 여러 줄에 걸쳐 몇 단어를 입력합니다.
  3. 한 줄의 일부 또는 여러 줄을 선택하기 위해 드래그합니다.
  4. 편집 가능한 영역 외부(예: 페이지 배경)를 클릭합니다.

관찰된 동작

  • 선택이 편집 가능한 요소 내부의 단일 캐럿 위치로 축소됩니다.
  • 범위가 지워지지 않아 시각적 피드백에 의존하는 사용자에게 혼란을 줄 수 있습니다.

예상 동작

  • 요소가 포커스를 잃을 때 선택이 완전히 지워지거나, 최소한 동일한 브라우저와 OS 조합에서 네이티브 텍스트 필드와 유사하게 동작해야 합니다.

참고사항

  • 이 동작은 선택 상태에 바인딩된 키보드 단축키(예: 복사 또는 삭제)에 영향을 줄 수 있습니다.

Playground for this case

Use the reported environment as a reference and record what happens in your environment while interacting with the editable area.

Reported environment
OS: macOS Ubuntu 22.04
Device: Laptop Any
Browser: Safari 120.0
Keyboard: US
Your environment
Sample HTML:
Event log
Use this log together with the case description when filing or updating an issue.
0 events
Interact with the editable area to see events here.