File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed
src/main/java/com/flowingcode/vaadin/addons/localecombobox Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -56,10 +56,14 @@ public LocaleComboBox() {
5656
5757 private LitRenderer <Locale > getLocaleRenderer () {
5858 return LitRenderer
59- .<Locale >of ("<vaadin-horizontal-layout class=\" " + ITEM_LAYOUT_CLASS_NAME + "\" >"
60- + "<span class=\" fi fi-${item.countryCode} " + ITEM_FLAG_CLASS_NAME
61- + "\" alt=\" ${item.countryName}\' s flag\" ></span>" + "<span>${item.displayName}</span>"
62- + "</vaadin-horizontal-layout>" )
59+ .<Locale >of (
60+ """
61+ <vaadin-horizontal-layout class="${item.layoutClass}">
62+ <span class="fi fi-${item.countryCode} ${item.flagClass} alt="${item.countryName}'s flag"></span>
63+ <span>${item.displayName}</span>
64+ </vaadin-horizontal-layout>""" )
65+ .withProperty ("layoutClass" , loc -> ITEM_LAYOUT_CLASS_NAME )
66+ .withProperty ("flagClass" , loc -> ITEM_FLAG_CLASS_NAME )
6367 .withProperty ("countryCode" , loc -> loc .getCountry ().toLowerCase ())
6468 .withProperty ("countryName" , loc -> loc .getDisplayCountry ())
6569 .withProperty ("displayName" , loc -> loc .getDisplayName ());
You can’t perform that action at this time.
0 commit comments