Menu Type

Input Style

Flat Layout Colors

Special Layout Colors

Themes

Current Version

6.0.0 running on PrimeFaces 11.0.0

Getting Started

First of all, you'd need SASS to compile CSS, proceed to SASS Installation before beginning if you do not have SASS available in your command line.

Demo project has an integrated jetty plugin so running the sample is easy as building the css first followed by the mvn jetty:run command.


sass --update src/main/webapp/resources:src/main/webapp/resources --no-source-map
mvn clean jetty:run

*Note: The sass command above is supported by Dart Sass. Please use Dart Sass instead of Ruby Sass.

Navigate to http://localhost:8080/verona to view the demos which is exactly same as the live version.

Size

rem units are utilized for scalability so in order to change the size of the overall UI, configure the font-size at the html root. Refer to the SASS Variables section for more information.


html {
    font-size: $fontSize;
}

Layout

Verona utilizes JSF templating APIs and provides a main template.xhtml along with additional topbar, menu, footer fragments for the base layout. These xhtml files must be placed under WEB-INF folder and client pages should reference the template.xhtml as their template. Provided empty.xhtml is a sample content page using the main template.xhtml that defines "content" as the main ui:define placeholder. By default template defines 3 placeholders (page title, header content and actual content)to insert content and you can add more as per your requirements.

Sample page below uses the main template from Verona.


<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:p="http://primefaces.org/ui"
                template="/WEB-INF/template.xhtml">
                
    <ui:define name="title">Test Page</ui:define>

    <ui:define name="content">
        Content goes here
    </ui:define>
</ui:composition>

Other required resources are the css, js and images that are located inside resources/verona-layout folder, simply copy the verona-layout folder to your %WEB-APP-FOLDER%/resources folder so that final path would be %WEB-APP-FOLDER%/resources/verona-layout/. Please refer to demo app or maven project of the demo app as the reference.

GuestPreferences Bean

GuestPreferences is a simple session scoped bean to keep the user customizations of the layout, template xhtml files refer to this bean to dynamically change their behavior such as menu mode or theme. This bean is not necessary to run the Verona and only used for demo purposes. For example template.xhtml includes layout color depending on a user preference using an EL expression.


<h:outputStylesheet name="css/layout-#{guestPreferences.layout}.css" library="verona-layout" />   

In your application, you may also need a similar bean to make the template dynamic or choose a static color with;

Theme

Verona provides 7 PrimeFaces themes out of the box, setup of a theme simple as including the theme jar in your classpath and defining primefaces.THEME context parameter in web.xml such as "primefaces-verona-green". Full list of available themes are;

  • primefaces-verona-amber
  • primefaces-verona-blue
  • primefaces-verona-bluegrey
  • primefaces-verona-green
  • primefaces-verona-purple
  • primefaces-verona-teal
  • primefaces-verona-turquoise

A custom theme can be developed by the following steps.

  • Create a custom theme folder such as primefaces-verona-myown under webapp/resources and place an empty theme.scss inside.
  • Copy the sass folder from the distribution to webapp/resources.
  • Define the variables listed below and import the /sass/theme/_theme.scss file.
  • Build the scss to generate css.
  • Set primefaces.THEME context parameter as verona-myown
  • Either bundle the css in a jar file or serve from webapp/resources/primefaces-verona-myown folder

Here are the variables required to create a theme.


$primaryColor: #f7cb00 !default;
$primaryLightColor: scale-color($primaryColor, $lightness: 60%) !default;
$primaryDarkColor: scale-color($primaryColor, $lightness: -10%) !default;
$primaryDarkerColor: scale-color($primaryColor, $lightness: -20%) !default;
$primaryTextColor: #2d353c !default;

@import '../sass/theme/_theme';

An example sass command to compile the css would be;


sass src/main/webapp/resources/primefaces-verona-myown/theme.scss src/main/webapp/resources/primefaces-verona-myown/theme.css  --sourcemap=none

Watch mode is handy to avoid compiling everytime when a change is made, instead use the following command so that sass generates the file whenever you make a customization. This builds all css files whenever a change is made to any scss file.


sass --watch src/main/webapp/resources:src/main/webapp/resources --no-source-map

Same can also be applied to layout itself;

  • Choose a layout name such as layout-myown.
  • Create an empty file named layout-myown.scss inside resources/verona-layout/css folder.
  • Copy the sass folder from the distribution to webapp/resources.
  • Define the variables listed below and import the /sass/layout/_layout.scss file.
  • Build the scss to generate css
  • Serve the css by importing it using a link tag or h:outputStylesheet.

Here are the variables required to create a layout


$topbarLeftBgColor:#00cdac;
$topbarRightBgColor:#02aab0;
$menuBgColor:#00979d;
$menuItemTextColor:#e3f0ee;
$menuItemHoverBgColor:#4ddbc4;
$menuItemHoverTextColor:#ffffff;
$menuButtonBgColor:#32d7bc;
$menuButtonHoverBgColor:#00a489;
$menuButtonActiveBgColor:#00979d;
$topbarMenuItemBadgeBgColor:#d86c6c;
$topbarMenuItemBadgeTextColor:#ffffff;

@import '../../sass/layout/_layout';

SASS Variables

_layout.scss under sass/variables folder define the shared variables of the layout.


$fontFamily: "Lato","Helvetica Neue",sans-serif !default;
$fontSize:13px !default;
$textColor:#2d353c !default;
$textSecondaryColor:lighten($textColor,25%) !default;
$borderRadius:2px !default;
$dividerColor:#dce2e7 !default;
$transitionDuration:.3s !default;
$tabletBreakpoint: 991px !default;
$phoneBreakpoint: 576px !default;

/* Predefined Colors */
$blue:#3ebaf8 !default;
$orange:#f7cb00 !default;
$purple:#985edb !default;
$pink:#f18983 !default;
$green:#9fd037 !default;
$black:#525262 !default;
$amber:#f7cb00 !default;
$secondary:#f4f4f4 !default;

