Small code cleanups and fix translations

This commit is contained in:
djmaze 2021-01-27 00:26:31 +01:00
parent b31bf3d7f5
commit 7ccc44616d
54 changed files with 288 additions and 426 deletions

View file

@ -11,7 +11,7 @@ import { AbstractViewRight } from 'Knoin/AbstractViews';
import { KeyboardShortcutsHelpPopupView } from 'View/Popup/KeyboardShortcutsHelp';
import { AccountPopupView } from 'View/Popup/Account';
const Settings = rl.settings;
import { Settings } from 'Common/Globals';
export class AbstractSystemDropDownUserView extends AbstractViewRight {
constructor(name) {

View file

@ -19,12 +19,12 @@ import Remote from 'Remote/User/Fetch';
import { command, showScreenPopup } from 'Knoin/Knoin';
import { AbstractViewCenter } from 'Knoin/AbstractViews';
import { Settings } from 'Common/Globals';
import { rootAdmin } from 'Common/Links';
import { LanguagesPopupView } from 'View/Popup/Languages';
const Settings = rl.settings,
const
LoginSignMeType = {
DefaultOff: 0,
DefaultOn: 1,

View file

@ -2,7 +2,7 @@ import ko from 'ko';
import { Capa, KeyState } from 'Common/Enums';
import { Focused, Layout } from 'Common/EnumsUser';
import { leftPanelDisabled, moveAction } from 'Common/Globals';
import { leftPanelDisabled, moveAction, Settings } from 'Common/Globals';
import { mailBox, settings } from 'Common/Links';
import { setFolderHash } from 'Common/Cache';
@ -18,8 +18,6 @@ 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 {
constructor() {
super('User/MailBox/FolderList', 'MailFolderList');

View file

@ -16,7 +16,7 @@ import {
import { UNUSED_OPTION_VALUE } from 'Common/Consts';
import { leftPanelDisabled, moveAction } from 'Common/Globals';
import { doc, leftPanelDisabled, moveAction, Settings } from 'Common/Globals';
import { computedPaginatorHelper } from 'Common/UtilsUser';
import { File } from 'Common/File';
@ -49,7 +49,6 @@ import { ComposePopupView } from 'View/Popup/Compose';
import { AdvancedSearchPopupView } from 'View/Popup/AdvancedSearch';
const
Settings = rl.settings,
canBeMovedHelper = (self) => self.canBeMoved(),
ifvisible = window.ifvisible;
@ -456,7 +455,7 @@ class MessageListMailBoxUserView extends AbstractViewRight {
}
getDragData(event) {
const item = ko.dataFor(document.elementFromPoint(event.clientX, event.clientY));
const item = ko.dataFor(doc.elementFromPoint(event.clientX, event.clientY));
item && item.checked && item.checked(true);
const uids = MessageStore.messageListCheckedOrSelectedUidsWithSubMails();
item && !uids.includes(item.uid) && uids.push(item.uid);

View file

@ -16,7 +16,7 @@ import {
MessageSetAction
} from 'Common/EnumsUser';
import { $htmlCL, leftPanelDisabled, keyScopeReal, moveAction } from 'Common/Globals';
import { $htmlCL, leftPanelDisabled, keyScopeReal, moveAction, Settings } from 'Common/Globals';
import { inFocus } from 'Common/Utils';
import { mailToHelper } from 'Common/UtilsUser';
@ -43,8 +43,6 @@ import { AbstractViewRight } from 'Knoin/AbstractViews';
import { ComposePopupView } from 'View/Popup/Compose';
const Settings = rl.settings;
function isTransparent(color) {
return 'rgba(0, 0, 0, 0)' === color || 'transparent' === color;
}