2014-12-17 20:58:20 +01:00
|
|
|
<?xml version='1.0' standalone='yes'?>
|
|
|
|
<container
|
2015-02-26 17:27:36 +01:00
|
|
|
xmlns="http://www.w3.org/1999/xhtml"
|
2015-07-24 21:35:29 +02:00
|
|
|
xmlns:var="http://www.skyrix.com/od/binding"
|
2015-04-29 17:23:21 +02:00
|
|
|
xmlns:label="OGo:label">
|
2015-07-15 19:44:17 +02:00
|
|
|
<div class="view-list" layout="column">
|
2015-09-03 22:10:05 +02:00
|
|
|
|
|
|
|
<!-- single-selection toolbars -->
|
|
|
|
<md-toolbar ng-show="mailbox.selectedFolder.$selectedCount() == 0">
|
2015-09-09 20:43:09 +02:00
|
|
|
<!-- sort mode (default) -->
|
2015-09-03 22:10:05 +02:00
|
|
|
<div class="md-toolbar-tools" ng-hide="mailbox.mode.search">
|
|
|
|
<md-button class="sg-icon-button" label:aria-label="Search"
|
|
|
|
ng-click="mailbox.mode.search = true">
|
|
|
|
<md-icon>search</md-icon>
|
|
|
|
</md-button>
|
2015-09-09 20:43:09 +02:00
|
|
|
<div class="md-flex">{{mailbox.selectedFolder.name}}</div>
|
2015-09-03 22:10:05 +02:00
|
|
|
<md-menu>
|
|
|
|
<md-button class="sg-icon-button" label:aria-label="Sort"
|
|
|
|
ng-click="$mdOpenMenu()">
|
|
|
|
<md-icon>sort</md-icon>
|
|
|
|
</md-button>
|
|
|
|
<md-menu-content>
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button ng-click="mailbox.sort('subject')">
|
|
|
|
<md-icon ng-class="{ 'icon-check': mailbox.sortedBy('subject') }">
|
|
|
|
<!-- subject --></md-icon> <var:string label:value="Subject"/>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button ng-click="mailbox.sort('from')">
|
|
|
|
<md-icon ng-class="{ 'icon-check': mailbox.sortedBy('from') }">
|
|
|
|
<!-- from --></md-icon> <var:string label:value="From"/>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button ng-click="mailbox.sort('date')">
|
|
|
|
<md-icon ng-class="{ 'icon-check': mailbox.sortedBy('date') }">
|
|
|
|
<!-- date --></md-icon> <var:string label:value="Date"/>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button ng-click="mailbox.sort('size')">
|
|
|
|
<md-icon ng-class="{ 'icon-check': mailbox.sortedBy('size') }">
|
|
|
|
<!-- size --></md-icon> <var:string label:value="Size"/>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
<md-menu-divider> <!-- divider --></md-menu-divider>
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button ng-click="mailbox.selectedFolder.$filter()">
|
|
|
|
<md-checkbox
|
|
|
|
ng-model="mailbox.service.$query.asc"
|
|
|
|
ng-true-value="0"
|
|
|
|
ng-false-value="1"><var:string label:value="Descending Order"/></md-checkbox>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
</md-menu-content>
|
|
|
|
</md-menu>
|
|
|
|
<md-button class="sg-icon-button" aria-label="Refresh" ng-click="mailbox.selectedFolder.$filter()" >
|
|
|
|
<md-icon>refresh</md-icon>
|
|
|
|
</md-button>
|
|
|
|
</div>
|
|
|
|
<!-- search mode -->
|
|
|
|
<div class="md-toolbar-tools sg-toolbar-secondary"
|
|
|
|
ng-show="mailbox.mode.search"
|
|
|
|
sg-search="mailbox.selectedFolder.$filter({ sort: 'date', asc: false }, [{ searchBy: searchField, searchInput: searchText }])">
|
|
|
|
<md-button class="sg-icon-button"
|
|
|
|
sg-search-cancel="mailbox.cancelSearch()"
|
|
|
|
label:aria-label="Back">
|
|
|
|
<md-icon>arrow_back</md-icon>
|
|
|
|
</md-button>
|
|
|
|
<md-input-container>
|
|
|
|
<input name="folderSearch" type="search" />
|
|
|
|
</md-input-container>
|
|
|
|
<md-input-container>
|
|
|
|
<md-select>
|
|
|
|
<md-option value="subject" selected="selected"><var:string label:value="Subject"/></md-option>
|
|
|
|
<md-option value="from"><var:string label:value="Sender"/></md-option>
|
|
|
|
<md-option value="subject_or_from"><var:string label:value="Subject or Sender"/></md-option>
|
|
|
|
<md-option value="to_or_cc"><var:string label:value="To or Cc"/></md-option>
|
|
|
|
<md-option value="body"><var:string label:value="Entire Message"/></md-option>
|
|
|
|
</md-select>
|
|
|
|
</md-input-container>
|
|
|
|
</div>
|
|
|
|
</md-toolbar>
|
|
|
|
|
|
|
|
<!-- multiple-selection mode -->
|
|
|
|
<md-toolbar class="md-hue-1 sg-toolbar-secondary" ng-show="mailbox.selectedFolder.$selectedCount() > 0">
|
|
|
|
<div class="md-toolbar-tools">
|
|
|
|
<md-button class="sg-icon-button" ng-click="mailbox.unselectMessages()">
|
|
|
|
<md-icon>arrow_back</md-icon>
|
|
|
|
</md-button>
|
|
|
|
<label>{{mailbox.selectedFolder.$selectedCount()}} <var:string label:value="selected"/></label>
|
|
|
|
<div class="md-flex"><!-- spacer --></div>
|
|
|
|
<md-button class="sg-icon-button" ng-click="mailbox.selectAll()">
|
|
|
|
<md-tooltip md-direction="bottom"><var:string label:value="Select All"/></md-tooltip>
|
|
|
|
<md-icon>select_all</md-icon>
|
|
|
|
</md-button>
|
|
|
|
<md-button class="sg-icon-button" ng-click="mailbox.confirmDeleteSelectedMessages()">
|
|
|
|
<md-icon>delete</md-icon>
|
|
|
|
</md-button>
|
|
|
|
<md-menu>
|
|
|
|
<md-button class="sg-icon-button" label:aria-label="Copy messages" ng-click="$mdOpenMenu()">
|
|
|
|
<md-tooltip md-direction="bottom"><var:string label:value="Copy To"/></md-tooltip>
|
|
|
|
<md-icon>content_copy</md-icon>
|
|
|
|
</md-button>
|
|
|
|
<md-menu-content width="4">
|
|
|
|
<div ng-repeat="account in mailbox.accounts track by account.id">
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button class="md-primary" ng-disabled="true">{{account.name}}</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
<md-menu-divider><!-- divider --></md-menu-divider>
|
|
|
|
<md-menu-item ng-repeat="folder in
|
|
|
|
account.$flattenMailboxes()
|
|
|
|
track by folder.path"
|
|
|
|
ng-hide="mailbox.id == folder.id">
|
|
|
|
<md-button ng-click="mailbox.copySelectedMessages(folder.id)">
|
|
|
|
<span ng-class="'sg-child-level-' + folder.level">{{folder.name}}</span>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
</div>
|
|
|
|
</md-menu-content>
|
|
|
|
</md-menu>
|
|
|
|
<md-menu>
|
|
|
|
<md-button class="sg-icon-button" label:aria-label="More messages options" ng-click="$mdOpenMenu()">
|
|
|
|
<md-icon>more_vert</md-icon>
|
|
|
|
</md-button>
|
|
|
|
<md-menu-content width="2">
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button ng-click="mailbox.markSelectedMessagesAsFlagged()">
|
|
|
|
<var:string label:value="Flag"/>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button ng-click="mailbox.markSelectedMessagesAsUnread()">
|
|
|
|
<var:string label:value="Mark as Unread"/>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
<md-menu-item>
|
|
|
|
<md-button ng-click="mailbox.saveSelectedMessages()">
|
|
|
|
<var:string label:value="Save As..."/>
|
|
|
|
</md-button>
|
|
|
|
</md-menu-item>
|
|
|
|
</md-menu-content>
|
|
|
|
</md-menu>
|
|
|
|
</div>
|
|
|
|
</md-toolbar>
|
|
|
|
|
2015-07-15 19:44:17 +02:00
|
|
|
<md-content id="messagesList" layout="column" class="md-flex">
|
2015-09-09 20:43:09 +02:00
|
|
|
<md-subheader>
|
|
|
|
<span ng-switch="mailbox.selectedFolder.$messages.length">
|
|
|
|
<span ng-switch-when="0"><var:string label:value="No message"/></span>
|
|
|
|
<span ng-switch-default="true">{{mailbox.selectedFolder.$messages.length}} <var:string label:value="messages"/></span>
|
|
|
|
</span>
|
|
|
|
</md-subheader>
|
2015-07-15 19:44:17 +02:00
|
|
|
<md-virtual-repeat-container class="md-flex">
|
2015-08-07 17:17:09 +02:00
|
|
|
<md-list class="sg-section-list">
|
2015-08-25 18:20:46 +02:00
|
|
|
<md-list-item
|
|
|
|
md-virtual-repeat="currentMessage in mailbox.selectedFolder"
|
|
|
|
md-on-demand="md-on-demand"
|
|
|
|
ng-class="{'sg-active': currentMessage.uid == mailbox.selectedFolder.selectedMessage, unread: !currentMessage.isread}"
|
|
|
|
ng-click="mailbox.selectMessage(currentMessage)"
|
2015-09-09 22:35:09 +02:00
|
|
|
ui-sref="mail.account.mailbox.message({accountId: mailbox.account.id, mailboxId: (mailbox.selectedFolder.path | encodeUri), messageId: currentMessage.uid})"
|
|
|
|
ui-sref-active="md-default-theme md-background md-bg md-hue-1">
|
2015-08-25 18:20:46 +02:00
|
|
|
<div class="sg-selected-avatar"
|
|
|
|
ng-show="currentMessage.selected"
|
2015-09-09 21:18:00 +02:00
|
|
|
ng-click="mailbox.toggleMessageSelection($event, currentMessage)"><!-- selected avatar --></div>
|
2015-08-25 18:20:46 +02:00
|
|
|
<sg-avatar-image class="md-tile-left"
|
|
|
|
ng-show="!currentMessage.selected"
|
2015-09-09 21:18:00 +02:00
|
|
|
ng-click="mailbox.toggleMessageSelection($event, currentMessage)"
|
2015-08-25 18:20:46 +02:00
|
|
|
sg-email="::currentMessage.from[0].email"
|
2015-09-04 15:09:43 +02:00
|
|
|
size="40"><!-- avatar --></sg-avatar-image>
|
2015-08-25 18:20:46 +02:00
|
|
|
<div class="sg-tile-content">
|
|
|
|
<span class="msg-date"
|
|
|
|
ng-bind-html="currentMessage.relativedate"><!-- date --></span>
|
|
|
|
<div class="sg-md-subhead-multi">{{currentMessage.$shortAddress('from')}}</div>
|
|
|
|
<div class="sg-md-body-multi">{{currentMessage.subject}}</div>
|
|
|
|
</div>
|
|
|
|
<div class="sg-tile-icons">
|
|
|
|
<md-icon ng-show="currentMessage.priority == 'highest' || currentMessage.priority == 'high'">warning</md-icon>
|
|
|
|
<md-icon ng-show="currentMessage.isflagged">star</md-icon>
|
|
|
|
<md-icon ng-show="currentMessage.isanswered">reply</md-icon>
|
|
|
|
<md-icon ng-show="currentMessage.isforwarded">forward</md-icon>
|
|
|
|
<md-icon ng-show="currentMessage.hasattachment">attach_file</md-icon>
|
|
|
|
</div>
|
|
|
|
</md-list-item>
|
2015-07-15 19:44:17 +02:00
|
|
|
</md-list>
|
|
|
|
</md-virtual-repeat-container>
|
2015-08-25 18:20:46 +02:00
|
|
|
<div class="sg-progress-circular-floating"
|
|
|
|
ng-show="mailbox.selectedFolder.$isLoading">
|
|
|
|
<md-progress-circular class="md-accent"
|
|
|
|
md-mode="indeterminate"
|
|
|
|
md-diameter="32"><!-- progress --></md-progress-circular>
|
|
|
|
</div>
|
2015-07-15 19:44:17 +02:00
|
|
|
<md-button class="md-fab md-fab-bottom-right md-accent"
|
|
|
|
label:aria-label="Write a new message"
|
2015-08-02 19:25:38 +02:00
|
|
|
ng-click="mailbox.newMessage($event)">
|
2015-08-03 18:43:21 +02:00
|
|
|
<md-icon>edit</md-icon>
|
2015-07-15 19:44:17 +02:00
|
|
|
</md-button>
|
|
|
|
</md-content>
|
2015-04-29 17:23:21 +02:00
|
|
|
</div>
|
|
|
|
|
2015-09-03 22:10:05 +02:00
|
|
|
<div id="detailView" class="view-detail" layout="column" layout-align="start center"
|
2015-08-26 23:28:03 +02:00
|
|
|
ng-class="{ 'sg-close': !mailbox.selectedFolder.selectedMessage }"
|
2015-08-27 19:37:47 +02:00
|
|
|
ui-view="message">
|
2015-09-03 22:10:05 +02:00
|
|
|
<md-toolbar class="hide-sm"><!-- empty toolbar --></md-toolbar>
|
|
|
|
<md-content class="hide-sm md-flex layout-fill md-hue-1" layout="column">
|
|
|
|
<md-input-container layout-align="center center">
|
|
|
|
<label class="sg-md-title"><var:string label:value="No message selected"/></label>
|
|
|
|
</md-input-container>
|
|
|
|
</md-content>
|
|
|
|
</div>
|
2015-03-19 08:40:46 +01:00
|
|
|
|
2014-12-17 20:58:20 +01:00
|
|
|
</container>
|