$bodyBgColor:#eaeff2 !default;
$footerBgColor:#dee0e3 !default;
$appNameTextColor:#ffffff !default;
$searchInputBgColor:#f5f8f9 !default;
$searchInputBorderColor:#f5f8f9 !default;
$searchInputFocusBorderColor:#a8b4be !default;
$menuItemActiveTextColor:#ffffff !default;
$cardBgColor:#f7f9fa !default;

Similarly _theme.scss files under sass/variables contains the whole set of variables to generate a PrimeFaces theme.


$colors: (
    "blue": #2196F3,
    "green": #4caf50,
    "yellow": #FBC02D,
    "cyan": #00BCD4,
    "pink": #E91E63,
    "indigo": #3F51B5,
    "teal": #009688,
    "orange": #F57C00,
    "bluegray": #607D8B,
    "purple": #9C27B0,
    "red": #FF4032,
    "primary": $primaryColor
) !default;

//shades of gray
$shade000:#ffffff !default;    //surface
$shade100:#f8f9fa !default;    //header background
$shade200:#e9ecef !default;    //hover background
$shade300:#dee2e6 !default;    //content border
$shade400:#ced4da !default;    //input border
$shade500:#adb5bd !default;    //input icon
$shade600:#6c757d !default;    //text secondary color
$shade700:#495057 !default;    //text color
$shade800:#343a40 !default;    //unused
$shade900:#212529 !default;    //unused

//highlight
$highlightBg: $primaryColor !default;
$highlightTextColor: $primaryTextColor !default;

//general
$fontSize:1rem !default;
$fontFamily:"Lato","Helvetica Neue",sans-serif;
$textColor:$shade700 !default;
$textSecondaryColor:$shade600 !default;
$transitionDuration:.2s !default;
$transition: background-color $transitionDuration, color $transitionDuration, border-color $transitionDuration, box-shadow $transitionDuration !default;
$actionIconTransition:background-color $transitionDuration, color $transitionDuration, box-shadow $transitionDuration, opacity $transitionDuration ease-in-out !default;
$listItemTransition: box-shadow $transitionDuration !default;
$animationDuration:.4s !default;
$animationTimingFunction:cubic-bezier(.05,.74,.2,.99) !default;
$letterSpacing:normal !default;
$borderRadius:3px !default;
$tabletBreakpoint:991px !default;
$phoneBreakpoint:576px !default;
$divider:1px solid $shade300 !default;
$disabledOpacity:.6 !default;
$maskBg:rgba(0, 0, 0, 0.4) !default;
$inlineSpacing:.5rem !default;
$iconSize:1rem !default;
$errorColor:#f44336 !default;

//action icon
$actionIconWidth:2rem !default;
$actionIconHeight:2rem !default;
$actionIconBg:transparent !default;
$actionIconBorder:0 none !default;
$actionIconColor:$shade600 !default;
$actionIconHoverBg:$shade200 !default;
$actionIconHoverBorderColor:transparent !default;
$actionIconHoverColor:$shade700 !default;
$actionIconBorderRadius:50% !default;

//focus
$focusOutlineColor:$primaryLightColor !default;
$focusOutline:0 none !default;
$focusOutlineOffset:0 !default;
$focusShadow:0 0 0 0.2rem $focusOutlineColor !default;

//input field
$inputPadding:.5rem .5rem !default;
$inputTextFontSize:1rem !default;
$inputBg:$shade000 !default;
$inputTextColor:$shade700 !default;
$inputIconColor:$shade600 !default;
$inputBorder:1px solid $shade400 !default;
$inputHoverBorderColor:$primaryColor !default;
$inputFocusBorderColor:$primaryColor !default;
$inputErrorBorderColor:$errorColor !default;
$inputPlaceholderTextColor:$shade600 !default;
$inputFocusShadow:0 0 0 0.2em $primaryLightColor !default;
$inputFilledBg:$shade100 !default;
$inputFilledHoverBg:$shade100 !default;
$inputFilledFocusBg:$shade100 !default;

//groups
$inputGroupBorderColor:$shade400 !default;
$inputGroupBg:$shade200 !default;
$inputGroupTextColor:$shade700 !default;
$inputGroupIconColor:$shade600 !default;
$inputGroupAddonMinWidth:2.357rem !default;

//input lists
$inputListMinWidth:12rem !default;
$inputListBg:$shade000 !default;
$inputListBorder:$inputBorder !default;
$inputListPadding:.5rem 0 !default;

$inputListItemPadding:.5rem 1rem !default;
$inputListItemBg:transparent !default;
$inputListItemTextColor:$shade700 !default;
$inputListItemHoverBg:$shade200 !default;
$inputListItemTextHoverColor:$shade700 !default;
$inputListItemHighlightBg:$highlightBg !default;
$inputListItemHighlightTextColor:$highlightTextColor !default;
$inputListItemBorder:0 none !default;
$inputListItemBorderRadius:0 !default;
$inputListItemMargin:0 !default;
$inputListItemFocusShadow:inset 0 0 0 .15rem $focusOutlineColor !default;
$inputListHeaderPadding:.5rem 1rem !default;
$inputListHeaderBg:$shade100 !default;
$inputListHeaderTextColor:$shade700 !default;
$inputListHeaderBorder:0 none !default;

//inputs with panels (password, keyboard)
$inputContentPanelPadding:1rem !default;
$inputContentPanelBg:$shade000 !default;
$inputContentPanelTextColor:$shade700 !default;

//inputs with overlays
$inputOverlayBorder:0 none !default;
$inputOverlayShadow:0 2px 4px -1px rgba(0,0,0,.2), 0 4px 5px 0 rgba(0,0,0,.14), 0 1px 10px 0 rgba(0,0,0,.12) !default;

//inputs with buttons
$inputButtonWidth:2.357rem !default;

//button
$buttonTextOnlyPadding:.5rem 1rem !default;
$buttonWithLeftIconPadding:.5rem 1rem .5rem 2rem !default;
$buttonWithRightIconPadding:.5rem 2rem .5rem 1rem !default;
$buttonIconOnlyPadding:.5rem !default;
$buttonIconOnlyWidth:2.357rem !default;

