commento.js: load CSS async

This commit is contained in:
Adhityaa Chandrasekar 2019-03-02 14:09:29 -05:00
parent c8a2ece0d6
commit d26b6f6e9f

View File

@ -374,8 +374,6 @@
commenters = Object.assign({}, commenters, resp.commenters) commenters = Object.assign({}, commenters, resp.commenters)
configuredOauths = resp.configuredOauths; configuredOauths = resp.configuredOauths;
cssLoad(cdn + "/css/commento.css", "window.commento.loadCssOverride()");
call(callback); call(callback);
}); });
} }
@ -1545,7 +1543,6 @@
var mainArea = $(ID_MAIN_AREA); var mainArea = $(ID_MAIN_AREA);
var modTools = $(ID_MOD_TOOLS); var modTools = $(ID_MOD_TOOLS);
var loggedContainer = $(ID_LOGGED_CONTAINER); var loggedContainer = $(ID_LOGGED_CONTAINER);
var footer = $(ID_FOOTER);
attrSet(mainArea, "style", ""); attrSet(mainArea, "style", "");
@ -1557,8 +1554,6 @@
attrSet(loggedContainer, "style", ""); attrSet(loggedContainer, "style", "");
} }
attrSet(footer, "style", "");
nameWidthFix(); nameWidthFix();
loadHash(); loadHash();
} }
@ -1640,12 +1635,15 @@
mainAreaCreate(); mainAreaCreate();
var footer = footerLoad();
cssLoad(cdn + "/css/commento.css", "window.commento.loadCssOverride()");
selfGet(function() { selfGet(function() {
commentsGet(function() { commentsGet(function() {
modToolsCreate(); modToolsCreate();
rootCreate(function() { rootCreate(function() {
commentsRender(); commentsRender();
footerLoad(); append(root, footer);
attrSet(root, "style", ""); attrSet(root, "style", "");
call(callback); call(callback);
}); });