GBC 5.01.03 new features and upgrade notes
A summary of new features and changes in functionality introduced with Genero Browser Client (GBC) 5.01.03. Note the changes you may need to make when moving to this version of the GBC.
This page covers only those new features introduced with the Genero Browser Client version specified in the page title. Check prior new features pages if you migrate from an earlier version.
For a detailed list of GBC 5.01.03 changes, please refer to the list of fixes on our issue tracker.
Previous new features page: GBC 5.01.02 new features and upgrade notes.
Widgets refactored to comply with BEM notation
We have refactored multiple GBC widgets to comply with the BEM structured naming convention for CSS classes.
BEM, which stands for block, element, modifier, is a methodology for naming and organizing CSS classes in a way that makes it clearer what widget each CSS class represents and how it relates to other classes.
The objective is to reduce CSS selector nesting and improve selector precision, which will ease the load on the browser's CSS engine for better performance, while also keeping the code easy to maintain. Each selector should clearly convey its purpose at a glance.
For details of the changes to the naming of widget classes, go to Widget CSS class naming pattern.
For the list of CSS classes implemented with BEM for this release, go to What is changing in CSS?. You may need to review JavaScript in your existing customizations for changes described in What is changing in JavaScript?.
What is changing in CSS?
To provide better visual feedback, the outline for the hover, focus, and activate state layers has been moved inside the widget to prevent cropped rendering. Additionally, the outline has been replaced with an inset box-shadow to avoid any issues with border width collision.
We have removed the file ChoiceDropDownWidget.scss, and moved its contents into DropDownWidget.scss file.
gbc_ListDropDownWidget__item
gbc_ListDropDownWidget__itemIcon
gbc_ListDropDownWidget__itemText
gbc_RadioGroupWidget__item
gbc_RadioGroupWidget__itemIcon
gbc_RadioGroupWidget__itemText
gbc_ToggleCheckBoxWidget__container
gbc_ToggleCheckBoxWidget__box
gbc_ToggleCheckBoxWidget__label
gbc_ToggleCheckBoxWidget__input
gbc_ToggleCheckBoxWidget__text
What is changing in JavaScript?
- A new method,
WidgetBase.getBEMPartName(partName: string)
, has been introduced to facilitate easy DOM element querying using BEM notation for widget element initialization. - The
CheckBoxWidget
no longer creates and adds the text HTMLElement when callingsetText()
. The widget construction includes it. - The WidgetEvents constants file now contains the DropDown static variables for events.
CheckBoxWidget variable
Variable | Comment |
---|---|
$gbc-CheckBoxWidget-gap | Defines the space between the checkbox and the text. |
DropDown widget items variables
Variable | Comment |
---|---|
$gbc-DropDownWidget-item-current-background-color | Background color of the current item of the Dropdown widget. |
$gbc-DropDownWidget-item-current-disabled-background-color | Background color of the current item of the Dropdown widget when disabled. |
$gbc-DropDownWidget-item-hover-background-color | Background color of hovered item of Dropdown widget. |
$gbc-DropDownWidget-item-checked-color | Color of the selected/checked items. |
$gbc-DropDownWidget-item-unchecked-color | Color of the unselected/unchecked items. |
$gbc-DropDownWidget-item-checked-icon | Icon used for the ListDropDownWidget checked items when multiple choices are possible. |
$gbc-DropDownWidget-item-unchecked-icon | Icon used for the ListDropDownWidget unchecked items when multiple choices are possible. |
$gbc-DropDownWidget-item-selected-icon | Icon used for the ListDropDownWidget selected item when only a single choice is possible. |
$gbc-DropDownWidget-item-icon-size | Icon size of items in Dropdown widget. |
DropDown widget default values changing
There are slight changes to default values for the DropDown widget margin variable:
Variable | Comment |
---|---|
$gbc-DropDownWidget-margin | using $theme-combobox-margin *
$gbc-DropDownWidget-margin-ratio rather than
$theme-combobox-margin |
DropDown widget variables removed
Three DropDown widget variables are removed.
Variable | Comment |
---|---|
$gbc-DropDownWidget-item-current-background-color |
Variable removed |
$gbc-DropDownWidget-item-current-disabled-background-color |
Variable removed |
$gbc-DropDownWidget-item-hover-background-color |
Variable removed |
DropDown widget state layer variable removed
One DropDown widget state layer variable is removed.
Variable | Comment |
---|---|
$gbc-DropDownWidget-hover-border-width |
Variable removed |
DropDown widget state layer default values changing
There are new default values for DropDown widget state layer variables:
Variable | Comment |
---|---|
$gbc-DropDownWidget-hover-color | using $theme-focus-border-width rather than
$gbc-mt-field-focus-border-width |
$gbc-DropDownWidget-focus-border-width | using $theme-active-border-width rather than
$gbc-mt-field-active-border-width |
RadioGroup widget variables
*padding
variables available:Variable | Comment |
---|---|
$gbc-RadioGroupWidget-padding | Space between radio group items. |
$gbc-RadioGroupWidget-item-padding | Space between radio group items. |
mt-field state layer default values changing
There are new default values for mt-field state layer *border-width
variables:
Variable | Comment |
---|---|
Theme state layer | using $theme-hover-border-width - $mt-field-border-width-top
rather than $theme-hover-border-width |
Theme state layer | using $theme-focus-border-width - $mt-field-border-width-top
rather than $theme-focus-border-width |
Theme state layer | using $theme-focus-border-width - $mt-field-border-width-top
rather than $theme-focus-border-width |
SliderWidget variable
Variable | Comment |
---|---|
$gbc-SliderWidget-border-radius | Border radius of the Slider Widget |
Slider widget default values changing
There are slight changes to default values for Slider widget padding variables:
Variable | Comment |
---|---|
$gbc-sliderWidget-horizontal-padding | using $theme-space-s * $theme-field-height-ratio rather than
$theme-space-xs * $theme-field-height-ratio |
$gbc-sliderWidget-vertical-padding | using $theme-space-xs * $theme-field-height-ratio rather
than $theme-space-xxs *$theme-field-height-ratio |
Application host variables
Variable | Comment |
---|---|
$gbc-ApplicationSettingsWidget-alertTopic-background-color | Background color of the message in ApplicationHostSettings Widget |
$gbc-ApplicationSettingsWidget-message-background-color | Background color of the message in ApplicationHostSettingsWidget |
Changes to theme color variables
The theme variables for the main color palettes have been deprecated in favor of an improved system. While theme colors were previously defined by these main color palettes, they are now being replaced with new default values for theme color variables, offering greater flexibility and consistency. For more information on these enhancements to the theme color variables, go to Main variables.