feat(web): determine initial UI view from URL and wire selected view to appdash; add interface and web README files; bump various dependencies
This commit is contained in:
@@ -63,6 +63,14 @@ export class OpsDashboard extends DeesElement {
|
||||
},
|
||||
];
|
||||
|
||||
/**
|
||||
* Get the current view tab based on the UI state's activeView.
|
||||
* Used to pass the correct selectedView to dees-simple-appdash on initial render.
|
||||
*/
|
||||
private get currentViewTab() {
|
||||
return this.viewTabs.find(t => t.name.toLowerCase() === this.uiState.activeView) || this.viewTabs[0];
|
||||
}
|
||||
|
||||
constructor() {
|
||||
super();
|
||||
document.title = 'DCRouter OpsServer';
|
||||
@@ -141,12 +149,13 @@ export class OpsDashboard extends DeesElement {
|
||||
public render(): TemplateResult {
|
||||
return html`
|
||||
<div class="maincontainer">
|
||||
<dees-simple-login
|
||||
<dees-simple-login
|
||||
name="DCRouter OpsServer"
|
||||
>
|
||||
<dees-simple-appdash
|
||||
<dees-simple-appdash
|
||||
name="DCRouter OpsServer"
|
||||
.viewTabs=${this.viewTabs}
|
||||
.selectedView=${this.currentViewTab}
|
||||
>
|
||||
</dees-simple-appdash>
|
||||
</dees-simple-login>
|
||||
|
||||
Reference in New Issue
Block a user