Frezyx / sidebarx

Flutter multiplatform navigation sidebar / side navigation bar / drawer widget
https://pub.dev/packages/sidebarx
MIT License
292 stars 48 forks source link

Sidebar not opening. #46

Open billyz313 opened 1 year ago

billyz313 commented 1 year ago

The sidebar is not opening when I try to expand it. I have it in a stack so it displays over the map. I tried it in a row like the example and it threw an error "Unsupported operation: -infinity" which is why I decided to try the stack.

image

Here is an animated gif with it in the stack. It loads fine, but it's not opening. Also, i confirmed it does the same if i deploy to an emulator and physical device as well:

sidebar_issue

To Reproduce

body: Stack(
        children: [Padding(
                            padding: const EdgeInsets.all(0),
                            child: Column(children: [
                              Flexible(
                                child: FlutterMap(
                                  mapController: _mapController,
                                  options: MapOptions(
                                    center: LatLng(42.58, 12.43),
                                    zoom: 6,
                                  ),
                                  children: [
                                    TileLayer(
                                      urlTemplate: 'https://tile.openstreetmap.org/{z}/{x}/{y}.png',
                                      subdomains: ['a', 'b', 'c'],
                                    ),
                                    _wmsTileLayer
                                  ],
                                ),
                              ),
                              SidebarX(
                                  controller: SidebarXController(selectedIndex: 0),
                                  items: const [
                                    SidebarXItem(icon: Icons.home, label: 'Home on the range!'),
                                    SidebarXItem(icon: Icons.search, label: 'Search'),
                                  ],
                                )
                            ]))

Expected behavior I would like it to open so I can interact with menus that i intend to put inside. The concept looks like:

goal_demo

Desktop (please complete the following information):

Smartphone (please complete the following information):

kopchok commented 1 year ago

Maybe >>> extendedTheme >>> width

tusharbhambere commented 1 year ago

In SidebarXController use extended: true