Skip to content
This repository has been archived by the owner on Oct 28, 2024. It is now read-only.

Commit

Permalink
Merge branch 'main' into feature/added-linter
Browse files Browse the repository at this point in the history
Signed-off-by: Robert Gogete <gogeterobert@yahoo.com>
  • Loading branch information
gogeterobert committed Jun 30, 2022
2 parents 0f72df6 + ba394a6 commit 42869de
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/Web/ClientApp/src/app/app.component.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<app-navbar></app-navbar>

<div class="container mx-4 is-fluid">
<div class="container is-fluid">
<router-outlet></router-outlet>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
<div class="has-text-weight-bold is-size-4">{{component.name}}</div>
<div class="is-underlined">
<div *ngIf="component.type === types.HTTP">
<a href="{{protocol}}//{{channel.domain}}{{component.route}}" target="_blank">{{component.route}}</a>
<a href="{{protocol}}//{{channel.domain}}{{getRedirectRoute(component.route!)}}" target="_blank">{{component.route}}</a>
</div>
<div *ngIf="component.type === types.Redis">{{component.channel}}</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,14 @@ export class OverviewComponent implements OnChanges {
},
});
}

getRedirectRoute(route: string): string {
if (route) {
if (route.slice(-3) === '...') {
return route.slice(0, -3);
} else {
return route;
}
} else return '';
}
}
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
<nav id="topbar" class="navbar" role="navigation" aria-label="main navigation">
<nav class="navbar is-wide is-sticky" role="navigation" aria-label="main navigation">
<div class="navbar-brand">
<a class="navbar-item" routerLink="/">
<div class="logo">
<img src="/assets/logo.svg" alt="banner logo" />
</div>
</a>

<a role="button" class="navbar-burger" aria-label="menu" aria-expanded="false" data-target="hippoMenu">
<a role="button" class="navbar-burger {{ menuActive }}" aria-label="menu" aria-expanded="false" (click)="onBurger()">
<span aria-hidden="true"></span>
<span aria-hidden="true"></span>
<span aria-hidden="true"></span>
</a>
</div>

<div id="hippoMenu" class="navbar-menu">
<div class="navbar-menu navbar-end" *ngIf="isLoggedIn(); else elseBlock">
<div class="navbar-menu {{ menuActive }}">
<div class="navbar-end" *ngIf="isLoggedIn(); else elseBlock">
<div class="navbar-item has-dropdown is-hoverable">
<a class="navbar-link">
<fa-icon class="icon" [icon]="faUser"></fa-icon>
Expand All @@ -29,7 +29,7 @@
</div>
</div>
<ng-template #elseBlock>
<div class="navbar-menu navbar-end">
<div class="navbar-end">
<div class="buttons">
<a class="navbar-item button is-outlined" routerLink="/login">Log in</a>
<a class="navbar-item button is-primary" routerLink="/register">Sign up</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { faUser } from '@fortawesome/free-solid-svg-icons';
})
export class NavbarComponent {
faUser = faUser;
menuActive = '';

constructor(private readonly sessionService: SessionService) {}

Expand All @@ -20,4 +21,7 @@ export class NavbarComponent {
this.sessionService.logout();
location.reload();
}
onBurger(): void {
this.menuActive = this.menuActive == '' ? 'is-active' : '';
}
}
1 change: 1 addition & 0 deletions src/Web/ClientApp/src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@
</head>
<body>
<app-root></app-root>
<script type="module" src="/assets/index.js"></script>
</body>
</html>

0 comments on commit 42869de

Please sign in to comment.