$buttonBg:$primaryColor !default;
$buttonBorder:1px solid $primaryColor !default;
$buttonTextColor:$primaryTextColor !default;

$buttonHoverBg:$primaryDarkColor !default;
$buttonHoverBorderColor:$primaryDarkColor !default;
$buttonTextHoverColor:$primaryTextColor !default;

$buttonActiveBg:$primaryDarkerColor !default;
$buttonActiveBorderColor:$primaryDarkerColor !default;
$buttonTextActiveColor:$primaryTextColor !default;

$buttonFocusOutline:0 none !default;
$buttonFocusOutlineOffset:0 !default;
$buttonFocusShadow:0 0 0 0.2em $primaryLightColor !default;
$raisedButtonShadow:0 3px 1px -2px rgba(0,0,0,.2), 0 2px 2px 0 rgba(0,0,0,.14), 0 1px 5px 0 rgba(0,0,0,.12) !default;
$roundedButtonBorderRadius:2rem !default;

$textButtonHoverBgOpacity:.04 !default;
$textButtonActiveBgOpacity:.16 !default;
$outlinedButtonBorder:1px solid !default;
$plainButtonTextColor:$shade600 !default;
$plainButtonHoverBgColor:$shade200 !default;
$plainButtonActiveBgColor:$shade300 !default;

//button severities
$secondaryButtonBg:#607D8B !default;
$secondaryButtonTextColor:#ffffff !default;
$secondaryButtonBorder:1px solid $secondaryButtonBg !default;
$secondaryButtonHoverBg:scale-color($secondaryButtonBg, $lightness: -10%) !default;
$secondaryButtonTextHoverColor:$secondaryButtonTextColor !default;
$secondaryButtonHoverBorderColor:scale-color($secondaryButtonBg, $lightness: -10%) !default;
$secondaryButtonActiveBg:scale-color($secondaryButtonBg, $lightness: -20%) !default;
$secondaryButtonTextActiveColor:$secondaryButtonTextColor !default;
$secondaryButtonActiveBorderColor:scale-color($secondaryButtonBg, $lightness: -20%) !default;
$secondaryButtonFocusShadow:0 0 0 0.2rem scale-color($secondaryButtonBg, $lightness: 60%) !default;

$infoButtonBg:#0288D1 !default;
$infoButtonTextColor:#ffffff !default;
$infoButtonBorder:1px solid $infoButtonBg !default;
$infoButtonHoverBg:scale-color($infoButtonBg, $lightness: -10%) !default;
$infoButtonTextHoverColor:$infoButtonTextColor !default;
$infoButtonHoverBorderColor:scale-color($infoButtonBg, $lightness: -10%) !default;
$infoButtonActiveBg:scale-color($infoButtonBg, $lightness: -20%) !default;
$infoButtonTextActiveColor:$infoButtonTextColor !default;
$infoButtonActiveBorderColor:scale-color($infoButtonBg, $lightness: -20%) !default;
$infoButtonFocusShadow:0 0 0 0.2rem scale-color($infoButtonBg, $lightness: 60%) !default;

$successButtonBg:#689F38 !default;
$successButtonTextColor:#ffffff !default;
$successButtonBorder:1px solid $successButtonBg !default;
$successButtonHoverBg:scale-color($successButtonBg, $lightness: -10%) !default;
$successButtonTextHoverColor:$successButtonTextColor !default;
$successButtonHoverBorderColor:scale-color($successButtonBg, $lightness: -10%) !default;
$successButtonActiveBg:scale-color($successButtonBg, $lightness: -20%) !default;
$successButtonTextActiveColor:$successButtonTextColor !default;
$successButtonActiveBorderColor:scale-color($successButtonBg, $lightness: -20%) !default;
$successButtonFocusShadow:0 0 0 0.2rem scale-color($successButtonBg, $lightness: 60%) !default;

$warningButtonBg:#FBC02D !default;
$warningButtonTextColor:#212529 !default;
$warningButtonBorder:1px solid $warningButtonBg !default;
$warningButtonHoverBg:scale-color($warningButtonBg, $lightness: -10%) !default;
$warningButtonTextHoverColor:$warningButtonTextColor !default;
$warningButtonHoverBorderColor:scale-color($warningButtonBg, $lightness: -10%) !default;
$warningButtonActiveBg:scale-color($warningButtonBg, $lightness: -20%) !default;
$warningButtonTextActiveColor:$warningButtonTextColor !default;
$warningButtonActiveBorderColor:scale-color($warningButtonBg, $lightness: -20%) !default;
$warningButtonFocusShadow:0 0 0 0.2rem scale-color($warningButtonBg, $lightness: 60%) !default;

$helpButtonBg:#9C27B0 !default;
$helpButtonTextColor:#ffffff !default;
$helpButtonBorder:1px solid $helpButtonBg !default;
$helpButtonHoverBg:scale-color($helpButtonBg, $lightness: -10%) !default;
$helpButtonTextHoverColor:$helpButtonTextColor !default;
$helpButtonHoverBorderColor:scale-color($helpButtonBg, $lightness: -10%) !default;
$helpButtonActiveBg:scale-color($helpButtonBg, $lightness: -20%) !default;
$helpButtonTextActiveColor:$helpButtonTextColor !default;
$helpButtonActiveBorderColor:scale-color($helpButtonBg, $lightness: -20%) !default;
$helpButtonFocusShadow:0 0 0 0.2rem scale-color($helpButtonBg, $lightness: 60%) !default;

$dangerButtonBg:#D32F2F !default;
$dangerButtonTextColor:#ffffff !default;
$dangerButtonBorder:1px solid $dangerButtonBg !default;
$dangerButtonHoverBg:scale-color($dangerButtonBg, $lightness: -10%) !default;
$dangerButtonTextHoverColor:$dangerButtonTextColor !default;
$dangerButtonHoverBorderColor:scale-color($dangerButtonBg, $lightness: -10%) !default;
$dangerButtonActiveBg:scale-color($dangerButtonBg, $lightness: -20%) !default;
$dangerButtonTextActiveColor:$dangerButtonTextColor !default;
$dangerButtonActiveBorderColor:scale-color($dangerButtonBg, $lightness: -20%) !default;
$dangerButtonFocusShadow:0 0 0 0.2rem scale-color($dangerButtonBg, $lightness: 60%) !default;

