bug(CdkMenuItem): Main menu closes after clicking on a menu item that is a menu
- 主要言語
- TypeScript
- スター
- 25k
- フォーク
- 6.8k
- 平均マージ
- 1日 8時間
- マージ済み PR(30日)
- 91
説明
### Is this a regression?
- [ ] Yes, this behavior used to work in the previous version
### The previous version in which this bug was not present was
_No response_
### Description
Clicking on a menu item that is also a menu will close the whole menu, instead of closing only the opened submenu.
### Reproduction
StackBlitz link: https://stackblitz.com/edit/4aortd
Steps to reproduce:
1. Click on `File` button
2. Click on `New` menu item
### Expected Behavior
The submenu for the `New` menu item is closed (or kept open), the menu associated with `File` is kept open (like a `CdkMenuBar` or the menu nested example: https://material.angular.io/components/menu/examples#menu-nested)
### Actual Behavior
The submenu for the `New` menu item is closed and the `File` menu is closed as well.
### Environment
- Angular: 19.0.0
- CDK/Material: 19.0.0
- Browser(s): 131.0.6778.70 (Official Build) (64-bit)
- Operating System (e.g. Windows, macOS, Ubuntu): Windows 10 Pro
コントリビューションガイド
調査の方向性
リンクされた StackBlitz の再現例から始め、issue に記載されている File > New の操作を行います。Angular CDK のメニュー実装におけるメニュー項目とサブメニューの閉じる動作を追跡し、nested-menu と CdkMenuBar の例を動作の参考として、New を閉じたときに File が開いたままになることを確認します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- angular, typescript
- 領域
- frontend
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100