mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-19 03:32:21 +08:00
chore(): sync with main:
This commit is contained in:
@ -458,9 +458,9 @@ export class Segment implements ComponentInterface {
|
||||
case 'last':
|
||||
return buttons[buttons.length - 1];
|
||||
case 'next':
|
||||
return buttons[currIndex + 1] || buttons[0];
|
||||
return buttons[currIndex + 1] ?? buttons[0];
|
||||
case 'previous':
|
||||
return buttons[currIndex - 1] || buttons[buttons.length - 1];
|
||||
return buttons[currIndex - 1] ?? buttons[buttons.length - 1];
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
|
Reference in New Issue
Block a user