Improved observables

This commit is contained in:
djmaze 2020-10-27 11:09:24 +01:00
parent 8d7e25fc7c
commit 7db7d5545b
28 changed files with 236 additions and 234 deletions

View file

@ -7,9 +7,21 @@ const Settings = rl.settings;
class AppUserStore {
constructor() {
this.currentAudio = ko.observable('');
ko.addObservablesTo(this, {
currentAudio: '',
this.focusedState = ko.observable(Focused.None);
focusedState: Focused.None,
projectHash: '',
threadsAllowed: false,
composeInEdit: false,
contactsAutosave: false,
useLocalProxyForExternalImages: false,
contactsIsAllowed: false
});
const isMobile = Settings.app('mobile');
@ -38,16 +50,6 @@ class AppUserStore {
}
});
this.projectHash = ko.observable('');
this.threadsAllowed = ko.observable(false);
this.composeInEdit = ko.observable(false);
this.contactsAutosave = ko.observable(false);
this.useLocalProxyForExternalImages = ko.observable(false);
this.contactsIsAllowed = ko.observable(false);
this.attachmentsActions = ko.observableArray([]);
this.devEmail = '';