Skip to content

Commit

Permalink
fix(date-textbox): recalculate num months on open
Browse files Browse the repository at this point in the history
  • Loading branch information
LuLaValva committed Nov 25, 2024
1 parent 30b5859 commit baade14
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/components/ebay-date-textbox/component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,6 @@ class DateTextbox extends Marko.Component<Input, State> {
secondSelected: null,
popover: false,
};

if (typeof document !== "undefined") {
this.calculateNumMonths();
}
}

onMount() {
Expand Down Expand Up @@ -119,6 +115,7 @@ class DateTextbox extends Marko.Component<Input, State> {
}

openPopover() {
this.calculateNumMonths();
this.state.popover = true;
}

Expand Down

0 comments on commit baade14

Please sign in to comment.