Skip to content

Commit

Permalink
fix(module: steps): fix step status icon (#577)
Browse files Browse the repository at this point in the history
  • Loading branch information
sWhite01111 authored and fisherspy committed Sep 10, 2019
1 parent 19b90da commit fef7568
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions components/steps/steps.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ export class StepsComponent implements OnInit, AfterContentInit {
@HostBinding('class.am-steps-horizontal')
clsStepsHztl: boolean;

constructor(private _elf: ElementRef, private _render: Renderer2) {}
constructor(private _elf: ElementRef, private _render: Renderer2) { }

setStepStyle() {
const itemCount = this.stepItems.length;
Expand All @@ -85,8 +85,17 @@ export class StepsComponent implements OnInit, AfterContentInit {
} else {
step.status = StepStatusEnum.WAIT;
}
} else if (step.status && !icon) {
switch (step.status) {
case StepStatusEnum.FINISH:
icon = 'check-circle-o';
break;
case StepStatusEnum.ERROR:
icon = 'cross-circle-o';
break;
}
}
if (!icon) {
if (!icon && step.status !== StepStatusEnum.PROCESS) {
if (index < this._current) {
icon = 'check-circle-o';
} else if (index > this._current) {
Expand Down

0 comments on commit fef7568

Please sign in to comment.