style: lint

This commit is contained in:
Brandy Carney
2024-09-17 14:17:45 -04:00
parent 0324a78c2b
commit 8af4d74846
2 changed files with 6 additions and 13 deletions

View File

@ -38,17 +38,10 @@
<ion-content>
<ion-segment-view id="myView">
<ion-segment-content>
Paid
</ion-segment-content>
<ion-segment-content>
Free
</ion-segment-content>
<ion-segment-content>
Top
</ion-segment-content>
<ion-segment-content> Paid </ion-segment-content>
<ion-segment-content> Free </ion-segment-content>
<ion-segment-content> Top </ion-segment-content>
</ion-segment-view>
</ion-content>
</ion-app>
</body>

View File

@ -81,15 +81,15 @@ export class Segment implements ComponentInterface {
protected valueChanged(value: SegmentValue | undefined, oldValue?: SegmentValue | undefined) {
if (oldValue !== undefined && value !== undefined) {
const buttons = this.getButtons();
const previous = buttons.find(button => button.value === oldValue);
const current = buttons.find(button => button.value === value);
const previous = buttons.find((button) => button.value === oldValue);
const current = buttons.find((button) => button.value === value);
if (previous && current) {
this.checkButton(previous, current);
}
}
/**
/**
* `ionSelect` is emitted every time the value changes (internal or external changes).
* Used by `ion-segment-button` to determine if the button should be checked.
*/