In my layout, I have a row with three columns and two buttons to toggle the visibility of the side panels:
col-md-3 col-md-7 col-md-2
------------------------------------
| | | |
| left | middle panel | | <= right panel
| panel | | |
| | | |
| | | |
------------------------------------
<<< >>>
When the left button is clicked, I want the middle panel to expand to fill the available space on the left:
col-md-10 col-md-2
------------------------------------
| | |
| middle panel | | <= right panel
| | |
| | |
| | |
------------------------------------
<<< >>>
The same behavior should occur when clicking the right button. If both buttons are clicked, the middle panel should expand to take up all available space.
I have achieved the desired effect by toggling classes on the div elements (e.g., changing from col-md-7 to col-md-12), but now I want to add animations for a smoother transition. I came across a solution using JQuery in this Stack Overflow thread: Animate bootstrap columns. However, I would prefer to avoid using JQuery and wonder if Angular2 animations could provide a solution instead.