//checkbox
$checkboxBorderWidth:2px !default;
$checkboxWidth:1.5rem !default;
$checkboxHeight:1.5rem !default;
$checkboxActiveBorderColor:$primaryColor !default;
$checkboxActiveBg:$primaryColor !default;
$checkboxActiveHoverBg:$primaryDarkColor !default;
$checkboxTextActiveColor:$primaryTextColor !default;
$checkboxFocusShadow:0 0 0 0.2em $primaryLightColor !default;

//radiobutton
$radiobuttonBorderWidth:2px !default;
$radiobuttonWidth:20px !default;
$radiobuttonHeight:20px !default;
$radiobuttonIconSize:12px !default;
$radiobuttonActiveBorderColor:$primaryColor !default;
$radiobuttonActiveBg:$primaryColor !default;
$radiobuttonActiveHoverBg:$primaryDarkColor !default;
$radiobuttonTextActiveColor:$primaryTextColor !default;
$radiobuttonFocusShadow:0 0 0 0.2em $primaryLightColor !default;

//togglebutton
$toggleButtonBg:$shade000 !default;
$toggleButtonBorder:1px solid $shade400 !default;
$toggleButtonTextColor:$shade700 !default;
$toggleButtonIconColor:$shade600 !default;
$toggleButtonHoverBg:$shade200 !default;
$toggleButtonHoverBorderColor:$shade400 !default;
$toggleButtonTextHoverColor:$shade700 !default;
$toggleButtonHoverIconColor:$shade600 !default;
$toggleButtonActiveBg:$primaryColor !default;
$toggleButtonActiveBorderColor:$primaryColor !default;
$toggleButtonTextActiveColor:$primaryTextColor !default;
$toggleButtonActiveIconColor:$primaryTextColor !default;
$toggleButtonActiveHoverBg:$primaryDarkColor !default;
$toggleButtonActiveHoverBorderColor:$primaryDarkColor !default;
$toggleButtonActiveTextHoverColor:$primaryTextColor !default;
$toggleButtonActiveHoverIconColor:$primaryTextColor !default;

//inplace
$inplacePadding:$inputPadding !default;
$inplaceHoverBg:$shade200 !default;
$inplaceTextHoverColor:$shade700 !default;

//rating
$ratingCancelIconColor:#e0284f !default;
$ratingCancelHoverIconColor:#e0284f !default;
$ratingIconWidth:1.25rem !default;
$ratingIconHeight:1.25rem !default;
$ratingIconFontSize:1.25rem !default;
$ratingStarIconColor:$shade700 !default;
$ratingStarIconHoverColor:$primaryDarkColor !default;
$ratingStarActiveIconColor:$primaryColor !default;

//slider
$sliderBg:$shade300 !default;
$sliderHeight:.286rem !default;
$sliderWidth:.286rem !default;
$sliderHandleWidth:1.143rem !default;
$sliderHandleHeight:1.143rem !default;
$sliderHandleBg:$shade000 !default;
$sliderHandleBorder:2px solid $primaryColor !default;
$sliderHandleBorderRadius:50% !default;
$sliderHandleHoverBorderColor:$primaryColor !default;
$sliderHandleHoverBg:$primaryColor !default;
$sliderRangeBg:$primaryColor !default;

//calendar
$calendarPadding:.5rem !default;
$calendarTitlePadding:1rem !default;
$calendarTitleBg:$shade000 !default;
$calendarTitleTextColor:$shade700 !default;
$calendarTitleBorder:solid $shade300 !default;
$calendarTitleBorderWidth:0 0 1px 0 !default;
$calendarTableMargin:.5rem 0 !default;
$calendarCellPadding:.5rem !default;
$calendarCellDateTextColor:$shade700 !default;
$calendarCellDateWidth:2.5rem !default;
$calendarCellDateHeight:2.5rem !default;
$calendarCellDateBorder:0 none !default;
$calendarCellDateHoverBg:$shade200 !default;
$calendarCellDateHoverBorderColor:transparent !default;
$calendarCellDateBorderRadius:50% !default;
$calendarCellDateSelectedBg:$highlightBg !default;
$calendarCellDateSelectedTextColor:$highlightTextColor !default;
$calendarCellDateSelectedBorder:0 none !default;
$calendarCellDateTodayBg:transparent !default;
$calendarCellDateTodayTextColor:$primaryDarkerColor !default;
$calendarCellDateTodayBorder:0 none !default;

$calendarButtonBarPadding:1rem 0 !default;
$calendarTimePickerMargin:.857em 0 !default;
$calendarTimePickerLabelPadding:0 !default;
$calendarTimePickerInputPadding:.5em 0 !default;
$calendarTimePickerInputMargin:0 .714em .714em 40% !default;

//keyboard
$keyboardButtonPadding:.5rem !default;
$keyboardButtonMargin:2px !default;
$keyboardButtonBorder:$inputBorder !default;
$keyboardButtonBg:$inputBg !default;
$keyboardButtonTextColor:$shade700 !default;
$keyboardButtonHoverBorderColor:$shade400 !default;
$keyboardButtonHoverBg:#ebebef !default;
$keyboardButtonTextHoverColor:$shade700 !default;
$keyboardButtonActiveBorderColor:$buttonActiveBorderColor !default;
$keyboardButtonActiveBg:$buttonActiveBg !default;
$keyboardButtonTextActiveColor:$shade000 !default;

