diff --git a/frontend/projects/setup-wizard/src/app/pages/init/init.page.html b/frontend/projects/setup-wizard/src/app/pages/init/init.page.html index 4c07e7bcf..10b3db268 100644 --- a/frontend/projects/setup-wizard/src/app/pages/init/init.page.html +++ b/frontend/projects/setup-wizard/src/app/pages/init/init.page.html @@ -2,22 +2,44 @@ - -
- +
+
- + - Initializing Embassy + Initializing Embassy Progress: {{ progress }}% - -

After completion, you will be prompted to download a file from your Embassy. Save the file somewhere safe, it is the easiest way to recover your Embassy's addresses and SSL certificate in case you lose them.

+ +

+ After completion, you will be prompted to download a file from + your Embassy. Save the file somewhere safe, it is the easiest way + to recover your Embassy's addresses and SSL certificate in case + you lose them. +

+

+ DO NOT: Close or refresh the browser window during + intialization process. +

diff --git a/frontend/projects/setup-wizard/src/app/pages/loading/loading.page.html b/frontend/projects/setup-wizard/src/app/pages/loading/loading.page.html index dfc05c269..b9fd8d817 100644 --- a/frontend/projects/setup-wizard/src/app/pages/loading/loading.page.html +++ b/frontend/projects/setup-wizard/src/app/pages/loading/loading.page.html @@ -2,20 +2,30 @@ - -
- +
+
- Recovering - Progress: {{ (stateService.dataProgress * 100).toFixed(0) }}% + Recovering + Progress: {{ (stateService.dataProgress * 100).toFixed(0) + }}% - -

After completion, you will be prompted to download a file from your Embassy. Save the file somewhere safe, it is the easiest way to recover your Embassy's addresses and SSL certificate in case you lose them.

+
diff --git a/frontend/projects/ui/src/app/modals/markdown/markdown.page.ts b/frontend/projects/ui/src/app/modals/markdown/markdown.page.ts index 06d421b1a..5f5ca48af 100644 --- a/frontend/projects/ui/src/app/modals/markdown/markdown.page.ts +++ b/frontend/projects/ui/src/app/modals/markdown/markdown.page.ts @@ -2,6 +2,7 @@ import { Component, Input } from '@angular/core' import { ModalController, IonicSafeString } from '@ionic/angular' import { ApiService } from 'src/app/services/api/embassy-api.service' import { getErrorMessage } from 'src/app/services/error-toast.service' +import { pauseFor } from '../../../../../shared/src/util/misc.util' @Component({ selector: 'markdown', @@ -25,6 +26,11 @@ export class MarkdownPage { if (!this.content) { this.content = await this.embassyApi.getStatic(this.contentUrl) } + } catch (e) { + this.loadingError = getErrorMessage(e) + } finally { + this.loading = false + await pauseFor(50) const links = document.links for (let i = 0, linksLength = links.length; i < linksLength; i++) { if (links[i].hostname != window.location.hostname) { @@ -33,10 +39,6 @@ export class MarkdownPage { links[i].className += ' externalLink' } } - } catch (e) { - this.loadingError = getErrorMessage(e) - } finally { - this.loading = false } } diff --git a/frontend/projects/ui/src/app/pages/apps-routes/app-show/components/app-show-status/app-show-status.component.ts b/frontend/projects/ui/src/app/pages/apps-routes/app-show/components/app-show-status/app-show-status.component.ts index 81f597214..f2f0ad6d4 100644 --- a/frontend/projects/ui/src/app/pages/apps-routes/app-show/components/app-show-status/app-show-status.component.ts +++ b/frontend/projects/ui/src/app/pages/apps-routes/app-show/components/app-show-status/app-show-status.component.ts @@ -108,8 +108,11 @@ export class AppShowStatusComponent { async stop(): Promise { const { id, title, version } = this.pkg.manifest + const hasDependents = !!Object.keys( + this.pkg.installed['current-dependents'], + ).filter(depId => depId !== this.pkg.manifest.id).length - if (isEmptyObject(this.pkg.installed['current-dependents'])) { + if (!hasDependents) { const loader = await this.loadingCtrl.create({ message: `Stopping...`, spinner: 'lines', diff --git a/frontend/projects/ui/src/app/pages/server-routes/marketplaces/marketplaces.page.ts b/frontend/projects/ui/src/app/pages/server-routes/marketplaces/marketplaces.page.ts index 2569ac309..5c0c61363 100644 --- a/frontend/projects/ui/src/app/pages/server-routes/marketplaces/marketplaces.page.ts +++ b/frontend/projects/ui/src/app/pages/server-routes/marketplaces/marketplaces.page.ts @@ -90,7 +90,7 @@ export class MarketplacesPage { async presentAction(id: string) { // no need to view actions if is selected marketplace - if (id === this.patch.getData().ui.marketplace['selected-id']) return + if (id === this.patch.getData().ui.marketplace?.['selected-id']) return const buttons: ActionSheetButton[] = [ { diff --git a/frontend/projects/ui/src/app/pages/server-routes/wifi/wifi.page.html b/frontend/projects/ui/src/app/pages/server-routes/wifi/wifi.page.html index 2ceb3fc0d..6cbea6b0a 100644 --- a/frontend/projects/ui/src/app/pages/server-routes/wifi/wifi.page.html +++ b/frontend/projects/ui/src/app/pages/server-routes/wifi/wifi.page.html @@ -79,7 +79,9 @@ - Saved Networks + Saved Networks Available Networks - - {{ avWifi.ssid }} - - - - - + + + {{ avWifi.ssid }} + + + + + + Join other network diff --git a/frontend/projects/ui/src/app/pages/server-routes/wifi/wifi.page.ts b/frontend/projects/ui/src/app/pages/server-routes/wifi/wifi.page.ts index d96d0c4f1..7e4432a86 100644 --- a/frontend/projects/ui/src/app/pages/server-routes/wifi/wifi.page.ts +++ b/frontend/projects/ui/src/app/pages/server-routes/wifi/wifi.page.ts @@ -40,8 +40,16 @@ export class WifiPage { ) {} async ngOnInit() { + await this.getWifi() + } + + async getWifi(timeout?: number): Promise { + this.loading = true try { - await this.getWifi() + this.wifi = await this.api.getWifi({}, timeout) + if (!this.wifi.country) { + await this.presentAlertCountry() + } } catch (e) { this.errToast.present(e) } finally { @@ -49,13 +57,6 @@ export class WifiPage { } } - async getWifi(timeout?: number): Promise { - this.wifi = await this.api.getWifi({}, timeout) - if (!this.wifi.country) { - await this.presentAlertCountry() - } - } - async presentAlertCountry(): Promise { if (!this.config.isLan) { const alert = await this.alertCtrl.create({ diff --git a/frontend/projects/ui/src/app/services/api/api.fixures.ts b/frontend/projects/ui/src/app/services/api/api.fixures.ts index 7cc3621c6..be8dd6580 100644 --- a/frontend/projects/ui/src/app/services/api/api.fixures.ts +++ b/frontend/projects/ui/src/app/services/api/api.fixures.ts @@ -1017,6 +1017,11 @@ export module Mock { strength: 99, security: ['1', '2', '3'], }, + { + ssid: '', + strength: 40, + security: [], + }, ], }