mirror of
https://github.com/chubin/wttr.in
synced 2025-01-26 02:34:59 +00:00
lib/constants.py: added WEATHER_SYMBOL_WIDTH_VTE, LOCALE, etc.
This commit is contained in:
parent
ad987b7a24
commit
50dff37040
1 changed files with 158 additions and 0 deletions
158
lib/constants.py
158
lib/constants.py
|
@ -73,6 +73,164 @@ WEATHER_SYMBOL = {
|
|||
"VeryCloudy": u"☁️",
|
||||
}
|
||||
|
||||
WEATHER_SYMBOL_WIDTH_VTE = {
|
||||
u"✨": 2,
|
||||
u"☁️": 1,
|
||||
u"🌫": 1,
|
||||
u"🌧": 2,
|
||||
u"🌧": 2,
|
||||
u"❄️": 1,
|
||||
u"❄️": 1,
|
||||
u"🌦": 1,
|
||||
u"🌦": 1,
|
||||
u"🌧": 1,
|
||||
u"🌧": 1,
|
||||
u"🌨": 2,
|
||||
u"🌨": 2,
|
||||
u"⛅️": 2,
|
||||
u"☀️": 1,
|
||||
u"🌩": 2,
|
||||
u"⛈": 1,
|
||||
u"⛈": 1,
|
||||
u"☁️": 1,
|
||||
}
|
||||
|
||||
WIND_DIRECTION = [
|
||||
u"↓", u"↙", u"←", u"↖", u"↑", u"↗", u"→", u"↘",
|
||||
]
|
||||
|
||||
MOON_PHASES = (
|
||||
u"🌑", u"🌒", u"🌓", u"🌔", u"🌕", u"🌖", u"🌗", u"🌘"
|
||||
)
|
||||
|
||||
WEATHER_SYMBOL_WEGO = {
|
||||
"Unknown": [
|
||||
" .-. ",
|
||||
" __) ",
|
||||
" ( ",
|
||||
" `-’ ",
|
||||
" • "],
|
||||
"Sunny": [
|
||||
"\033[38;5;226m \\ / \033[0m",
|
||||
"\033[38;5;226m .-. \033[0m",
|
||||
"\033[38;5;226m ― ( ) ― \033[0m",
|
||||
"\033[38;5;226m `-’ \033[0m",
|
||||
"\033[38;5;226m / \\ \033[0m"],
|
||||
"PartlyCloudy": [
|
||||
"\033[38;5;226m \\ /\033[0m ",
|
||||
"\033[38;5;226m _ /\"\"\033[38;5;250m.-. \033[0m",
|
||||
"\033[38;5;226m \\_\033[38;5;250m( ). \033[0m",
|
||||
"\033[38;5;226m /\033[38;5;250m(___(__) \033[0m",
|
||||
" "],
|
||||
"Cloudy": [
|
||||
" ",
|
||||
"\033[38;5;250m .--. \033[0m",
|
||||
"\033[38;5;250m .-( ). \033[0m",
|
||||
"\033[38;5;250m (___.__)__) \033[0m",
|
||||
" "],
|
||||
"VeryCloudy": [
|
||||
" ",
|
||||
"\033[38;5;240;1m .--. \033[0m",
|
||||
"\033[38;5;240;1m .-( ). \033[0m",
|
||||
"\033[38;5;240;1m (___.__)__) \033[0m",
|
||||
" "],
|
||||
"LightShowers": [
|
||||
"\033[38;5;226m _`/\"\"\033[38;5;250m.-. \033[0m",
|
||||
"\033[38;5;226m ,\\_\033[38;5;250m( ). \033[0m",
|
||||
"\033[38;5;226m /\033[38;5;250m(___(__) \033[0m",
|
||||
"\033[38;5;111m ‘ ‘ ‘ ‘ \033[0m",
|
||||
"\033[38;5;111m ‘ ‘ ‘ ‘ \033[0m"],
|
||||
"HeavyShowers": [
|
||||
"\033[38;5;226m _`/\"\"\033[38;5;240;1m.-. \033[0m",
|
||||
"\033[38;5;226m ,\\_\033[38;5;240;1m( ). \033[0m",
|
||||
"\033[38;5;226m /\033[38;5;240;1m(___(__) \033[0m",
|
||||
"\033[38;5;21;1m ‚‘‚‘‚‘‚‘ \033[0m",
|
||||
"\033[38;5;21;1m ‚’‚’‚’‚’ \033[0m"],
|
||||
"LightSnowShowers": [
|
||||
"\033[38;5;226m _`/\"\"\033[38;5;250m.-. \033[0m",
|
||||
"\033[38;5;226m ,\\_\033[38;5;250m( ). \033[0m",
|
||||
"\033[38;5;226m /\033[38;5;250m(___(__) \033[0m",
|
||||
"\033[38;5;255m * * * \033[0m",
|
||||
"\033[38;5;255m * * * \033[0m"],
|
||||
"HeavySnowShowers": [
|
||||
"\033[38;5;226m _`/\"\"\033[38;5;240;1m.-. \033[0m",
|
||||
"\033[38;5;226m ,\\_\033[38;5;240;1m( ). \033[0m",
|
||||
"\033[38;5;226m /\033[38;5;240;1m(___(__) \033[0m",
|
||||
"\033[38;5;255;1m * * * * \033[0m",
|
||||
"\033[38;5;255;1m * * * * \033[0m"],
|
||||
"LightSleetShowers": [
|
||||
"\033[38;5;226m _`/\"\"\033[38;5;250m.-. \033[0m",
|
||||
"\033[38;5;226m ,\\_\033[38;5;250m( ). \033[0m",
|
||||
"\033[38;5;226m /\033[38;5;250m(___(__) \033[0m",
|
||||
"\033[38;5;111m ‘ \033[38;5;255m*\033[38;5;111m ‘ \033[38;5;255m* \033[0m",
|
||||
"\033[38;5;255m *\033[38;5;111m ‘ \033[38;5;255m*\033[38;5;111m ‘ \033[0m"],
|
||||
"ThunderyShowers": [
|
||||
"\033[38;5;226m _`/\"\"\033[38;5;250m.-. \033[0m",
|
||||
"\033[38;5;226m ,\\_\033[38;5;250m( ). \033[0m",
|
||||
"\033[38;5;226m /\033[38;5;250m(___(__) \033[0m",
|
||||
"\033[38;5;228;5m ⚡\033[38;5;111;25m‘‘\033[38;5;228;5m⚡\033[38;5;111;25m‘‘ \033[0m",
|
||||
"\033[38;5;111m ‘ ‘ ‘ ‘ \033[0m"],
|
||||
"ThunderyHeavyRain": [
|
||||
"\033[38;5;240;1m .-. \033[0m",
|
||||
"\033[38;5;240;1m ( ). \033[0m",
|
||||
"\033[38;5;240;1m (___(__) \033[0m",
|
||||
"\033[38;5;21;1m ‚‘\033[38;5;228;5m⚡\033[38;5;21;25m‘‚\033[38;5;228;5m⚡\033[38;5;21;25m‚‘ \033[0m",
|
||||
"\033[38;5;21;1m ‚’‚’\033[38;5;228;5m⚡\033[38;5;21;25m’‚’ \033[0m"],
|
||||
"ThunderySnowShowers": [
|
||||
"\033[38;5;226m _`/\"\"\033[38;5;250m.-. \033[0m",
|
||||
"\033[38;5;226m ,\\_\033[38;5;250m( ). \033[0m",
|
||||
"\033[38;5;226m /\033[38;5;250m(___(__) \033[0m",
|
||||
"\033[38;5;255m *\033[38;5;228;5m⚡\033[38;5;255;25m*\033[38;5;228;5m⚡\033[38;5;255;25m* \033[0m",
|
||||
"\033[38;5;255m * * * \033[0m"],
|
||||
"LightRain": [
|
||||
"\033[38;5;250m .-. \033[0m",
|
||||
"\033[38;5;250m ( ). \033[0m",
|
||||
"\033[38;5;250m (___(__) \033[0m",
|
||||
"\033[38;5;111m ‘ ‘ ‘ ‘ \033[0m",
|
||||
"\033[38;5;111m ‘ ‘ ‘ ‘ \033[0m"],
|
||||
"HeavyRain": [
|
||||
"\033[38;5;240;1m .-. \033[0m",
|
||||
"\033[38;5;240;1m ( ). \033[0m",
|
||||
"\033[38;5;240;1m (___(__) \033[0m",
|
||||
"\033[38;5;21;1m ‚‘‚‘‚‘‚‘ \033[0m",
|
||||
"\033[38;5;21;1m ‚’‚’‚’‚’ \033[0m"],
|
||||
"LightSnow": [
|
||||
"\033[38;5;250m .-. \033[0m",
|
||||
"\033[38;5;250m ( ). \033[0m",
|
||||
"\033[38;5;250m (___(__) \033[0m",
|
||||
"\033[38;5;255m * * * \033[0m",
|
||||
"\033[38;5;255m * * * \033[0m"],
|
||||
"HeavySnow": [
|
||||
"\033[38;5;240;1m .-. \033[0m",
|
||||
"\033[38;5;240;1m ( ). \033[0m",
|
||||
"\033[38;5;240;1m (___(__) \033[0m",
|
||||
"\033[38;5;255;1m * * * * \033[0m",
|
||||
"\033[38;5;255;1m * * * * \033[0m"],
|
||||
"LightSleet": [
|
||||
"\033[38;5;250m .-. \033[0m",
|
||||
"\033[38;5;250m ( ). \033[0m",
|
||||
"\033[38;5;250m (___(__) \033[0m",
|
||||
"\033[38;5;111m ‘ \033[38;5;255m*\033[38;5;111m ‘ \033[38;5;255m* \033[0m",
|
||||
"\033[38;5;255m *\033[38;5;111m ‘ \033[38;5;255m*\033[38;5;111m ‘ \033[0m"],
|
||||
"Fog": [
|
||||
" ",
|
||||
"\033[38;5;251m _ - _ - _ - \033[0m",
|
||||
"\033[38;5;251m _ - _ - _ \033[0m",
|
||||
"\033[38;5;251m _ - _ - _ - \033[0m",
|
||||
" "],
|
||||
}
|
||||
|
||||
LOCALE = {
|
||||
"af": "af_ZA", "ar": "ar_TN", "az": "az_AZ", "be": "be_BY", "bg": "bg_BG",
|
||||
"bs": "bs_BA", "ca": "ca_ES", "cs": "cs_CZ", "cy": "cy_GB", "da": "da_DK",
|
||||
"de": "de_DE", "el": "el_GR", "eo": "eo", "es": "es_ES", "et": "et_EE",
|
||||
"fa": "fa_IR", "fi": "fi_FI", "fr": "fr_FR", "fy": "fy_NL", "ga": "ga_IE",
|
||||
"he": "he_IL", "hr": "hr_HR", "hu": "hu_HU", "hy": "hy_AM", "id": "id_ID",
|
||||
"is": "is_IS", "it": "it_IT", "ja": "ja_JP", "jv": "en_US", "ka": "ka_GE",
|
||||
"ko": "ko_KR", "kk": "kk_KZ", "ky": "ky_KG", "lt": "lt_LT", "lv": "lv_LV",
|
||||
"mk": "mk_MK", "ml": "ml_IN", "nb": "nb_NO", "nl": "nl_NL", "nn": "nn_NO",
|
||||
"pt": "pt_PT", "pt-br":"pt_BR", "pl": "pl_PL", "ro": "ro_RO", "ru": "ru_RU",
|
||||
"sv": "sv_SE", "sk": "sk_SK", "sl": "sl_SI", "sr": "sr_RS", "sr-lat": "sr_RS@latin",
|
||||
"sw": "sw_KE", "th": "th_TH", "tr": "tr_TR", "uk": "uk_UA", "uz": "uz_UZ",
|
||||
"vi": "vi_VN", "zh": "zh_TW", "zu": "zu_ZA",
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue