mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-30 20:14:49 +00:00
ui: eject disks todo
This commit is contained in:
committed by
Aiden McClelland
parent
8c79984e80
commit
5a4e980d31
@@ -88,4 +88,4 @@
|
||||
right: 0px;
|
||||
top: 0px;
|
||||
margin: 0px;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -58,4 +58,4 @@
|
||||
z-index: 1;
|
||||
right: -2px;
|
||||
--border-radius: 100px;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,26 +0,0 @@
|
||||
<ion-header *ngIf="{appLoading: $appLoading$ | async} as vars">
|
||||
<ion-toolbar>
|
||||
<ion-buttons style="margin: 0px 15px" slot="start">
|
||||
<img class="bulb" *ngIf="status$ | async | displayBulb: 'green'" src="assets/img/green-bulb.png"/>
|
||||
<img class="bulb" *ngIf="status$ | async | displayBulb: 'red'" src="assets/img/red-bulb.png"/>
|
||||
<img class="bulb" *ngIf="status$ | async | displayBulb: 'yellow'" src="assets/img/yellow-bulb.png"/>
|
||||
<img class="bulb" *ngIf="status$ | async | displayBulb: 'off'" src="assets/img/black-bulb.png"/>
|
||||
</ion-buttons>
|
||||
<ion-title>{{$app$.title | async}}</ion-title>
|
||||
<ion-buttons slot="end" *ngIf="">
|
||||
<ion-spinner *ngIf="vars.appLoading" name="dots" color="medium"></ion-spinner>
|
||||
<ion-button *ngIf="!vars.appLoading" (click)=presentPopoverMenu($event)>
|
||||
<ion-icon name="ellipsis-vertical"></ion-icon>
|
||||
</ion-button>
|
||||
</ion-buttons>
|
||||
</ion-toolbar>
|
||||
</ion-header>
|
||||
|
||||
<ion-content style="--overflow: hidden;" *ngIf="{isRunning: isRunning$ | async, status: status$ | async, appLoading: $appLoading$ | async, iframeLoading: $iframeLoading$ | async } as vars">
|
||||
<ion-spinner *ngIf="vars.appLoading || vars.iframeLoading" style="position: absolute; width: 4vh; left: calc(50% - 2vh); height: 100%;" name="lines" color="warning"></ion-spinner>
|
||||
<iframe (load)="iframeLoaded()" *ngIf="!vars.appLoading && vars.isRunning" [id]="appId + '-ui'" src="http://localhost:8100" width="100%" height="100%" style="border:1px solid black;"></iframe>
|
||||
<div *ngIf="!vars.appLoading && !vars.isRunning" class="flex-center" style="border:1px solid black; color: white">
|
||||
<ion-label style="margin:10px">{{$app$.title | async}} is not running.</ion-label>
|
||||
<ion-button fill="outline" (click)="toServiceShow()">View</ion-button>
|
||||
</div>
|
||||
</ion-content>
|
||||
@@ -7,6 +7,7 @@ import { SharingModule } from 'src/app/modules/sharing.module'
|
||||
import { PwaBackComponentModule } from 'src/app/components/pwa-back-button/pwa-back.component.module'
|
||||
import { BadgeMenuComponentModule } from 'src/app/components/badge-menu-button/badge-menu.component.module'
|
||||
import { ObjectConfigComponentModule } from 'src/app/components/object-config/object-config.component.module'
|
||||
// TODO: EJECT-DISKS
|
||||
|
||||
const routes: Routes = [
|
||||
{
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
<!-- TODO: EJECT-DISKS -->
|
||||
<ion-header>
|
||||
<ion-toolbar>
|
||||
<ion-buttons slot="start">
|
||||
@@ -16,16 +17,14 @@
|
||||
</ion-refresher>
|
||||
|
||||
<ion-item-group>
|
||||
<!-- <ion-list> -->
|
||||
<ion-item *ngFor="let d of disks; let i = index">
|
||||
<ion-icon slot="start" name="save-outline"></ion-icon>
|
||||
<ion-label>{{d.logicalname}} ({{ d.size }})</ion-label>
|
||||
<ion-button *ngIf="!(d.$ejecting$ | async)" slot="end" fill="clear" color="medium" (click)="ejectDisk(i)">
|
||||
<ion-icon color="primary" class="icon" src="/assets/icon/eject.svg"></ion-icon>
|
||||
</ion-button>
|
||||
<ion-spinner *ngIf="d.$ejecting$ | async" name="lines" color="medium"></ion-spinner>
|
||||
</ion-item>
|
||||
<!-- </ion-list> -->
|
||||
<ion-item *ngFor="let d of disks; let i = index">
|
||||
<ion-icon slot="start" name="save-outline"></ion-icon>
|
||||
<ion-label>{{d.logicalname}} ({{ d.size }})</ion-label>
|
||||
<ion-button *ngIf="!(d.$ejecting$ | async)" slot="end" fill="clear" color="medium" (click)="ejectDisk(i)">
|
||||
<ion-icon color="primary" class="icon" src="/assets/icon/eject.svg"></ion-icon>
|
||||
</ion-button>
|
||||
<ion-spinner *ngIf="d.$ejecting$ | async" name="lines" color="medium"></ion-spinner>
|
||||
</ion-item>
|
||||
</ion-item-group>
|
||||
</ion-content>
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@ import { DiskInfo } from 'src/app/models/server-model'
|
||||
import { markAsLoadingDuringP } from 'src/app/services/loader.service'
|
||||
import { BehaviorSubject } from 'rxjs'
|
||||
import { AlertController } from '@ionic/angular'
|
||||
// TODO: EJECT-DISKS
|
||||
|
||||
type Ejectable<T> = T & { $ejecting$: BehaviorSubject<boolean> }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user