mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-03 22:47:03 +03:00
Move popupVisibility to knoin
This commit is contained in:
parent
3374a2d2d3
commit
b0942a7ff7
3 changed files with 12 additions and 13 deletions
|
|
@ -1,6 +1,6 @@
|
|||
import ko from 'ko';
|
||||
|
||||
import { $htmlCL, VIEW_MODELS, popupVisibilityNames } from 'Common/Globals';
|
||||
import { $htmlCL, VIEW_MODELS } from 'Common/Globals';
|
||||
|
||||
//import { bMobileDevice } from 'Common/Globals';
|
||||
|
||||
|
|
@ -8,7 +8,15 @@ let currentScreen = null,
|
|||
defaultScreenName = '';
|
||||
|
||||
const SCREENS = {}, $ = jQuery,
|
||||
isNonEmptyArray = values => Array.isArray(values) && values.length;
|
||||
isNonEmptyArray = values => Array.isArray(values) && values.length,
|
||||
|
||||
popupVisibilityNames = ko.observableArray([]);
|
||||
|
||||
export const popupVisibility = ko.computed(() => 0 < popupVisibilityNames().length);
|
||||
|
||||
popupVisibility.subscribe((bValue) => {
|
||||
$htmlCL.toggle('rl-modal', bValue);
|
||||
});
|
||||
|
||||
export const ViewType = {
|
||||
Popup: 'Popups',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue