mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-04 06:57:03 +03:00
browserify -> webpack
Code refactoring
This commit is contained in:
parent
542c46b654
commit
27d4bd74ad
138 changed files with 27231 additions and 32424 deletions
|
|
@ -1,7 +1,7 @@
|
|||
// Base64 encode / decode
|
||||
// http://www.webtoolkit.info/
|
||||
|
||||
(function (module) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
|
|
@ -168,4 +168,4 @@
|
|||
module.exports = Base64;
|
||||
/*jslint bitwise: false*/
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
(function (module) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
(function (module) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
|
|
@ -427,4 +427,4 @@
|
|||
|
||||
module.exports = Enums;
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
|
|
@ -1,13 +1,13 @@
|
|||
|
||||
(function (module, require) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
var
|
||||
_ = require('_'),
|
||||
|
||||
Utils = require('Utils'),
|
||||
Plugins = require('Plugins')
|
||||
Utils = require('Common/Utils'),
|
||||
Plugins = require('Common/Plugins')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -62,4 +62,4 @@
|
|||
|
||||
module.exports = new Events();
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
(function (module, require) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
|
|
@ -12,7 +12,7 @@
|
|||
ko = require('ko'),
|
||||
key = require('key'),
|
||||
|
||||
Enums = require('Enums')
|
||||
Enums = require('Common/Enums')
|
||||
;
|
||||
|
||||
Globals.$win = $(window);
|
||||
|
|
@ -284,4 +284,4 @@
|
|||
|
||||
module.exports = Globals;
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
(function (module, require) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
|
|
@ -7,7 +7,7 @@
|
|||
window = require('window'),
|
||||
_ = require('_'),
|
||||
|
||||
Globals = require('Globals'),
|
||||
Globals = require('Common/Globals'),
|
||||
Settings = require('Storage:Settings')
|
||||
;
|
||||
|
||||
|
|
@ -272,4 +272,4 @@
|
|||
|
||||
module.exports = HtmlEditor;
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
|
|
@ -1,11 +1,10 @@
|
|||
|
||||
(function (module, require) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
var
|
||||
window = require('window'),
|
||||
Utils = require('Utils')
|
||||
Utils = require('Common/Utils')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -95,7 +94,7 @@
|
|||
*/
|
||||
LinkBuilder.prototype.change = function (sEmail)
|
||||
{
|
||||
return this.sServer + '/Change/' + this.sSpecSuffix + '/' + window.encodeURIComponent(sEmail) + '/';
|
||||
return this.sServer + '/Change/' + this.sSpecSuffix + '/' + Utils.encodeURIComponent(sEmail) + '/';
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -131,7 +130,7 @@
|
|||
*/
|
||||
LinkBuilder.prototype.avatarLink = function (sEmail)
|
||||
{
|
||||
return this.sServer + '/Raw/0/Avatar/' + window.encodeURIComponent(sEmail) + '/';
|
||||
return this.sServer + '/Raw/0/Avatar/' + Utils.encodeURIComponent(sEmail) + '/';
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -304,7 +303,7 @@
|
|||
*/
|
||||
LinkBuilder.prototype.openPgpJs = function ()
|
||||
{
|
||||
return this.sStaticPrefix + 'js/openpgp.min.js';
|
||||
return this.sStaticPrefix + 'js/min/openpgp.js';
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -333,4 +332,4 @@
|
|||
|
||||
module.exports = new LinkBuilder();
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
|
|
@ -1,12 +1,12 @@
|
|||
|
||||
(function (module, require) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
var
|
||||
_ = require('_'),
|
||||
|
||||
Utils = require('Utils')
|
||||
Utils = require('Common/Utils')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -110,4 +110,4 @@
|
|||
|
||||
module.exports = new Plugins();
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
(function (module, require) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
|
|
@ -9,8 +9,8 @@
|
|||
ko = require('ko'),
|
||||
key = require('key'),
|
||||
|
||||
Enums = require('Enums'),
|
||||
Utils = require('Utils')
|
||||
Enums = require('Common/Enums'),
|
||||
Utils = require('Common/Utils')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -726,4 +726,4 @@
|
|||
|
||||
module.exports = Selector;
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
(function (module, require) {
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
|
|
@ -11,11 +11,11 @@
|
|||
$ = require('$'),
|
||||
ko = require('ko'),
|
||||
|
||||
Enums = require('Enums'),
|
||||
Consts = require('Consts'),
|
||||
Globals = require('Globals')
|
||||
Enums = require('Common/Enums'),
|
||||
Consts = require('Common/Consts'),
|
||||
Globals = require('Common/Globals')
|
||||
;
|
||||
|
||||
|
||||
Utils.trim = $.trim;
|
||||
Utils.inArray = $.inArray;
|
||||
Utils.isArray = _.isArray;
|
||||
|
|
@ -80,6 +80,15 @@
|
|||
return Utils.isNormal(mValue) ? '' + mValue : '';
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {string} sComponent
|
||||
* @return {string}
|
||||
*/
|
||||
Utils.encodeURIComponent = function (sComponent)
|
||||
{
|
||||
return window.encodeURIComponent(sComponent);
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {*} aValue
|
||||
* @return {boolean}
|
||||
|
|
@ -1929,4 +1938,4 @@
|
|||
|
||||
module.exports = Utils;
|
||||
|
||||
}(module, require));
|
||||
}());
|
||||
Loading…
Add table
Add a link
Reference in a new issue