primefaces / primeng

The Most Complete Angular UI Component Library
https://primeng.org
Other
10.14k stars 4.54k forks source link

ButtonDirective changing severity does not update styles #16074

Open danemesis opened 1 month ago

danemesis commented 1 month ago

Describe the bug

Changing severity input for Directive does not change button styles.

https://github.com/primefaces/primeng/blob/98f96823b0e82dd60a432e11090cb9b611b01ecc/src/app/components/button/button.ts#L112

Environment

126.0.6478.183 (Official Build) (arm64), macos

Angular version

18

PrimeNG version

17.18.1

Build / Runtime

Angular CLI App

Language

TypeScript

Node version (for AoT issues node --version)

v20.15.1

Browser(s)

Chrome

Steps to reproduce the behavior

change directive's severity and see that styles are not changing.

Expected behavior

Styles change once button's severity is updated

Reproduced

https://stackblitz.com/edit/stackblitz-starters-8skcaw?file=src%2Fmain.ts

danemesis commented 1 month ago

I imagine if to update as label or other settable Input's it should work

https://github.com/primefaces/primeng/blob/98f96823b0e82dd60a432e11090cb9b611b01ecc/src/app/components/button/button.ts#L72