imba-localization 0.3.5 → 0.3.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/localization.imba +8 -1
- package/package.json +1 -1
package/localization.imba
CHANGED
|
@@ -58,10 +58,17 @@ tag language-selector
|
|
|
58
58
|
icons = "https://kapowaz.github.io/square-flags/flags/##.svg"
|
|
59
59
|
#dropdown = false
|
|
60
60
|
arrow = path-arrow-down
|
|
61
|
+
|
|
62
|
+
def setup
|
|
63
|
+
if data
|
|
64
|
+
state.active = data
|
|
65
|
+
else
|
|
66
|
+
data = state.active
|
|
61
67
|
|
|
62
68
|
def onselect key
|
|
63
69
|
#dropdown = false
|
|
64
|
-
|
|
70
|
+
data = key
|
|
71
|
+
state.active = key
|
|
65
72
|
|
|
66
73
|
def icon country
|
|
67
74
|
return icons.replace('##',country)
|