Datepicker icon clickable when disabled=true
Bug Report
- Package version(s): ^4.51.1
- Browser and OS versions: Chrome 63, IE 11, IE 10
Describe the issue:
Datepicker icon clickable when disabled=true
Actual behavior:
setting disabled prop to true does not disable the calendar icon. when clicked, datepicker pop-up shows. picking a date in the pop-up updates the text input field
Expected behavior:
icon is disabled/not clickable together with input textbox
I was unable to repro this. The disabled prop works as expected for me. Could you post a Codepen or sample code how you're using it? Thanks
I am using the component in an Office365 page. Initially thought it was because it was messing up with the Office365 core styling/classes, but it has the same behavior with the standard app via create-react-app running on local. I just used the sample code given in the Fabric UI site.
basically wrapped the sample code in the Fabric UI site in a component, and called the DatePicker with the following:
<DatePicker
label="Start date"
isRequired={false}
allowTextInput={true}
ariaLabel={desc}
firstDayOfWeek={firstDayOfWeek}
strings={DayPickerStrings}
value={value}
onSelectDate={date => this.setState({value: date})}
disabled={true}
/>
Ah there's a bug where it opens if a label is included. I'll submit a PR shortly