File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed
client/src/components/BadgesScreen Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -52,13 +52,16 @@ export const BadgesScreen = () => {
5252 < div className = "grid grid-cols-3 gap-2 pt-4" >
5353 { badges &&
5454 Object . values ( badges ) . map ( ( badge ) => {
55- const hasBadge = visitorInventory && Object . keys ( visitorInventory ) . includes ( badge . name ) ;
56- const style = { width : "90px" } ;
55+ const { name, description, icon } = badge ;
56+ const hasBadge = visitorInventory && Object . keys ( visitorInventory ) . includes ( name ) ;
57+ const style = { width : "90px" , filter : "none" } ;
5758 if ( ! hasBadge ) style . filter = "grayscale(1)" ;
5859 return (
59- < div className = "tooltip m-auto" key = { badge . id } >
60- < span className = "tooltip-content" > { badge . name } </ span >
61- < img src = { badge . icon } alt = { badge . name } style = { style } />
60+ < div className = "tooltip" key = { name } >
61+ < span className = "tooltip-content" style = { { width : "115px" } } >
62+ { name } { description && `- ${ description } ` }
63+ </ span >
64+ < img src = { icon } alt = { name } style = { style } />
6265 </ div >
6366 ) ;
6467 } ) }
You can’t perform that action at this time.
0 commit comments