Bring projects, wikis, and teams together with AI. AppFlowy is the AI collaborative workspace where you achieve more without losing control of your data. The leading open source Notion alternative.
Dart blogconfluence-alternativecontent-managementcontent-servicesdocumentationflutternote-takingnotion-alternativeproject-managementtask-managementteam-collaborationwiki
[flutter]: force ScrollbarListStack child as large as parent
appflowy6c8ecc8296c8
diff --git a/app_flowy/lib/workspace/presentation/stack_page/trash/trash_page.dart b/app_flowy/lib/workspace/presentation/stack_page/trash/trash_page.dartindex 25f725ca24..0df9d80490 100644--- a/app_flowy/lib/workspace/presentation/stack_page/trash/trash_page.dart+++ b/app_flowy/lib/workspace/presentation/stack_page/trash/trash_page.dart@@ -82,6 +82,7 @@ class _TrashStackPageState extends State<TrashStackPage> {barSize: barSize,child: StyledSingleChildScrollView(controller: ScrollController(),+ barSize: barSize,axis: Axis.horizontal,child: SizedBox(width: TrashSizes.totalWidth,diff --git a/app_flowy/lib/workspace/presentation/stack_page/trash/widget/sizes.dart b/app_flowy/lib/workspace/presentation/stack_page/trash/widget/sizes.dartindex d3c7d90bdc..ff960d28f9 100644--- a/app_flowy/lib/workspace/presentation/stack_page/trash/widget/sizes.dart+++ b/app_flowy/lib/workspace/presentation/stack_page/trash/widget/sizes.dart@@ -5,6 +5,5 @@ class TrashSizes {static double get lashModifyWidth => 230 * scale;static double get createTimeWidth => 230 * scale;static double get padding => 100 * scale;- static double get totalWidth =>- TrashSizes.fileNameWidth + TrashSizes.lashModifyWidth + TrashSizes.createTimeWidth + TrashSizes.padding;+ static double get totalWidth => TrashSizes.fileNameWidth + TrashSizes.lashModifyWidth + TrashSizes.createTimeWidth;}diff --git a/app_flowy/packages/flowy_infra_ui/lib/style_widget/scrolling/styled_scrollview.dart b/app_flowy/packages/flowy_infra_ui/lib/style_widget/scrolling/styled_scrollview.dartindex d548dc8f64..3df1fea4c7 100644--- a/app_flowy/packages/flowy_infra_ui/lib/style_widget/scrolling/styled_scrollview.dart+++ b/app_flowy/packages/flowy_infra_ui/lib/style_widget/scrolling/styled_scrollview.dart@@ -10,6 +10,7 @@ class StyledSingleChildScrollView extends StatefulWidget {final Color? handleColor;final ScrollController? controller;final EdgeInsets? scrollbarPadding;+ final double barSize;final Widget? child;@@ -22,6 +23,7 @@ class StyledSingleChildScrollView extends StatefulWidget {this.handleColor,this.controller,this.scrollbarPadding,+ this.barSize = 6,}) : super(key: key);@override@@ -58,14 +60,16 @@ class _StyledSingleChildScrollViewState extends State<StyledSingleChildScrollVieaxis: widget.axis,controller: scrollController,scrollbarPadding: widget.scrollbarPadding,- barSize: 12,+ barSize: widget.barSize,trackColor: widget.trackColor,handleColor: widget.handleColor,- child: SingleChildScrollView(- scrollDirection: widget.axis,- physics: StyledScrollPhysics(),- controller: scrollController,- child: widget.child,+ child: SizedBox.expand(+ child: SingleChildScrollView(+ scrollDirection: widget.axis,+ physics: StyledScrollPhysics(),+ controller: scrollController,+ child: widget.child,+ ),),);}