allow ca download over lan (#1877)

This commit is contained in:
Matt Hill
2022-10-19 10:22:25 -06:00
committed by Aiden McClelland
parent 9221f25e35
commit ad14503e9f
2 changed files with 1 additions and 24 deletions

View File

@@ -33,22 +33,10 @@
>instructions</a
>.
</h2>
<ng-container *ngIf="downloadIsDisabled && (server$ | async) as server">
<br />
<ion-text color="warning">
For security reasons, you must setup LAN over a
<a
[attr.href]="server['tor-address']"
target="_blank"
rel="noreferrer"
>Tor connection</a
>.
</ion-text>
</ng-container>
</ion-label>
</ion-item>
<ion-item button (click)="installCert()" [disabled]="downloadIsDisabled">
<ion-item button (click)="installCert()">
<ion-icon slot="start" name="download-outline" size="large"></ion-icon>
<ion-label>
<h1>Download Root CA</h1>

View File

@@ -1,7 +1,4 @@
import { ChangeDetectionStrategy, Component } from '@angular/core'
import { ConfigService } from 'src/app/services/config.service'
import { PatchDB } from 'patch-db-client'
import { DataModel } from 'src/app/services/patch-db/data-model'
@Component({
selector: 'lan',
@@ -10,14 +7,6 @@ import { DataModel } from 'src/app/services/patch-db/data-model'
changeDetection: ChangeDetectionStrategy.OnPush,
})
export class LANPage {
readonly downloadIsDisabled = !this.config.isTor()
readonly server$ = this.patch.watch$('server-info')
constructor(
private readonly config: ConfigService,
private readonly patch: PatchDB<DataModel>,
) {}
installCert(): void {
document.getElementById('install-cert')?.click()
}