add feed indication

This commit is contained in:
chsakell
2016-12-06 16:36:04 +02:00
parent b947ed635f
commit 694cb912e8
3 changed files with 14 additions and 6 deletions

View File

@@ -33,7 +33,7 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">Live Feed</a>
<a class="navbar-brand" href="#"><span id="horn" class="glyphicon glyphicon-bullhorn"></span> Live Game Feed</a>
</div>
<div class="collapse navbar-collapse" id="myNavbar">
<ul class="nav navbar-nav">

View File

@@ -7,8 +7,12 @@ export class HighlightDirective {
constructor(private el: ElementRef, private renderer: Renderer) {
let self = this;
self.renderer.setElementClass(this.el.nativeElement, 'feed-highlight', true);
let horn = document.getElementById('horn');
horn.className += ' orange';
setTimeout(function () {
self.renderer.setElementClass(self.el.nativeElement, 'feed-highlight-light', true);
document.getElementById("horn").className = document.getElementById("horn").className.replace(/(?:^|\s)orange(?!\S)/g, '')
}, 1000);
}

View File

@@ -80,3 +80,7 @@ footer {
bottom: 0;
width: 100%;
}
.orange {
color: #ff5525;
}