Created unified file card component, recent videos component (not done) and started scaffolding work on the backend

This commit is contained in:
Isaac Grynsztein
2020-07-13 22:09:48 -04:00
parent d371ccf094
commit 4ebb2d4297
14 changed files with 310 additions and 3 deletions

View File

@@ -46,6 +46,8 @@ export class AppComponent implements OnInit {
@ViewChild('hamburgerMenu', { read: ElementRef }) hamburgerMenuButton: ElementRef;
navigator: string = null;
subscriptions = null;
constructor(public postsService: PostsService, public snackBar: MatSnackBar, private dialog: MatDialog,
public router: Router, public overlayContainer: OverlayContainer, private elementRef: ElementRef) {
@@ -86,6 +88,13 @@ export class AppComponent implements OnInit {
if (!localStorage.getItem('theme')) {
this.setTheme(themingExists ? this.defaultTheme : 'default');
}
// gets the subscriptions
if (this.allowSubscriptions) {
this.postsService.getAllSubscriptions().subscribe(res => {
this.subscriptions = res['subscriptions'];
})
}
}
// theme stuff
@@ -162,6 +171,11 @@ onSetTheme(theme, old_theme) {
}
getSubscriptions() {
}
goBack() {
if (!this.navigator) {
this.router.navigate(['/home']);