Improve translatability

This commit is contained in:
Djuri Baars 2022-05-26 13:11:30 +02:00
parent 2eacfe3048
commit 64ed51e5db
9 changed files with 24 additions and 33 deletions

View File

@ -3,15 +3,10 @@
<div class="col-md-8">
<h1>{{ 'Home.WELCOME_HEADER' | translate }} <span *ngIf="testnet">for Testnet 🧪 </span></h1>
<p [innerHTML]="'Home.WELCOME_TEXT' | translate"></p>
<p><span [innerHTML]="'Home.DONATE_TEXT' | translate"></span><a href="#donate" (click)="openDonationModal($event)" translate>Home.DONATE_LINK</a>.</p>
<h4>How does this work</h4>
<p>
Ring Participants and their information (loaded from the CSV) will be stored in your browser
(LocalStorage)</p>
<h4>Acknowledgements</h4>
<h4 translate>Home.EXPLAIN_HEADER</h4>
<p translate>Home.EXPLAIN_TEXT</p>
<h4 translate>Home.ACKNOWLEDGEMENTS</h4>
<ul>
<li>Based on the work by <a href="https://github.com/StijnBTC/Ringtools" target="_blank">@stijnbtc</a>
</li>

View File

@ -6,22 +6,22 @@
</div>
<div class="col-md-8 participants">
<h2>Ring participants
<h2 translate>Overview.HEADER
<div class="btn-group btn-small small btn-group-toggle" [formGroup]="viewModeForm">
<input type="radio" formControlName="viewMode" value="node" class="btn-check" id="nodenameBtn">
<label class="btn btn-primary btn-sm" for="nodenameBtn">Nodename</label>
<label class="btn btn-primary btn-sm" for="nodenameBtn" translate>General.NODENAME</label>
<input type="radio" formControlName="viewMode" value="tg" class="btn-check" id="tgnameBtn">
<label class="btn btn-primary btn-sm" for="tgnameBtn">TG username
<label class="btn btn-primary btn-sm" for="tgnameBtn" translate>General.TG_USERNAME
</label>
</div>
</h2>
<app-participant-table [participants]="ring"></app-participant-table>
<button (click)="downloadAsPng()" class="btn btn-primary">Download Visual</button>
<button (click)="downloadAsPng()" class="btn btn-primary" translate>Overview.DOWNLOAD_VISUAL</button>
&nbsp;
<small>Red channels: Fee policy missing</small>
<small translate>Overview.RED_CHANNELS</small>
</div>
</div>
</div>

View File

@ -67,9 +67,9 @@
<thead>
<tr>
<th colspan="2" scope="col" class="external-services"></th>
<th scope="col">Public Key</th>
<th scope="col">Nodename</th>
<th scope="col">TG username</th>
<th scope="col" translate>General.PUBLIC_KEY</th>
<th scope="col" translate>General.NODENAME</th>
<th scope="col" translate>General.TG_USERNAME</th>
<th scope="col">&nbsp;</th>
</tr>
</thead>
@ -100,9 +100,7 @@
</ng-container>
<tr>
<th colspan="2">
Manual add
</th>
<th colspan="2" translate>Settings.MANUAL_ADD</th>
<th scope="row" class="no-padding" colspan="1">
<input class="form-control form-control-sm" type="text" id="pubkey" formControlName="pubKey"

View File

@ -1,7 +1,7 @@
<div class="container-fluid">
<div class="row">
<div class="col-md-8">
<h3>Node connections
<h3 translate>Visual.HEADER
</h3>
<app-node-connections></app-node-connections>
</div>

View File

@ -11,5 +11,5 @@
</li>
</ul>
<span *ngIf="isDirty">
<span class="badge bg-warning"><i class="bi bi-exclamation-triangle"></i> Unsaved changes, click "Persist channel order" to save.</span>
<span class="badge bg-warning"><i class="bi bi-exclamation-triangle"></i> <span translate>Visual.UNSAVED_CHANGES</span></span>
</span>

View File

@ -1,10 +1,6 @@
<div class="d-grid gap-2">
<button type="button" class="btn btn-warning btn-lg btn-sm" (click)="persistOrder()">Persist channel
order</button>
<button type="button" class="btn btn-primary btn-lg btn-sm" (click)="downloadChannelsTxt()">Download
channels.txt</button>
<button type="button" class="btn btn-success btn-lg btn-sm" (click)="downloadPubKeysTxt()">Download
pubkeys.txt</button>
<button type="button" class="btn btn-secondary btn-lg btn-sm" (click)="downloadIgniterPubkeys()">Download
igniter.sh pubkeys</button>
<button type="button" class="btn btn-warning btn-lg btn-sm" (click)="persistOrder()" translate>Visual.BTN_DOWNLOAD_IGNITER_PUBKEYS </button>
<button type="button" class="btn btn-primary btn-lg btn-sm" (click)="downloadChannelsTxt()" translate>Visual.BTN_DOWNLOAD_CHANNELS_TXT</button>
<button type="button" class="btn btn-success btn-lg btn-sm" (click)="downloadPubKeysTxt()" translate>Visual.BTN_DOWNLOAD_PUBKEYS_TXT</button>
<button type="button" class="btn btn-secondary btn-lg btn-sm" (click)="downloadIgniterPubkeys()" translate>Visual.BTN_DOWNLOAD_IGNITER_PUBKEYS</button>
</div>

View File

@ -15,6 +15,7 @@ import { NgbPopoverModule, NgbTooltip, NgbTooltipModule } from '@ng-bootstrap/ng
import { QrCodeComponent } from './qr-code/qr-code.component';
import { CopyComponent } from './copy/copy.component';
import { ClipboardModule } from 'ngx-clipboard';
import { TranslateModule } from '@ngx-translate/core';
@ -39,6 +40,7 @@ import { ClipboardModule } from 'ngx-clipboard';
FormsModule,
SharedModule,
ClipboardModule,
TranslateModule,
DragulaModule.forRoot(),
],
exports: [

View File

@ -3,7 +3,7 @@
<div class="form-floating">
<select class="form-select" [(ngModel)]="selectedIgniter" name="selectedIgniter" id="floatingSelect">
<option [value]="undefined">Select</option>
<option [value]="undefined" translate>Visual.LBL_SELECT_RINGLEADER</option>
<ng-container *ngFor="let s of nodeOwners">
<option [ngValue]="s">
<ng-template [ngIf]="(settings$ | async)?.viewMode === 'tg'" [ngIfElse]="elseBlock">
@ -15,10 +15,10 @@
</option>
</ng-container>
</select>
<label for="floatingSelect">Ringleader</label>
<label for="floatingSelect" translate>Visual.LBL_RINGLEADER</label>
</div>
</div>
<div class="col-12">
<button type="submit" class="btn btn-primary my-1" (click)="reorderIgniter()">Reorder</button>
<button type="submit" class="btn btn-primary my-1" (click)="reorderIgniter()" translate>Visual.BTN_REORDER</button>
</div>
</form>

@ -1 +1 @@
Subproject commit 06a98ab7033fc1f36297a7f4ec85718bf734e5c7
Subproject commit 5cd98e0ebcb2b15ecf0c0e0354777dc903bf83f4