diff options
author | Robert Jaros <rjaros@finn.pl> | 2019-10-25 20:46:42 +0200 |
---|---|---|
committer | Robert Jaros <rjaros@finn.pl> | 2019-10-25 20:46:42 +0200 |
commit | c78775aa2aaf76f9fa1404ff32a10fb8227f380e (patch) | |
tree | a6991e1f520e1ce54679b2194a756203a645f99e /kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/dropdown | |
parent | a990385dd3f2dbac4807b7a9498271efb3519c0d (diff) | |
download | kvision-c78775aa2aaf76f9fa1404ff32a10fb8227f380e.tar.gz kvision-c78775aa2aaf76f9fa1404ff32a10fb8227f380e.tar.bz2 kvision-c78775aa2aaf76f9fa1404ff32a10fb8227f380e.zip |
Style fixes
Diffstat (limited to 'kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/dropdown')
-rw-r--r-- | kvision-modules/kvision-bootstrap/src/main/kotlin/pl/treksoft/kvision/dropdown/DropDown.kt | 10 |
1 files changed, 4 insertions, 6 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) } } |