Add perpetuity to hovercard portrait
This commit is contained in:
parent
2ef1863637
commit
3d7726918e
2 changed files with 28 additions and 4 deletions
|
|
@ -1,4 +1,19 @@
|
||||||
.Character.HovercardContent {
|
.Character.HovercardContent {
|
||||||
|
.title .Image {
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
.Perpetuity {
|
||||||
|
position: absolute;
|
||||||
|
background-image: url('/icons/perpetuity/filled.svg');
|
||||||
|
background-size: $unit-3x $unit-3x;
|
||||||
|
z-index: 20;
|
||||||
|
top: $unit-half * -1;
|
||||||
|
right: $unit-3x;
|
||||||
|
width: $unit-3x;
|
||||||
|
height: $unit-3x;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.Mastery {
|
.Mastery {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|
|
||||||
|
|
@ -65,6 +65,12 @@ const CharacterHovercard = (props: Props) => {
|
||||||
window.open(url, '_blank')
|
window.open(url, '_blank')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const perpetuity = () => {
|
||||||
|
if (props.gridCharacter && props.gridCharacter.perpetuity) {
|
||||||
|
return <i className="Perpetuity" />
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function characterImage() {
|
function characterImage() {
|
||||||
let imgSrc = ''
|
let imgSrc = ''
|
||||||
|
|
||||||
|
|
@ -223,11 +229,14 @@ const CharacterHovercard = (props: Props) => {
|
||||||
<div className="top">
|
<div className="top">
|
||||||
<div className="title">
|
<div className="title">
|
||||||
<h4>{props.gridCharacter.object.name[locale]}</h4>
|
<h4>{props.gridCharacter.object.name[locale]}</h4>
|
||||||
|
<div className="Image">
|
||||||
|
{perpetuity()}
|
||||||
<img
|
<img
|
||||||
alt={props.gridCharacter.object.name[locale]}
|
alt={props.gridCharacter.object.name[locale]}
|
||||||
src={characterImage()}
|
src={characterImage()}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<div className="subInfo">
|
<div className="subInfo">
|
||||||
<div className="icons">
|
<div className="icons">
|
||||||
<WeaponLabelIcon
|
<WeaponLabelIcon
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue