angulardart / angular_components

The official Material Design components for AngularDart. Used at Google in production apps.
https://pub.dev/packages/angular_components
374 stars 123 forks source link

yesText in material-stepper seems not to work. #438

Open giorgiofran opened 4 years ago

giorgiofran commented 4 years ago

I'm using: Dart 2.5.0,

dependencies:
  angular: ^5.3.0
  angular_components: ^0.13.0

If I set a text on yesText in a MaterialStepperComponent, the stepper ignores it and shows "Continue".

I have simply taken the first example and added yesText="OK"

    <h2>Horizontal orientation, backwards jumps allowed, and default size</h2>
    <material-stepper legalJumps="backwards"
                      orientation="horizontal"
                      yesText="ok"
                      size="default">
        <template step name="Step A Title"
                  (continue)="validDelayedCheck($event)">
            <div class="step-a">
                <h1>Content A</h1>
                (1s continue validation)
            </div>
        </template>
        <template step name="Step B Title"
                  (cancel)="validDelayedCheck($event)">
            <div class="step-b">
                <h1>Content B</h1>
                (1s cancel validation time)
            </div>
        </template>
        <template step name="Step C Title">
            <div class="step-c">
                <h1>Content C</h1>
            </div>
        </template>
        <template step name="Step D Title">
            <div class="step-d">
                <h1>Content C</h1>
            </div>
        </template>
    </material-stepper>

Doing the same with noText works.

I have seen also that, on the first step, the cancel button is not shown. Is it correct? In my case it could be useful to go back to the component where the stepper was called.

It could be also interesting to have yesText and noText at step level.

Update 1: It seems that the attribute "yesText" does not exist anymore, but in the example gallery is still there. Anyone can explain me what is correct? Should I use custom buttons?