diff --git a/package.json b/package.json index fe051acd..4199f88a 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@soramitsu/soramitsu-js-ui", - "version": "0.9.1", + "version": "0.9.2", "private": false, "publishConfig": { "registry": "https://nexus.iroha.tech/repository/npm-soramitsu/" diff --git a/src/components/Button/SButton.vue b/src/components/Button/SButton.vue index b4d15841..f7daf048 100644 --- a/src/components/Button/SButton.vue +++ b/src/components/Button/SButton.vue @@ -9,7 +9,7 @@ :disabled="disabled" :loading="isLoading" :autofocus="autofocus" - :circle="type === ButtonTypes.ACTION && rounded" + :circle="isRounded" :icon="elementIcon" @click="handleClick" > @@ -134,7 +134,7 @@ export default class SButton extends Mixins(SizeMixin, BorderRadiusMixin, Design if ((Object.values(ButtonTypes) as Array).includes(this.type)) { cssClasses.push(`s-${this.type}`) } - if ((Object.values(ButtonIconPosition) as Array).includes(this.iconPosition)) { + if (!!this.availableIcon && (Object.values(ButtonIconPosition) as Array).includes(this.iconPosition)) { cssClasses.push(`s-i-position-${this.iconPosition}`) } if (this.isLoading) { @@ -169,8 +169,14 @@ export default class SButton extends Mixins(SizeMixin, BorderRadiusMixin, Design return this.icon } + get isRounded (): boolean { + if (([ButtonTypes.LINK, ButtonTypes.ACTION] as Array).includes(this.type)) return false + + return this.rounded + } + get isLoading (): boolean { - if (([ButtonTypes.LINK, ButtonTypes.ACTION] as Array).includes(this.type)) { + if (([ButtonTypes.LINK, ButtonTypes.ACTION] as Array).includes(this.type) || this.isRounded) { return false } return this.loading diff --git a/src/components/Input/SFloatInput.vue b/src/components/Input/SFloatInput.vue index 5667791a..e4aab325 100644 --- a/src/components/Input/SFloatInput.vue +++ b/src/components/Input/SFloatInput.vue @@ -8,7 +8,11 @@ input: handleInput, blur: onBlur }" - /> + > + +