Skip to content

Commit

Permalink
Allow stepper to go to any step
Browse files Browse the repository at this point in the history
  • Loading branch information
shff committed Mar 22, 2018
1 parent 2ba69ab commit 89c51df
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion UI/app/components/elements/step.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<div
v-if="!visible || disabled"
class="p2 mb3 bg-white shadow2 rounded flex items-center"
:class="{ pointer: !disabled && $parent.value > index }"
:class="{ pointer: !disabled }"
@click="$parent.goTo(index)">
<Ball
:index="index"
Expand Down
2 changes: 1 addition & 1 deletion UI/app/components/elements/stepper.vue
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
methods: {
goTo(index) {
const { disabled } = this.$children.find(a => a.index === index);
if (this.value > index && !disabled) {
if (!disabled) {
this.$emit("input", index);
}
},
Expand Down
2 changes: 1 addition & 1 deletion UI/app/components/elements/stepper_header.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
:complete="value > step.id"
:title="step.name"
:key="step.id"
:class="{ pointer: value > step.id }"
class="pointer"
@click="$emit('input', step.id)" />
<hr
v-if="step.id < steps.length"
Expand Down

0 comments on commit 89c51df

Please sign in to comment.