|
|
|
@ -13,26 +13,43 @@ class SideViewLayout extends StatelessWidget {
|
|
|
|
final sideView = this.sideView;
|
|
|
|
final sideView = this.sideView;
|
|
|
|
final hideSideView =
|
|
|
|
final hideSideView =
|
|
|
|
!FluffyThemes.isThreeColumnMode(context) || sideView == null;
|
|
|
|
!FluffyThemes.isThreeColumnMode(context) || sideView == null;
|
|
|
|
return sideView == null
|
|
|
|
const sideViewWidth = 360.0;
|
|
|
|
? mainView
|
|
|
|
return Stack(
|
|
|
|
: hideSideView
|
|
|
|
|
|
|
|
? sideView
|
|
|
|
|
|
|
|
: Row(
|
|
|
|
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Expanded(
|
|
|
|
AnimatedPositioned(
|
|
|
|
|
|
|
|
duration: FluffyThemes.animationDuration,
|
|
|
|
|
|
|
|
curve: FluffyThemes.animationCurve,
|
|
|
|
|
|
|
|
top: 0,
|
|
|
|
|
|
|
|
left: 0,
|
|
|
|
|
|
|
|
bottom: 0,
|
|
|
|
|
|
|
|
right: hideSideView ? 0 : sideViewWidth,
|
|
|
|
child: ClipRRect(child: mainView),
|
|
|
|
child: ClipRRect(child: mainView),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
AnimatedPositioned(
|
|
|
|
width: 1.0,
|
|
|
|
|
|
|
|
color: Theme.of(context).dividerColor,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
AnimatedContainer(
|
|
|
|
|
|
|
|
duration: FluffyThemes.animationDuration,
|
|
|
|
duration: FluffyThemes.animationDuration,
|
|
|
|
curve: FluffyThemes.animationCurve,
|
|
|
|
curve: FluffyThemes.animationCurve,
|
|
|
|
clipBehavior: Clip.antiAlias,
|
|
|
|
bottom: 0,
|
|
|
|
decoration: const BoxDecoration(),
|
|
|
|
top: 0,
|
|
|
|
width: hideSideView ? 0 : 360.0,
|
|
|
|
right: 0,
|
|
|
|
child: hideSideView ? null : sideView,
|
|
|
|
left: !FluffyThemes.isThreeColumnMode(context) && sideView != null
|
|
|
|
|
|
|
|
? 0
|
|
|
|
|
|
|
|
: null,
|
|
|
|
|
|
|
|
width: sideView == null
|
|
|
|
|
|
|
|
? 0
|
|
|
|
|
|
|
|
: !FluffyThemes.isThreeColumnMode(context)
|
|
|
|
|
|
|
|
? null
|
|
|
|
|
|
|
|
: sideViewWidth,
|
|
|
|
|
|
|
|
child: Container(
|
|
|
|
|
|
|
|
clipBehavior: Clip.hardEdge,
|
|
|
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
|
|
|
border: Border(
|
|
|
|
|
|
|
|
left: BorderSide(
|
|
|
|
|
|
|
|
color: Theme.of(context).dividerColor,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
child: sideView,
|
|
|
|
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
);
|
|
|
|
);
|
|
|
|
|