File tree Expand file tree Collapse file tree 1 file changed +28
-18
lines changed
apps/frontend/src/components/ui/charts Expand file tree Collapse file tree 1 file changed +28
-18
lines changed Original file line number Diff line number Diff line change 192
192
class =" country-value"
193
193
>
194
194
<div class =" country-flag-container" >
195
- <img
196
- :src ="
197
- name.toLowerCase() === 'xx' || !name
198
- ? 'https://cdn.modrinth.com/placeholder-banner.svg'
199
- : countryCodeToFlag(name)
200
- "
201
- alt =" Hidden country"
202
- class =" country-flag"
203
- />
195
+ <template v-if =" name .toLowerCase () === ' xx' || ! name " >
196
+ <img
197
+ src =" https://cdn.modrinth.com/placeholder-banner.svg"
198
+ alt =" Placeholder flag"
199
+ class =" country-flag"
200
+ />
201
+ </template >
202
+ <template v-else >
203
+ <img
204
+ :src =" countryCodeToFlag(name)"
205
+ :alt =" `${countryCodeToName(name)}'s flag`"
206
+ class =" country-flag"
207
+ />
208
+ </template >
204
209
</div >
205
210
<div class =" country-text" >
206
211
<strong class =" country-name"
246
251
class =" country-value"
247
252
>
248
253
<div class =" country-flag-container" >
249
- <img
250
- :src ="
251
- name.toLowerCase() === 'xx' || !name
252
- ? 'https://cdn.modrinth.com/placeholder-banner.svg'
253
- : countryCodeToFlag(name)
254
- "
255
- alt =" Hidden country"
256
- class =" country-flag"
257
- />
254
+ <template v-if =" name .toLowerCase () === ' xx' || ! name " >
255
+ <img
256
+ src =" https://cdn.modrinth.com/placeholder-banner.svg"
257
+ alt =" Placeholder flag"
258
+ class =" country-flag"
259
+ />
260
+ </template >
261
+ <template v-else >
262
+ <img
263
+ :src =" countryCodeToFlag(name)"
264
+ :alt =" `${countryCodeToName(name)}'s flag`"
265
+ class =" country-flag"
266
+ />
267
+ </template >
258
268
</div >
259
269
<div class =" country-text" >
260
270
<strong class =" country-name" >
You can’t perform that action at this time.
0 commit comments