react-split-pane icon indicating copy to clipboard operation
react-split-pane copied to clipboard

Allow Content within Resizer (i.e. Text, Icon, etc.)

Open TaylorClay opened this issue 7 years ago • 2 comments
trafficstars

Is your feature request related to a problem? Please describe.

I am in need of including text on the Resizer (the "title" for the pane below it) as well as an Icon that signals to the user that it is grabbable/draggable that is centered in the Resizer.

e.g. ||||My Title||||||||||||||||||||||||||||||||^^^||||||||||||||||||||||||||||||||||||||||||||

Describe the solution you'd like

I believe the easiest solution would be to, instead of immediately closing the <span... /> (that makes up the Resizer), we should instead include an optional prop (perhaps "children") that is nested inside the Resizer <span>{children}</span>.

Describe alternatives you've considered

I've set the bottom margin of the top pane to -##px so that the top content of the bottom pane overlays the resizer (that has an invisible background); however, this only works until the bottom pane has scrollable content in which my overlay content scrolls up into hidden.

Additional context

N/A

TaylorClay avatar Nov 08 '18 13:11 TaylorClay

It appears there might already be an open PR for this

TaylorClay avatar Nov 08 '18 13:11 TaylorClay

Just made a new PR for this https://github.com/tomkp/react-split-pane/pull/409

goudarziha avatar Dec 13 '19 19:12 goudarziha