carsondrobe / Fellas

3 stars 2 forks source link

Added max date to be today #235

Closed Davis245 closed 5 months ago

Davis245 commented 5 months ago

Set the maximum date to be today if the user selects a date in the future, today's date will be selected.

Closes #218

Davis245 commented 5 months ago

So there are two options:

  1. Remove the clear button. This only works on Webkit-based browsers.
  2. Set the date to the previous date when the clear button is pressed. This would make the clear button do nothing.

Also for context, Safari does not have a clear button nor a today button, Chrome has both a clear and today button, and Firefox only has a clear button.

abijeet-dhillon commented 5 months ago

So there are two options:

  1. Remove the clear button. This only works on Webkit-based browsers.
  2. Set the date to the previous date when the clear button is pressed. This would make the clear button do nothing.

Also for context, Safari does not have a clear button nor a today button, Chrome has both a clear and today button, and Firefox only has a clear button.

Ohhhh I see, I'm good with either option. Whichever is quicker/easiest to implement tbh.

Davis245 commented 5 months ago

I implemented the second option in the last commit "Disabled the clear button".