Skip to content

Commit

Permalink
preparing for pull request to master
Browse files Browse the repository at this point in the history
  • Loading branch information
kirkhess committed Sep 18, 2018
1 parent c31b212 commit 12685d9
Show file tree
Hide file tree
Showing 13 changed files with 11,298 additions and 9,362 deletions.
2 changes: 1 addition & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ module.exports = function(grunt) {
}
});

grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-uglify-es');
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.loadNpmTasks('grunt-contrib-concat');

Expand Down
368 changes: 171 additions & 197 deletions build_support/mini_require.js
Original file line number Diff line number Diff line change
@@ -1,197 +1,171 @@
/*
kefo: Copied from Ace editor repository. This file is needed
to hook up the requirejs defines so they work with a defined
javascript bfe namespace since we use dryice to build and not requirejs.
https://github.com/ajaxorg/ace/blob/master/build_support/mini_require.js
Beyond the note above, it is not used in any other way. It is only
invoked when building/minifying the code.
*/

/* ***** BEGIN LICENSE BLOCK *****
* Distributed under the BSD license:
*
* Copyright (c) 2010, Ajax.org B.V.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* * Neither the name of Ajax.org B.V. nor the
* names of its contributors may be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* ***** END LICENSE BLOCK ***** */

/**
* Define a module along with a payload
* @param module a name for the payload
* @param payload a function to call with (require, exports, module) params
*/

