ng-show exists. So, for clarity, avoid to use ng-hide and double negation test.
This commit is contained in:
parent
246b2a3c3e
commit
96baf62e7a
|
@ -45,13 +45,13 @@
|
|||
</td>
|
||||
<td ng-class="!msg.content.membership ? (msg.content.msgtype === 'm.emote' ? 'emote text' : 'text') : 'membership text'">
|
||||
<div class="bubble">
|
||||
<span ng-hide='msg.type !== "m.room.member"'>
|
||||
<span ng-show='msg.type === "m.room.member"'>
|
||||
{{ members[msg.user_id].displayname || msg.user_id }}
|
||||
{{ {"join": "joined", "leave": "left", "invite": "invited"}[msg.content.membership] }}
|
||||
{{ msg.content.membership === "invite" ? (msg.state_key || '') : '' }}
|
||||
</span>
|
||||
<span ng-hide='msg.content.msgtype !== "m.emote"' ng-bind-html="'* ' + (members[msg.user_id].displayname || msg.user_id) + ' ' + msg.content.body | linky:'_blank'"/>
|
||||
<span ng-hide='msg.content.msgtype !== "m.text"' ng-bind-html="((msg.content.msgtype === 'm.text') ? msg.content.body : '') | linky:'_blank'"/>
|
||||
<span ng-show='msg.content.msgtype === "m.emote"' ng-bind-html="'* ' + (members[msg.user_id].displayname || msg.user_id) + ' ' + msg.content.body | linky:'_blank'"/>
|
||||
<span ng-show='msg.content.msgtype === "m.text"' ng-bind-html="((msg.content.msgtype === 'm.text') ? msg.content.body : '') | linky:'_blank'"/>
|
||||
<div ng-show='msg.content.msgtype === "m.image"'>
|
||||
<div ng-hide='msg.content.thumbnail_url' ng-style="msg.content.body.h && { 'height' : (msg.content.body.h < 320) ? msg.content.body.h : 320}">
|
||||
<img class="image" ng-src="{{ msg.content.url }}"/>
|
||||
|
@ -101,7 +101,7 @@
|
|||
</div>
|
||||
|
||||
{{ feedback }}
|
||||
<div ng-hide="!state.stream_failure">
|
||||
<div ng-show="state.stream_failure">
|
||||
{{ state.stream_failure.data.error || "Connection failure" }}
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue