Skip to content

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.

fix: context menu now opens behind the icon as well

Aryaman72c5c937ae8c
diff --git a/frontend/app_flowy/lib/workspace/presentation/home/menu/app/section/item.dart b/frontend/app_flowy/lib/workspace/presentation/home/menu/app/section/item.dart
index bfc51f4bf9..cb3146a70c 100644
--- a/frontend/app_flowy/lib/workspace/presentation/home/menu/app/section/item.dart
+++ b/frontend/app_flowy/lib/workspace/presentation/home/menu/app/section/item.dart
@@ -42,18 +42,28 @@ class ViewSectionItem extends StatelessWidget {
],
child: BlocBuilder<ViewBloc, ViewState>(
builder: (context, state) {
- return Padding(
- padding: const EdgeInsets.symmetric(vertical: 4),
- child: InkWell(
- onTap: () => onSelected(context.read<ViewBloc>().state.view),
- child: FlowyHover(
- style: HoverStyle(hoverColor: theme.bg3),
- builder: (_, onHover) =>
- _render(context, onHover, state, theme.iconColor),
- setSelected: () => state.isEditing || isSelected,
- ),
- ),
- );
+ return ViewDisclosureRegion(
+ onTap: () => context
+ .read<ViewBloc>()
+ .add(const ViewEvent.setIsEditing(true)),
+ onSelected: (action) {
+ context
+ .read<ViewBloc>()
+ .add(const ViewEvent.setIsEditing(false));
+ _handleAction(context, action);
+ },
+ child: Padding(
+ padding: const EdgeInsets.symmetric(vertical: 4),
+ child: InkWell(
+ onTap: () => onSelected(context.read<ViewBloc>().state.view),
+ child: FlowyHover(
+ style: HoverStyle(hoverColor: theme.bg3),
+ builder: (_, onHover) =>
+ _render(context, onHover, state, theme.iconColor),
+ setSelected: () => state.isEditing || isSelected,
+ ),
+ ),
+ ));
},
),
);
@@ -85,20 +95,13 @@ class ViewSectionItem extends StatelessWidget {
);
}
- return ViewDisclosureRegion(
- onTap: () =>
- context.read<ViewBloc>().add(const ViewEvent.setIsEditing(true)),
- onSelected: (action) {
- context.read<ViewBloc>().add(const ViewEvent.setIsEditing(false));
- _handleAction(context, action);
- },
- child: SizedBox(
- height: 26,
- child: Row(children: children).padding(
- left: MenuAppSizes.expandedPadding,
- right: MenuAppSizes.headerPadding,
- ),
- ));
+ return SizedBox(
+ height: 26,
+ child: Row(children: children).padding(
+ left: MenuAppSizes.expandedPadding,
+ right: MenuAppSizes.headerPadding,
+ ),
+ );
}
void _handleAction(