Skip to content

Commit

Permalink
Add "Join Pool" button and fix colors for some input fields
Browse files Browse the repository at this point in the history
  • Loading branch information
felixbrucker committed Oct 20, 2023
1 parent ca04c39 commit a596e25
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/app/harvester-card/harvester-card.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ <h5 class="d-flex align-items-center gap-1">
</ng-template>

<ng-template editMode>
<input editableOnEnter editableOnEscape class="form-control harvester-name-input" type="text" [formControl]="nameControl"/>
<input editableOnEnter editableOnEscape class="form-control input-field harvester-name-input" type="text" [formControl]="nameControl"/>
</ng-template>
</editable>
<span *ngIf="(status$ | async) !== null" class="badge status-pill" [ngClass]="statusDotColorClass$ | async" [ngbTooltip]="statusTooltip$ | async">{{status$ | async}}</span>
Expand Down
7 changes: 6 additions & 1 deletion src/app/header/header.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,12 @@
<div class="header-row-item" *ngIf="showLogoutButton">
<button class="btn btn-outline-danger logout-button" (click)="accountService.logout()">{{snippetService.getSnippet('header-component.button.logout')}}</button>
</div>
<div class="header-row-item" *ngIf="ratesService.currencies && ratesService.currencies.length > 0">
<div class="header-row-item" *ngIf="showJoinPoolButton">
<a class="btn btn-primary text-decoration-none" [href]="joinPoolUrl" target="_blank">
Join Pool
</a>
</div>
<div class="header-row-item" *ngIf="ratesService.currencies.length > 0">
<app-currency-selector></app-currency-selector>
</div>
<div class="input-group header-row-item search-input">
Expand Down
8 changes: 8 additions & 0 deletions src/app/header/header.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,14 @@ export class HeaderComponent {
public readonly accountSearchInputPlaceholder: string = makeAccountIdentifierName(this.poolsProvider.pool.type)
public readonly isSearchingAccount$: Observable<boolean>

public get showJoinPoolButton(): boolean {
return this.accountService.accountIdentifierFromLocalStorage === null
}

public get joinPoolUrl(): string {
return `https://docs.foxypool.io/proof-of-spacetime/foxy-pool/pools/${this.poolsProvider.poolIdentifier}/getting-started/`
}

public get showMoonInThemeSwitcher(): boolean {
return !this.isDarkTheme
}
Expand Down
2 changes: 1 addition & 1 deletion src/app/my-farmer/my-farmer.component.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div class="row">
<div class="col-12" *ngIf="(accountService.haveAccountIdentifier$ | async) === false">
<div class="d-flex justify-content-center">
<input type="text" class="form-control" placeholder="{{accountIdentifierInputPlaceholder}}" [(ngModel)]="accountIdentifierInput" style="width: 32em;margin-right: 0.5rem;">
<input type="text" class="form-control input-field" placeholder="{{accountIdentifierInputPlaceholder}}" [(ngModel)]="accountIdentifierInput" style="width: 32em;margin-right: 0.5rem;">
<button class="btn btn-success" style="margin-left: 0.5rem;" (click)="login()">
<fa-icon *ngIf="accountService.isLoading$ | async" [icon]="faCircleNotch" animation="spin"></fa-icon>
<span *ngIf="accountService.isLoading$ | async"> {{snippetService.getSnippet('my-farmer-component.login-button.label-logging-in')}}</span>
Expand Down

0 comments on commit a596e25

Please sign in to comment.