aboutsummaryrefslogtreecommitdiff
path: root/kvision-modules/kvision-bootstrap/src
diff options
context:
space:
mode:
authorRobert Jaros <rjaros@finn.pl>2019-10-25 20:46:42 +0200
committerRobert Jaros <rjaros@finn.pl>2019-10-25 20:46:42 +0200
commitc78775aa2aaf76f9fa1404ff32a10fb8227f380e (patch)
treea6991e1f520e1ce54679b2194a756203a645f99e /kvision-modules/kvision-bootstrap/src
parenta990385dd3f2dbac4807b7a9498271efb3519c0d (diff)
downloadkvision-c78775aa2aaf76f9fa1404ff32a10fb8227f380e.tar.gz
kvision-c78775aa2aaf76f9fa1404ff32a10fb8227f380e.tar.bz2
kvision-c78775aa2aaf76f9fa1404ff32a10fb8227f380e.zip
Style fixes
Diffstat (limited to 'kvision-modules/kvision-bootstrap/src')
-rw-r--r--kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/dropdown/DropDown.kt10
-rw-r--r--kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/modal/Modal.kt1
-rw-r--r--kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/navbar/Navbar.kt1
-rw-r--r--kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/window/Window.kt1
4 files changed, 4 insertions, 9 deletions
diff --git a/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/dropdown/DropDown.kt b/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/dropdown/DropDown.kt
index 342a8e84..891cd226 100644
--- a/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/dropdown/DropDown.kt
+++ b/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/dropdown/DropDown.kt
@@ -377,12 +377,10 @@ internal class DropDownButton(
}
override fun getSnClass(): List<StringBoolPair> {
- return if (forNavbar) {
- listOf("nav-link" to true, "dropdown-toggle" to true)
- } else if (forDropDown) {
- super.getSnClass() + listOf("dropdown-item" to true, "dropdown-toggle" to true)
- } else {
- super.getSnClass() + ("dropdown-toggle" to true)
+ return when {
+ forNavbar -> listOf("nav-link" to true, "dropdown-toggle" to true)
+ forDropDown -> super.getSnClass() + listOf("dropdown-item" to true, "dropdown-toggle" to true)
+ else -> super.getSnClass() + ("dropdown-toggle" to true)
}
}
diff --git a/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/modal/Modal.kt b/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/modal/Modal.kt
index 08fc7aa8..b064e30c 100644
--- a/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/modal/Modal.kt
+++ b/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/modal/Modal.kt
@@ -25,7 +25,6 @@ import com.github.snabbdom.VNode
import pl.treksoft.kvision.core.Component
import pl.treksoft.kvision.core.Container
import pl.treksoft.kvision.core.StringBoolPair
-import pl.treksoft.kvision.core.StringPair
import pl.treksoft.kvision.core.Widget
import pl.treksoft.kvision.html.Button
import pl.treksoft.kvision.html.TAG
diff --git a/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/navbar/Navbar.kt b/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/navbar/Navbar.kt
index 92f8832d..68975f8d 100644
--- a/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/navbar/Navbar.kt
+++ b/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/navbar/Navbar.kt
@@ -29,7 +29,6 @@ import pl.treksoft.kvision.core.StringBoolPair
import pl.treksoft.kvision.core.StringPair
import pl.treksoft.kvision.html.Link
import pl.treksoft.kvision.html.Span
-import pl.treksoft.kvision.html.div
import pl.treksoft.kvision.html.span
import pl.treksoft.kvision.panel.SimplePanel
diff --git a/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/window/Window.kt b/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/window/Window.kt
index b993b649..861127fa 100644
--- a/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/window/Window.kt
+++ b/kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/window/Window.kt
@@ -24,7 +24,6 @@ package pl.treksoft.kvision.window
import com.github.snabbdom.VNode
import org.w3c.dom.events.Event
import org.w3c.dom.events.MouseEvent
-import pl.treksoft.kvision.KVManager
import pl.treksoft.kvision.KVManagerBootstrap
import pl.treksoft.kvision.core.Component
import pl.treksoft.kvision.core.Container