mirror of
https://github.com/sbrl/Minetest-WorldEditAdditions.git
synced 2024-12-23 12:05:01 +00:00
docs/HTMLPicture: remove debug logging
This commit is contained in:
parent
460aed4f3b
commit
a855ca729e
1 changed files with 1 additions and 2 deletions
|
@ -118,7 +118,6 @@ async function picture(source_image, alt, target_dir, urlpath, formats = "__AUTO
|
|||
}
|
||||
|
||||
const target_original = path.join(target_dir, source_parsed.base);
|
||||
console.error(`DEBUG:target_original`, target_original, `DIRNAME`, path.dirname(target_original));
|
||||
if (!fs.existsSync(path.dirname(target_original)))
|
||||
await fs.promises.mkdir(path.dirname(target_original), { recursive: true });
|
||||
await fs.promises.copyFile(source_image, target_original);
|
||||
|
@ -137,7 +136,7 @@ async function picture(source_image, alt, target_dir, urlpath, formats = "__AUTO
|
|||
};
|
||||
}));
|
||||
|
||||
let result = `<picture>\n\t`;
|
||||
let result = `<picture data-zoomable="true">\n\t`;
|
||||
result += sources.map(source => `<source srcset="${source.srcset}" type="${source.mime}" />`).join(`\n\t`);
|
||||
result += `\n\t<img loading="lazy" decoding="async" src="${urlpath}/${source_parsed.base}" alt="${htmlentities.encode(alt)}" />\n`;
|
||||
result += `</picture>\n`
|
||||
|
|
Loading…
Reference in a new issue