Fix default mining pool img fallback behavior
This commit is contained in:
		
							parent
							
								
									4e26e1f196
								
							
						
					
					
						commit
						e6fb93140c
					
				| @ -33,7 +33,7 @@ | |||||||
|             <div *ngIf="indexingAvailable" class="tooltip-custom"> |             <div *ngIf="indexingAvailable" class="tooltip-custom"> | ||||||
|               <a class="clear-link" [routerLink]="['/mining/pool' | relativeUrl, block.extras.pool.slug]"> |               <a class="clear-link" [routerLink]="['/mining/pool' | relativeUrl, block.extras.pool.slug]"> | ||||||
|                 <img width="22" height="22" src="{{ block.extras.pool['logo'] }}" |                 <img width="22" height="22" src="{{ block.extras.pool['logo'] }}" | ||||||
|                   onError="this.src = '/resources/mining-pools/default.svg'" [alt]="'Logo of ' + block.extras.pool.name + ' mining pool'"> |                   onError="this.onerror=null; this.src = '/resources/mining-pools/default.svg'" [alt]="'Logo of ' + block.extras.pool.name + ' mining pool'"> | ||||||
|                 <span class="pool-name">{{ block.extras.pool.name }}</span> |                 <span class="pool-name">{{ block.extras.pool.name }}</span> | ||||||
|               </a> |               </a> | ||||||
|               <span *ngIf="!widget" class="tooltiptext badge badge-secondary scriptmessage">{{ block.extras.coinbaseRaw | hex2ascii }}</span> |               <span *ngIf="!widget" class="tooltiptext badge badge-secondary scriptmessage">{{ block.extras.coinbaseRaw | hex2ascii }}</span> | ||||||
|  | |||||||
| @ -102,7 +102,7 @@ | |||||||
|         <tr *ngFor="let pool of miningStats.pools"> |         <tr *ngFor="let pool of miningStats.pools"> | ||||||
|           <td class="d-none d-md-table-cell">{{ pool.rank }}</td> |           <td class="d-none d-md-table-cell">{{ pool.rank }}</td> | ||||||
|           <td class="text-right"> |           <td class="text-right"> | ||||||
|             <img width="25" height="25" src="{{ pool.logo }}" [alt]="pool.name + ' mining pool logo'" onError="this.src = '/resources/mining-pools/default.svg'"> |             <img width="25" height="25" src="{{ pool.logo }}" [alt]="pool.name + ' mining pool logo'" onError="this.onerror=null; this.src = '/resources/mining-pools/default.svg'"> | ||||||
|           </td> |           </td> | ||||||
|           <td class="pool-name"><a [routerLink]="[('/mining/pool/' + pool.slug) | relativeUrl]">{{ pool.name }}</a></td> |           <td class="pool-name"><a [routerLink]="[('/mining/pool/' + pool.slug) | relativeUrl]">{{ pool.name }}</a></td> | ||||||
|           <td class="" *ngIf="this.miningWindowPreference === '24h'">{{ pool.lastEstimatedHashrate }} {{ |           <td class="" *ngIf="this.miningWindowPreference === '24h'">{{ pool.lastEstimatedHashrate }} {{ | ||||||
|  | |||||||
| @ -6,7 +6,7 @@ | |||||||
|   <div *ngIf="poolStats$ | async as poolStats; else loadingMain"> |   <div *ngIf="poolStats$ | async as poolStats; else loadingMain"> | ||||||
|     <div style="display:flex" class="mb-3"> |     <div style="display:flex" class="mb-3"> | ||||||
|       <img width="50" height="50" src="{{ poolStats['logo'] }}" [alt]="poolStats.pool.name + ' mining pool logo'" |       <img width="50" height="50" src="{{ poolStats['logo'] }}" [alt]="poolStats.pool.name + ' mining pool logo'" | ||||||
|         onError="this.src = '/resources/mining-pools/default.svg'" class="mr-3"> |         onError="this.onerror=null; this.src = '/resources/mining-pools/default.svg'" class="mr-3"> | ||||||
|       <h1 class="m-0 pt-1 pt-md-0">{{ poolStats.pool.name }}</h1> |       <h1 class="m-0 pt-1 pt-md-0">{{ poolStats.pool.name }}</h1> | ||||||
|     </div> |     </div> | ||||||
| 
 | 
 | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user