gravity-ui / date-components

MIT License
10 stars 3 forks source link

RelativeRangeDatePicker: cannot write smth in input #95

Closed saxumcordis closed 4 months ago

saxumcordis commented 4 months ago

Input has cursor, but it is always readonly

Calendar using is not always comfortable. I'd prefer using keyboard

ValeraS commented 4 months ago

RelativeRangeDatePicker can contain relative and absolute start and end dates in any combination. So input here is only for copying selected value. You still can select value in dialog box using a keyboard.

If you don't need relative dates, you can use RangeDatePicker, it supports typing in an input.

saxumcordis commented 4 months ago

RelativeRangeDatePicker can contain relative and absolute start and end dates in any combination. So input here is only for copying selected value. You still can select value in dialog box using a keyboard.

If you don't need relative dates, you can use RangeDatePicker, it supports typing in an input.

I need both. Relative and input

ValeraS commented 4 months ago

If you find a good solution on how to present such an input, PR is welcome. But as I said, you can already select values ​​using a keyboard.

sareyu commented 4 months ago

@saxumcordis @korvin89 @ValeraS guys, maybe we could set up a meeting and discuss possible solutions of this issue, as it is such complicated

korvin89 commented 4 months ago

@saxumcordis @korvin89 @ValeraS guys, maybe we could set up a meeting and discuss possible solutions of this issue, as it is such complicated

@sareyu Sure, you can create one. But saxumcordis should be less toxic. Valera said his opinion and got only unsuitable reaction as answer

saxumcordis commented 4 months ago

A possible compromise is to remove the cursor from the input field (if it is read-only) and open the calendar when the input is pressed. This way, the user will not expect to be able to enter data in the main input.

Sorry that it turned out to be toxic, I didn't mean to offend

saxumcordis commented 4 months ago

remove cursor https://github.com/gravity-ui/date-components/pull/104

and always opening here https://github.com/gravity-ui/date-components/pull/105/files