Spaces:
Running
Running
Alejandro Cremades
commited on
Commit
·
c955f0a
1
Parent(s):
dc2bac2
Bonus: minor localization fixes
Browse files- Middle_School_Card_Search.py +6 -6
- streamlit_common/locale.py +30 -28
Middle_School_Card_Search.py
CHANGED
@@ -56,17 +56,17 @@ results_df = results_en_df.merge(results_ja_df, how="outer")
|
|
56 |
colorcol6,
|
57 |
) = st.columns(7)
|
58 |
colorcol0.write(_["search"]["search_by_color"][l])
|
59 |
-
if colorcol1.checkbox(_["
|
60 |
results_df = results_df[results_df["w"] == True]
|
61 |
-
if colorcol2.checkbox(_["
|
62 |
results_df = results_df[results_df["u"] == True]
|
63 |
-
if colorcol3.checkbox(_["
|
64 |
results_df = results_df[results_df["b"] == True]
|
65 |
-
if colorcol4.checkbox(_["
|
66 |
results_df = results_df[results_df["r"] == True]
|
67 |
-
if colorcol5.checkbox(_["
|
68 |
results_df = results_df[results_df["g"] == True]
|
69 |
-
if colorcol6.checkbox(_["
|
70 |
results_df = results_df[results_df["c"] == True]
|
71 |
|
72 |
col1, col2 = st.columns(2)
|
|
|
56 |
colorcol6,
|
57 |
) = st.columns(7)
|
58 |
colorcol0.write(_["search"]["search_by_color"][l])
|
59 |
+
if colorcol1.checkbox(_["basic"]["color_w"][l]):
|
60 |
results_df = results_df[results_df["w"] == True]
|
61 |
+
if colorcol2.checkbox(_["basic"]["color_u"][l]):
|
62 |
results_df = results_df[results_df["u"] == True]
|
63 |
+
if colorcol3.checkbox(_["basic"]["color_b"][l]):
|
64 |
results_df = results_df[results_df["b"] == True]
|
65 |
+
if colorcol4.checkbox(_["basic"]["color_r"][l]):
|
66 |
results_df = results_df[results_df["r"] == True]
|
67 |
+
if colorcol5.checkbox(_["basic"]["color_g"][l]):
|
68 |
results_df = results_df[results_df["g"] == True]
|
69 |
+
if colorcol6.checkbox(_["basic"]["color_c"][l]):
|
70 |
results_df = results_df[results_df["c"] == True]
|
71 |
|
72 |
col1, col2 = st.columns(2)
|
streamlit_common/locale.py
CHANGED
@@ -34,30 +34,6 @@ def get_locale():
|
|
34 |
"en": "Color:",
|
35 |
"ja": "色:",
|
36 |
},
|
37 |
-
"color_w": {
|
38 |
-
"en": "W",
|
39 |
-
"ja": "白",
|
40 |
-
},
|
41 |
-
"color_u": {
|
42 |
-
"en": "U",
|
43 |
-
"ja": "青",
|
44 |
-
},
|
45 |
-
"color_b": {
|
46 |
-
"en": "B",
|
47 |
-
"ja": "黒",
|
48 |
-
},
|
49 |
-
"color_r": {
|
50 |
-
"en": "R",
|
51 |
-
"ja": "赤",
|
52 |
-
},
|
53 |
-
"color_g": {
|
54 |
-
"en": "G",
|
55 |
-
"ja": "緑",
|
56 |
-
},
|
57 |
-
"color_c": {
|
58 |
-
"en": "C",
|
59 |
-
"ja": "無/茶",
|
60 |
-
},
|
61 |
"cards_found": {
|
62 |
"en": " cards were found.",
|
63 |
"ja": "枚 のカードが見つかりました。",
|
@@ -67,12 +43,12 @@ def get_locale():
|
|
67 |
"ja": "上位の検索結果:",
|
68 |
},
|
69 |
"see_more": {
|
70 |
-
"en": "See more",
|
71 |
-
"ja": "
|
72 |
},
|
73 |
"see_20": {
|
74 |
-
"en": "
|
75 |
-
"ja": "20
|
76 |
},
|
77 |
},
|
78 |
"check": {
|
@@ -97,4 +73,30 @@ def get_locale():
|
|
97 |
"ja": "**枚",
|
98 |
},
|
99 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
100 |
}
|
|
|
34 |
"en": "Color:",
|
35 |
"ja": "色:",
|
36 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
37 |
"cards_found": {
|
38 |
"en": " cards were found.",
|
39 |
"ja": "枚 のカードが見つかりました。",
|
|
|
43 |
"ja": "上位の検索結果:",
|
44 |
},
|
45 |
"see_more": {
|
46 |
+
"en": "See more results",
|
47 |
+
"ja": "さらに表示する",
|
48 |
},
|
49 |
"see_20": {
|
50 |
+
"en": "Reset to 20 results",
|
51 |
+
"ja": "上位20枚表示に戻す",
|
52 |
},
|
53 |
},
|
54 |
"check": {
|
|
|
73 |
"ja": "**枚",
|
74 |
},
|
75 |
},
|
76 |
+
"basic": {
|
77 |
+
"color_w": {
|
78 |
+
"en": "W",
|
79 |
+
"ja": "白",
|
80 |
+
},
|
81 |
+
"color_u": {
|
82 |
+
"en": "U",
|
83 |
+
"ja": "青",
|
84 |
+
},
|
85 |
+
"color_b": {
|
86 |
+
"en": "B",
|
87 |
+
"ja": "黒",
|
88 |
+
},
|
89 |
+
"color_r": {
|
90 |
+
"en": "R",
|
91 |
+
"ja": "赤",
|
92 |
+
},
|
93 |
+
"color_g": {
|
94 |
+
"en": "G",
|
95 |
+
"ja": "緑",
|
96 |
+
},
|
97 |
+
"color_c": {
|
98 |
+
"en": "C",
|
99 |
+
"ja": "無/茶",
|
100 |
+
},
|
101 |
+
},
|
102 |
}
|