2

I added a flag, but for some reason the window doesn’t close when choosing a date https://www.npmjs.com/package/react-datepicker

enter image description here

   <label className="label-block">
            <DatePicker
                selected={date}
                onChange={handleChange}
                placeholderText="Выберите день"
                minDate={moment().toDate()}
                shouldCloseOnSelect={true}
            />
   </label>
Стас Рябцев
  • 1,318
  • 4
  • 19
  • 36

1 Answers1

2

keep it out of label tag easy.

  • 1
    As it’s currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community May 19 '22 at 12:49
  • Might be a solution, but what if its needed like that, or the setup made so that it cant be kept out of the label? – ii iml0sto1 Nov 17 '22 at 12:52