Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pickers][DatePicker] Hijiri Change date from keyboard #16165

Open
ltobolik91 opened this issue Jan 14, 2025 · 7 comments
Open

[pickers][DatePicker] Hijiri Change date from keyboard #16165

ltobolik91 opened this issue Jan 14, 2025 · 7 comments
Labels
bug 🐛 Something doesn't work component: pickers This is the name of the generic UI component, not the React module! external dependency Blocked by external dependency, we can’t do anything about it l10n localization

Comments

@ltobolik91
Copy link

ltobolik91 commented Jan 14, 2025

Steps to reproduce

Steps:

  1. I implemented DatePicker with moment-hijri adapter, date format is "iYYYY-iMM-iDD"
    2.When user try to change year typing inside the input he cannot change year data only day and month is available

Current behavior

Year is not changable via keyboard

Expected behavior

I expect that user will have posssibility to change year from keyboard

Context

Im trying to use DatePicker to set date with hijiri calendar

Your environment

npx @mui/envinfo
  Don't forget to mention which browser you used.
  Output from `npx @mui/envinfo` goes here.
System:
    OS: Windows 10 10.0.19045
  Binaries:
    Node: 19.3.0 - C:\Program Files\nodejs\node.EXE
    npm: 9.2.0 - C:\Program Files\nodejs\npm.CMD   
    pnpm: Not Found
  Browsers:
    Chrome: Not Found
    Edge: Chromium (130.0.2849.56)
  npmPackages:
    @emotion/react:  11.14.0
    @emotion/styled:  11.14.0
    @mui/base:  5.0.0-beta.68
    @mui/core-downloads-tracker:  5.16.13
    @mui/material:  5.16.13
    @mui/private-theming:  5.16.13
    @mui/styled-engine:  5.16.13
    @mui/system:  5.16.13
    @mui/types:  7.2.20
    @mui/utils:  5.16.13
    @mui/x-date-pickers: ^7.23.3 => 7.23.3
    @mui/x-internals:  7.23.0
    @types/react:  18.0.28
    react: ^18.2.0 => 18.2.0
    react-dom: ^18.2.0 => 18.2.0
    typescript:  4.9.5

Chrome

Reproduction
https://stackblitz.com/edit/react-snggk45q?file=Demo.tsx

Search keywords: hijiri year keyboard

@ltobolik91 ltobolik91 added bug 🐛 Something doesn't work status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jan 14, 2025
@github-actions github-actions bot added the component: pickers This is the name of the generic UI component, not the React module! label Jan 14, 2025
@ltobolik91 ltobolik91 changed the title Change date from keyboard Hijiri Change date from keyboard Jan 14, 2025
@michelengelen
Copy link
Member

To help us diagnose the issue efficiently, could you provide a stripped-down reproduction test case using the latest version? A live example would be fantastic! ✨

For your convenience, our documentation offers templates and guides on creating targeted examples: Support - Bug reproduction

Just a friendly reminder: clean, functional code with minimal dependencies is most helpful. Complex code can make it tougher to pinpoint the exact issue. Sometimes, simply going through the process of creating a minimal reproduction can even clarify the problem itself!

Thanks for your understanding! 🙇🏼

@michelengelen michelengelen added status: waiting for author Issue with insufficient information component: date picker This is the name of the generic UI component, not the React module! and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jan 14, 2025
@michelengelen michelengelen changed the title Hijiri Change date from keyboard [pickers][DatePicker] Hijiri Change date from keyboard Jan 14, 2025
@ltobolik91
Copy link
Author

@michelengelen thank you for support, I already added minimal env with bug reproduced. So when we click on input year cannot be changed but we can change month and day. ( without opening popup)

@github-actions github-actions bot added status: waiting for maintainer These issues haven't been looked at yet by a maintainer and removed status: waiting for author Issue with insufficient information labels Jan 14, 2025
@michelengelen
Copy link
Member

sry for the late reply ... I'll add this to the board.

@michelengelen michelengelen added l10n localization and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jan 21, 2025
@ltobolik91
Copy link
Author

In which version i could expect bug to be fixed ?

@LukasTy
Copy link
Member

LukasTy commented Jan 21, 2025

@ltobolik91 Am I missing something, but doesn't this refer to the issue mentioned here: https://mui.com/x/react-date-pickers/calendar-systems/#hijri? 🤔
In this case, it's an external dependency issue that we do not maintain. 🙈
The underlying problem has to be fixed in the library itself.

@LukasTy LukasTy added the status: waiting for author Issue with insufficient information label Jan 21, 2025
@ltobolik91
Copy link
Author

@LukasTy my issue is related to years not to months.

@github-actions github-actions bot added status: waiting for maintainer These issues haven't been looked at yet by a maintainer and removed status: waiting for author Issue with insufficient information labels Jan 21, 2025
@LukasTy LukasTy removed the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Jan 21, 2025
@LukasTy
Copy link
Member

LukasTy commented Jan 21, 2025

@ltobolik91 It is the same problem though.
The original demo in the documentation has broken year and month sections.
In your example, you have changed the format of the month from the default parsed iMMMM to iMM, thus, it started working, but years are still broken. 🙈

I appreciate your input, which helped uncover this different case that is also problematic. 🙏
I'm linking this issue to the original problem: xsoh/moment-hijri#83.

I'm adding an external dependency label to signal that we can not fit it from our side. 🙈

@LukasTy LukasTy added external dependency Blocked by external dependency, we can’t do anything about it and removed component: date picker This is the name of the generic UI component, not the React module! labels Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something doesn't work component: pickers This is the name of the generic UI component, not the React module! external dependency Blocked by external dependency, we can’t do anything about it l10n localization
Projects
None yet
Development

No branches or pull requests

3 participants