Interface redesign (attachments, new preview pane layout)

This commit is contained in:
RainLoop Team 2015-01-04 23:30:07 +04:00
parent 6755a0ce51
commit e3e7c1d963
64 changed files with 1286 additions and 1009 deletions

View file

@ -882,7 +882,6 @@ class Utils
'p7c' => 'application/pkcs7-mime',
'p7m' => 'application/pkcs7-mime',
'p7s' => 'application/pkcs7-signature',
'ttf' => 'application/x-ttf',
'torrent' => 'application/x-bittorrent',
// scripts
@ -963,7 +962,6 @@ class Utils
'flv' => 'video/x-flv',
'qt' => 'video/quicktime',
'mov' => 'video/quicktime',
'wmv' => 'video/windows-media',
'avi' => 'video/x-msvideo',
'mpg' => 'video/mpeg',
'mpeg' => 'video/mpeg',
@ -976,6 +974,7 @@ class Utils
'h263' => 'video/h263',
'h264' => 'video/h264',
'jpgv' => 'video/jpgv',
'mp4' => 'video/mp4',
'mp4v' => 'video/mp4',
'mpg4' => 'video/mp4',
'ogv' => 'video/ogg',

View file

@ -2067,7 +2067,7 @@ class Actions
}
return $this->TrueResponse(__FUNCTION__);
return $this->DefaultResponse(__FUNCTION__, $this->FiltersProvider()->Save($aFilters));
// return $this->DefaultResponse(__FUNCTION__, $this->FiltersProvider()->Save($aFilters));
}
/**
@ -2539,6 +2539,9 @@ class Actions
case \RainLoop\Enumerations\Capa::GRAVATAR:
$this->setConfigFromParams($oConfig, $sParamName, 'labs', 'allow_gravatar', 'bool');
break;
case \RainLoop\Enumerations\Capa::ATTACHMENT_THUMBNAILS:
$this->setConfigFromParams($oConfig, $sParamName, 'interface', 'show_attachment_thumbnail', 'bool');
break;
case \RainLoop\Enumerations\Capa::THEMES:
$this->setConfigFromParams($oConfig, $sParamName, 'webmail', 'allow_themes', 'bool');
break;
@ -2636,6 +2639,7 @@ class Actions
$this->setCapaFromParams($oConfig, 'CapaGravatar', \RainLoop\Enumerations\Capa::GRAVATAR);
$this->setCapaFromParams($oConfig, 'CapaThemes', \RainLoop\Enumerations\Capa::THEMES);
$this->setCapaFromParams($oConfig, 'CapaUserBackground', \RainLoop\Enumerations\Capa::USER_BACKGROUND);
$this->setCapaFromParams($oConfig, 'CapaAttachmentThumbnails', \RainLoop\Enumerations\Capa::ATTACHMENT_THUMBNAILS);
$this->setConfigFromParams($oConfig, 'DetermineUserLanguage', 'login', 'determine_user_language', 'bool');
$this->setConfigFromParams($oConfig, 'DetermineUserDomain', 'login', 'determine_user_domain', 'bool');
@ -3538,6 +3542,19 @@ class Actions
\is_file(APP_INDEX_ROOT_PATH.'rainloop/v/'.$sNewVersion.'/index.php'))
{
$bResult = \copy($sTmpFolder.'/index.php', APP_INDEX_ROOT_PATH.'index.php');
if ($bResult)
{
if (\MailSo\Base\Utils::FunctionExistsAndEnabled('opcache_invalidate'))
{
@\opcache_invalidate(APP_INDEX_ROOT_PATH.'index.php', true);
}
if (\MailSo\Base\Utils::FunctionExistsAndEnabled('apc_delete_file'))
{
@\apc_delete_file(APP_INDEX_ROOT_PATH.'index.php');
}
}
}
else
{
@ -3577,6 +3594,7 @@ class Actions
$aDirs = @\array_map('basename', @\array_filter(@\glob($sVPath.'*'), 'is_dir'));
$this->Logger()->Write('Versions GC: Count:'.(\is_array($aDirs) ? \count($aDirs) : 0));
if (\is_array($aDirs) && 5 < \count($aDirs))
{
\uasort($aDirs, 'version_compare');
@ -6945,6 +6963,11 @@ class Actions
$aResult[] = \RainLoop\Enumerations\Capa::GRAVATAR;
}
if ($oConfig->Get('interface', 'show_attachment_thumbnail', true))
{
$aResult[] = \RainLoop\Enumerations\Capa::ATTACHMENT_THUMBNAILS;
}
if ($oConfig->Get('labs', 'allow_prefetch', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::PREFETCH;
@ -8017,6 +8040,7 @@ class Actions
$bHook = true;
$sClassName = \get_class($mResponse);
$bHasSimpleJsonFunc = \method_exists($mResponse, 'ToSimpleJSON');
$bThumb = $this->GetCapa(false, \RainLoop\Enumerations\Capa::ATTACHMENT_THUMBNAILS);
if ($bHasSimpleJsonFunc)
{
@ -8278,7 +8302,7 @@ class Actions
'CID' => $mResponse->Cid(),
'ContentLocation' => $mResponse->ContentLocation(),
'IsInline' => $mResponse->IsInline(),
'IsThumbnail' => !!$this->Config()->Get('interface', 'show_attachment_thumbnail', true),
'IsThumbnail' => $bThumb,
'IsLinked' => ($mFoundedCIDs && \in_array(\trim(\trim($mResponse->Cid()), '<>'), $mFoundedCIDs)) ||
($mFoundedContentLocationUrls && \in_array(\trim($mResponse->ContentLocation()), $mFoundedContentLocationUrls))
));
@ -8300,8 +8324,6 @@ class Actions
'FileName' => $mResult['FileName'],
'Framed' => $mResult['Framed']
));
$this->Logger()->WriteDump($mResult);
}
else if ('MailSo\Mail\Folder' === $sClassName)
{

View file

@ -151,7 +151,7 @@ abstract class AbstractConfig
if (\is_int($iMTime) && 0 < $iMTime)
{
$sKey = $this->cacheKey();
\apc_store($sKey.'time', $iMTime);
\apc_store($sKey.'data', $this->aData);
@ -161,7 +161,7 @@ abstract class AbstractConfig
return false;
}
/**
* @return bool
*/
@ -192,7 +192,7 @@ abstract class AbstractConfig
return true;
}
$aData = @\parse_ini_file($this->sFile, true);
$aData = \RainLoop\Utils::CustomParseIniFile($this->sFile, true);
if (\is_array($aData) && 0 < count($aData))
{
foreach ($aData as $sSectionKey => $aSectionValue)

View file

@ -12,6 +12,7 @@ class Capa
const THEMES = 'THEMES';
const USER_BACKGROUND = 'USER_BACKGROUND';
const SIEVE = 'SIEVE';
const ATTACHMENT_THUMBNAILS = 'ATTACHMENT_THUMBNAILS';
const ADDITIONAL_ACCOUNTS = 'ADDITIONAL_ACCOUNTS';
const ADDITIONAL_IDENTITIES = 'ADDITIONAL_IDENTITIES';
}

