// This adds a mask element to the page, based on the Bootstrap modal dialog backdrop. The mark
// is present immediately, but fades in visually after a short delay, and is removed
// after page initialization is complete. For a client that doesn't have JavaScript enabled,
// this will do nothing (though I suspect the page will not behave to expectations!).
Element script = body.element("script", "type", "text/javascript");
script.raw("document.write(\"<div class=\\\"pageloading-mask\\\"><div></div></div>\");");
script.moveToTop(body);
}
moduleManager.writeConfiguration(body, moduleConfigurationCallbacks);