//switch
$inputSwitchOffBg:$shade300 !default;
$inputSwitchHandleOffBg:$shade000 !default;
$inputSwitchHandleOffBorder:2px solid $shade300 !default;
$inputSwitchOnBg:$primaryColor !default;
$inputSwitchHandleOnBg:$shade000 !default;
$inputSwitchHandleOnBorderColor:$primaryDarkerColor !default;
$inputSwitchHandleBorderRadius:50% !default;
$inputSwitchHandleShadow:0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0,0,0,.12) !default;
$inputSwitchBorderRadius:30px !default;

//panel common
$panelHeaderBorder:1px solid $shade300 !default;
$panelHeaderBg:$shade100 !default;
$panelHeaderTextColor:$shade700 !default;
$panelHeaderFontWeight:700 !default;
$panelHeaderPadding:1rem !default;
$panelContentBorder:1px solid $shade300 !default;
$panelContentBg:$shade000 !default;
$panelContentTextColor:$shade700 !default;
$panelContentPadding:1rem !default;
$panelFooterBorder:1px solid $shade300 !default;
$panelFooterBg:$shade000 !default;
$panelFooterTextColor:$shade700 !default;
$panelFooterPadding:1rem !default;

$panelHeaderHoverBg:$shade200 !default;
$panelHeaderHoverBorderColor:$shade300 !default;
$panelHeaderTextHoverColor:$shade700 !default;
$panelHeaderHoverIconColor:$shade700 !default;

//accordion
$accordionSpacing:0 !default;
$accordionHeaderBorder:$panelHeaderBorder !default;
$accordionHeaderBg:$panelHeaderBg !default;
$accordionHeaderTextColor:$panelHeaderTextColor !default;
$accordionHeaderFontWeight:$panelHeaderFontWeight !default;
$accordionHeaderPadding:$panelHeaderPadding !default;

$accordionHeaderHoverBg:$shade200 !default;
$accordionHeaderHoverBorderColor:$shade300 !default;
$accordionHeaderTextHoverColor:$shade700 !default;

$accordionHeaderActiveBg:$panelHeaderBg !default;
$accordionHeaderActiveBorderColor:$shade300 !default;
$accordionHeaderTextActiveColor:$shade700 !default;

$accordionHeaderActiveHoverBg:$shade200 !default;
$accordionHeaderActiveHoverBorderColor:$shade300 !default;
$accordionHeaderActiveTextHoverColor:$shade700 !default;

$accordionContentBorder:$panelContentBorder !default;
$accordionContentBg:$panelContentBg !default;
$accordionContentTextColor:$panelContentTextColor !default;
$accordionContentPadding:$panelContentPadding !default;

//tabview
$tabsHeaderSpacing:.286rem !default;
$tabsNavBorderWidth:2px !default;
$tabsNavBorder:$tabsNavBorderWidth solid $shade300 !default;
$tabsNavBg:$shade000 !default;

$tabsHeaderBg:$shade000 !default;
$tabsHeaderTextColor:$shade600 !default;
$tabsHeaderFontWeight:700 !default;
$tabsHeaderPadding:$panelHeaderPadding !default;

$tabsHeaderHoverBg:$shade000 !default;
$tabsHeaderHoverBorderColor:$shade500 !default;
$tabsHeaderTextHoverColor:$shade600 !default;

$tabsHeaderActiveBg:$shade000 !default;
$tabsHeaderActiveBorderColor:$primaryColor !default;
$tabsHeaderTextActiveColor:$primaryColor !default;

$tabsContentBorder:0 none !default;
$tabsContentBg:$shade000 !default;
$tabsContentTextColor:$shade700 !default;
$tabsContentPadding:$panelContentPadding !default;

//action icon
$tabsScrollerButtonBg:$shade000 !default;
$tabsScrollerButtonIconColor:$shade600 !default;
$tabsScrollerButtonHoverBg:$shade200 !default;
$tabsScrollerButtonIconHoverColor:$shade700 !default;

//scrollpanel
$scrollPanelHandleBg:#dadada !default;
$scrollPanelTrackBorder:0 none !default;
$scrollPanelTrackBg:#f8f8f8 !default;

//paginator
$paginatorBg:$shade000 !default;
$paginatorBorder:solid $shade200 !default;
$paginatorBorderWidth:0 !default;
$paginatorIconColor:$shade600 !default;
$paginatorPadding:1rem !default;
$paginatorElementWidth:2.286em !default;
$paginatorElementHeight:2.286em !default;
$paginatorElementHoverBg:$shade200 !default;
$paginatorElementHoverIconColor:$shade700 !default;
$paginatorElementMargin:0 .125em !default;
$paginatorElementBorder:1px solid transparent !default;
$paginatorElementHoverBorderColor:transparent !default;
$paginatorElementBorderRadius:$borderRadius !default;

//datatable
$datatableHeaderBorder:1px solid $shade200 !default;
$datatableHeaderBorderWidth:1px 0 1px 0 !default;
$datatableHeaderBg:$shade100 !default;
$datatableHeaderTextColor:$shade700 !default;
$datatableHeaderFontWeight:600 !default;
$datatableHeaderPadding:1rem 1rem !default;

$datatableHeaderCellPadding:1rem 1rem !default;
$datatableHeaderCellBg:$shade100 !default;
$datatableHeaderCellTextColor:$shade700 !default;
$datatableHeaderCellFontWeight:700 !default;
$datatableHeaderCellBorder:1px solid $shade200 !default;
$datatableHeaderCellBorderWidth:0 0 1px 0 !default;
$datatableHeaderCellHoverBg:$shade200 !default;
$datatableHeaderCellTextHoverColor:$shade700 !default;
$datatableHeaderCellHighlightBg:$shade100 !default;
$datatableHeaderCellHighlightTextColor:$primaryColor !default;
$datatableHeaderCellHighlightHoverBg:$shade200 !default;
$datatableHeaderCellHighlightTextHoverColor:$primaryColor !default;
$datatableSortableColumnBadgeSize:1.143rem !default;
$datatableBodyRowBg:$shade000 !default;
$datatableBodyRowTextColor:$shade700 !default;
$datatableBodyRowBorder:1px solid rgba(0, 0, 0, 0.08) !default;
$datatableBodyRowOddBg:#fbfcfc !default;
$datatableBodyRowHoverBg:$shade200 !default;
$datatableBodyRowTextHoverColor:$shade700 !default;
$datatableBodyCellPadding:1rem 1rem !default;
$datatableBodyCellBorderWidth:0 0 1px 0 !default;
$datatableFooterBorderWidth:0 0 1px 0 !default;
$datatableFooterCellPadding:1rem 1rem !default;
$datatableFooterCellBg:$shade100 !default;
$datatableFooterCellTextColor:$shade700 !default;
$datatableFooterCellFontWeight:700 !default;
$datatableFooterCellBorder:1px solid $shade200 !default;
$datatableFooterCellBorderWidth:0 0 1px 0 !default;
$datatableResizerHelperBg:$primaryColor !default;

