GUAC-605: Migrate status to guacNotification. Add countdown string to en_US translation. Use 15 second reconnect countdown if appropriate for error at hand.

This commit is contained in:
Michael Jumper
2014-11-29 20:54:50 -08:00
parent 5b31b206a7
commit ed31e0c026
7 changed files with 166 additions and 248 deletions

View File

@@ -37,20 +37,17 @@ THE SOFTWARE.
<!-- Global status/error dialog -->
<div ng-class="{shown: status}" class="status-outer">
<div class="status-middle">
<div class="status" ng-class="status.className">
<!-- Status title -->
<p ng-show="status.title" class="title">{{status.title | translate}}</p>
<!-- Status text -->
<p ng-show="status.text" class="text">{{status.text | translate}}</p>
<!-- All action buttons, if any -->
<div ng-show="status.actions && status.actions.length" class="buttons">
<button ng-repeat="action in status.actions" ng-click="action.callback()">{{action.name | translate}}</button>
</div>
</div>
<guac-notification
class-name="status.className"
title="status.title"
text="status.text"
progress="status.progress"
actions="status.actions"
countdown-text="status.countdown.text"
countdown="status.countdown.remaining"
default-callback="status.countdown.callback"/>
</div>
</div>
@@ -59,24 +56,19 @@ THE SOFTWARE.
<!-- Notification area -->
<div id="notificationArea">
<div ng-repeat="wrapper in notifications" ng-class="wrapper.notification.className" class="notification">
<!-- Notification title -->
<div ng-show="wrapper.notification.title" class="title-bar">
<div class="title">{{wrapper.notification.title | translate}}</div>
</div>
<!-- Notification text -->
<p ng-show="wrapper.notification.text" class="text">{{wrapper.notification.text}}</p>
<div ng-show="wrapper.notification.progress" class="progress">
{{wrapper.notification.progress}}
</div>
<div ng-show="wrapper.notification.actions && wrapper.notification.actions.length" class="buttons">
<button ng-repeat="action in wrapper.notification.actions" ng-click="action.callback()">{{action.name | translate}}</button>
</div>
</div>
<div ng-repeat="wrapper in notifications">
<guac-notification
class-name="wrapper.notification.className"
title="wrapper.notification.title"
text="wrapper.notification.text"
progress="wrapper.notification.progress"
actions="wrapper.notification.actions"
countdown-text="wrapper.notification.countdown.text"
countdown="wrapper.notification.countdown.remaining"
default-callback="wrapper.notification.countdown.callback"/>
<div>
</div>
<script type="text/javascript" src="guacamole.min.js"></script>