Bruno Windels
68afadd83b
try flex-basis for resizing
2019-01-10 14:03:17 +01:00
Bruno Windels
51376c5c07
draft room sub list item api
2019-01-09 15:53:04 +01:00
Bruno Windels
b82e19b1f7
size header explicitly for content size
...
otherwise it just grows with max-height
2019-01-09 15:45:47 +01:00
Bruno Windels
0803ea9158
support collapsed items
2019-01-08 18:17:34 +01:00
Bruno Windels
8352d8c6bd
not sure we need this, but adding the padding in _offset container
2019-01-08 18:17:00 +01:00
Bruno Windels
b4197059a0
change min size to exactly one room tile + header
2019-01-08 18:16:09 +01:00
Bruno Windels
4bd6ce8e2c
WIP2 for making smart resizer work, sort of works now but shows big scrollbar
2019-01-08 16:47:47 +01:00
Bruno Windels
d558ea1dbf
WIP
2018-12-19 23:51:19 +01:00
Bruno Windels
3ddc8baed1
fix resizing sometimes not working (and selecting text)
...
Last friday a child <div> was added inside the ResizeHandle component,
which made the parentElement/classList checks fail on the event.target
here. This would only fail (and select all the text) when dragging exactly on
the grey line (the div), not the transparent margin around it.
use closest to make sure we have the root element of the handle.
2018-12-18 14:27:10 +01:00
Bruno Windels
75925f6192
room sublist seems to get rendered w/o _scroll element
...
when loading the page from a community url
2018-12-10 16:51:32 +01:00
Bruno Windels
f7a37be6dd
support associating an id with a resize item/handle
2018-11-26 16:46:27 +01:00
Bruno Windels
dae509d0eb
introduce resizeFromContainerOffset method on distributor
...
up till now, resize received the offset of the resize handle
within the container upon resizing, and would then calculate
it's new size. For this first item in the container, this is
the same, and has therefor not been a problem yet.
Now however, we'll need to be able to programatically
(from localStorage) set the size of any roomsublist,
so need a method we can call with just the size and not an offset
within the container. The resizer calls the new method,
which subsequently calls resize.
This also has the nice side-effect that you can now easily
call super.resize after having transformed the new item size
2018-11-26 16:42:58 +01:00
Bruno Windels
3e496833fc
remove unused PercentageDistributor
...
it's not used and we need to make some
api changes that don't work with it (resize will receive itemSize
which it doesn't really support)
2018-11-26 16:41:49 +01:00
Bruno Windels
8929ff9b5e
use room resize classes
2018-11-26 14:42:01 +01:00
Bruno Windels
0939a40d3a
adjust room distributor to roomsublist dom structure
...
also better classes to apply
2018-11-26 14:41:15 +01:00
Bruno Windels
4c5bd71114
fix lint
2018-11-01 17:56:08 +01:00
Bruno Windels
4d53e13a28
make manual resizing follow cursor more accurately
...
by clearing flex-grow that was set based on the list size,
you don't want it to grow anymore but be exactly the size
you are giving it.
2018-10-22 15:56:39 +02:00
Bruno Windels
73d9a71b29
Merge pull request #2226 from matrix-org/bwindels/resizeroomsublists
...
Redesign: 1st go at resizing room sublists
2018-10-19 13:33:28 +00:00
Bruno Windels
eb1ee1ca55
bind instead of second member var
2018-10-19 15:15:49 +02:00
Bruno Windels
44b92eb071
set sub list height with flex-basis to make it ... well, grow less
2018-10-18 16:58:17 +02:00
Bruno Windels
39ab3d86bd
create sizer that sets item size with flex-basis
...
works with the flex-grow we set initially for the sub lists
2018-10-18 15:51:22 +02:00
Bruno Windels
a910f46c5b
don't assume config
2018-10-18 15:51:01 +02:00
Bruno Windels
8d414d0986
more docs
2018-10-17 13:45:56 +02:00
Bruno Windels
d8ead8a8bb
add some description to some classes
2018-10-17 13:42:30 +02:00
Bruno Windels
8d3347bcfb
fix lint
2018-10-17 13:36:15 +02:00
Bruno Windels
6fdcebb876
add copyright headers
2018-10-17 11:38:25 +02:00
Bruno Windels
3a26f0fa12
only fire onCollapsed once when changing
2018-10-16 18:43:13 +02:00
Bruno Windels
28ec0f7462
onResized callback
2018-10-16 18:42:56 +02:00
Bruno Windels
bb184a4ae0
support programmatic access to a distributor (to set size from storage)
2018-10-16 17:22:12 +02:00
Bruno Windels
650e19ff77
don't expose direction, handleIndex to distributor ctor
2018-10-16 16:25:00 +02:00
Bruno Windels
30003d8f91
turn resizer into class to make programmatic interaction/cleanup easier
2018-10-16 15:16:10 +02:00
Bruno Windels
c095e30ae4
provide collapsed callback to also collapse on react side of things
2018-10-16 14:56:49 +02:00
Bruno Windels
c56975d93d
dont base collapse toggle size on min-width, as it's not available in collapsed state
2018-10-16 12:26:08 +02:00
Bruno Windels
4f006b033e
collapse left panel when 50px past min-width
2018-10-11 15:40:59 +02:00
Bruno Windels
928b6d47c8
add resize handles between 3 main app columns
2018-09-24 16:07:42 +01:00