$datatableFooterBorder:1px solid $shade200 !default;
$datatableFooterBorderWidth:0 0 1px 0 !default;
$datatableFooterBg:$shade100 !default;
$datatableFooterTextColor:$shade700 !default;
$datatableFooterFontWeight:600 !default;
$datatableFooterPadding:1rem 1rem !default;

$datatableTopPaginatorBorderWidth:0 0 1px 0 !default;
$datatableBottomPaginatorBorderWidth:0 0 1px 0 !default;

$datatableScaleSm:0.5 !default;
$datatableScaleLg:1.25 !default;

//dataview
$dataViewContentPadding:0 !default;
$dataViewContentBorder:0 none !default;
$dataViewListItemBorder:solid $shade200 !default;
$dataViewListItemBorderWidth:0 0 1px 0 !default;

//orderlist, picklist
$orderListDropPlaceholderBg:scale-color($highlightBg, $lightness: -20%) !default;
$pickListDropPlaceholderBg:scale-color($highlightBg, $lightness: -20%) !default;

//schedule
$scheduleCellBorderColor: $shade300 !default;
$scheduleTodayBg:$primaryLightColor !default;
$scheduleEventBg:$primaryDarkColor !default;
$scheduleEventBorder:0px solid $primaryDarkColor !default;
$scheduleEventTextColor:$primaryTextColor !default;

//tree
$treeNodePadding:.143em 0 !default;
$treeNodeLabelPadding:.286em !default;

//messages
$messagesMargin:1rem 0 !default;
$messagesPadding:1.5rem !default;
$messagesIconFontSize:1.5rem !default;
$messagesBorderWidth:0 0 0 6px !default;
$messagesFontWeight:600 !default;
$infoMessageBg:#B3E5FC !default;
$infoMessageBorder:1px solid #03A9F4 !default;
$infoMessageTextColor:#01579B !default;
$infoMessageIconColor:#01579B !default;
$warnMessageBg:#FFECB3 !default;
$warnMessageBorder:1px solid #FFC107 !default;
$warnMessageTextColor:#7f6003 !default;
$warnMessageIconColor:#7f6003 !default;
$errorMessageBg:#FFCDD2 !default;
$errorMessageBorder:1px solid #EF5350 !default;
$errorMessageTextColor:#B71C1C !default;
$errorMessageIconColor:#B71C1C !default;
$growlIconFontSize:2rem !default;
$growlMargin:0 0 1rem 0 !default;
$growlPadding:1rem !default;
$messageBorderWidth:0 0 0 3px !default;

//overlays
$overlayContentBorder:0 none !default;
$overlayContainerShadow:0px 11px 15px -7px rgba(0, 0, 0, 0.2), 0px 24px 38px 3px rgba(0, 0, 0, 0.14), 0px 9px 46px 8px rgba(0,0,0,.12) !default;

//dialog
$dialogHeaderBorder:0 none !default;
$dialogHeaderBg:$shade000 !default;
$dialogHeaderTextColor:$shade700 !default;
$dialogHeaderFontWeight:700 !default;
$dialogHeaderFontSize:1.25rem !default;
$dialogHeaderPadding:1.5rem !default;
$dialogContentBorder:0 none !default;
$dialogContentBg:$shade000 !default;
$dialogContentTextColor:$shade700 !default;
$dialogContentPadding:0 1.5rem 2rem 1.5rem !default;
$dialogFooterBorder:0 none !default;
$dialogFooterBg:$shade000 !default;
$dialogFooterTextColor:$shade700 !default;
$dialogFooterPadding:0 1.5rem 1.5rem 1.5rem !default;

$confirmDialogContentPadding:0 1.5rem 2rem 1.5rem !default;
$confirmDialogIconFontSize:2.5rem !default;

//overlay panel
$overlayPanelCloseIconBg:$primaryColor !default;
$overlayPanelCloseIconColor:$primaryTextColor !default;
$overlayPanelCloseIconHoverBg:$primaryDarkColor !default;
$overlayPanelCloseIconHoverColor:$primaryTextColor !default;

//tooltip
$tooltipBg:#252529 !default;
$tooltipTextColor:#ffffff !default;

//steps
$stepsItemTextColor:$shade600 !default;
$stepsItemNumberBorder:1px solid $shade200 !default;
$stepsItemNumberColor:$shade700 !default;
$stepsItemNumberBg:$shade000 !default;
$stepsItemNumberFontSize: 1.143rem !default;
$stepsItemNumberWidth: 2rem !default;
$stepsItemNumberHeight: 2rem !default;
$stepsItemNumberBorderRadius: 50% !default;

//progressbar
$progressBarHeight:1rem !default;
$progressBarBorder:0 none !default;
$progressBarBg:#efefef !default;
$progressBarValueBg:$primaryColor !default;

//menu
$verticalMenuPadding:.25rem 0 !default;
$menuBg:$shade000 !default;
$menuBorder:1px solid $shade300 !default;
$menuitemTextColor:$shade700 !default;
$menuitemIconColor:$shade600 !default;
$menuitemHoverBg:$shade200 !default;
$menuitemTextHoverColor:$shade700 !default;
$menuitemHoverIconColor:$shade700 !default;
$menuitemPadding:.75rem 1rem !default;
$menuitemMargin:0 !default;
$menuitemBorderRadius:0 !default;
$menuSeparatorMargin:.25rem 0 !default;

