From 4fee258fa1c4db3c93c84196bced15418545627a Mon Sep 17 00:00:00 2001 From: Nathakit Date: Thu, 1 Jun 2017 17:59:58 +0700 Subject: [PATCH] remove webp blog mixin --- templates/includes/webp-blog.jade | 22 ---------------------- 1 file changed, 22 deletions(-) delete mode 100644 templates/includes/webp-blog.jade diff --git a/templates/includes/webp-blog.jade b/templates/includes/webp-blog.jade deleted file mode 100644 index 13b381e7..00000000 --- a/templates/includes/webp-blog.jade +++ /dev/null @@ -1,22 +0,0 @@ -mixin webp-blog(path, title, alt) - - - var path_nosuffix = path.replace(/[.][a-z]{3}/, ""); - - var path_ns_preview = path_nosuffix + "_preview" - - - var validpath = fs.existsSync("./contents" + path); - //- console.log(validpath + " : " +path) - - //- - var buffer = readChunk.sync(path); - //- - var filetype = fileType(buffer); - //- - console.log(path + " : " + filetype) - - - picture(style="height:30vh;").ratio-box.lazy-img - source(srcset="#{path_nosuffix}.webp" type="image/webp") - source(srcset="#{path_ns_preview}.webp" type="image/webp") - source(srcset="#{path_nosuffix}.png" type="image/png") - source(srcset="#{path_ns_preview}.png" type="image/png") - source(srcset="#{path_nosuffix}.jpg" type="image/jpeg") - source(srcset="#{path_ns_preview}.jpg" type="image/jpeg") - img(src="#{path_ns_preview}.webp" style="object-fit:contain;height:30vh;padding-bottom:3em;").img-small - img(data-src="#{path_nosuffix}.webp" title="#{title}" alt="#{alt}" style="object-fit:contain;height:30vh;padding-bottom:3em;").img-large-webp.lazyload \ No newline at end of file