Skip to content

Commit

Permalink
feat(Date Picker): refactor nested ternary operation
Browse files Browse the repository at this point in the history
  • Loading branch information
Cata1989 committed May 13, 2024
1 parent 5587548 commit 2c7da4b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ export class BqDatePicker {
default: 'calendar-date',
};

const key = this.multi ? 'multi' : this.range ? 'range' : 'default';
const key = (this.multi && 'multi') || (this.range && 'range') || 'default';
const CalendarComponentType = componentTypes[key];

return (
Expand Down

0 comments on commit 2c7da4b

Please sign in to comment.