$breadcrumbPadding:1rem !default;
$breadcrumbBg:$menuBg !default;
$breadcrumbBorder:$menuBorder !default;
$breadcrumbItemTextColor:$menuitemTextColor !default;
$breadcrumbItemIconColor:$menuitemIconColor !default;
$breadcrumbLastItemTextColor:$menuitemTextColor !default;
$breadcrumbLastItemIconColor:$menuitemIconColor !default;
$breadcrumbSeparatorColor:$menuitemTextColor !default;

$submenuHeaderMargin:0 !default;
$submenuHeaderPadding:.75rem 1rem !default;
$submenuHeaderBg:#ffffff !default;
$submenuHeaderBorder:0 none !default;
$submenuHeaderTextColor:$shade700 !default;
$submenuHeaderFontWeight:700 !default;
$submenuHeaderFontSize:1rem !default;

$horizontalMenuPadding: .5rem !default;
$horizontalMenuBg: $shade100 !default;

$overlayMenuShadow: 0 2px 4px -1px rgba(0,0,0,.2), 0 4px 5px 0 rgba(0,0,0,.14), 0 1px 10px 0 rgba(0,0,0,.12) !default;

//upload
$fileItemPadding:1rem !default;

//badge and tag
$badgeBg:$primaryColor !default;
$badgeTextColor:$primaryTextColor !default;
$badgeMinWidth:1.5rem !default;
$badgeHeight:1.5rem !default;
$badgeFontWeight:700 !default;
$badgeFontSize:.75rem !default;

$tagPadding:.25rem .4rem !default;

//card
$cardBodyPadding:1rem !default;
$cardTitleFontSize:1.5rem !default;
$cardTitleFontWeight:700 !default;
$cardSubTitleFontWeight:400 !default;
$cardSubTitleColor:$shade600 !default;
$cardContentPadding:1rem 0 !default;
$cardFooterPadding:1rem 0 0 0 !default;
$cardShadow:0 2px 1px -1px rgba(0,0,0,.2), 0 1px 1px 0 rgba(0,0,0,.14), 0 1px 3px 0 rgba(0,0,0,.12) !default;

//divider
$dividerHorizontalMargin:1rem 0 !default;
$dividerHorizontalPadding:0 1rem !default;
$dividerVerticalMargin:0 1rem !default;
$dividerVerticalPadding:1rem 0 !default;
$dividerSize:1px !default;
$dividerColor:$shade300 !default;

//avatar
$avatarBg:$shade300 !default;
$avatarTextColor:$textColor !default;

//chip
$chipBg:$shade300 !default;
$chipTextColor:$textColor !default;
$chipBorderRadius: 16px !default;

//scrollTop
$scrollTopBg:rgba(0,0,0,0.7) !default;
$scrollTopHoverBg:rgba(0,0,0,0.8) !default;
$scrollTopWidth:3rem !default;
$scrollTopHeight:3rem !default;
$scrollTopBorderRadius:50% !default;
$scrollTopFontSize:1.5rem !default;
$scrollTopTextColor:$shade100 !default;

//skeleton
$skeletonBg:$shade200 !default;
$skeletonAnimationBg:rgba(255,255,255,0.4) !default;

//splitter
$splitterGutterBg:$shade100 !default;
$splitterGutterHandleBg:$shade300 !default;

//chronoline
$chronolineVerticalEventContentPadding:0 1rem !default;
$chronolineHorizontalEventContentPadding:1rem 0 !default;
$chronolineEventMarkerWidth:1rem !default;
$chronolineEventMarkerHeight:1rem !default;
$chronolineEventMarkerBorderRadius:50% !default;
$chronolineEventMarkerBorder:2px solid $primaryColor !default;
$chronolineEventMarkerBackground:$shade000 !default;
$chronolineEventConnectorSize:2px !default;
$chronolineEventColor:$shade300 !default;

//confirmpopup
$confirmPopupContentPadding:$panelContentPadding !default;
$confirmPopupFooterPadding:0 1rem 1rem 1rem !default;

//speeddial
$speedDialButtonWidth: 4rem !default;
$speedDialButtonHeight: 4rem !default;
$speedDialButtonIconFontSize: 1.3rem !default;
$speedDialActionWidth: 3rem !default;
$speedDialActionHeight: 3rem !default;
$speedDialActionBg: $shade700 !default;
$speedDialActionHoverBg: $shade800 !default;
$speedDialActionTextColor: #fff !default;
$speedDialActionTextHoverColor: #fff !default;

//carousel
$carouselIndicatorsPadding:1rem !default;
$carouselIndicatorBg:$shade200 !default;
$carouselIndicatorHoverBg:$shade300 !default;
$carouselIndicatorBorderRadius:0 !default;
$carouselIndicatorWidth:2rem !default;
$carouselIndicatorHeight:.5rem !default;

//galleria
$galleriaMaskBg:rgba(0,0,0,0.9) !default;
$galleriaCloseIconMargin:.5rem !default;
$galleriaCloseIconFontSize:2rem !default;
$galleriaCloseIconBg:transparent !default;
$galleriaCloseIconColor:$shade100 !default;
$galleriaCloseIconHoverBg:rgba(255,255,255,0.1) !default;
$galleriaCloseIconHoverColor:$shade100 !default;
$galleriaCloseIconWidth:4rem !default;
$galleriaCloseIconHeight:4rem !default;
$galleriaCloseIconBorderRadius:50% !default;

$galleriaItemNavigatorBg:transparent !default;
$galleriaItemNavigatorColor:$shade100 !default;
$galleriaItemNavigatorMargin:0 .5rem !default;
$galleriaItemNavigatorFontSize:2rem !default;
$galleriaItemNavigatorHoverBg:rgba(255,255,255,0.1) !default;
$galleriaItemNavigatorHoverColor:$shade100 !default;
$galleriaItemNavigatorWidth:4rem !default;
$galleriaItemNavigatorHeight:4rem !default;
$galleriaItemNavigatorBorderRadius:$borderRadius !default;

