Remove bindonce for Angular 1.3 One-Time Bindings
This commit is contained in:
parent
2cb6b05498
commit
4cdf86ed14
3 changed files with 12 additions and 13 deletions
|
@ -1,18 +1,18 @@
|
||||||
<div ng-show="plugin.visible">
|
<div ng-show="plugin.visible">
|
||||||
<button class="btn btn-primary btn-sm pull-right"
|
<button class="btn btn-primary btn-sm pull-right"
|
||||||
ng-click="hideContent()">
|
ng-click="hideContent()">
|
||||||
Hide {{ plugin.name }}
|
Hide {{ ::plugin.name }}
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<div ng-bind-html="displayedContent" class="embed" bo-class="'embed_' + plugin.$$hashKey"></div>
|
<div ng-bind-html="displayedContent" class="embed" ng-class="::('embed_' + plugin.$$hashKey)"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div ng-hide="plugin.visible">
|
<div ng-hide="plugin.visible">
|
||||||
<button class="btn btn-sm pull-right"
|
<button class="btn btn-sm pull-right"
|
||||||
bo-class="{
|
ng-class="::{
|
||||||
'btn-warning': plugin.nsfw,
|
'btn-warning': plugin.nsfw,
|
||||||
'btn-primary': !plugin.nsfw}"
|
'btn-primary': !plugin.nsfw}"
|
||||||
ng-click="showContent()">
|
ng-click="showContent()">
|
||||||
Show {{ plugin.name }}
|
Show {{ ::plugin.name }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
15
index.html
15
index.html
|
@ -27,7 +27,6 @@
|
||||||
<script type="text/javascript" src="js/websockets.js"></script>
|
<script type="text/javascript" src="js/websockets.js"></script>
|
||||||
<script type="text/javascript" src="js/models.js"></script>
|
<script type="text/javascript" src="js/models.js"></script>
|
||||||
<script type="text/javascript" src="js/plugins.js"></script>
|
<script type="text/javascript" src="js/plugins.js"></script>
|
||||||
<script type="text/javascript" src="3rdparty/bindonce.min.js"></script>
|
|
||||||
<script type="text/javascript" src="3rdparty/favico-0.3.4-mod.min.js"></script>
|
<script type="text/javascript" src="3rdparty/favico-0.3.4-mod.min.js"></script>
|
||||||
</head>
|
</head>
|
||||||
<body ng-controller="WeechatCtrl" ng-keydown="handleKeyPress($event)" ng-class="{'no-overflow': connected}" lang="en-US">
|
<body ng-controller="WeechatCtrl" ng-keydown="handleKeyPress($event)" ng-class="{'no-overflow': connected}" lang="en-US">
|
||||||
|
@ -220,7 +219,7 @@ $ openssl req -nodes -newkey rsa:4096 -keyout relay.pem -x509 -days 365 -out rel
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div bindonce id="sidebar" data-state="visible" ng-swipe-left="hideSidebar()" class="vertical-line">
|
<div id="sidebar" data-state="visible" ng-swipe-left="hideSidebar()" class="vertical-line">
|
||||||
<ul class="nav nav-pills nav-stacked" ng-class="{'indented': (predicate === 'serverSortKey')}">
|
<ul class="nav nav-pills nav-stacked" ng-class="{'indented': (predicate === 'serverSortKey')}">
|
||||||
<li class="bufferfilter">
|
<li class="bufferfilter">
|
||||||
<form role="form">
|
<form role="form">
|
||||||
|
@ -235,11 +234,11 @@ $ openssl req -nodes -newkey rsa:4096 -keyout relay.pem -x509 -days 365 -out rel
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div bindonce id="bufferlines" class="favorite-font" ng-swipe-right="showSidebar()" ng-swipe-left="hideSidebar()" ng-class="{'withnicklist': showNicklist}">
|
<div id="bufferlines" class="favorite-font" ng-swipe-right="showSidebar()" ng-swipe-left="hideSidebar()" ng-class="{'withnicklist': showNicklist}">
|
||||||
<div id="nicklist" ng-if="showNicklist" ng-swipe-right="closeNick()" class="vertical-line-left">
|
<div id="nicklist" ng-if="showNicklist" ng-swipe-right="closeNick()" class="vertical-line-left">
|
||||||
<ul class="nicklistgroup list-unstyled" ng-repeat="group in nicklist">
|
<ul class="nicklistgroup list-unstyled" ng-repeat="group in nicklist">
|
||||||
<li ng-repeat="nick in group.nicks|orderBy:'name'">
|
<li ng-repeat="nick in group.nicks|orderBy:'name'">
|
||||||
<a ng-click="openBuffer(nick.name)"><span bo-class="nick.prefixClasses" bo-text="nick.prefix"></span><span bo-class="nick.nameClasses" bo-text="nick.name"></span></a>
|
<a ng-click="openBuffer(nick.name)"><span ng-class="::nick.prefixClasses" ng-bind="::nick.prefix"></span><span ng-class="::nick.nameClasses" ng-bind="::nick.name"></span></a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
@ -255,14 +254,14 @@ $ openssl req -nodes -newkey rsa:4096 -keyout relay.pem -x509 -days 365 -out rel
|
||||||
<tbody ng-repeat="bufferline in bufferlines">
|
<tbody ng-repeat="bufferline in bufferlines">
|
||||||
<tr class="bufferline">
|
<tr class="bufferline">
|
||||||
<td class="time">
|
<td class="time">
|
||||||
<span class="date" bo-class="{'repeated-time': bufferline.shortTime==bufferlines[$index-1].shortTime}">
|
<span class="date" ng-class="::{'repeated-time': bufferline.shortTime==bufferlines[$index-1].shortTime}">
|
||||||
<span class="cof-chat_time cob-chat_time coa-chat_time" bo-text="bufferline.date|date:'HH'"></span><span class="cof-chat_time_delimiters cob-chat_time_delimiters coa-chat_time_delimiters">:</span><span class="cof-chat_time cob-chat_time coa-chat_time" bo-text="bufferline.date|date:'mm'"></span><span class="seconds"><span class="cof-chat_time_delimiters cob-chat_time_delimiters coa-chat_time_delimiters">:</span><span class="cof-chat_time cob-chat_time coa-chat_time" bo-text="bufferline.date|date:'ss'"></span></span>
|
<span class="cof-chat_time cob-chat_time coa-chat_time" ng-bind="::(bufferline.date|date:'HH')"></span><span class="cof-chat_time_delimiters cob-chat_time_delimiters coa-chat_time_delimiters">:</span><span class="cof-chat_time cob-chat_time coa-chat_time" ng-bind="::(bufferline.date|date:'mm')"></span><span class="seconds"><span class="cof-chat_time_delimiters cob-chat_time_delimiters coa-chat_time_delimiters">:</span><span class="cof-chat_time cob-chat_time coa-chat_time" ng-bind="::(bufferline.date|date:'ss')"></span></span>
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
<td class="prefix"><a ng-click="addMention(bufferline.prefix)"><span ng-repeat="part in ::bufferline.prefix" bo-class="part.classes" bo-html="part.text"></span></a></td>
|
<td class="prefix"><a ng-click="addMention(bufferline.prefix)"><span ng-repeat="part in ::bufferline.prefix" ng-class="::part.classes" ng-bind="::part.text"></span></a></td>
|
||||||
<td class="message">
|
<td class="message">
|
||||||
<div ng-repeat="metadata in ::bufferline.metadata" plugin data="::metadata"></div>
|
<div ng-repeat="metadata in ::bufferline.metadata" plugin data="::metadata"></div>
|
||||||
<span ng-repeat="part in ::bufferline.content" class="text" bo-class="part.classes" bo-html="part.text | irclinky:'_blank' | inlinecolour"></span>
|
<span ng-repeat="part in ::bufferline.content" class="text" ng-class="::part.classes" ng-bind-html="::part.text | irclinky:'_blank' | inlinecolour"></span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr class="readmarker" ng-if="activeBuffer().lastSeen==$index">
|
<tr class="readmarker" ng-if="activeBuffer().lastSeen==$index">
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
var weechat = angular.module('weechat', ['ngRoute', 'localStorage', 'weechatModels', 'plugins', 'ngSanitize', 'ngWebsockets', 'pasvaz.bindonce', 'ngTouch']);
|
var weechat = angular.module('weechat', ['ngRoute', 'localStorage', 'weechatModels', 'plugins', 'ngSanitize', 'ngWebsockets', 'ngTouch']);
|
||||||
|
|
||||||
weechat.filter('toArray', function () {
|
weechat.filter('toArray', function () {
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
Loading…
Reference in a new issue