(function() {

var ACE_NAMESPACE = "bfe";

var global = (function() {
return this;
})();


if (!ACE_NAMESPACE && typeof requirejs !== "undefined")
return;


var _define = function(module, deps, payload) {
if (typeof module !== 'string') {
if (_define.original)
_define.original.apply(window, arguments);
else {
console.error('dropping module because define wasn\'t a string.');
console.trace();
}
return;
}

if (arguments.length == 2)
payload = deps;

if (!_define.modules) {
_define.modules = {};
_define.payloads = {};
}

_define.payloads[module] = payload;
_define.modules[module] = null;
};

/**
* Get at functionality define()ed using the function above
*/
var _require = function(parentId, module, callback) {
if (Object.prototype.toString.call(module) === "[object Array]") {
var params = [];
for (var i = 0, l = module.length; i < l; ++i) {
var dep = lookup(parentId, module[i]);
if (!dep && _require.original)
return _require.original.apply(window, arguments);
params.push(dep);
}
if (callback) {
callback.apply(null, params);
}
}
else if (typeof module === 'string') {
var payload = lookup(parentId, module);
if (!payload && _require.original)
return _require.original.apply(window, arguments);

if (callback) {
callback();
}

return payload;
}
else {
if (_require.original)
return _require.original.apply(window, arguments);
}
};

var normalizeModule = function(parentId, moduleName) {
// normalize plugin requires
if (moduleName.indexOf("!") !== -1) {
var chunks = moduleName.split("!");
return normalizeModule(parentId, chunks[0]) + "!" + normalizeModule(parentId, chunks[1]);
}
// normalize relative requires
if (moduleName.charAt(0) == ".") {
var base = parentId.split("/").slice(0, -1).join("/");
moduleName = base + "/" + moduleName;

while(moduleName.indexOf(".") !== -1 && previous != moduleName) {
var previous = moduleName;
moduleName = moduleName.replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
}
}

return moduleName;
};

/**
* Internal function to lookup moduleNames and resolve them by calling the
* definition function if needed.
*/
var lookup = function(parentId, moduleName) {

moduleName = normalizeModule(parentId, moduleName);

var module = _define.modules[moduleName];
if (!module) {
module = _define.payloads[moduleName];
if (typeof module === 'function') {
var exports = {};
var mod = {
id: moduleName,
uri: '',
exports: exports,
packaged: true
};

var req = function(module, callback) {
return _require(moduleName, module, callback);
};

var returnValue = module(req, exports, mod);
exports = returnValue || mod.exports;
_define.modules[moduleName] = exports;
delete _define.payloads[moduleName];
}
module = _define.modules[moduleName] = exports || module;
}
return module;
};

function exportAce(ns) {
var require = function(module, callback) {
return _require("", module, callback);
};

var root = global;
if (ns) {
if (!global[ns])
global[ns] = {};
root = global[ns];
}

if (!root.define || !root.define.packaged) {
_define.original = root.define;
root.define = _define;
root.define.packaged = true;
}

if (!root.require || !root.require.packaged) {
_require.original = root.require;
root.require = require;
root.require.packaged = true;
}
}

exportAce(ACE_NAMESPACE);

})();
/* ***** BEGIN LICENSE BLOCK *****
* Distributed under the BSD license:
*
* Copyright (c) 2010, Ajax.org B.V.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* * Neither the name of Ajax.org B.V. nor the
* names of its contributors may be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* ***** END LICENSE BLOCK ***** */
/**
* Define a module along with a payload
* @param module a name for the payload
* @param payload a function to call with (require, exports, module) params
*/
(function () {
var ACE_NAMESPACE = 'bfe';

var global = (function () {
return this;
})();

if (!ACE_NAMESPACE && typeof requirejs !== 'undefined') { return; }

var _define = function (module, deps, payload) {
if (typeof module !== 'string') {
if (_define.original) { _define.original.apply(window, arguments); } else {
console.error('dropping module because define wasn\'t a string.');
console.trace();
}
return;
}

if (arguments.length === 2) { payload = deps; }

if (!_define.modules) {
_define.modules = {};
_define.payloads = {};
}

_define.payloads[module] = payload;
_define.modules[module] = null;
};

/**
* Get at functionality define()ed using the function above
*/
var _require = function (parentId, module, callback) {
if (Object.prototype.toString.call(module) === '[object Array]') {
var params = [];
for (var i = 0, l = module.length; i < l; ++i) {
var dep = lookup(parentId, module[i]);
if (!dep && _require.original) { return _require.original.apply(window, arguments); }
params.push(dep);
}
if (callback) {
callback.apply(null, params);
}
} else if (typeof module === 'string') {
var payload = lookup(parentId, module);
if (!payload && _require.original) { return _require.original.apply(window, arguments); }

if (callback) {
callback();
}

return payload;
} else {
if (_require.original) { return _require.original.apply(window, arguments); }
}
};

var normalizeModule = function (parentId, moduleName) {
// normalize plugin requires
if (moduleName.indexOf('!') !== -1) {
var chunks = moduleName.split('!');
return normalizeModule(parentId, chunks[0]) + '!' + normalizeModule(parentId, chunks[1]);
}
// normalize relative requires
if (moduleName.charAt(0) === '.') {
var base = parentId.split('/').slice(0, -1).join('/');
moduleName = base + '/' + moduleName;

while (moduleName.indexOf('.') !== -1 && previous !== moduleName) {
var previous = moduleName;
moduleName = moduleName.replace(/\/\.\//, '/').replace(/[^\/]+\/\.\.\//, '');
}
}

return moduleName;
};

/**
* Internal function to lookup moduleNames and resolve them by calling the
* definition function if needed.
*/
var lookup = function (parentId, moduleName) {
moduleName = normalizeModule(parentId, moduleName);
var exports;
var module = _define.modules[moduleName];
if (!module) {
module = _define.payloads[moduleName];
if (typeof module === 'function') {
exports = {};
var mod = {
id: moduleName,
uri: '',
exports: exports,
packaged: true
};

var req = function (module, callback) {
return _require(moduleName, module, callback);
};

var returnValue = module(req, exports, mod);
exports = returnValue || mod.exports;
_define.modules[moduleName] = exports;
delete _define.payloads[moduleName];
}
module = _define.modules[moduleName] = exports || module;
}
return module;
};

function exportAce (ns) {
var require = function (module, callback) {
return _require('', module, callback);
};

var root = global;
if (ns) {
if (!global[ns]) { global[ns] = {}; }
root = global[ns];
}

if (!root.define || !root.define.packaged) {
_define.original = root.define;
root.define = _define;
root.define.packaged = true;
}

if (!root.require || !root.require.packaged) {
_require.original = root.require;
root.require = require;
root.require.packaged = true;
}
}

exportAce(ACE_NAMESPACE);
})();

6 changes: 1 addition & 5 deletions builds/bfe.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* bfe 2018-09-10 *//*!
/* bfe 2018-09-18 *//*!
* Bootstrap v3.1.1 (http://getbootstrap.com)
* Copyright 2011-2014 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
Expand Down Expand Up @@ -4211,7 +4211,3 @@ button.close {
div#save-btn{
margin-bottom:10px;
}

input[pattern]:invalid {
color: red;
}
Loading

0 comments on commit 12685d9

Please sign in to comment.