feat(Calendar): add month/year picker modes and view switching by onmax ยท Pull Request #5981 ยท nuxt/ui

@onmax

๐Ÿ”— Linked issue

Resolves #4889

โ“ Type of change

  • ๐Ÿ“– Documentation (updates to the documentation or readme)
  • ๐Ÿž Bug fix (a non-breaking change that fixes an issue)
  • ๐Ÿ‘Œ Enhancement (improving an existing functionality)
  • โœจ New feature (a non-breaking change that adds functionality)
  • ๐Ÿงน Chore (updates to the build process or auxiliary tools and libraries)
  • โš ๏ธ Breaking change (fix or feature that would cause existing functionality to change)

๐Ÿ“š Description

  1. Add supports for calendar month picker modes via type prop
  2. Add support for year picker modes via type prop
  3. Interactive view switching (day -> month -> year). Maybe too opinionated?

Changes:

  • Add type prop (date | month | year) for standalone pickers
  • Add view / defaultView props for view state control
  • Clickable heading to switch views (day -> month -> year) when type="date"
  • New theme slots: monthGrid, monthCell, yearGrid, yearCell
  • New slots: month-cell, year-cell for custom rendering

๐Ÿ“ธ Screenshots

Feature Screenshot
Month Picker (type="month") image
Year Picker (type="year") image
View Switching (heading click) video below
Cap.2026-02-04.at.14.31.40.mp4

๐Ÿ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@onmax

@benjamincanac what do you think about this PR? Do you like the API?

There are some styles I would like to improve and nail down. But I think is mostly ready :)

Let me know your thoughts! Thank you!

Once we decide to move forward I will ammend PR fixing CI and fixing UI issues

@benjamincanac Volta.net

Thanks for the PR! I do like the API with the type prop approach, it's consistent with other components.

However, it adds lots of code since there are no primitives for this in Reka UI. @J-Michalek what do you think about this? Are you aware of such thing being added in Reka UI any time soon?

@J-Michalek

Well there is an issue open for 8 months unovue/reka-ui#1933 and the activity in the repo is mild at best, but I think we should rely on RekaUI to provide these inputs...

Perhaps the author of this PR would be interested in implementing in RekaUI?

@caiotarifa

Iโ€™m the author of the feature request in Reka UI (unovue/reka-ui#1933), and it has already gathered meaningful community interest (19+ reactions).

As mentioned above, this PR adds a fair amount of code mainly because Reka UI doesnโ€™t provide primitives for month/year picking yet.

@onmax, if youโ€™re open to it, migrating this PR to add MonthPicker and YearPicker primitives in Reka UI would be an excellent win for the ecosystem (as @J-Michalek suggested).

@onmax

Thanks for the feedback. I will prepare a PR for Reka UI.

@benjamincanac, should I keep the behaviour shown in the video? I am not 100% this is the best ux ๐Ÿค”

@onmax onmax mentioned this pull request

Feb 3, 2026

@benjamincanac

I think I like it yes, it avoids having to implement popover and lets us render a Calendar only for months at the same time as selecting a month for a normal calendar.

@onmax

Ok, i won't bother you again ๐Ÿ˜ฌ,

once reka ui is released and this pr is ready I will mark this pr ready and i will ping you.

Feel free to post any feedback though. Most of the code is ready. I am just testing it throughly :)

@pkg-pr-new

npm i https://pkg.pr.new/@nuxt/ui@5981

commit: ae0edf7

@onmax

For reference: much better approach imho

image

@sewalsh

@onmax

@onmax

@onmax