-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
32 changed files
with
243 additions
and
125 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,18 @@ | ||
<div *ngIf="user" class="home"> | ||
<navigation (onFeedToggle)="feed.toggle()" (onPreferencesToggle)="preferences.toggle()"></navigation> | ||
|
||
<mat-sidenav-container class="main-container" hasBackdrop="false"> | ||
<mat-sidenav #feed mode="side" position="start" opened> | ||
<feed-panel class="feed" [event]="event" [observationLocation]="newObservation"></feed-panel> | ||
</mat-sidenav> | ||
|
||
<mat-sidenav #preferences mode="slide" position="end" disableClose="true"> | ||
<preferences></preferences> | ||
</mat-sidenav> | ||
|
||
<map (addObservation)="onAddObservation($event)"></map> | ||
|
||
</mat-sidenav-container> | ||
<div class="home-content"> | ||
<mat-sidenav-container hasBackdrop="false"> | ||
<mat-sidenav #feed mode="side" position="start" opened> | ||
<feed-panel class="feed" [event]="event" [observationLocation]="newObservation"></feed-panel> | ||
</mat-sidenav> | ||
|
||
<mat-sidenav #preferences mode="slide" position="end" disableClose="true"> | ||
<preferences></preferences> | ||
</mat-sidenav> | ||
|
||
<map (addObservation)="onAddObservation($event)"></map> | ||
|
||
</mat-sidenav-container> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
<button mat-mini-fab color="accent" matTooltip="Create New Observation" matTooltipPosition="after" (click)="addObservation($event)"> | ||
<button mat-fab color="accent" matTooltip="Create New Observation" matTooltipPosition="after" (click)="addObservation($event)"> | ||
<mat-icon>add_location</mat-icon> | ||
</button> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,3 @@ | ||
button { | ||
margin-top: 32px; | ||
} | ||
|
||
mat-icon { | ||
color: white; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<button mat-mini-fab color="default" matTooltip="Filter" matTooltipPosition="after" (click)="onClick($event)"> | ||
<mat-icon color="primary">file_download</mat-icon> | ||
</button> |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; | ||
|
||
import { AddObservationComponent } from './add-observation.component'; | ||
import { MatButtonModule } from '@angular/material/button'; | ||
import { MatIconModule } from '@angular/material/icon'; | ||
import { ExportControlComponent } from './export.component'; | ||
|
||
describe('Export Control Component', () => { | ||
let component: ExportControlComponent; | ||
let fixture: ComponentFixture<ExportControlComponent>; | ||
|
||
beforeEach(waitForAsync(() => { | ||
TestBed.configureTestingModule({ | ||
imports: [ MatIconModule, MatButtonModule ], | ||
declarations: [ AddObservationComponent ] | ||
}) | ||
.compileComponents(); | ||
})); | ||
|
||
beforeEach(() => { | ||
fixture = TestBed.createComponent(ExportControlComponent); | ||
component = fixture.componentInstance; | ||
fixture.detectChanges(); | ||
}); | ||
|
||
it('should create', () => { | ||
expect(component).toBeTruthy(); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { Component, EventEmitter, Output, AfterViewInit, ElementRef, ViewChild } from '@angular/core'; | ||
import { MatButton } from '@angular/material/button'; | ||
import { DomEvent } from 'leaflet'; | ||
|
||
@Component({ | ||
selector: 'map-control-export', | ||
templateUrl: './export.component.html', | ||
styleUrls: ['./export.component.scss'] | ||
}) | ||
export class ExportControlComponent implements AfterViewInit { | ||
@ViewChild(MatButton, { read: ElementRef }) button: ElementRef; | ||
|
||
@Output() click = new EventEmitter<void>(); | ||
|
||
ngAfterViewInit(): void { | ||
DomEvent.disableClickPropagation(this.button.nativeElement); | ||
} | ||
|
||
onClick($event: MouseEvent): void { | ||
$event.stopPropagation(); | ||
this.click.emit(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<button mat-mini-fab color="default" matTooltip="Filter" matTooltipPosition="after" (click)="onClick($event)"> | ||
<mat-icon color="primary">filter_alt</mat-icon> | ||
</button> |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; | ||
|
||
import { AddObservationComponent } from './add-observation.component'; | ||
import { MatButtonModule } from '@angular/material/button'; | ||
import { MatIconModule } from '@angular/material/icon'; | ||
import { FilterControlComponent } from './filter.component'; | ||
|
||
describe('Filter Control Component', () => { | ||
let component: FilterControlComponent; | ||
let fixture: ComponentFixture<FilterControlComponent>; | ||
|
||
beforeEach(waitForAsync(() => { | ||
TestBed.configureTestingModule({ | ||
imports: [ MatIconModule, MatButtonModule ], | ||
declarations: [ AddObservationComponent ] | ||
}) | ||
.compileComponents(); | ||
})); | ||
|
||
beforeEach(() => { | ||
fixture = TestBed.createComponent(FilterControlComponent); | ||
component = fixture.componentInstance; | ||
fixture.detectChanges(); | ||
}); | ||
|
||
it('should create', () => { | ||
expect(component).toBeTruthy(); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { Component, EventEmitter, Output, AfterViewInit, ElementRef, ViewChild } from '@angular/core'; | ||
import { MatButton } from '@angular/material/button'; | ||
import { DomEvent } from 'leaflet'; | ||
|
||
@Component({ | ||
selector: 'map-control-filter', | ||
templateUrl: './filter.component.html', | ||
styleUrls: ['./filter.component.scss'] | ||
}) | ||
export class FilterControlComponent implements AfterViewInit { | ||
@ViewChild(MatButton, { read: ElementRef }) button: ElementRef; | ||
|
||
@Output() click = new EventEmitter<void>(); | ||
|
||
ngAfterViewInit(): void { | ||
DomEvent.disableClickPropagation(this.button.nativeElement); | ||
} | ||
|
||
onClick($event: MouseEvent): void { | ||
$event.stopPropagation(); | ||
this.click.emit(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
<div class="zoom"> | ||
<button mat-mini-fab color="basic" (click)="onZoomIn($event)"> | ||
<mat-icon color="primary">add</mat-icon> | ||
</button> | ||
<button mat-mini-fab color="basic" (click)="onZoomOut($event)"> | ||
<mat-icon color="primary">remove</mat-icon> | ||
</button> | ||
|
||
<button mat-mini-fab color="basic" (click)="onZoomIn($event)"> | ||
<mat-icon color="primary">add</mat-icon> | ||
</button> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.