we (web engine): Experimental web browser project to understand the limits of Claude

Form element parsing and DOM interfaces #147

open opened by pierrelf.com

Summary#

Add HTML form-related elements to the parser and DOM tree, and implement their DOM interfaces.

Elements to support#

  • <form>HTMLFormElement
  • <input>HTMLInputElement (types: text, password, checkbox, radio, submit, reset, hidden, number, email, url, search, tel)
  • <textarea>HTMLTextAreaElement
  • <select>HTMLSelectElement
  • <option>HTMLOptionElement
  • <optgroup>HTMLOptGroupElement
  • <button>HTMLButtonElement
  • <label>HTMLLabelElement
  • <fieldset>HTMLFieldSetElement
  • <legend>HTMLLegendElement

Acceptance criteria#

  • HTML parser tokenizes and tree-builds all listed elements correctly
  • DOM nodes expose element-specific attributes (e.g., input.type, input.value, input.name, form.action, form.method, textarea.rows, select.multiple)
  • HTMLFormElement.elements returns a collection of associated form controls
  • HTMLInputElement.form, HTMLSelectElement.form, etc. return the owning form
  • <label> for attribute resolves to the labeled control
  • Unit tests cover parsing and attribute access for each element type

Notes#

This is the foundation issue for Phase 16. All other form issues depend on this.

sign up or login to add to the discussion
Labels

None yet.

assignee

None yet.

Participants 1
AT URI
at://did:plc:meotu43t6usg4qdwzenk4s2t/sh.tangled.repo.issue/3mihoxg4tl72h