Rating cancel icon

Post Reply
FkJ
Posts: 170
Joined: 08 Jan 2010, 19:16

31 Mar 2017, 20:06

On modena theme, the rating cancel icon is rendered as a thumbs down icon. This can confuse users...

Could you please replace it with a cancel icon?

Regular theme rating: https://www.primefaces.org/showcase/ui/ ... ting.xhtml

Modena rating: https://www.primefaces.org/eos/modena/forms.xhtml

User avatar
aragorn
Posts: 2600
Joined: 29 Jun 2013, 12:38

03 Apr 2017, 09:26

I think you can override cancel icon. Please try;

Code: Select all

.ui-rating-cancel a {
	background-image: ...
}

FkJ
Posts: 170
Joined: 08 Jan 2010, 19:16

18 May 2017, 16:10

It works, but I would appreciate an official solution, since my custom icon is not displayed correctly and it doesn't matches the other icons from the theme.

User avatar
aragorn
Posts: 2600
Joined: 29 Jun 2013, 12:38

18 May 2017, 16:49

Please try;

Code: Select all

<style type="text/css">
body .ui-rating-cancel a {
    background-image: none !important; 
    font-family: 'Modena';
    text-indent: initial;
    speak: none;
    font-size: 20px !important;
    font-style: normal;
    font-weight: normal;
    font-variant: normal;
    text-transform: none;
    line-height: 1;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    width: 20px !important;
    height: 20px !important;
    color: #E53935;
}

body .ui-rating-cancel-hover a {
    opacity: .7;
}

body .ui-rating-cancel a:before {
    content: "\e287";  /* You can use icon codes in "Modena Material Font Icons" section at https://www.primefaces.org/eos/modena/font-icons.xhtml */
}
</style>

FkJ
Posts: 170
Joined: 08 Jan 2010, 19:16

18 May 2017, 20:25

Looks good, thanks.

User avatar
aragorn
Posts: 2600
Joined: 29 Jun 2013, 12:38

19 May 2017, 10:20

Glad to hear, thanks for the update!

Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 1 guest