-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Mobile table styles * 4.11.1 * 4.11.1 * 4.11.1 * 4.11.2 * Start * 4.12.0 * 4.12.0 * 4.12.0
- Loading branch information
Showing
13 changed files
with
223 additions
and
91 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
import { NgModule } from '@angular/core'; | ||
import { ListItemTagComponent } from './list-item-tag.component'; | ||
import { CommonModule } from '@angular/common'; | ||
|
||
@NgModule({ | ||
declarations: [ListItemTagComponent], | ||
exports: [ListItemTagComponent], | ||
imports: [CommonModule], | ||
}) | ||
export class ListItemTagModule {} |
11 changes: 11 additions & 0 deletions
11
src/app/overlays/actions/add-spyglass/add-spyglass.component.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
.add-spyglass-overlay { | ||
width: 380px; | ||
} | ||
|
||
.add-spyglass-example { | ||
font-family: monospace; | ||
background: #e6e6e6; | ||
padding: 0 4px; | ||
border-radius: 4px; | ||
margin-top: 8px; | ||
} |
65 changes: 65 additions & 0 deletions
65
src/app/overlays/actions/add-spyglass/add-spyglass.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
import { Component, EventEmitter, Output } from '@angular/core'; | ||
import { FormControl } from '@angular/forms'; | ||
import { ADD_RPC_NODE_BY_URL } from '@app/services/wallet-events.service'; | ||
|
||
@Component({ | ||
selector: 'app-add-spyglass-overlay', | ||
styleUrls: ['add-spyglass.component.scss'], | ||
template: ` | ||
<div class="add-spyglass-overlay overlay-action-container"> | ||
<div class="overlay-header">Add new Spyglass API datasource</div> | ||
<div class="overlay-body"> | ||
<div class="mat-body-1" style="margin-bottom: 16px"> | ||
If the default Spyglass API hosts are unavailable, you can add a custom API instead. | ||
</div> | ||
<div class="mat-body-1"> | ||
<div>Use the input field below to enter the URL of your new API source e.g:</div> | ||
<div class="add-spyglass-example mat-body-1">https://api.spyglass.pw/banano</div> | ||
</div> | ||
<form style="margin: 32px 0 16px 0"> | ||
<mat-form-field style="width: 100%" appearance="fill"> | ||
<mat-label>Spyglass API URL</mat-label> | ||
<textarea | ||
type="text" | ||
matInput | ||
(keyup.enter)="addRpcNode()" | ||
[formControl]="urlFormControl" | ||
data-cy="add-new-spyglass-input" | ||
></textarea> | ||
</mat-form-field> | ||
</form> | ||
</div> | ||
<div class="overlay-footer"> | ||
<button mat-stroked-button mat-dialog-close color="primary" (click)="close.emit()">Close</button> | ||
<button | ||
data-cy="add-spyglass-overlay-button" | ||
mat-flat-button | ||
color="primary" | ||
[disabled]="isDisabled()" | ||
(click)="addRpcNode()" | ||
> | ||
Add | ||
</button> | ||
</div> | ||
</div> | ||
`, | ||
}) | ||
export class AddSpyglassOverlayComponent { | ||
urlFormControl = new FormControl(''); | ||
|
||
@Output() close: EventEmitter<void> = new EventEmitter<void>(); | ||
|
||
isDisabled(): boolean { | ||
return !this.urlFormControl.value; | ||
} | ||
|
||
addRpcNode(): void { | ||
if (this.isDisabled()) { | ||
return; | ||
} | ||
|
||
// TODO: Add checks to see if the node is accessible and online before adding it to the list. | ||
ADD_RPC_NODE_BY_URL.next(this.urlFormControl.value); | ||
this.close.emit(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.