move logo into the badge

This commit is contained in:
softsimon 2024-07-08 22:47:49 +09:00
parent c391a532de
commit 432496d2a0
No known key found for this signature in database
GPG Key ID: 488D7DCFB5A430D7
4 changed files with 12 additions and 8 deletions

View File

@ -183,6 +183,7 @@
<td *ngIf="stateService.env.MINING_DASHBOARD">
<a placement="bottom" [routerLink]="['/mining/pool' | relativeUrl, block.extras.pool.slug]" class="badge"
[class]="block.extras.pool.slug === 'unknown' ? 'badge-secondary' : 'badge-primary'">
<img class="pool-logo" [src]="'/resources/mining-pools/' + block.extras.pool.slug + '.svg'" onError="this.src = '/resources/mining-pools/default.svg'" [alt]="'Logo of ' + block.extras.pool.name + ' mining pool'">
{{ block.extras.pool.name }}
</a>
</td>

View File

@ -272,3 +272,10 @@ h1 {
}
}
}
.pool-logo {
width: 12px;
height: 12px;
position: relative;
top: 0px;
}

View File

@ -60,10 +60,8 @@
</ng-container>
</div>
<div class="animated" [class]="markHeight === block.height ? 'hide' : 'show'" *ngIf="block.extras?.pool != undefined && showPools">
<a [routerLink]="[('/mining/pool/' + block.extras.pool.slug) | relativeUrl]">
<img class="pool-logo" [src]="'/resources/mining-pools/' + block.extras.pool.slug + '.svg'" onError="this.src = '/resources/mining-pools/default.svg'" [alt]="'Logo of ' + block.extras.pool.name + ' mining pool'">
</a>
<a [attr.data-cy]="'bitcoin-block-' + offset + '-index-' + i + '-pool'" class="badge badge-primary" [routerLink]="[('/mining/pool/' + block.extras.pool.slug) | relativeUrl]">
<img class="pool-logo" [src]="'/resources/mining-pools/' + block.extras.pool.slug + '.svg'" onError="this.src = '/resources/mining-pools/default.svg'" [alt]="'Logo of ' + block.extras.pool.name + ' mining pool'">
{{ block.extras.pool.name}}
</a>
</div>

View File

@ -157,15 +157,13 @@
position: relative;
top: 15px;
z-index: 101;
left: -7.5px;
}
.pool-logo {
width: 15px;
height: 15px;
width: 12px;
height: 12px;
position: relative;
top: 15px;
left: -12px;
top: -1px;
}
.animated {