Skip to content

v1.1.0

Choose a tag to compare

@github-actions github-actions released this 27 Oct 22:18
· 13 commits to main since this release

Added

  • InteractivePage.SetTextContent, SetClassName, AddClass, RemoveClass, ToggleClass, SetAttribute, RemoveAttribute, GetTextContent, GetClassName and GetAttribute: change the text of an element with one text node, and classes and attributes (disabled, hidden, style, checked, value, href, tabindex, name ...) of HTML elements, after the page was created. The page restyles, lays out and paints incrementally where it can (otherwise it is built again from the edited document), keeps focus, hover, scroll and form state, moves focus off an element that stops being focusable, and equals a page created from the equivalent HTML. Text changes allocate nothing once warm; class and attribute changes make a new OneHtml document snapshot (about 0.8 MB on a 1,800-node page; attributes a control reads when its boxes are made, such as value, checked and type, rebuild the page, about 7 MB). Use text, transform, opacity or a hover rule for per-frame changes. See docs/game-hosts.md.

Fixed

  • A radio group whose checked radio is the page's first tab stop kept the wrong stop (the first or last radio instead of the checked one).
  • InteractivePage.SetValue threw a NullReferenceException on a text control that had never been focused.