Browse Source

Feature/add semantic list structure to header navigation (#2044)

* Add semantic list structure (ul and li elements)

* Update changelog
pull/2052/head
Thomas Kaul 2 years ago
committed by GitHub
parent
commit
7082ff12f8
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      CHANGELOG.md
  2. 61
      apps/client/src/app/components/header/header.component.html

1
CHANGELOG.md

@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Added the investment streaks to the analysis page - Added the investment streaks to the analysis page
- Added support for a unit in the value component - Added support for a unit in the value component
- Added a semantic list structure to the header navigation
- Added a default value for the `includeHistoricalData` attribute in the symbol data endpoint - Added a default value for the `includeHistoricalData` attribute in the symbol data endpoint
## 1.276.0 - 2023-06-03 ## 1.276.0 - 2023-06-03

61
apps/client/src/app/components/header/header.component.html

@ -8,18 +8,23 @@
<gf-logo [label]="pageTitle"></gf-logo> <gf-logo [label]="pageTitle"></gf-logo>
</a> </a>
<span class="spacer"></span> <span class="spacer"></span>
<ul class="alig-items-center d-flex list-inline m-0">
<li class="list-inline-item">
<a <a
class="d-none d-sm-block" class="d-none d-sm-block"
i18n i18n
mat-flat-button mat-flat-button
[ngClass]="{ [ngClass]="{
'font-weight-bold': currentRoute === 'home' || currentRoute === 'zen', 'font-weight-bold':
currentRoute === 'home' || currentRoute === 'zen',
'text-decoration-underline': 'text-decoration-underline':
currentRoute === 'home' || currentRoute === 'zen' currentRoute === 'home' || currentRoute === 'zen'
}" }"
[routerLink]="['/']" [routerLink]="['/']"
>Overview</a >Overview</a
> >
</li>
<li class="list-inline-item">
<a <a
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
@ -31,6 +36,8 @@
[routerLink]="['/portfolio']" [routerLink]="['/portfolio']"
>Portfolio</a >Portfolio</a
> >
</li>
<li class="list-inline-item">
<a <a
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
@ -42,8 +49,9 @@
[routerLink]="['/accounts']" [routerLink]="['/accounts']"
>Accounts</a >Accounts</a
> >
</li>
<li *ngIf="hasPermissionToAccessAdminControl" class="list-inline-item">
<a <a
*ngIf="hasPermissionToAccessAdminControl"
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
mat-flat-button mat-flat-button
@ -54,6 +62,8 @@
[routerLink]="['/admin']" [routerLink]="['/admin']"
>Admin Control</a >Admin Control</a
> >
</li>
<li class="list-inline-item">
<a <a
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
@ -65,10 +75,14 @@
[routerLink]="['/resources']" [routerLink]="['/resources']"
>Resources</a >Resources</a
> >
<a </li>
<li
*ngIf=" *ngIf="
hasPermissionForSubscription && user?.subscription?.type === 'Basic' hasPermissionForSubscription && user?.subscription?.type === 'Basic'
" "
class="list-inline-item"
>
<a
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
mat-flat-button mat-flat-button
@ -79,6 +93,8 @@
[routerLink]="['/pricing']" [routerLink]="['/pricing']"
>Pricing</a >Pricing</a
> >
</li>
<li class="list-inline-item">
<a <a
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
@ -90,6 +106,8 @@
[routerLink]="['/about']" [routerLink]="['/about']"
>About</a >About</a
> >
</li>
<li class="list-inline-item">
<button <button
class="no-min-width px-1" class="no-min-width px-1"
mat-flat-button mat-flat-button
@ -146,7 +164,8 @@
i18n i18n
mat-menu-item mat-menu-item
[ngClass]="{ [ngClass]="{
'font-weight-bold': currentRoute === 'home' || currentRoute === 'zen' 'font-weight-bold':
currentRoute === 'home' || currentRoute === 'zen'
}" }"
[routerLink]="['/']" [routerLink]="['/']"
>Overview</a >Overview</a
@ -198,7 +217,8 @@
> >
<a <a
*ngIf=" *ngIf="
hasPermissionForSubscription && user?.subscription?.type === 'Basic' hasPermissionForSubscription &&
user?.subscription?.type === 'Basic'
" "
class="d-flex d-sm-none" class="d-flex d-sm-none"
i18n i18n
@ -218,6 +238,8 @@
<hr class="d-flex d-sm-none m-0" /> <hr class="d-flex d-sm-none m-0" />
<button mat-menu-item (click)="onSignOut()">Logout</button> <button mat-menu-item (click)="onSignOut()">Logout</button>
</mat-menu> </mat-menu>
</li>
</ul>
</ng-container> </ng-container>
<ng-container *ngIf="user === null"> <ng-container *ngIf="user === null">
<a <a
@ -231,6 +253,8 @@
></gf-logo> ></gf-logo>
</a> </a>
<span class="spacer"></span> <span class="spacer"></span>
<ul class="alig-items-center d-flex list-inline m-0">
<li class="list-inline-item">
<a <a
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
@ -242,6 +266,8 @@
[routerLink]="['/features']" [routerLink]="['/features']"
>Features</a >Features</a
> >
</li>
<li class="list-inline-item">
<a <a
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
@ -253,8 +279,9 @@
[routerLink]="['/about']" [routerLink]="['/about']"
>About</a >About</a
> >
</li>
<li *ngIf="hasPermissionForSubscription" class="list-inline-item">
<a <a
*ngIf="hasPermissionForSubscription"
i18n i18n
mat-flat-button mat-flat-button
[ngClass]="{ [ngClass]="{
@ -264,8 +291,12 @@
[routerLink]="['/pricing']" [routerLink]="['/pricing']"
>Pricing</a >Pricing</a
> >
<a </li>
<li
*ngIf="hasPermissionToAccessFearAndGreedIndex" *ngIf="hasPermissionToAccessFearAndGreedIndex"
class="list-inline-item"
>
<a
class="d-none d-sm-block mx-1" class="d-none d-sm-block mx-1"
i18n i18n
mat-flat-button mat-flat-button
@ -276,22 +307,32 @@
[routerLink]="['/markets']" [routerLink]="['/markets']"
>Markets</a >Markets</a
> >
</li>
<li class="list-inline-item">
<a <a
class="d-none d-sm-block no-min-width" class="d-none d-sm-block no-min-width p-1"
href="https://github.com/ghostfolio/ghostfolio" href="https://github.com/ghostfolio/ghostfolio"
mat-icon-button mat-flat-button
><ion-icon name="logo-github"></ion-icon ><ion-icon name="logo-github"></ion-icon
></a> ></a>
</li>
<li class="list-inline-item">
<button class="mx-1" mat-flat-button (click)="openLoginDialog()"> <button class="mx-1" mat-flat-button (click)="openLoginDialog()">
<ng-container i18n>Sign in</ng-container> <ng-container i18n>Sign in</ng-container>
</button> </button>
<a </li>
<li
*ngIf="currentRoute !== 'register' && hasPermissionToCreateUser" *ngIf="currentRoute !== 'register' && hasPermissionToCreateUser"
class="list-inline-item"
>
<a
class="d-none d-sm-block" class="d-none d-sm-block"
color="primary" color="primary"
mat-flat-button mat-flat-button
[routerLink]="['/register']" [routerLink]="['/register']"
><ng-container i18n>Get started</ng-container> ><ng-container i18n>Get started</ng-container>
</a> </a>
</li>
</ul>
</ng-container> </ng-container>
</mat-toolbar> </mat-toolbar>

Loading…
Cancel
Save