mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-30 20:49:20 +03:00
This version uses Rollup instead of WebPack.
Due to that the code is smaller and has changes to prevent Circular Dependencies
This commit is contained in:
parent
5e63ade9dd
commit
ad8fd8879b
49 changed files with 595 additions and 577 deletions
|
|
@ -14,6 +14,10 @@ import MessageStore from 'Stores/User/Message';
|
|||
import { showScreenPopup } from 'Knoin/Knoin';
|
||||
import { AbstractViewLeft } from 'Knoin/AbstractViews';
|
||||
|
||||
import { ComposePopupView } from 'View/Popup/Compose';
|
||||
import { FolderCreatePopupView } from 'View/Popup/FolderCreate';
|
||||
import { ContactsPopupView } from 'View/Popup/Contacts';
|
||||
|
||||
const Settings = rl.settings;
|
||||
|
||||
class FolderListMailBoxUserView extends AbstractViewLeft {
|
||||
|
|
@ -200,12 +204,12 @@ class FolderListMailBoxUserView extends AbstractViewLeft {
|
|||
|
||||
composeClick() {
|
||||
if (Settings.capa(Capa.Composer)) {
|
||||
showScreenPopup(require('View/Popup/Compose'));
|
||||
showScreenPopup(ComposePopupView);
|
||||
}
|
||||
}
|
||||
|
||||
createFolder() {
|
||||
showScreenPopup(require('View/Popup/FolderCreate'));
|
||||
showScreenPopup(FolderCreatePopupView);
|
||||
}
|
||||
|
||||
configureFolders() {
|
||||
|
|
@ -214,7 +218,7 @@ class FolderListMailBoxUserView extends AbstractViewLeft {
|
|||
|
||||
contactsClick() {
|
||||
if (this.allowContacts) {
|
||||
showScreenPopup(require('View/Popup/Contacts'));
|
||||
showScreenPopup(ContactsPopupView);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,6 +44,10 @@ import Remote from 'Remote/User/Fetch';
|
|||
import { command, showScreenPopup, popupVisibility } from 'Knoin/Knoin';
|
||||
import { AbstractViewRight } from 'Knoin/AbstractViews';
|
||||
|
||||
import { FolderClearPopupView } from 'View/Popup/FolderClear';
|
||||
import { ComposePopupView } from 'View/Popup/Compose';
|
||||
import { AdvancedSearchPopupView } from 'View/Popup/AdvancedSearch';
|
||||
|
||||
const
|
||||
Settings = rl.settings,
|
||||
canBeMovedHelper = (self) => self.canBeMoved(),
|
||||
|
|
@ -244,7 +248,7 @@ class MessageListMailBoxUserView extends AbstractViewRight {
|
|||
@command()
|
||||
clearCommand() {
|
||||
if (Settings.capa(Capa.DangerousActions)) {
|
||||
showScreenPopup(require('View/Popup/FolderClear'), [FolderStore.currentFolder()]);
|
||||
showScreenPopup(FolderClearPopupView, [FolderStore.currentFolder()]);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -258,7 +262,7 @@ class MessageListMailBoxUserView extends AbstractViewRight {
|
|||
@command(canBeMovedHelper)
|
||||
multyForwardCommand() {
|
||||
if (Settings.capa(Capa.Composer)) {
|
||||
showScreenPopup(require('View/Popup/Compose'), [
|
||||
showScreenPopup(ComposePopupView, [
|
||||
ComposeType.ForwardAsAttachment,
|
||||
MessageStore.messageListCheckedOrSelected()
|
||||
]);
|
||||
|
|
@ -350,7 +354,7 @@ class MessageListMailBoxUserView extends AbstractViewRight {
|
|||
|
||||
composeClick() {
|
||||
if (Settings.capa(Capa.Composer)) {
|
||||
showScreenPopup(require('View/Popup/Compose'));
|
||||
showScreenPopup(ComposePopupView);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -761,7 +765,7 @@ class MessageListMailBoxUserView extends AbstractViewRight {
|
|||
if (Settings.capa(Capa.Composer)) {
|
||||
// write/compose (open compose popup)
|
||||
shortcuts.add('w,c,new', '', [KeyState.MessageList, KeyState.MessageView], () => {
|
||||
showScreenPopup(require('View/Popup/Compose'));
|
||||
showScreenPopup(ComposePopupView);
|
||||
return false;
|
||||
});
|
||||
}
|
||||
|
|
@ -887,7 +891,7 @@ class MessageListMailBoxUserView extends AbstractViewRight {
|
|||
|
||||
advancedSearchClick() {
|
||||
Settings.capa(Capa.SearchAdv)
|
||||
&& showScreenPopup(require('View/Popup/AdvancedSearch'), [this.mainMessageListSearch()]);
|
||||
&& showScreenPopup(AdvancedSearchPopupView, [this.mainMessageListSearch()]);
|
||||
}
|
||||
|
||||
quotaTooltip() {
|
||||
|
|
|
|||
|
|
@ -41,6 +41,8 @@ import Remote from 'Remote/User/Fetch';
|
|||
import { command, showScreenPopup, createCommand } from 'Knoin/Knoin';
|
||||
import { AbstractViewRight } from 'Knoin/AbstractViews';
|
||||
|
||||
import { ComposePopupView } from 'View/Popup/Compose';
|
||||
|
||||
const Settings = rl.settings;
|
||||
|
||||
function isTransparent(color) {
|
||||
|
|
@ -342,7 +344,7 @@ class MessageViewMailBoxUserView extends AbstractViewRight {
|
|||
* @returns {void}
|
||||
*/
|
||||
replyOrforward(sType) {
|
||||
Settings.capa(Capa.Composer) && showScreenPopup(require('View/Popup/Compose'), [sType, MessageStore.message()]);
|
||||
Settings.capa(Capa.Composer) && showScreenPopup(ComposePopupView, [sType, MessageStore.message()]);
|
||||
}
|
||||
|
||||
checkHeaderHeight() {
|
||||
|
|
@ -426,7 +428,7 @@ class MessageViewMailBoxUserView extends AbstractViewRight {
|
|||
3 !== event.which &&
|
||||
mailToHelper(
|
||||
el.href,
|
||||
Settings.capa(Capa.Composer) ? require('View/Popup/Compose') : null
|
||||
Settings.capa(Capa.Composer) ? ComposePopupView : null
|
||||
)
|
||||
);
|
||||
}
|
||||
|
|
@ -684,13 +686,13 @@ class MessageViewMailBoxUserView extends AbstractViewRight {
|
|||
|
||||
composeClick() {
|
||||
if (Settings.capa(Capa.Composer)) {
|
||||
showScreenPopup(require('View/Popup/Compose'));
|
||||
showScreenPopup(ComposePopupView);
|
||||
}
|
||||
}
|
||||
|
||||
editMessage() {
|
||||
if (Settings.capa(Capa.Composer) && MessageStore.message()) {
|
||||
showScreenPopup(require('View/Popup/Compose'), [ComposeType.Draft, MessageStore.message()]);
|
||||
showScreenPopup(ComposePopupView, [ComposeType.Draft, MessageStore.message()]);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue