transition: color 0.3s;
color: #88C56A;
}
+#kiwi .membercount {
+ border-bottom: 1px solid #8A8A8A;
+ font-size: 0.9em;
+ margin-bottom: 10px;
+ padding: 0 0 5%;
+ text-align: center;
+}
+#kiwi .membercount span {
+ display: none;
+}
+#kiwi .membercount span.active {
+ display: block;
+}
#kiwi .messages .msg > div { color:#6d6d6d; font-family: Inconsolata, Consolas, 'courier new', monospace; }
#kiwi .messages .msg { border: none; padding: 2px 5px; }
transition: color 0.3s;
color: #88C56A;
}
+#kiwi .membercount {
+ border-bottom: 1px solid #8A8A8A;
+ font-size: 0.9em;
+ margin-bottom: 10px;
+ padding: 0 0 5%;
+ text-align: center;
+}
+#kiwi .membercount span {
+ display: none;
+}
+#kiwi .membercount span.active {
+ display: block;
+}
#kiwi .messages { color: #333333; }
#kiwi .messages.active { }
<i class="icon-signout channel_part" title="Leave Channel"></i>\r
<i class="icon-double-angle-right right-bar-toggle-inner" title="Hide"></i>\r
</div>\r
+ <div class="membercount"></div>\r
<div class="memberlists"></div>\r
</div>\r
</div>\r
render: function () {
var $this = this.$el;
$this.empty();
+
this.model.forEach(function (member) {
member.view.$el.data('member', member);
$this.append(member.view.$el);
});
+
+ // User count
+ if(this.model.channel.cid === _kiwi.app.panels().active.cid) {
+ var members_count = this.model.length + ' ' + translateText('client_applets_chanlist_users');
+
+ $('#kiwi .membercount > span.' + this.model.channel.cid).text(members_count);
+ $('#kiwi .membercount > span.' + this.model.channel.cid).addClass('active');
+ }
+
return this;
},
nickClick: function (event) {
show: function () {
$('#kiwi .memberlists').children().removeClass('active');
$(this.el).addClass('active');
+
+ // User count
+ var members_count = this.model.length + ' ' + translateText('client_applets_chanlist_users');
+ var members_count_code = '<span class="' + this.model.channel.cid + '">';
+
+ $('#kiwi .membercount').children().removeClass('active');
+ // If the span for this panel doesn't exist, create it
+ if($('#kiwi .membercount > span.' + this.model.channel.cid).length == 0){
+ $(members_count_code).appendTo('#kiwi .membercount');
+ }
+
+ $('#kiwi .membercount > span.' + this.model.channel.cid).text(members_count);
+ $('#kiwi .membercount > span.' + this.model.channel.cid).addClass('active');
}
});
\ No newline at end of file