All files export their public interface if `exports` is available.
This commit is contained in:
parent
003c2a59aa
commit
2b5d7a0048
|
@ -370,3 +370,7 @@ function Ace2Editor()
|
|||
|
||||
return editor;
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.Ace2Editor = Ace2Editor;
|
||||
}
|
||||
|
|
|
@ -147,7 +147,19 @@ function htmlPrettyEscape(str)
|
|||
}).replace(/\r?\n/g, '\\n');
|
||||
}
|
||||
|
||||
if (typeof exports !== "undefined")
|
||||
{
|
||||
exports.map = map;
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.isNodeText = isNodeText;
|
||||
exports.object = object;
|
||||
exports.extend = extend;
|
||||
exports.forEach = forEach;
|
||||
exports.map = map;
|
||||
exports.filter = filter;
|
||||
exports.isArray = isArray;
|
||||
exports.browser = browser;
|
||||
exports.getAssoc = getAssoc;
|
||||
exports.setAssoc = setAssoc;
|
||||
exports.binarySearch = binarySearch;
|
||||
exports.binarySearchInfinite = binarySearchInfinite;
|
||||
exports.htmlPrettyEscape = htmlPrettyEscape;
|
||||
exports.map = map;
|
||||
}
|
||||
|
|
|
@ -5858,3 +5858,7 @@ function OUTER(gscope)
|
|||
};
|
||||
|
||||
OUTER(this);
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.OUTER = OUTER; // This is probably unimportant.
|
||||
}
|
||||
|
|
|
@ -758,3 +758,7 @@ function loadBroadcastJS()
|
|||
|
||||
receiveAuthorData(clientVars.historicalAuthorData);
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.loadBroadcastJS = loadBroadcastJS;
|
||||
}
|
||||
|
|
|
@ -125,3 +125,7 @@ function loadBroadcastRevisionsJS()
|
|||
};
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.loadBroadcastRevisionsJS = loadBroadcastRevisionsJS;
|
||||
}
|
||||
|
|
|
@ -496,3 +496,7 @@ function loadBroadcastSliderJS()
|
|||
$("#viewlatest").html(loc == BroadcastSlider.getSliderLength() ? "Viewing latest content" : "View latest content");
|
||||
})
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.loadBroadcastSliderJS = loadBroadcastSliderJS;
|
||||
}
|
||||
|
|
|
@ -207,3 +207,7 @@ function makeChangesetTracker(scheduler, apool, aceCallbacksProvider)
|
|||
};
|
||||
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.makeChangesetTracker = makeChangesetTracker;
|
||||
}
|
||||
|
|
|
@ -172,3 +172,7 @@ var chat = (function()
|
|||
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.chat = chat;
|
||||
}
|
||||
|
|
|
@ -722,3 +722,8 @@ function selectElementContents(elem)
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.getCollabClient = getCollabClient;
|
||||
exports.selectElementContents = selectElementContents;
|
||||
}
|
||||
|
|
|
@ -119,3 +119,7 @@ colorutils.blend = function(c1, c2, t)
|
|||
{
|
||||
return [colorutils.scale(t, c1[0], c2[0]), colorutils.scale(t, c1[1], c2[1]), colorutils.scale(t, c1[2], c2[2])];
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.colorutils = colorutils;
|
||||
}
|
||||
|
|
|
@ -692,3 +692,8 @@ function makeContentCollector(collectStyles, browser, apool, domInterface, class
|
|||
|
||||
return cc;
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.sanitizeUnicode = sanitizeUnicode;
|
||||
exports.makeContentCollector = makeContentCollector;
|
||||
}
|
||||
|
|
|
@ -118,3 +118,7 @@ function makeCSSManager(emptyStylesheetTitle, top)
|
|||
}
|
||||
};
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.makeCSSManager = makeCSSManager;
|
||||
}
|
||||
|
|
|
@ -114,3 +114,7 @@ function makeCSSManager(emptyStylesheetTitle)
|
|||
}
|
||||
};
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.makeCSSManager = makeCSSManager;
|
||||
}
|
||||
|
|
|
@ -310,3 +310,7 @@ domline.processSpaces = function(s, doesWrap)
|
|||
}
|
||||
return parts.join('');
|
||||
};
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.domline = domline;
|
||||
}
|
||||
|
|
|
@ -309,3 +309,7 @@ domline.processSpaces = function(s, doesWrap)
|
|||
}
|
||||
return parts.join('');
|
||||
};
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.domline = domline;
|
||||
}
|
||||
|
|
|
@ -193,3 +193,7 @@ function makeResizableHPane(left, sep, right, minLeft, minRight, sepWidth, sepOf
|
|||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.makeDraggable = makeDraggable;
|
||||
}
|
||||
|
|
|
@ -2508,3 +2508,8 @@ Changeset.followAttributes = function(att1, att2, pool)
|
|||
}
|
||||
return buf.toString();
|
||||
};
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.Changeset = Changeset;
|
||||
exports.AttribPool = AttribPool;
|
||||
}
|
||||
|
|
|
@ -2269,3 +2269,8 @@ Changeset.inverse = function(cs, lines, alines, pool)
|
|||
|
||||
return Changeset.checkRep(builder.toString());
|
||||
};
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.Changeset = Changeset;
|
||||
exports.AttribPool = AttribPool;
|
||||
}
|
||||
|
|
|
@ -352,3 +352,7 @@ linestylefilter.populateDomLine = function(textLine, aline, apool, domLineObj)
|
|||
func = linestylefilter.getLineStyleFilter(text.length, aline, func, apool);
|
||||
func(text, '');
|
||||
};
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.linestylefilter = linestylefilter;
|
||||
}
|
||||
|
|
|
@ -350,3 +350,7 @@ linestylefilter.populateDomLine = function(textLine, aline, apool, domLineObj)
|
|||
func = linestylefilter.getLineStyleFilter(text.length, aline, func, apool);
|
||||
func(text, '');
|
||||
};
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.linestylefilter = linestylefilter;
|
||||
}
|
||||
|
|
|
@ -953,3 +953,16 @@ var alertBar = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.settings = settings;
|
||||
exports.createCookie = createCookie;
|
||||
exports.readCookie = readCookie;
|
||||
exports.randomString = randomString;
|
||||
exports.getParams = getParams;
|
||||
exports.getUrlVars = getUrlVars;
|
||||
exports.savePassword = savePassword;
|
||||
exports.handshake = handshake;
|
||||
exports.pad = pad;
|
||||
exports.alertBar = alertBar;
|
||||
}
|
||||
|
|
|
@ -85,3 +85,7 @@ var padconnectionstatus = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.padconnectionstatus = padconnectionstatus;
|
||||
}
|
||||
|
|
|
@ -126,3 +126,7 @@ var padcookie = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.padcookie = padcookie;
|
||||
}
|
||||
|
|
|
@ -456,3 +456,7 @@ var paddocbar = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.paddocbar = paddocbar;
|
||||
}
|
||||
|
|
|
@ -230,3 +230,7 @@ var padeditbar = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.padeditbar = padeditbar;
|
||||
}
|
||||
|
|
|
@ -150,3 +150,7 @@ var padeditor = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.padeditor = padeditor;
|
||||
}
|
||||
|
|
|
@ -325,3 +325,7 @@ var padimpexp = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.padimpexp = padimpexp;
|
||||
}
|
||||
|
|
|
@ -364,3 +364,7 @@ var padmodals = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.padmodals = padmodals;
|
||||
}
|
||||
|
|
|
@ -518,3 +518,7 @@ var padsavedrevs = (function()
|
|||
};
|
||||
return self;
|
||||
}());
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.padsavedrevs = padsavedrevs;
|
||||
}
|
||||
|
|
|
@ -805,3 +805,7 @@ function showColorPicker()
|
|||
$($("#colorpickerswatches li")[myUserInfo.colorId]).addClass("picked"); //seems weird
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.paduserlist = paduserlist;
|
||||
}
|
||||
|
|
|
@ -486,3 +486,7 @@ window.onerror = function test (msg, url, linenumber)
|
|||
|
||||
return false;
|
||||
};
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.padutils = padutils;
|
||||
}
|
||||
|
|
|
@ -31,3 +31,7 @@ plugins = {
|
|||
}).join(sep || "");
|
||||
}
|
||||
};
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.plugins = plugins;
|
||||
}
|
||||
|
|
|
@ -488,3 +488,7 @@ that is a string.
|
|||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.newSkipList = newSkipList;
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
*/
|
||||
|
||||
|
||||
undoModule = (function()
|
||||
var undoModule = (function()
|
||||
{
|
||||
var stack = (function()
|
||||
{
|
||||
|
@ -329,3 +329,7 @@ undoModule = (function()
|
|||
apool: null
|
||||
}; // apool is filled in by caller
|
||||
})();
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.undoModule = undoModule;
|
||||
}
|
||||
|
|
|
@ -384,3 +384,7 @@ function makeVirtualLineView(lineNode)
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
if (typeof exports !== 'undefined') {
|
||||
exports.makeVirtualLineView = makeVirtualLineView;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue