Я получаю ошибку
Невозможно прочитать свойство 'mobileStepText' неопределенного при попытке использования ngx-stepper.
Ниже мой код:
Это прямой пример с этого сайта: Директива Angular Steppers для Angular Material .
Но это не работает.
<ngx-stepper #stepperDemo="stepper" [options]="options">
<ngx-step [label]="'Select a campaign'">
<ngx-step-body>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consectetur </p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consectetur nobis</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consectetur nobis saepe </p>
<p>Lorem ipsumsamus repellendus deserunt. Odio sit similique, labore </p>
</ngx-step-body>
<ngx-step-actions>
<button md-button class="md-primary md-raised" (click)="selectCampaign()">Continue</button>
<button md-button class="md-primary" (click)="stepper.back()">Cancel</button>
</ngx-step-actions>
</ngx-step>
<ngx-step [label]="'Publish the ad'">
<ngx-step-body>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consectetur nobis saepe facere suscipit atque,
sapiente, natus mollitia ipsum odit accusamus repellendus deserunt. Odio sit similique, labore maxime
voluptatibus, eaque autem!</p>
</ngx-step-body>
<ngx-step-actions>
<button md-button class="md-primary md-raised" (click)="stepper.next()">Complete</button>
<button md-button class="md-primary" (click)="stepper.back()">Back</button>
</ngx-step-actions>
</ngx-step></ngx-stepper>
.ts
import { Component, OnInit, ViewChild } from '@angular/core';
import { MatStepper } from '@angular/material';
import {FormBuilder, FormGroup, Validators} from '@angular/forms';
import { NgxStepperModule, NgxStepperComponent } from 'ngx-stepper';
@Component({
selector: 'app-registration',
templateUrl: './registration.component.html',
styleUrls: ['./registration.component.sass']
})
export class RegistrationComponent implements OnInit {
@ViewChild('stepperDemo')
public steppers: NgxStepperComponent;
public selectCampaign(): void {
this.steppers.showFeedback('Checking, please wait ...');
this.steppers.next();
}
constructor(private _formBuilder: FormBuilder) { }
ngOnInit() {
}
}
Что я могу с этим поделать?