Fixed notifications

This commit is contained in:
Fergal Moran
2015-12-08 20:19:15 +00:00
parent 221227cf5e
commit 12027f3e1f
5 changed files with 26 additions and 77 deletions

View File

@@ -16,11 +16,25 @@
<span>Upload</span>
</a>
</li>
<li>
<form class="navbar-form" role="search">
<div class="input-group">
<input type="text" ng-model="selected" placeholder="Search..."
typeahead="result for results in getSearchResults($viewValue)"
typeahead-template-url="app/views/templates/searchResult.html"
typeahead-loading="loadingSearchResults"
class="form-control"/>
<div class="input-group-btn">
<button class="btn btn-default" type="submit"><i class="glyphicon glyphicon-search"></i></button>
</div>
</div>
</form>
</li>
</ul>
<div class="user" ng-if="$root.currentUser">
<ul class="icon-nav">
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
<li class="dropdown" id="notifications">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" id="notifications-button">
<i class="fa fa-envelope"></i>
<span class="label label-lightred">{{notificationCount}}</span>
</a>
@@ -52,27 +66,6 @@
</div>
</div>
<ul class="main-nav pull-right">
<li>
<form action="" class="search-form">
<div class="form-group has-feedback">
<label for="search" class="sr-only">Search</label>
<input type="text" class="form-control" name="search" id="search" placeholder="search">
<span class="glyphicon glyphicon-search form-control-feedback"></span>
</div>
</form>
<!--
<form class="search-form">
<div class="search-pane">
<input type="text" ng-model="selected" placeholder="Search..."
typeahead="result for results in getSearchResults($viewValue)"
typeahead-template-url="app/views/templates/searchResult.html"
typeahead-loading="loadingSearchResults"
class="form-control"/>
<i ng-show="loadingSearchResults" class="glyphicon glyphicon-refresh"></i>
</div>
</form>
-->
</li>
<li class="ms-hover" ng-if="!$root.currentUser">
<a href="#" data-toggle="dropdown" class="dropdown-toggle">
Login/Signup

View File

@@ -38,53 +38,3 @@ div.social-buttons a {
}
.search-form .form-group {
float: right !important;
transition: all 0.35s, border-radius 0s;
width: 32px;
height: 32px;
background-color: #fff;
box-shadow: 0 1px 1px rgba(0, 0, 0, 0.075) inset;
border-radius: 25px;
border: 1px solid #ccc;
}
.search-form .form-group input.form-control {
padding-right: 20px;
border: 0 none;
background: transparent;
box-shadow: none;
display:block;
}
.search-form .form-group input.form-control::-webkit-input-placeholder {
display: none;
}
.search-form .form-group input.form-control:-moz-placeholder {
/* Firefox 18- */
display: none;
}
.search-form .form-group input.form-control::-moz-placeholder {
/* Firefox 19+ */
display: none;
}
.search-form .form-group input.form-control:-ms-input-placeholder {
display: none;
}
.search-form .form-group:hover,
.search-form .form-group.hover {
width: 100%;
border-radius: 4px 25px 25px 4px;
}
.search-form .form-group span.form-control-feedback {
position: absolute;
top: -1px;
right: -2px;
z-index: 2;
display: block;
width: 34px;
height: 34px;
line-height: 34px;
text-align: center;
color: #3596e0;
left: initial;
font-size: 14px;
}

View File

@@ -1,8 +1,11 @@
<li ng-repeat="notification in notifications">
<a ui-sref="root.mixes.mix({slug: notification.target})">
<a ui-sref="root.mixes.mix({slug: notification.target})"
ng-class="notification.accepted_date ? '' : 'notification-new'">
<img ng-src="{{notification.from_user.profile_image_small}}" alt="">
<div class="details">
<div class="name">{{notification.from_user.display_name}}</div>
<div class="name">
{{notification.from_user.first_name}}
</div>
<div class="message">
{{notification.verb}}&nbsp;{{notification.target_desc}}
</div>

View File

@@ -2,3 +2,8 @@
overflow: scroll;
overflow-x: hidden;
}
.notification-new .message{
font-weight: bold;
}

View File

@@ -1,5 +1,4 @@
var helpers = helpers || {};
/*
if (FB) {
FB.init({
appId: '154504534677009',
@@ -9,7 +8,6 @@ if (FB) {
version: 'v2.3'
});
}
*/
helpers.social = {
postToFacebook: function (mix) {
FB.getLoginStatus(function (oResponse) {