Browse Source
- Fix several issues in Chats
- Fix several issues in Chats
- Use the :empty CSS selector to put the placeholder (+ JS fix to trim the content) - Remove useless Notification refresh - Fix JS fatal errorpull/16/head
8 changed files with 72 additions and 63 deletions
-
14app/widgets/Chat/chat.js
-
22app/widgets/Chats/Chats.php
-
15app/widgets/Chats/_chats.tpl
-
44app/widgets/Chats/_chats_add.tpl
-
7app/widgets/Chats/chats.css
-
8app/widgets/Chats/chats.js
-
13app/widgets/Chats/chats.tpl
-
12app/widgets/Notification/Notification.php
@ -1,14 +1 @@ |
|||
{if="$chats == null"} |
|||
<div class="placeholder icon"> |
|||
<h1>{$c->__('chats.empty_title')}</h1> |
|||
<h4>{$c->__('chats.empty')}</h4> |
|||
</div> |
|||
{/if} |
|||
|
|||
{loop="$chats"} |
|||
{$c->prepareChat($key)} |
|||
{/loop} |
|||
|
|||
<a onclick="Chats_ajaxAdd()" class="button action color"> |
|||
<i class="zmdi zmdi-plus"></i> |
|||
</a> |
|||
{loop="$chats"}{$c->prepareChat($key)}{/loop} |
@ -0,0 +1,7 @@ |
|||
#chats_widget_list ~ .placeholder { |
|||
display: none; |
|||
} |
|||
|
|||
#chats_widget_list:empty ~ .placeholder { |
|||
display: block; |
|||
} |
@ -1,3 +1,10 @@ |
|||
<ul id="chats_widget_list" class="middle active divided spaced"> |
|||
{$list} |
|||
</ul> |
|||
<ul id="chats_widget_list" class="middle active divided spaced">{$list}</ul> |
|||
|
|||
<div class="placeholder icon"> |
|||
<h1>{$c->__('chats.empty_title')}</h1> |
|||
<h4>{$c->__('chats.empty')}</h4> |
|||
</div> |
|||
|
|||
<a onclick="Chats_ajaxAdd()" class="button action color"> |
|||
<i class="zmdi zmdi-plus"></i> |
|||
</a> |
Write
Preview
Loading…
Cancel
Save
Reference in new issue