()
| 578 | } |
| 579 | |
| 580 | toString() { |
| 581 | const month = this.date.getMonth() |
| 582 | return Match.value(this.token.length).pipe( |
| 583 | Match.when(2, () => `${month + 1}`.padStart(2, "0")), |
| 584 | Match.when(3, () => this.locales!.monthsShort[month]!), |
| 585 | Match.when(4, () => this.locales!.months[month]!), |
| 586 | Match.orElse(() => `${month + 1}`) |
| 587 | ) |
| 588 | } |
| 589 | } |
| 590 | |
| 591 | class Year extends DatePart { |