added menu icon for columns
This commit is contained in:
parent
1acad1ca03
commit
49f6d1a22a
|
@ -4,8 +4,11 @@
|
|||
[browseAccountData]="overlayAccountToBrowse" [browseHashtagData]="overlayHashtagToBrowse" [browseThreadData]="overlayThreadToBrowse"></app-stream-overlay>
|
||||
|
||||
<div class="stream-column__stream-header">
|
||||
<a class="stream-column__stream-selector" href title="return to top" (click)="goToTop()">
|
||||
<fa-icon class="stream-column__stream-selector--icon" [icon]="faIcon"></fa-icon>
|
||||
<a class="stream-column__open-menu" href title="open menu" (click)="openMenu()">
|
||||
<fa-icon class="stream-column__open-menu--icon" [icon]="menuFaIcon"></fa-icon>
|
||||
</a>
|
||||
<a class="stream-column__stream-selector" href title="return to top" (click)="goToTop()">
|
||||
<fa-icon class="stream-column__stream-selector--icon" [icon]="columnFaIcon"></fa-icon>
|
||||
<h1 class="stream-column__stream-selector--title">{{ streamElement.name.toUpperCase() }}</h1>
|
||||
</a>
|
||||
</div>
|
||||
|
|
|
@ -11,6 +11,28 @@ $stream-header-height: 40px;
|
|||
border-bottom: 1px solid #222736;
|
||||
}
|
||||
|
||||
&__open-menu {
|
||||
float: right;
|
||||
display: block;
|
||||
width: $stream-header-height - 10px;
|
||||
height: $stream-header-height - 10px;
|
||||
margin: 5px;
|
||||
|
||||
&:hover &--icon {
|
||||
color: darken(whitesmoke, 30);
|
||||
}
|
||||
|
||||
&--icon {
|
||||
color: whitesmoke;
|
||||
// float: left;
|
||||
position: relative;
|
||||
top: 4px;
|
||||
left: 8px;
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
&__stream-selector {
|
||||
display: block;
|
||||
width: calc(100%);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import { Component, OnInit, Input, ElementRef, ViewChild, HostListener } from "@angular/core";
|
||||
import { Subject } from "rxjs";
|
||||
import { faHome, faGlobe, faUser, faHashtag, faListUl, IconDefinition } from "@fortawesome/free-solid-svg-icons";
|
||||
import { faHome, faGlobe, faUser, faHashtag, faListUl, faBars, IconDefinition } from "@fortawesome/free-solid-svg-icons";
|
||||
|
||||
import { StreamElement, StreamTypeEnum } from "../../states/streams.state";
|
||||
import { Status } from "../../services/models/mastodon.interfaces";
|
||||
|
@ -12,7 +12,8 @@ import { AccountInfo } from "../../states/accounts.state";
|
|||
styleUrls: ["./stream.component.scss"]
|
||||
})
|
||||
export class StreamComponent implements OnInit {
|
||||
faIcon: IconDefinition;
|
||||
columnFaIcon: IconDefinition;
|
||||
menuFaIcon = faBars;
|
||||
|
||||
overlayActive: boolean;
|
||||
overlayAccountToBrowse: string;
|
||||
|
@ -27,19 +28,19 @@ export class StreamComponent implements OnInit {
|
|||
set streamElement(stream: StreamElement) {
|
||||
switch (stream.type) {
|
||||
case StreamTypeEnum.personnal:
|
||||
this.faIcon = faHome;
|
||||
this.columnFaIcon = faHome;
|
||||
break;
|
||||
case StreamTypeEnum.global:
|
||||
this.faIcon = faGlobe;
|
||||
this.columnFaIcon = faGlobe;
|
||||
break;
|
||||
case StreamTypeEnum.local:
|
||||
this.faIcon = faUser;
|
||||
this.columnFaIcon = faUser;
|
||||
break;
|
||||
case StreamTypeEnum.tag:
|
||||
this.faIcon = faHashtag;
|
||||
this.columnFaIcon = faHashtag;
|
||||
break;
|
||||
case StreamTypeEnum.list:
|
||||
this.faIcon = faListUl;
|
||||
this.columnFaIcon = faListUl;
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -87,6 +88,11 @@ export class StreamComponent implements OnInit {
|
|||
this.overlayThreadToBrowse = null;
|
||||
this.overlayActive = false;
|
||||
}
|
||||
|
||||
openMenu(): bool {
|
||||
console.log('opened menu');
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
export class StatusWrapper {
|
||||
|
|
Loading…
Reference in New Issue