Multiple ContextMenu's on the same page/component do not work as expected #11048
Labels
LTS-PORTABLE
Type: Bug
Issue contains a bug related to a specific component. Something about the component is not working
Milestone
If you have a PrimeNG PRO Support subscription please post your issue at;
https://pro.primefaces.org
where our team will respond within 4 business hours.
If you do not have a PrimeNG PRO Support subscription, fill-in the report below. Please note that
your issue will be added to the waiting list of community issues and will be reviewed on a first-come first-serve basis, as a result, the support team is unable to guarantee a specific schedule on when it will be reviewed. Thank you for your understanding.
Current Queue Time for Review
Without PRO Support: ~8-12 weeks.
With PRO Support: 1 hour
I'm submitting a ... (check one with "x")
Plunkr Case (Bug Reports)
Please demonstrate your case at stackblitz by using the issue template below. Issues without a test case have much less possibility to be reviewd in detail and assisted.
https://stackblitz.com/github/primefaces/primeng-issue-template
Current behavior
https://stackblitz.com/edit/primeng-tablecontextmenu-demo-b2qvhr
when we add two tables and two context menu's when right clicking on the tables in sequence they both open. But also synchronize the selection which is wrong!
Expected behavior
multiple contextMenu's should be supported
Minimal reproduction of the problem with instructions
reproduction with the sample from (https://www.primefaces.org/primeng/showcase/#/table/contextmenu) your site.
I just added an extra table and menu and made the context menu 'unique':
https://stackblitz.com/edit/primeng-tablecontextmenu-demo-b2qvhr
What is the motivation / use case for changing the behavior?
In my opinion this should just work. two separate contextMenu's should operate independently
Please tell us about your environment:
Angular 12, PrimeNG 12, Stackblitz ( but really anywhere you use the component )
Angular version: 5.X
Angular 12
PrimeNG version: 5.X
PrimeNG12
Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]
All
Language: [all | TypeScript X.X | ES6/7 | ES5]
Typescript 4.0.2
Node (for AoT issues):
node --version
=package.json:
"dependencies": {
"rxjs": "6.6.7",
"quill": "1.3.7",
"tslib": "2.3.1",
"primeng": "13.0.4",
"zone.js": "0.11.4",
"chart.js": "3.7.0",
"primeflex": "2.0.0",
"primeicons": "5.0.0",
"@types/node": "8.9.5",
"@angular/cdk": "13.0.4",
"@angular/core": "13.0.3",
"@angular/forms": "13.0.3",
"@types/jasmine": "3.3.16",
"@angular/common": "13.0.3",
"@angular/router": "13.0.3",
"@angular/compiler": "13.0.3",
"@types/jasminewd2": "2.0.8",
"web-animations-js": "2.3.2",
"@fullcalendar/core": "4.4.0",
"@angular/animations": "13.0.3",
"@angular/platform-browser": "13.0.3",
"@angular/platform-browser-dynamic": "13.0.3"
},
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.1100.4",
"@angular/cli": "~11.0.4",
"@angular/compiler-cli": "~11.0.4",
"@types/jasmine": "~3.6.0",
"@types/node": "^12.11.1",
"codelyzer": "^6.0.0",
"jasmine-core": "~3.6.0",
"jasmine-spec-reporter": "~5.0.0",
"karma": "~5.1.0",
"karma-chrome-launcher": "~3.1.0",
"karma-coverage": "~2.0.3",
"karma-jasmine": "~4.0.0",
"karma-jasmine-html-reporter": "^1.5.0",
"protractor": "~7.0.0",
"ts-node": "~8.3.0",
"tslint": "~6.1.0",
"typescript": "~4.0.2"
}
The text was updated successfully, but these errors were encountered: