This PR replaces overflow: auto on fillable containers (i.e. .html-fill-container) with min-width: 0 and min-height: 0. This causes the fillable flex container to resize its contents (in particular to shrink them) correctly without clipping the child container. (See the discussion and reprex in #386.)
Note that we retain overflow: auto on .html-fill-item, which means that elements within a fillable item will still cause scrolling, e.g long select input choice menus.
Fixes #386
This PR replaces
overflow: auto
on fillable containers (i.e..html-fill-container
) withmin-width: 0
andmin-height: 0
. This causes the fillable flex container to resize its contents (in particular to shrink them) correctly without clipping the child container. (See the discussion and reprex in #386.)Reprex
```r library(htmltools) library(bslib) page_fixed( bindFillRole( container = TRUE, div( class = "m-3 float-left", style = css(height = "300px", width = "300px"), bindFillRole( div(class = "border border-2 shadow"), item = TRUE ) ) ), bindFillRole( container = TRUE, div( # class = "overflow-visible", class = "m-3 float-left", style = css(height = "300px", width = "300px"), bindFillRole( div(class = "border border-2 shadow"), item = TRUE ) ) ) ) ```Note that we retain
overflow: auto
on.html-fill-item
, which means that elements within a fillable item will still cause scrolling, e.g long select input choice menus.