Browse Source

Refactoring

pull/3978/head
Thomas Kaul 10 months ago
parent
commit
fcc398d5b5
  1. 2
      apps/client/src/app/app.component.ts
  2. 6
      apps/client/src/app/pages/resources/resources-page-routing.module.ts
  3. 18
      apps/client/src/app/pages/resources/resources-page.component.ts
  4. 10
      apps/client/src/app/pages/resources/resources-page.scss

2
apps/client/src/app/app.component.ts

@ -183,6 +183,7 @@ export class AppComponent implements OnDestroy, OnInit {
this.hasTabs = this.hasTabs =
(this.currentRoute === this.routerLinkAbout[0].slice(1) || (this.currentRoute === this.routerLinkAbout[0].slice(1) ||
this.currentRoute === this.routerLinkFaq[0].slice(1) || this.currentRoute === this.routerLinkFaq[0].slice(1) ||
this.currentRoute === this.routerLinkResources[0].slice(1) ||
this.currentRoute === 'account' || this.currentRoute === 'account' ||
this.currentRoute === 'admin' || this.currentRoute === 'admin' ||
this.currentRoute === 'home' || this.currentRoute === 'home' ||
@ -198,7 +199,6 @@ export class AppComponent implements OnDestroy, OnInit {
this.currentRoute === 'p' || this.currentRoute === 'p' ||
this.currentRoute === this.routerLinkPricing[0].slice(1) || this.currentRoute === this.routerLinkPricing[0].slice(1) ||
this.currentRoute === this.routerLinkRegister[0].slice(1) || this.currentRoute === this.routerLinkRegister[0].slice(1) ||
this.currentRoute === this.routerLinkResources[0].slice(1) ||
this.currentRoute === 'start') && this.currentRoute === 'start') &&
this.deviceType !== 'mobile'; this.deviceType !== 'mobile';

6
apps/client/src/app/pages/resources/resources-page-routing.module.ts

@ -7,9 +7,8 @@ import { ResourcesPageComponent } from './resources-page.component';
const routes: Routes = [ const routes: Routes = [
{ {
path: '',
component: ResourcesPageComponent,
canActivate: [AuthGuard], canActivate: [AuthGuard],
component: ResourcesPageComponent,
children: [ children: [
{ {
path: '', path: '',
@ -39,7 +38,8 @@ const routes: Routes = [
(m) => m.ResourcesMarketsModule (m) => m.ResourcesMarketsModule
) )
} }
] ],
path: ''
} }
]; ];

18
apps/client/src/app/pages/resources/resources-page.component.ts

@ -9,8 +9,8 @@ import { Subject } from 'rxjs';
@Component({ @Component({
host: { class: 'page has-tabs' }, host: { class: 'page has-tabs' },
selector: 'gf-resources-page', selector: 'gf-resources-page',
templateUrl: './resources-page.html', styleUrls: ['./resources-page.scss'],
styleUrls: ['./resources-page.scss'] templateUrl: './resources-page.html'
}) })
export class ResourcesPageComponent implements OnInit { export class ResourcesPageComponent implements OnInit {
public deviceType: string; public deviceType: string;
@ -25,22 +25,22 @@ export class ResourcesPageComponent implements OnInit {
{ {
path: '.', path: '.',
label: $localize`Overview`, label: $localize`Overview`,
iconName: 'information-circle-outline' iconName: 'reader-outline'
}, },
{ {
path: 'guides', path: 'guides',
label: $localize`Guides`, label: $localize`Guides`,
iconName: 'book-outline' iconName: 'book-outline'
}, },
{
path: 'glossary',
label: $localize`Glossary`,
iconName: 'list-outline'
},
{ {
path: 'markets', path: 'markets',
label: $localize`Markets`, label: $localize`Markets`,
iconName: 'trending-up-outline' iconName: 'newspaper-outline'
},
{
path: 'glossary',
label: $localize`Glossary`,
iconName: 'library-outline'
} }
]; ];

10
apps/client/src/app/pages/resources/resources-page.scss

@ -1,11 +1,7 @@
:host { :host {
display: flex; color: rgb(var(--dark-primary-text));
flex-direction: row;
height: 100%;
} }
@media (max-width: 599px) { :host-context(.theme-dark) {
:host { color: rgb(var(--light-primary-text));
flex-direction: column-reverse;
}
} }

Loading…
Cancel
Save