Added a rules & calendar page

This commit is contained in:
2022-10-26 21:46:25 -04:00
parent 4830b35363
commit f1b875a87e
12 changed files with 138 additions and 23 deletions

View File

@ -1,4 +1,4 @@
<mat-toolbar>
<mat-toolbar class="d-print-none">
<mat-toolbar-row>
<div>
<a class="navbar-brand d-flex align-items-center" routerLink="/" fragment="banner" (click)="scroll('banner')">
@ -15,9 +15,9 @@
<ng-container *ngFor="let group of links.other">
<ng-template [ngTemplateOutlet]="navGroup" [ngTemplateOutletContext]="{'$implicit': group}"></ng-template>
</ng-container>
<a href="#">
<button mat-button class="navbar-button">Donate</button>
</a>
<!-- <a href="#">-->
<!-- <button mat-button class="navbar-button">Donate</button>-->
<!-- </a>-->
</div>
<button *ngIf="hamburger" mat-icon-button class="mr-3">
<mat-icon (click)="hamburgerClick.emit()">menu</mat-icon>

View File

@ -1,6 +1,6 @@
import {AfterViewInit, Component, EventEmitter, Input, OnDestroy, Output} from '@angular/core';
import {ActivatedRoute, NavigationEnd, Router} from '@angular/router';
import {filter, Subscription} from 'rxjs';
import {combineLatest, filter, Subscription} from 'rxjs';
import {NAVIGATION} from '../../misc/navigation';
@Component({
@ -20,11 +20,12 @@ export class NavbarComponent implements AfterViewInit, OnDestroy {
@Output() hamburgerClick = new EventEmitter<void>();
constructor(private route: ActivatedRoute) { }
constructor(private route: ActivatedRoute, private router: Router) { }
ngAfterViewInit() {
this.sub = this.route.fragment.subscribe(frag => {
console.log('fire');
this.sub = combineLatest([this.router.events.pipe(filter(e => e instanceof NavigationEnd)), this.route.fragment]).subscribe(([url, frag]) => {
console.log('fire', frag);
if(frag) this.scroll(frag);
else this.scroll('top');
});