package pl.treksoft.kvision import pl.treksoft.kvision.basic.Label import pl.treksoft.kvision.core.Container import pl.treksoft.kvision.core.Img import pl.treksoft.kvision.core.Root import pl.treksoft.kvision.dropdown.DD.* import pl.treksoft.kvision.dropdown.DropDown import pl.treksoft.kvision.html.* import pl.treksoft.kvision.html.TAG.H1 import pl.treksoft.kvision.routing.routing class Showcase : ApplicationBase() { override fun start(state: Map) { val root = Root("showcase") val container = Container(setOf("abc", "def")) val h1 = Tag(H1, "To jest test pisania tekstu", false, ALIGN.NONE, classes = setOf("test", "test2")) container.add(h1) val label = Label("KVLabel1") container.add(label) val label2 = Label("KVLabel2") container.add(label2) root.add(container) label.hide() label.show() val link = Link("test", "http://www.google.pl") link.add(Tag(TAG.P, "Cośtam")) root.add(link) val dd = DropDown("Dropdown", listOf("abc" to "#!/x", "def" to "#!/y"), "flag") root.add(dd) dd.setEventListener