Page 1 of 2

PrimeNG 'severity' buttons with premium themes?

Posted: 21 Jul 2017, 22:31
by Sasha
Hello,

By default, PrimeNG comes with button severity color options (such as "ui-button-danger") as documented here: https://www.primefaces.org/primeng/#/button
Also by default, all the PrimeNG premium themes come with multiple colored buttons (such as "blue-btn") that are showcased in the live preview pages like here: https://www.primefaces.org/poseidon-ng/#/forms

My question is, what are the expectations (or design guidelines) for using the severity button classes with a premium theme? Shouldn't the default severity buttons work just fine straight out of the box? Do you have any plans or suggestions to map the premium theme color scheme to the severity buttons (for instance, the color for pink-btn used for ui-button-danger)?

I arrived at this question because I noticed that in PoseidonNG, on a button with a severity class, clicking then moving the mouse out of the button causes the button to have the primary color of the color theme.

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 24 Aug 2017, 09:23
by bossqone
I agree with Sasha, we currently hit the same issue. I think it should work out of box.

Image

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 12 Sep 2017, 08:29
by cagatay.civici
I agree, we'll add support for the next version to map the severities to the color schemes.

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 13 Sep 2017, 02:14
by Sasha
Thank you, looking forward to it!

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 06 Oct 2017, 20:06
by Sasha
Hello, I updated to Poseidon 4.2.0 with PrimeNG 4.2.2. It does not look like this has been addressed yet.

The biggest challenge to using the severity buttons in Poseidon right now is, as bossqone illustrated, the button's background color changes to the primary color on Focus. It looks like all that would need to be done is to add the rules for "ui-button-danger" and other severity buttons with ":enabled:hover" to have a "background-color" rule in the Poseidon _forms.scss style sheet.

Thank you,

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 01 Dec 2017, 12:04
by cagatay.civici
We've tried it but took more effort than expected initially, we'll give it another go in next release. As there are many themes, it will take a bit of time to add support for all of them. But Poseidon 5.0 is due next week so we'll work on it.

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 15 May 2018, 17:08
by bossqone
Version 5.2.0 has same issue.

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 29 Jun 2018, 09:57
by merve7
Severity buttons are supported by Poseidon 6.0. Please try the new version.

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 22 Aug 2018, 09:48
by bossqone
I've upgraded to PrimeNG to 6.1.2 and theme to 6.0 and now my styles doesn't work as should.

Image

CLI setup:

Code: Select all

"styles": [
  "node_modules/font-awesome/css/font-awesome.min.css",
  "node_modules/primeicons/primeicons.css",
  "node_modules/primeng/resources/primeng.min.css",
  "src/styles/styles.scss"
],
Theme CSS and layout CSS are loaded on runtime (color is picked from configuration file).

I've checked your demo page and I'm not sure from where this "secondary" style comes.
Image

Can you please help?

Re: PrimeNG 'severity' buttons with premium themes?

Posted: 22 Aug 2018, 11:29
by cagatay.civici
Please attach your button code and a screenshot of the rendered visuals.

What is your Poseidon version?