Render conversation placeholder hint in place
// FREEBIE
This commit is contained in:
parent
891a5e54ad
commit
8d214b73d9
4 changed files with 10 additions and 19 deletions
|
@ -23,6 +23,10 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class='conversation-stack'>
|
<div class='conversation-stack'>
|
||||||
|
<div class='conversation placeholder'>
|
||||||
|
<h3>Welcome to Signal</h3>
|
||||||
|
<p> Select a contact or group to start chatting.</p>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</script>
|
</script>
|
||||||
<script type='text/x-tmpl-mustache' id='hint'>
|
<script type='text/x-tmpl-mustache' id='hint'>
|
||||||
|
|
|
@ -102,13 +102,7 @@
|
||||||
this.inboxListView.$el.hide();
|
this.inboxListView.$el.hide();
|
||||||
});
|
});
|
||||||
|
|
||||||
this.hintView = new Whisper.HintView({
|
|
||||||
className: 'conversation placeholder',
|
|
||||||
content: "Select a contact or group to start chatting."
|
|
||||||
});
|
|
||||||
if (inboxCollection.length === 0) {
|
if (inboxCollection.length === 0) {
|
||||||
this.hintView.render();
|
|
||||||
this.hintView.$el.prependTo(this.$('.conversation-stack'));
|
|
||||||
this.searchView.showAllContacts = true;
|
this.searchView.showAllContacts = true;
|
||||||
this.searchView.reset();
|
this.searchView.reset();
|
||||||
this.listenToOnce(inboxCollection, 'add', function() {
|
this.listenToOnce(inboxCollection, 'add', function() {
|
||||||
|
@ -141,7 +135,6 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
hideHints: function() {
|
hideHints: function() {
|
||||||
this.hintView.remove();
|
|
||||||
this.searchView.hideHints();
|
this.searchView.hideHints();
|
||||||
},
|
},
|
||||||
openConversation: function(e, conversation) {
|
openConversation: function(e, conversation) {
|
||||||
|
|
|
@ -218,14 +218,10 @@ input.search {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.placeholder p {
|
|
||||||
color: $grey;
|
|
||||||
}
|
|
||||||
.conversation.placeholder {
|
.conversation.placeholder {
|
||||||
p {
|
text-align: center;
|
||||||
text-align: center;
|
padding-top: 100px;
|
||||||
margin-top: 120px;
|
color: #aaa;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
.contact.placeholder {
|
.contact.placeholder {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
|
|
@ -536,12 +536,10 @@ input.search {
|
||||||
border-color: transparent #2eace0 transparent transparent;
|
border-color: transparent #2eace0 transparent transparent;
|
||||||
left: -30px; }
|
left: -30px; }
|
||||||
|
|
||||||
.placeholder p {
|
.conversation.placeholder {
|
||||||
color: #616161; }
|
|
||||||
|
|
||||||
.conversation.placeholder p {
|
|
||||||
text-align: center;
|
text-align: center;
|
||||||
margin-top: 120px; }
|
padding-top: 100px;
|
||||||
|
color: #aaa; }
|
||||||
|
|
||||||
.contact.placeholder {
|
.contact.placeholder {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
|
Loading…
Reference in a new issue