View file

@ -166,7 +166,7 @@ class DefaultDomain implements \RainLoop\Providers\Domain\DomainAdminInterface
if (\file_exists($this->sDomainPath.'/'.$sRealFileName.'.ini') &&
(!$bCheckDisabled || 0 === \strlen($sDisabled) || false === \strpos(','.$sDisabled.',', ','.\MailSo\Base\Utils::IdnToAscii($sName, true).',')))
{
$aDomain = @\parse_ini_file($this->sDomainPath.'/'.$sRealFileName.'.ini');
$aDomain = \RainLoop\Utils::CustomParseIniFile($this->sDomainPath.'/'.$sRealFileName.'.ini');
// fix misspellings (#119)
if (\is_array($aDomain))
{

View file

@ -149,16 +149,16 @@ class Utils
}
/**
* @param string $FileName
* @param string $sFileName
* @param array $aResultLang
*
* @return void
*/
public static function ReadAndAddLang($FileName, &$aResultLang)
public static function ReadAndAddLang($sFileName, &$aResultLang)
{
if (\file_exists($FileName))
if (\file_exists($sFileName))
{
$aLang = @\parse_ini_file($FileName, true);
$aLang = \RainLoop\Utils::CustomParseIniFile($sFileName, true);
if (\is_array($aLang))
{
foreach ($aLang as $sKey => $mValue)
@ -307,6 +307,23 @@ class Utils
@\setcookie($sName, '', \time() - 3600 * 24 * 30, '/');
}
/**
* @param string $sFileName
* @param bool $bProcessSections = false
*
* @return array
*/
public static function CustomParseIniFile($sFileName, $bProcessSections = false)
{
if (\MailSo\Base\Utils::FunctionExistsAndEnabled('parse_ini_file'))
{
return @\parse_ini_file($sFileName, !!$bProcessSections);
}
$sData = @\file_get_contents($sFileName);
return \is_string($sData) ? @\parse_ini_string($sData, !!$bProcessSections) : null;
}
public static function CustomBaseConvert($sNumberInput, $sFromBaseInput = '0123456789', $sToBaseInput = '0123456789')
{
if ($sFromBaseInput === $sToBaseInput)

View file

@ -76,6 +76,14 @@
</div>
<div class="control-group">
<div class="controls">
<div data-bind="component: {
name: 'Checkbox',
params: {
label: 'Show thumbnails (attachments)',
value: capaAttachmentThumbnails,
inline: false
}
}"></div>
<div data-bind="component: {
name: 'Checkbox',
params: {

View file

@ -1,8 +1,18 @@
<div class="b-attacment">
<label data-bind="click: function () { enabled(!enabled()); }">
<i class="checkboxAttachment" data-bind="css: enabled() ? 'checkboxMessage icon-checkbox-checked' : 'checkboxMessage icon-checkbox-unchecked'"></i>
&nbsp;&nbsp;
<span class="name" data-bind="text: fileName"></span>
(<span class="size" data-bind="text: friendlySize"></span>)
</label>
</div>
<li class="attachmentItem clearfix" data-tooltip-placement="bottom" data-bind="attr: { 'title': title }, css: {'waiting': waiting, 'error': '' !== error()}">
<div class="attachmentIconParent pull-left">
<div class="iconMain">
<i class="attachmentIcon attachmentMainIcon" data-bind="css: iconClass(), visible: !uploading() || 0 === progress()"></i>
</div>
<div class="iconProgress" data-bind="attr: { 'style': progressStyle }, visible: uploading"></div>
<div class="iconBG" data-bind="text: progressText, visible: uploading"></div>
</div>
<div class="attachmentNameParent">
<button type="button" class="close pull-right" style="margin-top:-4px;" data-bind="click: cancel">×</button>
<div style="white-space: nowrap; text-overflow: ellipsis; overflow: hidden;">
<span class="attachmentName" data-bind="text: fileName"></span>&nbsp;
</div>
<div>
<span class="attachmentSize" data-bind="text: friendlySize"></span>&nbsp;
</div>
</div>
</li>

View file

@ -1,13 +0,0 @@
<div class="b-attacment-in-process" data-bind="css: {'error': '' !== error(), 'uploading': uploading, 'waiting': waiting }, in18nInit: true">
<a class="close" data-bind="click: cancel">&times;</a>
<span class="uploading"><i class="icon-spinner animated"></i></span>
<span class="namedStr">
<span class="name" data-bind="text: fileName"></span>
&nbsp;&nbsp;
(<span class="size" data-bind="text: friendlySize"></span>)
<span class="upload-progress" data-bind="text: progress"></span>
</span>
<div class="error">
<span data-bind="text: error"></span>
</div>
</div>

View file

@ -1,10 +1,10 @@
<!-- ko template: { name: 'PhotoSwipe' } --><!-- /ko -->
<div id="rl-sub-right">
<div class="messageView" data-bind="css: {'message-selected': isMessageSelected, 'message-focused': message.focused}">
<div class="toolbar g-ui-user-select-none">
<div class="toolbar top-toolbar g-ui-user-select-none" data-bind="visible: !usePreviewPane()">
<nobr>
<div class="messageButtons btn-toolbar">
<div class="btn-group" data-tooltip-placement="bottom" data-bind="visible: !usePreviewPane(), tooltip: 'MESSAGE/BUTTON_CLOSE'">
<div class="btn-group" data-tooltip-placement="bottom" data-bind="tooltip: 'MESSAGE/BUTTON_CLOSE'">
<a class="btn btn-dark-disabled-border buttonClose" data-bind="command: closeMessage">
<i class="icon-remove"></i>
</a>
@ -42,7 +42,7 @@
</div>
</nobr>
</div>
<div class="b-content thm-message-view-background-color">
<div class="b-content b-message-view-wrapper thm-message-view-background-color">
<div>
<div class="b-message-view-checked-helper" data-bind="visible: !message() && '' === messageError() && hasCheckedMessages()">
<span data-bind="text: printableCheckedMessageCount()"></span>
@ -57,124 +57,131 @@
<div data-bind="visible: message">
<div class="btn-group colored-toggle pull-right messageItemDropdown">
<a class="btn btn-dark-disabled-border buttonReply" data-tooltip-placement="bottom"
data-bind="command: replyCommand, tooltip: 'MESSAGE/BUTTON_REPLY'">
<i class="icon-reply"></i>
</a>
<!--
<a class="btn btn-dark-disabled-border buttonReplyAll" data-tooltip-placement="bottom"
data-bind="command: replyAllCommand, tooltip: 'MESSAGE/BUTTON_REPLY_ALL'">
<i class="icon-reply-all"></i>
</a>
<a class="btn btn-dark-disabled-border buttonForward" data-tooltip-placement="bottom"
data-bind="command: forwardCommand, tooltip: 'MESSAGE/BUTTON_FORWARD'">
<i class="icon-reply-all"></i>
</a>
-->
<a id="more-view-dropdown-id" class="btn btn-dark-disabled-border dropdown-toggle buttonMore"
href="#" tabindex="-1" data-toggle="dropdown" data-tooltip-placement="bottom"
data-bind="command: messageVisibilityCommand, tooltip: 'MESSAGE/BUTTON_MORE'">
<span class="caret"></span>
</a>
<ul class="dropdown-menu g-ui-menu" role="menu" aria-labelledby="more-view-dropdown-id">
<div class="message-fixed-button-toolbar clearfix">
<div class="btn-group colored-toggle pull-right">
<a class="btn btn-dark-disabled-border buttonReply" data-tooltip-placement="bottom"
data-bind="command: replyCommand, tooltip: 'MESSAGE/BUTTON_REPLY'">
<i class="icon-reply"></i>
</a>
<!--
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: replyCommand">
<i class="icon-reply"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_REPLY"></span>
</a>
</li>
<a class="btn btn-dark-disabled-border buttonReplyAll" data-tooltip-placement="bottom"
data-bind="command: replyAllCommand, tooltip: 'MESSAGE/BUTTON_REPLY_ALL'">
<i class="icon-reply-all"></i>
</a>
<a class="btn btn-dark-disabled-border buttonForward" data-tooltip-placement="bottom"
data-bind="command: forwardCommand, tooltip: 'MESSAGE/BUTTON_FORWARD'">
<i class="icon-reply-all"></i>
</a>
-->
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: replyAllCommand">
<i class="icon-reply-all"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_REPLY_ALL"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: forwardCommand">
<i class="icon-forward"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_FORWARD"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: editAsNewCommand">
<i class="icon-pencil"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_EDIT_AS_NEW"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: forwardAsAttachmentCommand">
<i class="icon-forward"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_FORWARD_AS_ATTACHMENT"></span>
</a>
</li>
<li class="divider" role="presentation" data-bind="visible: !isDraftFolder()"></li>
<li class="e-item" role="presentation" data-bind="visible: usePreviewPane() && !isDraftFolder() && !isArchiveFolder() && !isArchiveDisabled()">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="command: archiveCommand">
<i class="icon-archive"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_ARCHIVE"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: usePreviewPane() && !isDraftFolder() && !isSentFolder() && !isSpamFolder() && !isSpamDisabled()">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="command: spamCommand">
<i class="icon-angry-smiley"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_SPAM"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: usePreviewPane() && !isDraftFolder() && !isSentFolder() && isSpamFolder() && !isSpamDisabled()">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="command: notSpamCommand">
<i class="icon-happy-smiley"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_NOT_SPAM"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: usePreviewPane()">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="command: deleteCommand">
<i class="icon-trash"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_DELETE"></span>
</a>
</li>
<li class="divider" role="presentation" data-bind="visible: usePreviewPane()"></li>
<li class="e-item" role="presentation">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="click: function () { if (message()) { message().printMessage(); }} ">
<i class="icon-print"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/MENU_PRINT"></span>
</a>
</li>
<li class="e-item" role="presentation">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="click: function () { if (message()) { message().viewPopupMessage(); }}">
<i class="icon-popup"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_IN_NEW_WINDOW"></span>
</a>
</li>
<li class="divider" role="presentation"></li>
<li class="e-item" role="presentation">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="link: viewViewLink()">
<i class="icon-file-code"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/MENU_VIEW_ORIGINAL"></span>
</a>
</li>
<li class="e-item" role="presentation">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="link: viewDownloadLink()">
<i class="icon-download"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/MENU_DOWNLOAD_ORIGINAL"></span>
</a>
</li>
</ul>
<a id="more-view-dropdown-id" class="btn btn-dark-disabled-border dropdown-toggle buttonMore"
href="#" tabindex="-1" data-toggle="dropdown" data-tooltip-placement="bottom"
data-bind="command: messageVisibilityCommand, tooltip: 'MESSAGE/BUTTON_MORE'">
<span class="caret"></span>
</a>
<ul class="dropdown-menu g-ui-menu" role="menu" aria-labelledby="more-view-dropdown-id">
<!--
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: replyCommand">
<i class="icon-reply"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_REPLY"></span>
</a>
</li>
-->
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: replyAllCommand">
<i class="icon-reply-all"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_REPLY_ALL"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: forwardCommand">
<i class="icon-forward"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_FORWARD"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: editAsNewCommand">
<i class="icon-pencil"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_EDIT_AS_NEW"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: !isDraftFolder()">
<a class="e-link menuitem" href="#" tabindex="-1" data-bind="command: forwardAsAttachmentCommand">
<i class="icon-forward"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_FORWARD_AS_ATTACHMENT"></span>
</a>
</li>
<li class="divider" role="presentation" data-bind="visible: !isDraftFolder()"></li>
<li class="e-item" role="presentation" data-bind="visible: usePreviewPane() && !isDraftFolder() && !isArchiveFolder() && !isArchiveDisabled()">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="command: archiveCommand">
<i class="icon-archive"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_ARCHIVE"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: usePreviewPane() && !isDraftFolder() && !isSentFolder() && !isSpamFolder() && !isSpamDisabled()">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="command: spamCommand">
<i class="icon-angry-smiley"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_SPAM"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: usePreviewPane() && !isDraftFolder() && !isSentFolder() && isSpamFolder() && !isSpamDisabled()">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="command: notSpamCommand">
<i class="icon-happy-smiley"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_NOT_SPAM"></span>
</a>
</li>
<li class="e-item" role="presentation" data-bind="visible: usePreviewPane()">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="command: deleteCommand">
<i class="icon-trash"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_DELETE"></span>
</a>
</li>
<li class="divider" role="presentation" data-bind="visible: usePreviewPane()"></li>
<li class="e-item" role="presentation">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="click: function () { if (message()) { message().printMessage(); }} ">
<i class="icon-print"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/MENU_PRINT"></span>
</a>
</li>
<li class="e-item" role="presentation">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="click: function () { if (message()) { message().viewPopupMessage(); }}">
<i class="icon-popup"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/BUTTON_IN_NEW_WINDOW"></span>
</a>
</li>
<li class="divider" role="presentation"></li>
<li class="e-item" role="presentation">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="link: viewViewLink()">
<i class="icon-file-code"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/MENU_VIEW_ORIGINAL"></span>
</a>
</li>
<li class="e-item" role="presentation">
<a target="_blank" class="e-link menuitem" href="#" tabindex="-1" data-bind="link: viewDownloadLink()">
<i class="icon-download"></i>
&nbsp;&nbsp;
<span class="i18n" data-i18n-text="MESSAGE/MENU_DOWNLOAD_ORIGINAL"></span>
</a>
</li>
</ul>
</div>
<div class="btn-group pull-right" data-bind="visible: isDraftFolder()" style="margin-right: 5px">
<a class="btn btn-success buttonEdit" data-bind="command: messageEditCommand">
<i class="icon-pencil icon-white"></i>
</a>
</div>
</div>
<div class="messageItem" data-bind="css: viewLineAsCcc(), nano: true">
@ -295,7 +302,8 @@
</div>
<div class="attachmentsPlace" data-bind="visible: message() && message().hasVisibleAttachments()">
<ul class="attachmentList" data-bind="foreach: message() ? message().attachments() : []">
<li class="attachmentItem clearfix" draggable="true" data-bind="visible: !isLinked, title: fileName, event: { 'dragstart': eventDragStart }">
<li class="attachmentItem clearfix" draggable="true" data-tooltip-placement="bottom"
data-bind="visible: !isLinked, event: { 'dragstart': eventDragStart }, attr: { 'title': fileName }">
<div class="attachmentIconParent pull-left" data-bind="css: { 'hasPreview': hasPreview() }">
<div class="hidePreview">
<div class="iconMain">
@ -303,7 +311,7 @@
</div>
</div>
<div class="showPreview">
<a data-bind="css: {'attachmentImagePreview': isImage()}, attr: {'href': linkPreviewMain(), title: fileName, 'data-index': $index}">
<a data-bind="css: {'attachmentImagePreview': isImage()}, attr: {'href': linkPreviewMain(), 'data-index': $index}" target="_blank">
<div class="iconMain">
<i class="attachmentIcon attachmentMainIcon" data-bind="css: iconClass()"></i>
</div>

View file

@ -26,7 +26,7 @@
<div>
<div class="b-header g-ui-user-select-none">
<div class="g-ui-table">
<div class="e-row">
<div class="e-row" style="height: 40px;">
<div class="e-cell e-label">
<label class="control-label">
<span class="i18n" data-i18n-text="COMPOSE/TITLE_FROM"></span>
@ -50,7 +50,7 @@
</ul>
<!-- /ko -->
</div>
<div class="btn-group dropdown colored-toggle pull-right">
<div class="btn-group dropdown colored-toggle pull-right" style="margin-right: 4px;">
<a class="btn dropdown-toggle buttonMore" data-toggle="dropdown">
<i class="icon-list"></i>
</a>
@ -139,18 +139,33 @@
<div class="e-row">
<div class="e-cell e-label"></div>
<div class="e-cell e-value">
<div class="b-appachments pull-left" data-bind="visible: 0 < attachments().length">
<div data-bind="template: { name: 'ComposeAttachment', foreach: attachmentsInReady }"></div>
<div data-bind="template: { name: 'ComposeAttachmentInProcess', foreach: attachmentsInProcess }"></div>
<span class="help-block error-desc" data-bind="visible: attachmentsInProcessError">
<span class="i18n" data-i18n-text="COMPOSE/ATTACHMENTS_UPLOAD_ERROR_DESC"></span>
</span>
</div>
<div>
<div class="b-attachment-place" data-bind="visible: addAttachmentEnabled() && dragAndDropEnabled() && dragAndDropVisible(), initDom: composeUploaderDropPlace, css: {'dragAndDropOver': dragAndDropOver}">
<span class="i18n" data-i18n-text="COMPOSE/ATTACH_DROP_FILES_DESC"></span>
</div>
<div class="pull-right">
<div class="pull-left">
<div class="btn-group" data-toggle="buttons-radio">
<button type="button" class="btn" data-bind="click: function () { attachmentsPlace(false); },
css: { 'active': !attachmentsPlace() }">
<i class="icon-file-text"></i>
</button>
<button type="button" class="btn" data-bind="click: function () { attachmentsPlace(true); },
css: { 'btn-danger': 0 < attachmentsInErrorCount(), 'active': attachmentsPlace() }">
<span data-bind="visible: 0 < attachmentsCount()">
<b data-bind="text: attachmentsCount"></b>
&nbsp;&nbsp;
</span>
<i data-bind="css: { 'icon-attachment': 0 === attachmentsInProcessCount(), 'icon-spinner animated': 0 < attachmentsInProcessCount(), 'icon-white': 0 < attachmentsInErrorCount() }"></i>
</button>
</div>
<span class="help-block error-desc" data-bind="visible: attachmentsInProcessError">
<span class="i18n" data-i18n-text="COMPOSE/ATTACHMENTS_UPLOAD_ERROR_DESC"></span>
</span>
<span class="help-block error-desc" data-bind="visible: !attachmentsInProcessError() && attachmentsInErrorError()">
<span class="i18n" data-i18n-text="COMPOSE/ATTACHMENTS_ERROR_DESC"></span>
</span>
</div>
<div class="pull-right" style="margin-right: 4px;">
<div class="btn-group pull-right">
<a class="btn" data-tooltip-placement="top" data-bind="visible: addAttachmentEnabled(), initDom: composeUploaderButton, tooltip: 'COMPOSE/ATTACH_FILES'">
<i class="icon-attachment"></i>
@ -169,8 +184,19 @@
</div>
</div>
<div class="attachmentAreaParent b-content" style="height: 200px; min-height: 200px" data-bind="nano: true, visible: attachmentsPlace, initResizeTrigger: [resizer(), 200, 47]">
<div class="content g-scrollbox">
<div class="content-wrapper">
<ul class="attachmentList" data-bind="template: { name: 'ComposeAttachment', foreach: attachments }"></ul>
<div class="no-attachments-desc" data-bind="visible: 0 === attachments().length">
<span class="i18n" data-i18n-text="COMPOSE/NO_ATTACHMENTS_HERE_DESC"></span>
</div>
</div>
</div>
</div>
<div class="textAreaParent" style="height: 200px; min-height: 200px"
data-bind="initDom: composeEditorArea, initResizeTrigger: [resizer(), 200, 30]"></div>
data-bind="visible: !attachmentsPlace(), initDom: composeEditorArea, initResizeTrigger: [resizer(), 200, 30]"></div>
</div>
</div>
</div>

View file

@ -38,6 +38,23 @@
}"></div>
</div>
</div>
<div class="control-group">
<label class="control-label" style="padding-top: 0;">
<span class="i18n" data-i18n-text="SETTINGS_GENERAL/LABEL_LAYOUT"></span>
</label>
<div class="controls">
<div data-bind="component: {
name: 'Select',
params: {
options: layoutTypes,
value: layout,
trigger: layoutTrigger,
optionsText: 'name',
optionsValue: 'id'
}
}"></div>
</div>
</div>
</div>
<div class="form-horizontal">
<div class="legend">
@ -74,13 +91,6 @@
value: useCheckboxesInList
}
}"></div>
<div data-bind="component: {
name: 'Checkbox',
params: {
label: 'SETTINGS_GENERAL/LABEL_USE_PREVIEW_PANE',
value: usePreviewPaneCheckbox
}
}"></div>
<div data-bind="visible: threading, component: {
name: 'Checkbox',
params: {

View file

@ -1,11 +1,9 @@
<div class="b-system-drop-down g-ui-user-select-none">
<div class="b-toolbar">
<div class="btn-toolbar">
<div class="accountPlace" data-bind="text: emailTitle()"></div>
<div class="btn-group pull-right dropdown colored-toggle" data-bind="registrateBootstrapDropdown: true, openDropdownTrigger: accountMenuDropdownTrigger">
<a id="top-system-dropdown-id" href="#" tabindex="-1" class="btn btn-ellipsis btn-block dropdown-toggle system-dropdown"
data-toggle="dropdown" data-tooltip-placement="left" data-tooltip-i18n="off"
data-tooltip-class="tooltip-big" data-bind="tooltip: emailTitle">
<a id="top-system-dropdown-id" href="#" tabindex="-1" class="btn btn-ellipsis btn-block dropdown-toggle system-dropdown" data-toggle="dropdown">
<i data-bind="css: {'icon-user': !loading(), 'icon-spinner animated': loading()}"></i>
&nbsp;&nbsp;
<span class="caret"></span>