bug(cdkMenu): changing cdkMenuPosition during runtime is not updating the position correctly #30145
Labels
area: cdk/menu
P3
An issue that is relevant to core functions, but does not impede progress. Important, but not urgent
Is this a regression?
The previous version in which this bug was not present was
No response
Description
if it is a user-issue/skill-issue on my side, excuse me to waste your time 😅
Reproduction
StackBlitz link: https://stackblitz.com/edit/stackblitz-starters-6rd4gzr4?description=An%20angular-cli%20project%20based%20on%20@angular/animations,%20@angular/common,%20@angular/compiler,%20@angular/core,%20@angular/forms,%20@angular/platform-browser,%20@angular/platform-browser-dynamic,%20@angular/router,%20core-js,%20rxjs,%20tslib%20and%20zone.js&file=src%2Fmain.ts&file=src%2Fglobal_styles.css&template=node&title=Angular%20Starter
Steps to reproduce:
Click the button in the first container to open a cdkMenu.
Update the position with the controls above. you will notive that the projected overlay is not positioned differently.
If you change the values for the initial position you will notice that the menu is positioned differently initially.
Hint: the second container below uses cdkOverlayOrigin and cdkConnectedOverlay for comparision.
Here's also a short video
CleanShot.2024.12.07.-.Google.Chrome-cdkMenu.-.StackBlitz-000231.mp4
Expected Behavior
The cdkMenu-Position should react to new values via cdkMenuPosition-input
Actual Behavior
See repro
Environment
The text was updated successfully, but these errors were encountered: