Skip to content

TagSpaces is an offline, open source, document manager with tagging support

fix js styling

uggrock77b20605109e
diff --git a/data/ext/perspectiveGrid/extension.js b/data/ext/perspectiveGrid/extension.js
index 256df147a..f48b825a7 100644
--- a/data/ext/perspectiveGrid/extension.js
+++ b/data/ext/perspectiveGrid/extension.js
@@ -30,7 +30,7 @@ define(function(require, exports, module) {
UI = new extUI.ExtUI(extensionID);
UI.buildUI(toolbarTemplate);
platformTuning();
- if(isCordova) {
+ if (isCordova) {
TSCORE.reLayout();
}
$('#' + extensionID + 'Container [data-i18n]').i18n();
diff --git a/data/ext/perspectiveList/extension.js b/data/ext/perspectiveList/extension.js
index 98e17cd40..a969c6162 100644
--- a/data/ext/perspectiveList/extension.js
+++ b/data/ext/perspectiveList/extension.js
@@ -67,7 +67,7 @@ define(function(require, exports, module) {
$('#' + extensionID + 'Container').find("th:contains('File Name')").text(translation);
}
- if(isCordova) {
+ if (isCordova) {
TSCORE.reLayout();
}
diff --git a/data/ext/viewerImage/viewer.js b/data/ext/viewerImage/viewer.js
index 6679eab7f..c983d088f 100644
--- a/data/ext/viewerImage/viewer.js
+++ b/data/ext/viewerImage/viewer.js
@@ -154,7 +154,7 @@ $(document).ready(function() {
// Init internationalization
$.i18n.init({
- ns: { namespaces: [ 'ns.viewerImage' ] },
+ ns: {namespaces: ['ns.viewerImage']},
debug: true,
fallbackLng: 'en_US'
}, function() {
diff --git a/data/js/core.api.js b/data/js/core.api.js
index d9ffead7e..5d5d13bc3 100644
--- a/data/js/core.api.js
+++ b/data/js/core.api.js
@@ -291,6 +291,7 @@ define(function(require, exports, module) {
var twoColumn = fullWidth >= 660 && fullWidth < 1024;
showPerspectiveMenu();
+ tsCoreUI.hideAllDropDownMenus();
if (isFullWidth) {
oneColumn = true;
@@ -328,13 +329,31 @@ define(function(require, exports, module) {
}
}
- if(shouldOpenCol1) {
+ if (shouldOpenCol1) {
$("#openLeftPanel").hide();
+ $("#closeLeftPanel").show();
+ $(".col1").show();
+ } else {
+ $("#closeLeftPanel").hide();
+ $("#openLeftPanel").show();
+ $(".col1").hide();
+ }
+
+ if (shouldOpenCol2) {
+// $("#openLeftPanel").hide();
+ $(".col2").show();
+ } else {
+ $(".col2").hide();
}
- shouldOpenCol1 ? $(".col1").show() : $(".col1").hide();
- shouldOpenCol2 ? $(".col2").show() : $(".col2").hide();
- shouldOpenCol3 ? $(".col3").show() : $(".col3").hide();
+ if (shouldOpenCol3) {
+// $("#openLeftPanel").hide();
+ $(".col3").show();
+ hidePerspectiveMenu();
+ } else {
+ $(".col3").hide();
+ showPerspectiveMenu();
+ }
}
function hidePerspectiveMenu() {
@@ -346,16 +365,13 @@ define(function(require, exports, module) {
}
function openFileViewer() {
- tsCoreUI.hideAllDropDownMenus();
shouldOpenCol3 = true;
- hidePerspectiveMenu();
reLayout();
}
function closeFileViewer() {
shouldOpenCol3 = false;
isFullWidth = false;
- showPerspectiveMenu();
reLayout();
}
@@ -365,15 +381,11 @@ define(function(require, exports, module) {
}
function closeLeftPanel() {
- $("#closeLeftPanel").hide();
- $("#openLeftPanel").show();
shouldOpenCol1 = false;
reLayout();
}
function openLeftPanel() {
- $("#openLeftPanel").hide();
- $("#closeLeftPanel").show();
shouldOpenCol1 = true;
reLayout();
}