mui / mui-x

MUI X: Build complex and data-rich applications using a growing list of advanced React components, like the Data Grid, Date and Time Pickers, Charts, and more!
https://mui.com/x/
4.57k stars 1.35k forks source link

[pickers] Create a week view #6297

Open Evaldas189 opened 2 years ago

Evaldas189 commented 2 years ago

Order ID 💳

is there any way to create week picker from date picker library?

Duplicates

Latest version

The problem in depth 🔍

I would like to create calendar date picker that allows to display only one week in a calendar, and arrow button should navigate to the next or prev week.

Your environment 🌎

`npx @mui/envinfo` ``` Don't forget to mention which browser you used. Output from `npx @mui/envinfo` goes here. ```
alexfauquette commented 2 years ago

It let me think about the following demo

But not sure to understand what you mean by a "week peaker". Maybe providing more context about why you need such a specific component could help to discuss your issue

Evaldas189 commented 2 years ago

I would like to have a calendar that displays only a week not a full month. Here is an example: Week view calendar

alexfauquette commented 2 years ago

OK, it's a completely different behavior. I do not think it's possible to do that starting from the calendar. It would be faster to do it from scratch

alexfauquette commented 2 years ago

Just adding a screenshot of the code sandbox in case it gets deleted latter image

MonstraG commented 1 year ago

It let me think about the following demo

But not sure to understand what you mean by a "week peaker". Maybe providing more context about why you need such a specific component could help to discuss your issue

For future readers, link for [the following demo] has changed: https://mui.com/x/react-date-pickers/date-calendar/#custom-day-rendering

LukasTy commented 1 year ago

For future readers, link for [the following demo] has changed: https://mui.com/x/react-date-pickers/date-calendar/#custom-day-rendering

It has been actually changed once again to better reflect the improved example: https://mui.com/x/react-date-pickers/date-calendar/#week-picker 🙈

dostontech commented 7 months ago

Just adding a screenshot of the code sandbox in case it gets deleted latter image

hey guy how i can make like this calendar can you someone help me please? thank you