From 3600064ac87beeccb3c4abd8f1c5b740cda0aed8 Mon Sep 17 00:00:00 2001 From: Joffrey Bion Date: Sun, 22 Mar 2020 19:21:08 +0100 Subject: Add blueprint externals and migrate --- .../ui/components/home/ChooseNameForm.kt | 43 +++++++++++----------- .../sevenwonders/ui/components/lobby/Lobby.kt | 23 +++++------- .../ui/components/lobby/RadialPlayerList.kt | 16 +++----- .../org/luxons/sevenwonders/ui/utils/Utils.kt | 13 +++++++ 4 files changed, 50 insertions(+), 45 deletions(-) create mode 100644 sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/utils/Utils.kt (limited to 'sw-ui-kt/src/main/kotlin/org/luxons') diff --git a/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/home/ChooseNameForm.kt b/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/home/ChooseNameForm.kt index 778ef684..94058131 100644 --- a/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/home/ChooseNameForm.kt +++ b/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/home/ChooseNameForm.kt @@ -1,7 +1,9 @@ package org.luxons.sevenwonders.ui.components.home -import kotlinx.html.InputType -import kotlinx.html.js.onChangeFunction +import com.palantir.blueprintjs.Intent +import com.palantir.blueprintjs.bpButton +import com.palantir.blueprintjs.inputGroup +import com.palantir.blueprintjs.org.luxons.sevenwonders.ui.utils.createElement import kotlinx.html.js.onSubmitFunction import org.luxons.sevenwonders.ui.redux.RequestChooseName import org.luxons.sevenwonders.ui.redux.connectDispatch @@ -11,6 +13,7 @@ import react.RClass import react.RComponent import react.RProps import react.RState +import react.ReactElement import react.dom.* private interface ChooseNameFormProps: RProps { @@ -28,28 +31,26 @@ private class ChooseNameForm(props: ChooseNameFormProps): RComponent) => (this._username = e.target.value)} - // rightElement={this.renderSubmit()} - // /> - // Where: - // renderSubmit = () => ( - //