Workday/canvas-kit

Select Options Are Not Covered By Thier Container After Scrolling

Opened this issue ยท 0 comments

๐Ÿ› Bug Report

When the Select component is in container (e.g. a Modal), if you open the Select and scroll the options of it are not constrained by the parent container.

To Reproduce

This was provided as a minimum public example of the internal issue we faced: https://stackblitz.com/edit/select-overflow-5ye5se?file=package.json,src%2FApp.tsx,src%2Fmain.tsx&terminal=dev

Expected Behavior

It was agreed after talking to the Canvas Kit team that the Select options will be hidden automatically when the Select itself no longer shows.

Actual Results

See how the Select options stay open in the To Reproduce section.

Browser (if applicable)

Chrome - though it probably applies in all browsers.

Link to repl or repo (highly encouraged)

It is not public unfortunately.

Error Output

No errors triggered.