Updated WeaponLabelIcon styles
This commit is contained in:
parent
e35879d03c
commit
4f1bcf5bca
2 changed files with 10 additions and 2 deletions
|
|
@ -1,4 +1,4 @@
|
||||||
.WeaponLabelIcon {
|
.icon {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
background-size: 60px 25px;
|
background-size: 60px 25px;
|
||||||
height: 25px;
|
height: 25px;
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import { useRouter } from 'next/router'
|
import { useRouter } from 'next/router'
|
||||||
|
import classNames from 'classnames'
|
||||||
|
|
||||||
import styles from './index.module.scss'
|
import styles from './index.module.scss'
|
||||||
|
|
||||||
|
|
@ -10,7 +11,14 @@ interface Props {
|
||||||
const WeaponLabelIcon = (props: Props) => {
|
const WeaponLabelIcon = (props: Props) => {
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
|
|
||||||
return <i className={`WeaponLabelIcon ${props.labelType} ${router.locale}`} />
|
const classes = classNames({
|
||||||
|
[styles.icon]: true,
|
||||||
|
[styles[props.labelType]]: true,
|
||||||
|
[styles.en]: router.locale === 'en',
|
||||||
|
[styles.ja]: router.locale === 'ja',
|
||||||
|
})
|
||||||
|
|
||||||
|
return <i className={classes} />
|
||||||
}
|
}
|
||||||
|
|
||||||
export default WeaponLabelIcon
|
export default WeaponLabelIcon
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue