wvlet / airframe

Essential Building Blocks for Scala

Home Page:https://wvlet.org/airframe

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

rx-html: Remove added DOM attributes at cancel

xerial opened this issue · comments

var selected = Rx.variable("Home")

selected.map { current =>
  Seq("Home", "Edit", ..).map { x =>
    div(
     (cls += "active").when(x == current)
      x
    )
  )
}

The active style will not be removed properly even when the selected value is updated.