|
|
@@ -479,6 +479,15 @@ this.singlefile.lib.core = this.singlefile.lib.core || (() => {
|
|
|
canonicalLink.href = this.options.saveUrl;
|
|
|
}
|
|
|
}
|
|
|
+ if (this.options.insertMetaNoIndex) {
|
|
|
+ let metaElement = this.doc.querySelector("meta[name=robots][content*=noindex]");
|
|
|
+ if (!metaElement) {
|
|
|
+ metaElement = this.doc.createElement("meta");
|
|
|
+ metaElement.setAttribute("name", "robots");
|
|
|
+ metaElement.setAttribute("content", "noindex");
|
|
|
+ this.doc.head.appendChild(metaElement);
|
|
|
+ }
|
|
|
+ }
|
|
|
let size;
|
|
|
if (this.options.displayStats) {
|
|
|
size = util.getContentSize(this.doc.documentElement.outerHTML);
|
|
|
@@ -986,6 +995,7 @@ this.singlefile.lib.core = this.singlefile.lib.core || (() => {
|
|
|
async function initializeProcessor(frameData, frameElement, frameWindowId, batchRequest, options) {
|
|
|
options.insertSingleFileComment = false;
|
|
|
options.insertCanonicalLink = false;
|
|
|
+ options.insertMetaNoIndex = false;
|
|
|
options.saveFavicon = false;
|
|
|
options.url = frameData.baseURI;
|
|
|
options.windowId = frameWindowId;
|
|
|
@@ -1072,6 +1082,7 @@ this.singlefile.lib.core = this.singlefile.lib.core || (() => {
|
|
|
const options = Object.create(this.options);
|
|
|
options.insertSingleFileComment = false;
|
|
|
options.insertCanonicalLink = false;
|
|
|
+ options.insertMetaNoIndex = false;
|
|
|
options.saveFavicon = false;
|
|
|
options.removeUnusedStyles = false;
|
|
|
options.removeAlternativeMedias = false;
|