$galleriaCaptionBg:rgba(0,0,0,.5) !default;
$galleriaCaptionTextColor:$shade100 !default;
$galleriaCaptionPadding:1rem !default;

$galleriaIndicatorsPadding:1rem !default;
$galleriaIndicatorBg:$shade200 !default;
$galleriaIndicatorHoverBg:$shade300 !default;
$galleriaIndicatorBorderRadius:50% !default;
$galleriaIndicatorWidth:1rem !default;
$galleriaIndicatorHeight:1rem !default;
$galleriaIndicatorsBgOnItem:rgba(0,0,0,.5) !default;
$galleriaIndicatorBgOnItem:rgba(255,255,255,.4) !default;
$galleriaIndicatorHoverBgOnItem:rgba(255,255,255,.6) !default;

$galleriaThumbnailContainerBg:rgba(0,0,0,.9) !default;
$galleriaThumbnailContainerPadding:.8rem .25rem !default;
$galleriaThumbnailContentMargin:.2rem !default;
$galleriaThumbnailNavigatorBg:transparent !default;
$galleriaThumbnailNavigatorColor:$shade100 !default;
$galleriaThumbnailNavigatorHoverBg:rgba(255,255,255,0.1) !default;
$galleriaThumbnailNavigatorHoverColor:$shade100 !default;
$galleriaThumbnailNavigatorBorderRadius:50% !default;
$galleriaThumbnailNavigatorWidth:2rem !default;
$galleriaThumbnailNavigatorHeight:2rem !default;

:root {
    --surface-a:#{$shade000};
    --surface-b:#{$shade100};
    --surface-c:#{$shade200};
    --surface-d:#{$shade300};
    --surface-e:#{$shade000};
    --surface-f:#{$shade000};
    --text-color:#{$shade700};
    --text-color-secondary:#{$shade600};
    --primary-color:#{$primaryColor};
    --primary-color-text:#{$primaryTextColor};
    --font-family:#{$fontFamily};
    --surface-0: #ffffff;
    --surface-50: #FAFAFA;
    --surface-100: #F5F5F5;
    --surface-200: #EEEEEE;
    --surface-300: #E0E0E0;
    --surface-400: #BDBDBD;
    --surface-500: #9E9E9E;
    --surface-600: #757575;
    --surface-700: #616161;
    --surface-800: #424242;
    --surface-900: #212121;
    --gray-50: #FAFAFA;
    --gray-100: #F5F5F5;
    --gray-200: #EEEEEE;
    --gray-300: #E0E0E0;
    --gray-400: #BDBDBD;
    --gray-500: #9E9E9E;
    --gray-600: #757575;
    --gray-700: #616161;
    --gray-800: #424242;
    --gray-900: #212121;
    --content-padding:#{$panelContentPadding};
    --inline-spacing:#{$inlineSpacing};
    --border-radius:#{$borderRadius};
    --surface-ground:#f8f9fa;
    --surface-section:#ffffff;
    --surface-card:#ffffff;
    --surface-overlay:#ffffff;
    --surface-border:#dee2e6;
    --surface-hover: #e9ecef;
    --maskbg: #{$maskBg};
    --focus-ring: #{$focusShadow};
}

Layout and Theme Combinations

Verona has 14 built-in layout colors and 7 themes, following are the suggested combinations.

  • Dark layout with all themes.
  • Blue layout with amber and blue themes.
  • Turquoise layout with amber, turquoise and purple themes.
  • Green layout with teal, amber and purple themes.
  • Rose layout with purple, green, turquoise and amber themes.
  • Teal layout with green, turquoise, amber and purple themes.
  • BlueGrey layout with all themes.
  • Cosmic layout with all themes except purple.
  • Beach layout with turquoise, amber and teal themes.
  • Flow layout with turquoise, amber, blue and teal themes.
  • Fly layout with purple, turquoise, blue, green and amber themes.
  • Nepal layout with green, turquoise, purple and amber themes.

Menu

Menu is a regular JSF component that supports PrimeFaces MenuModel API allowing both declarative and programmatic approaches.


xmlns:pv="http://primefaces.org/verona"

<pv:menu>
</pv:menu>

Menu has 4 modes, horizontal, popup, static and overlay. Layout wrapper element in template.xhtml is used to define which mode to use by adding specific classes. List below indicates the style classes for each mode.

  • Horizontal: "layout-menu-horizontal"
  • Static: "layout-menu-static"
  • Overlay: "layout-menu-overlay"
  • Popup: "layout-menu-popup"

For example to create a static menu, the div element should be in following form;


<div class="layout-wrapper layout-menu-static">
    ...
</div>

Icons

Verona Layout uses PrimeIcons v5.0 for layout which is included in the resources and no configuration is required.

Outlined vs Filled

Input fields come in two styles, default is outlined with borders around the field whereas filled alternative adds a background color to the field. Applying ui-input-filled to an ancestor of an input enables the filled style. If you prefer to use filled inputs in the entire application, use a global container such as document body or the application element to apply the style class.


<div class="ui-input-filled">
    <p:inputText type="text" />
</div>

Card

Card is a section to group content and layout provides a built-in css for it. Apply .card style class to your container to use it. If the card has a title defined with h1 tag, add card-w-title to adjust paddings.


<div class="card">
    Content here
</div>

<div class="card card-w-title">
    <h1>Card with Title<h1>
    Content here
</div>

Tips

  • Familiarity with SASS is required to make customizations to the layout and theme.
  • Demo application war and the maven project tag are included in distribution however you don't necessarily need them to install Verona, the actual artifacts required are the layout zip file and the theme jar.
  • Sample demo application war includes the JSF libraries so it is suggested to remove them from the war file when you deploy to an appserver.
  • When running the maven project, you need to build the sass with (sass --update src/main/webapp/resources:src/main/webapp/resources --no-source-map) command.

Migration Guide

Every change is included in CHANGELOG.md file at the root folder of the distribution along with the instructions to update.