DataTable nests `<form>` inside `<form>`
オープン
まだ誰も着手していません。
bug
- 主要言語
- Ruby
- スター
- 1k
- フォーク
- 67
- 平均マージ
- 3日 12時間
- マージ済み PR(30日)
- 14
説明
- Where:
DataTableFormwraps the table;DataTableSearchand
DataTablePerPageSelecteach render their own<form>inside it.
Snapshotdata_table/full_frameholds three<formelements. - Effect: nested forms are invalid HTML. A browser ignores the inner
<form>start tags when a form is in scope, so the search input and the
per-page select become children of the outer bulk form, and
this.form.requestSubmit()indata_table_search_controller.jssubmits
the wrong form. - Fix: render the search and per-page forms outside the bulk form, or
make their controls reference it with theform=attribute; re-record (on the 2.0 line)
data_table/*. - 2.0 note: Herb's
NestingValidatorwill likely reject this at compile
time, which makes it a template adjustment in the DataTable migration.
Fixing it on 1.6 first keeps the migration a pure port.
Surfaced by the golden HTML suite (PR #536), which pins what 1.6 renders today — this defect included. Per maintainer decision (2026-09-19) main stays as is: this is addressed on the 2.0 line, and the golden snapshot that pins it is re-recorded there with the diff reviewed.
Source: design/v2/follow-up-issues.md.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
DataTableForm、DataTableSearch、DataTablePerPageSelect、data_table_search_controller.js から始め、次に data_table/full_frame スナップショットとその他の data_table スナップショットを調べます。レンダリングされたフォームの構造と、requestSubmit() が送信先を選択する方法を確認します。2.0 テンプレートがフォームの入れ子を避け、data_table/* スナップショットが修正後の出力で再記録され、レビュー済みになれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- javascript, ruby
- 領域
- frontend, testing
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 活発
- 明瞭さ
- 明確に書かれている
- 初心者へのやさしさ
- 68/100