summaryrefslogtreecommitdiffstats
path: root/client/lib
diff options
context:
space:
mode:
authorLauri Ojansivu <x@xet7.org>2018-09-17 12:49:43 +0300
committerLauri Ojansivu <x@xet7.org>2018-09-17 12:49:43 +0300
commit5445955a774f6a9f29ee48109913ea3c4a9db33f (patch)
tree7b3bee4a7ce6d1053ca6ce0395c267f9ce3a45d8 /client/lib
parent338e18870f937359c50c9be8b2a0fd96e0b4e141 (diff)
downloadwekan-5445955a774f6a9f29ee48109913ea3c4a9db33f.tar.gz
wekan-5445955a774f6a9f29ee48109913ea3c4a9db33f.tar.bz2
wekan-5445955a774f6a9f29ee48109913ea3c4a9db33f.zip
- Revert IFTTT.
Thanks to xet7 !
Diffstat (limited to 'client/lib')
-rw-r--r--client/lib/modal.js14
-rw-r--r--client/lib/utils.js29
2 files changed, 5 insertions, 38 deletions
diff --git a/client/lib/modal.js b/client/lib/modal.js
index 3c27a179..d5350264 100644
--- a/client/lib/modal.js
+++ b/client/lib/modal.js
@@ -4,7 +4,6 @@ window.Modal = new class {
constructor() {
this._currentModal = new ReactiveVar(closedValue);
this._onCloseGoTo = '';
- this._isWideModal = false;
}
getHeaderName() {
@@ -21,10 +20,6 @@ window.Modal = new class {
return this.getTemplateName() !== closedValue;
}
- isWide(){
- return this._isWideModal;
- }
-
close() {
this._currentModal.set(closedValue);
if (this._onCloseGoTo) {
@@ -32,16 +27,9 @@ window.Modal = new class {
}
}
- openWide(modalName, { header = '', onCloseGoTo = ''} = {}) {
- this._currentModal.set({ header, modalName });
- this._onCloseGoTo = onCloseGoTo;
- this._isWideModal = true;
- }
-
open(modalName, { header = '', onCloseGoTo = ''} = {}) {
this._currentModal.set({ header, modalName });
this._onCloseGoTo = onCloseGoTo;
-
}
}();
@@ -50,5 +38,5 @@ Blaze.registerHelper('Modal', Modal);
EscapeActions.register('modalWindow',
() => Modal.close(),
() => Modal.isOpen(),
- { noClickEscapeOn: '.modal-container' }
+ { noClickEscapeOn: '.modal-content' }
);
diff --git a/client/lib/utils.js b/client/lib/utils.js
index 525cfb83..5349e500 100644
--- a/client/lib/utils.js
+++ b/client/lib/utils.js
@@ -39,11 +39,11 @@ Utils = {
if (!prevData && !nextData) {
base = 0;
increment = 1;
- // If we drop the card in the first position
+ // If we drop the card in the first position
} else if (!prevData) {
base = nextData.sort - 1;
increment = -1;
- // If we drop the card in the last position
+ // If we drop the card in the last position
} else if (!nextData) {
base = prevData.sort + 1;
increment = 1;
@@ -71,11 +71,11 @@ Utils = {
if (!prevCardDomElement && !nextCardDomElement) {
base = 0;
increment = 1;
- // If we drop the card in the first position
+ // If we drop the card in the first position
} else if (!prevCardDomElement) {
base = Blaze.getData(nextCardDomElement).sort - 1;
increment = -1;
- // If we drop the card in the last position
+ // If we drop the card in the last position
} else if (!nextCardDomElement) {
base = Blaze.getData(prevCardDomElement).sort + 1;
increment = 1;
@@ -189,27 +189,6 @@ Utils = {
window._paq.push(['trackPageView']);
}
},
-
- getTriggerActionDesc(event, tempInstance) {
- const jqueryEl = tempInstance.$(event.currentTarget.parentNode);
- const triggerEls = jqueryEl.find('.trigger-content').children();
- let finalString = '';
- for (let i = 0; i < triggerEls.length; i++) {
- const element = tempInstance.$(triggerEls[i]);
- if (element.hasClass('trigger-text')) {
- finalString += element.text().toLowerCase();
- } else if (element.find('select').length > 0) {
- finalString += element.find('select option:selected').text().toLowerCase();
- } else if (element.find('input').length > 0) {
- finalString += element.find('input').val();
- }
- // Add space
- if (i !== length - 1) {
- finalString += ' ';
- }
- }
- return finalString;
- },
};
// A simple tracker dependency that we invalidate every time the window is