Skip to content

Commit

Permalink
refactor: set min width for translator
Browse files Browse the repository at this point in the history
  • Loading branch information
dfguerrerom committed Sep 11, 2024
1 parent d22f3ce commit 86ad6a9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions sepal_ui/sepalwidgets/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from sepal_ui import sepalwidgets as sw
sw.LocaleSelect()
sw.LocaleSelect()`
"""

from datetime import datetime
Expand Down Expand Up @@ -87,6 +87,7 @@ def __init__(self, translator: Optional[Translator] = None, **kwargs) -> None:
kwargs["v_model"] = False
kwargs["v_on"] = "x.on"
kwargs["children"] = [self.locale_icon, code]
kwargs["min_width"] = 95

self.btn = v.Btn(**kwargs)

Expand Down Expand Up @@ -152,7 +153,7 @@ def _on_locale_select(self, change: dict) -> None:
loc = self.COUNTRIES[self.COUNTRIES.code == change["new"]].squeeze()

self.btn.children = [self.locale_icon, loc.code]
self.btn.color = "info"
# self.btn.color = "info"

# change the parameter file
su.set_config("locale", loc.code)
Expand Down

0 comments on commit 86ad6a9

Please sign in to comment.