Juxtapose constructor
Juxtapose({
- Key? key,
- required Widget backgroundWidget,
- required Widget foregroundWidget,
- Color dividerColor = Colors.white,
- Color thumbColor = Colors.white,
- double dividerThickness = 3,
- Size thumbSize = const Size(12, 100),
- Axis direction = Axis.horizontal,
- double? height,
- double? width,
- BorderRadius? thumbBorderRadius,
- bool showArrows = false,
- Color backgroundColor = Colors.transparent,
Creates a Juxtapose widget.
This widget simply is used to compare two stacked frames/widgets by dragging or sliding the thumb based on the set direction.
direction can be Axis.horizontal or Axis.vertical.
Default direction is Axis.horizontal.
Implementation
Juxtapose({
Key? key,
required this.backgroundWidget,
required this.foregroundWidget,
// this.fit = StackFit.expand,
this.dividerColor = Colors.white,
this.thumbColor = Colors.white,
this.dividerThickness = 3,
this.thumbSize = const Size(12, 100),
this.direction = Axis.horizontal,
this.height,
this.width,
this.thumbBorderRadius,
this.showArrows = false,
this.backgroundColor = Colors.transparent,
}) : assert(thumbSize.width >= 12 || thumbSize.height >= 12),
super(key: key);