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

Date and DateTime picker selection palette isn't working on pressing calendar button #24874

Closed
2 tasks done
Vineet-Sharma29 opened this issue Feb 12, 2021 · 10 comments · Fixed by #24981
Closed
2 tasks done
Labels
bug 🐛 Something doesn't work component: pickers This is the name of the generic UI component, not the React module!

Comments

@Vineet-Sharma29
Copy link

Selection palette for date and datetime picker does not show up for date and datetime picker component

  • The issue is present in the latest release.
  • I have searched the issues of this repository and believe that this is not a duplicate.

Current Behavior 😯

On pressing calendar button, date/datetime selection palette does not show up

Expected Behavior 🤔

After pressing calendar button, date/datetime palette shows up to take user input

Steps to Reproduce 🕹

Steps:

  1. Click here for date picker and here for datetime picker
  2. Click on calendar icon

Context 🔦

Your Environment 🌎

`npx @material-ui/envinfo`
npx: installed 2 in 13.98s

  System:
    OS: Linux 4.15 Ubuntu 18.04.4 LTS (Bionic Beaver)
  Binaries:
    Node: 10.15.3 - ~/.nvm/versions/node/v10.15.3/bin/node
    Yarn: 1.21.1 - /usr/bin/yarn
    npm: 6.4.1 - ~/.nvm/versions/node/v10.15.3/bin/npm
  Browsers:
    Chrome: 79.0.3945.130
  npmPackages:
    @emotion/react: ^11.1.5 => 11.1.5 
    @emotion/styled: ^11.1.5 => 11.1.5 
    @material-ui/core: ^5.0.0-alpha.25 => 5.0.0-alpha.25 
    @material-ui/icons: ^5.0.0-alpha.24 => 5.0.0-alpha.24 
    @material-ui/lab: ^5.0.0-alpha.25 => 5.0.0-alpha.25 
    @material-ui/pickers: ^3.2.10 => 3.2.10 
    @material-ui/styled-engine:  5.0.0-alpha.25 
    @material-ui/styles:  5.0.0-alpha.25 
    @material-ui/system:  5.0.0-alpha.25 
    @material-ui/types:  5.1.7 
    @material-ui/unstyled:  5.0.0-alpha.25 
    @material-ui/utils:  5.0.0-alpha.25 
    @types/react:  17.0.0 
    react: ^17.0.1 => 17.0.1 
    react-dom: ^17.0.1 => 17.0.1
@Vineet-Sharma29 Vineet-Sharma29 added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Feb 12, 2021
@mariedasig
Copy link

can you share your code

@oliviertassinari oliviertassinari added bug 🐛 Something doesn't work component: pickers 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 Feb 14, 2021
@Vineet-Sharma29
Copy link
Author

Vineet-Sharma29 commented Feb 14, 2021

@mariedasig following is my code:-

...
import {DatePicker, DateTimePicker, LocalizationProvider} from '@material-ui/lab';
import AdapterDateFns from '@material-ui/lab/AdapterDateFns';
....

<LocalizationProvider dateAdapter={AdapterDateFns}>
           <DatePicker
                     views={['date']}
                     value={this.props.values}
                     onChange={(date) => this.handleValueChange(this.props.index, date.toISOString(), "values")}
                     renderInput={(params) => <TextField {...params} variant="standard" helperText={null} />}
           />
</LocalizationProvider>

@mariedasig
Copy link

Is there an error code?

@Vineet-Sharma29
Copy link
Author

After running over here, there seem to be no error code

@mariedasig
Copy link

It seems to be working fine. I'm able to open the calendar.

@Vineet-Sharma29
Copy link
Author

Can you share your code ? I checked it over here again and the issue persists

@mariedasig
Copy link

You just want the calendar to pop up when you click the calendar icon right? When I click it, it shows up.

@linze99
Copy link

linze99 commented Feb 14, 2021

i got the same problem under version 5.0.0-alpha.25.the calendar panel dosen't show up when user click the icon.
then i downgrade the material-ui/core and material-ui/lab to the version 5.0.0-alpha.24 it works fine!

@oliviertassinari
Copy link
Member

I would assume this is a regression from: #24653

@Xhale1
Copy link

Xhale1 commented Feb 16, 2021

I have reproduced this issue by modifying the Material-UI provided nextjs-with-typescript example to show a date picker. The code is here https://github.com/Xhale1/mui-datepicker-bug. Reverting back to alpha 24 fixes the issue.

Note: I used NPM 7.5.4 to install packages

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!
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants