react-datetime icon indicating copy to clipboard operation
react-datetime copied to clipboard

[Feature] Add useFixedPosition prop to render picker outside an "overflow: hidden" div

Open AdrielD opened this issue 3 years ago • 2 comments

Description

This PR adds new optional flag, so users can force fixed position rendering and then calculating it's position based on datepicker's wrapper. This is useful in cases where the datepicker is rendered inside a div with hidden overflow and the view is being cropped.

Motivation and Context

I developed this solution while working on a dynamic table that would scroll laterally, with datepickers as headers. When the table had just a few or no rows, the div container would severely crop datepicker's view.

Default datepicker datepicker1

WIth applied solution: datepicker2

Also, this PR should solve issue 186

Checklist

[X] I have not included any built dist files (us maintainers do that prior to a new release)
[X] I have added tests covering my changes
[X] All new and existing tests pass
[X] My changes required the documentation to be updated
  [X] I have updated the documentation accordingly
  [X] I have updated the TypeScript 1.8 type definitions accordingly
  [X] I have updated the TypeScript 2.0+ type definitions accordingly

AdrielD avatar Mar 01 '21 21:03 AdrielD

This should be merged, much need PR

erpardeepjain avatar Nov 23 '22 08:11 erpardeepjain

+1 to merge this.

TonniDev avatar May 11 '23 20:05 TonniDev