akveo / akveo/nebular

NbSidebar: menu item toggled when expanding sidebar

Đang mở
#630 5 bình luận 1 reaction 2 người được giao Được @katebatura nhận Xem trên GitHub
bug module:theme needs info P2: important quality
Ngôn ngữ chính
TypeScript
Star
8.1k
Fork
1.5k
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

### Issue type

**I'm submitting a ...** (check one with "x")

* [x] bug report
* [ ] feature request

### Issue description
When sidebar is compacted, clicking on menu item with submenu causes menu item toggling.

**Current behavior:**
Menu item 'expanded' state changed after each click.

**Expected behavior:**
Clicked menu item should always be expanded.

**Steps to reproduce:**
1. Go to [ngx-admin](http://akveo.com/ngx-admin/).
2. Shrink viewport to the size when sidebar is compacted.
3. Click on any menu item which has submenu.
4. Collapse sidebar.
5. Repeat steps 3 and 4 several times.

Every time menu item has a different state.

**Related code:**
https://github.com/akveo/nebular/blob/7542d5ed11a6556b7a91c4209e58a878daed37fa/src/framework/theme/components/sidebar/sidebar.component.ts#L296
https://github.com/akveo/nebular/blob/7542d5ed11a6556b7a91c4209e58a878daed37fa/src/framework/theme/components/menu/menu-item.component.html#L36

### Other information:

**npm, node, OS, Browser**
```
any
```

**Angular, Nebular**
```
@nebular/theme: "2.0.0-rc.10"
```

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.