Remove single range restriction for selection interface apis
@sambandaru がすでに取り組んでいます。
2026年5月14日 から。
評価
この issue はまだ評価されていません。
説明
Proposal
Remove the single-range restriction from the Selection API. Allow addRange() to accumulate disjoint ranges, rangeCount to return values > 1, and getRangeAt(index) to accept index > 0. The API was designed for multiple ranges; this reverses the 2011 restriction. Chromium is pursuing implementation.
Explainer: MicrosoftEdge/MSEdgeExplainers — Multi-Range Selection (PR)
Canonical issue: #41 (open since Jan 2015)
Chromium feature request: issues.chromium.org/504686717
Webkit open bug: webkit.org/b/186465
Spec changes required
- Section 2 — Allow a collection of ranges instead of "a single range"
- Section 3,
addRange()Step 2 — Remove the abort; define accumulation/merge semantics - Section 3,
rangeCount— Allow values > 1 - Section 3,
getRangeAt()— Allow index > 0
Prior vendor interest
- Google/Blink (TPAC 2017): @yoichio — "As Google Chrome, we are interested in supporting multiple range" (minutes)
- Microsoft (2015): Ben Peters — "Layout order is not possible without multi-selection" (public-webapps)
- Mozilla/Gecko: Ships multi-range for 20+ years. Stable, no web-compat issues.
- #336 — Shadow DOM flat tree (TPAC 2024) acknowledges multi-range as a solution path
- #115 — Developer request for table column selection, closed as dup of #41
Request
Requesting discussion in the Web Editing WG to build consensus on removing this restriction.
- 主要言語
- HTML
- スター
- 49
- フォーク
- 30
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
w3c/selection-api のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
w3c/selection-api#354 ·
-
Agenda+
難易度 3/5 1〜2日 初心者へのやさしさ 48/100
w3c/selection-api#361 · コメント 2 件 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
w3c/selection-api#355 ·
-
the steps of Selection.extend() does not check whether the given offset is valid in the containerオープン
難易度 1/5 1時間未満 初心者へのやさしさ 55/100
w3c/selection-api#353 · コメント 1 件 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
w3c/selection-api#352 ·