diff --git a/art/short-hair.eno b/art/short-hair.eno new file mode 100644 index 0000000..b628931 --- /dev/null +++ b/art/short-hair.eno @@ -0,0 +1,5 @@ +-- Alt Text + +A brown haired girl with dark eyes looking at the viewer. She has a pale purple tank top and playing with her short hair. + +-- Alt Text diff --git a/art/sword-leftlean.eno b/art/sword-leftlean.eno new file mode 100644 index 0000000..67f5fe5 --- /dev/null +++ b/art/sword-leftlean.eno @@ -0,0 +1,8 @@ +-- Alt Text + +A girl is looking at you. She has dark brown hair, and pale skin. She has a dark dress with golden accents and is plastered against a simple light background. + +-- Alt Text + +Characters: +- Mysterious Swordswoman diff --git a/assets/art/short-hair.webp b/assets/art/short-hair.webp new file mode 100644 index 0000000..80df660 Binary files /dev/null and b/assets/art/short-hair.webp differ diff --git a/content/art/demon.md b/content/art/demon.md index 2e34c69..d12fa65 100644 --- a/content/art/demon.md +++ b/content/art/demon.md @@ -6,4 +6,5 @@ date: 2022-01-01 excludefeed: true layout: art-detail filename: /art/demon.webp +nsfw: true --- diff --git a/content/art/ffxiv-sketches.md b/content/art/ffxiv-sketches.md index c425c84..69fc223 100644 --- a/content/art/ffxiv-sketches.md +++ b/content/art/ffxiv-sketches.md @@ -4,4 +4,5 @@ date: 2021-01-01 excludefeed: true layout: art-detail filename: /art/ffxiv-sketches.webp +nsfw: true --- diff --git a/content/art/ffxiv-swim.md b/content/art/ffxiv-swim.md index 09c1e96..96938bc 100644 --- a/content/art/ffxiv-swim.md +++ b/content/art/ffxiv-swim.md @@ -4,4 +4,5 @@ date: 2020-01-01 excludefeed: true layout: art-detail filename: /art/ffxiv-swim.webp +nsfw: true --- diff --git a/content/art/miqote-swimsuit.md b/content/art/miqote-swimsuit.md index 6ce8760..3d3286d 100644 --- a/content/art/miqote-swimsuit.md +++ b/content/art/miqote-swimsuit.md @@ -6,4 +6,5 @@ date: 2021-01-01 excludefeed: true layout: art-detail filename: /art/miqote-swimsuit.webp +nsfw: true --- diff --git a/content/art/naked-elf.md b/content/art/naked-elf.md index e98403d..c17e09d 100644 --- a/content/art/naked-elf.md +++ b/content/art/naked-elf.md @@ -4,4 +4,5 @@ date: 2019-01-01 excludefeed: true layout: art-detail filename: /art/naked-elf.webp +nsfw: true --- diff --git a/content/art/naked.md b/content/art/naked.md index 070bd7f..f2a6d83 100644 --- a/content/art/naked.md +++ b/content/art/naked.md @@ -4,4 +4,5 @@ date: 2019-01-01 excludefeed: true layout: art-detail filename: /art/naked.webp +nsfw: true --- diff --git a/content/art/short-hair.md b/content/art/short-hair.md new file mode 100644 index 0000000..586c2ed --- /dev/null +++ b/content/art/short-hair.md @@ -0,0 +1,9 @@ +--- +layout: art-detail +filename: /art/short-hair.webp +alt_text: "A brown haired girl with dark eyes looking at the viewer. She has a pale purple tank top and playing with her short hair." +date: 2023-02-01 +slug: short-hair +characters: +arttags: +--- diff --git a/content/art/summer-byleth.md b/content/art/summer-byleth.md index 81bd4cb..fcfd4d1 100644 --- a/content/art/summer-byleth.md +++ b/content/art/summer-byleth.md @@ -8,6 +8,7 @@ slug: summer-byleth characters: - Byleth arttags: +nsfw: true --- This is my first proper painted character piece, and I'm pretty happy with how it turned out still. Why does she need a knife on the beach though? diff --git a/content/art/summer-eva-girls.md b/content/art/summer-eva-girls.md index f0e4a27..5eb6429 100644 --- a/content/art/summer-eva-girls.md +++ b/content/art/summer-eva-girls.md @@ -10,6 +10,7 @@ characters: - Asuka - Rei arttags: +nsfw: true --- I drew this while on a trip, and I thought it was about time to do a summer-themed Evangelion drawing! Mari is of course having some fun with Asuka! diff --git a/content/art/sword-leftlean.md b/content/art/sword-leftlean.md index a92c687..8a653ea 100644 --- a/content/art/sword-leftlean.md +++ b/content/art/sword-leftlean.md @@ -1,6 +1,10 @@ --- -slug: sword-leftlean -date: 2023-01-05 layout: art-detail filename: /art/sword-leftlean.webp +alt_text: "A girl is looking at you. She has dark brown hair, and pale skin. She has a dark dress with golden accents and is plastered against a simple light background." +date: 2023-01-05 +slug: sword-leftlean +characters: +- Mysterious Swordswoman +arttags: --- diff --git a/content/art/two-girls.md b/content/art/two-girls.md index 1801042..453e38a 100644 --- a/content/art/two-girls.md +++ b/content/art/two-girls.md @@ -6,4 +6,5 @@ date: 2022-01-01 excludefeed: true layout: art-detail filename: /art/two-girls.webp +nsfw: true --- diff --git a/content/art/underwear.md b/content/art/underwear.md index 7f8beec..e5a91f3 100644 --- a/content/art/underwear.md +++ b/content/art/underwear.md @@ -9,4 +9,5 @@ slug: underwear characters: - Merume arttags: +nsfw: true --- diff --git a/content/art/viera1.md b/content/art/viera1.md index 8e0818e..d58c087 100644 --- a/content/art/viera1.md +++ b/content/art/viera1.md @@ -6,4 +6,5 @@ date: 2022-01-01 excludefeed: true layout: art-detail filename: /art/viera1.webp +nsfw: true --- diff --git a/content/art/viera2.md b/content/art/viera2.md index c325bb5..5cbdc91 100644 --- a/content/art/viera2.md +++ b/content/art/viera2.md @@ -6,4 +6,5 @@ date: 2022-01-01 excludefeed: true layout: art-detail filename: /art/viera2.webp +nsfw: true --- diff --git a/content/art/working-out.md b/content/art/working-out.md index ff69965..c712eda 100644 --- a/content/art/working-out.md +++ b/content/art/working-out.md @@ -8,4 +8,5 @@ excludefeed: true slug: working-out characters: arttags: +nsfw: true --- diff --git a/data/art.json b/data/art.json index 01b00c5..6180770 100644 --- a/data/art.json +++ b/data/art.json @@ -195,14 +195,16 @@ "filename": "summer-eva-girls.webp", "newgrounds_url": "https://www.newgrounds.com/art/view/redstrate/summer-eva-girls", "pixiv_url": "https://www.pixiv.net/en/artworks/100026963", - "date": "7-27" + "date": "7-27", + "nsfw": true }, { "title": "summer byleth", "filename": "summer-byleth.webp", "pixiv_url": "https://www.pixiv.net/en/artworks/98726204", "newgrounds_url": "https://www.newgrounds.com/art/view/redstrate/summer-byleth", - "date": "5-30" + "date": "5-30", + "nsfw": true }, { "title": "after the rain", @@ -249,13 +251,15 @@ "filename": "tree2.webp" }, { - "filename": "naked-elf.webp" + "filename": "naked-elf.webp", + "nsfw": true }, { "filename": "sketch-collect.webp" }, { - "filename": "naked.webp" + "filename": "naked.webp", + "nsfw": true }, { "filename": "2019.webp" @@ -369,7 +373,8 @@ "filename": "water-test.webp" }, { - "filename": "ffxiv-swim.webp" + "filename": "ffxiv-swim.webp", + "nsfw": true }, { "title": "Trainwatching", @@ -458,7 +463,8 @@ }, { "title": "Miq'ote in a Swimsuit", - "filename": "miqote-swimsuit.webp" + "filename": "miqote-swimsuit.webp", + "nsfw": true }, { "filename": "drawpile-snippet.webp" @@ -482,7 +488,8 @@ "filename": "aerith.webp" }, { - "filename": "ffxiv-sketches.webp" + "filename": "ffxiv-sketches.webp", + "nsfw": true }, { "filename": "futaba.webp" @@ -543,7 +550,8 @@ }, { "title": "Underwear", - "filename": "underwear.webp" + "filename": "underwear.webp", + "nsfw": true }, { "title": "Sketch Dump", @@ -567,15 +575,18 @@ }, { "title": "Viera #1", - "filename": "viera1.webp" + "filename": "viera1.webp", + "nsfw": true }, { "title": "Viera #2", - "filename": "viera2.webp" + "filename": "viera2.webp", + "nsfw": true }, { "title": "Two Girls", - "filename": "two-girls.webp" + "filename": "two-girls.webp", + "nsfw": true }, { "title": "Overalls", @@ -587,7 +598,8 @@ }, { "title": "Demonness", - "filename": "demon.webp" + "filename": "demon.webp", + "nsfw": true }, { "title": "Guns", @@ -599,7 +611,8 @@ }, { "title": "Working Out", - "filename": "working-out.webp" + "filename": "working-out.webp", + "nsfw": true }, { "title": "Funny", @@ -646,6 +659,10 @@ { "date": "1-5", "filename": "sword-leftlean.webp" + }, + { + "date": "2-1", + "filename": "short-hair.webp" } ] } diff --git a/resources/_gen/images/after-the-rain_hu582817e2f11ab1efa9f326e0b80d2535_110666_e4f979e9412860b38ab72038bcf66ecf.webp b/resources/_gen/images/after-the-rain_hu582817e2f11ab1efa9f326e0b80d2535_110666_e4f979e9412860b38ab72038bcf66ecf.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/alley_hu3e45cc0cee2ad657dedb19efe3abaadf_129742_6bad2d0728a969162ba0c838d3f3645e.webp b/resources/_gen/images/alley_hu3e45cc0cee2ad657dedb19efe3abaadf_129742_6bad2d0728a969162ba0c838d3f3645e.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/bard_hu76b27965f49442c528354170619b798a_146664_8a151782cbbdee0fd6c78484e2999daf.webp b/resources/_gen/images/bard_hu76b27965f49442c528354170619b798a_146664_8a151782cbbdee0fd6c78484e2999daf.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/chains_hu04c5aa4d2bc9ea59d64375eae2fd858a_157668_c91c5a13ff38e480cb84d873bbc470b3.webp b/resources/_gen/images/chains_hu04c5aa4d2bc9ea59d64375eae2fd858a_157668_c91c5a13ff38e480cb84d873bbc470b3.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/demon_hu4b996eb1a1775601961e4abac45eb6f2_137022_997b7ee4b4ec89e819c46e42c0d5998f.webp b/resources/_gen/images/demon_hu4b996eb1a1775601961e4abac45eb6f2_137022_997b7ee4b4ec89e819c46e42c0d5998f.webp new file mode 100644 index 0000000..04fed86 Binary files /dev/null and b/resources/_gen/images/demon_hu4b996eb1a1775601961e4abac45eb6f2_137022_997b7ee4b4ec89e819c46e42c0d5998f.webp differ diff --git a/resources/_gen/images/ffxiv-sketches_hub373bc532cb718261faaf1269ef93387_78082_d05a8724b8458d81bff96afbb10c4c5d.webp b/resources/_gen/images/ffxiv-sketches_hub373bc532cb718261faaf1269ef93387_78082_d05a8724b8458d81bff96afbb10c4c5d.webp new file mode 100644 index 0000000..30cc5a6 Binary files /dev/null and b/resources/_gen/images/ffxiv-sketches_hub373bc532cb718261faaf1269ef93387_78082_d05a8724b8458d81bff96afbb10c4c5d.webp differ diff --git a/resources/_gen/images/ffxiv-swim_hu837f443333d655db434356354512b989_358758_8191ee64f23b37e313f124b0bbfd4fae.webp b/resources/_gen/images/ffxiv-swim_hu837f443333d655db434356354512b989_358758_8191ee64f23b37e313f124b0bbfd4fae.webp new file mode 100644 index 0000000..61d3f3f Binary files /dev/null and b/resources/_gen/images/ffxiv-swim_hu837f443333d655db434356354512b989_358758_8191ee64f23b37e313f124b0bbfd4fae.webp differ diff --git a/resources/_gen/images/goinghome_hu829fc8757b394e4f9916df75d63c1f60_188066_3663a161a335ca996920be54294adbf7.webp b/resources/_gen/images/goinghome_hu829fc8757b394e4f9916df75d63c1f60_188066_3663a161a335ca996920be54294adbf7.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/grocery-shopping_hu9b8ee466b9e9d05e99c40d64ce277613_101944_d1e1b0a4aeda2f4e31d8995e885a9187.webp b/resources/_gen/images/grocery-shopping_hu9b8ee466b9e9d05e99c40d64ce277613_101944_d1e1b0a4aeda2f4e31d8995e885a9187.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/lets-get-fit_hu0c43977cbeea902110f7fd081c9e3b58_137936_c89849e822ac4eb9394661175679f0b2.webp b/resources/_gen/images/lets-get-fit_hu0c43977cbeea902110f7fd081c9e3b58_137936_c89849e822ac4eb9394661175679f0b2.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/mari-and-asuka_hub7c77f663da56ae7ffc0b96b9ce96581_102776_1b8c45c0288b74ba75fad0c8d465361a.webp b/resources/_gen/images/mari-and-asuka_hub7c77f663da56ae7ffc0b96b9ce96581_102776_1b8c45c0288b74ba75fad0c8d465361a.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/miqote-swimsuit_hu5a8f684306428ae98fb900d9501966b2_66818_852875f2e5927f799bb1bb5f6b2baee6.webp b/resources/_gen/images/miqote-swimsuit_hu5a8f684306428ae98fb900d9501966b2_66818_852875f2e5927f799bb1bb5f6b2baee6.webp new file mode 100644 index 0000000..789ce85 Binary files /dev/null and b/resources/_gen/images/miqote-swimsuit_hu5a8f684306428ae98fb900d9501966b2_66818_852875f2e5927f799bb1bb5f6b2baee6.webp differ diff --git a/resources/_gen/images/mythra_hu2963336c80a45960d4c9efbace3686a3_170080_8b1b8f8348ee042c0dd248a1d40ffe32.webp b/resources/_gen/images/mythra_hu2963336c80a45960d4c9efbace3686a3_170080_8b1b8f8348ee042c0dd248a1d40ffe32.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/naked-elf_huce7aa24a87a8fbf0bc7578510cea98be_35964_baf7ba03fdcfab659431e030bc6d1ace.webp b/resources/_gen/images/naked-elf_huce7aa24a87a8fbf0bc7578510cea98be_35964_baf7ba03fdcfab659431e030bc6d1ace.webp new file mode 100644 index 0000000..d128da6 Binary files /dev/null and b/resources/_gen/images/naked-elf_huce7aa24a87a8fbf0bc7578510cea98be_35964_baf7ba03fdcfab659431e030bc6d1ace.webp differ diff --git a/resources/_gen/images/naked_hubec334d60e42816f5a4454ae61e9b7c1_39712_d91239151ecdc780b71e8e6da1b15149.webp b/resources/_gen/images/naked_hubec334d60e42816f5a4454ae61e9b7c1_39712_d91239151ecdc780b71e8e6da1b15149.webp new file mode 100644 index 0000000..8daf70c Binary files /dev/null and b/resources/_gen/images/naked_hubec334d60e42816f5a4454ae61e9b7c1_39712_d91239151ecdc780b71e8e6da1b15149.webp differ diff --git a/resources/_gen/images/orbit-correction_hu43dcb8b3055aabf6c3899771e9698b98_112388_1884b5dd640ac6e4c43c83ca0ff21c5b.webp b/resources/_gen/images/orbit-correction_hu43dcb8b3055aabf6c3899771e9698b98_112388_1884b5dd640ac6e4c43c83ca0ff21c5b.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/samus_hu31bc8dda38b1c7e2e5255ca8896a54f9_21136_461b2806c256d06dea8e3232583e8e74.webp b/resources/_gen/images/samus_hu31bc8dda38b1c7e2e5255ca8896a54f9_21136_461b2806c256d06dea8e3232583e8e74.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/short-hair_hueb30ae43da29abb5cda5c73f66142522_50762_300x0_resize_q75_h2_box_2.webp b/resources/_gen/images/short-hair_hueb30ae43da29abb5cda5c73f66142522_50762_300x0_resize_q75_h2_box_2.webp new file mode 100644 index 0000000..1be043d Binary files /dev/null and b/resources/_gen/images/short-hair_hueb30ae43da29abb5cda5c73f66142522_50762_300x0_resize_q75_h2_box_2.webp differ diff --git a/resources/_gen/images/summer-byleth_hubcff664ee3d0c2284020bd06f85a881d_159318_a0084cbe3d8b0ef0bbe827a939b65a8a.webp b/resources/_gen/images/summer-byleth_hubcff664ee3d0c2284020bd06f85a881d_159318_a0084cbe3d8b0ef0bbe827a939b65a8a.webp new file mode 100644 index 0000000..fdc2ad5 Binary files /dev/null and b/resources/_gen/images/summer-byleth_hubcff664ee3d0c2284020bd06f85a881d_159318_a0084cbe3d8b0ef0bbe827a939b65a8a.webp differ diff --git a/resources/_gen/images/summer-eva-girls_hue6313b00151c349951873304e2c20c05_84238_b753a1412cc131981b047eed04c57c35.webp b/resources/_gen/images/summer-eva-girls_hue6313b00151c349951873304e2c20c05_84238_b753a1412cc131981b047eed04c57c35.webp new file mode 100644 index 0000000..04ea7e3 Binary files /dev/null and b/resources/_gen/images/summer-eva-girls_hue6313b00151c349951873304e2c20c05_84238_b753a1412cc131981b047eed04c57c35.webp differ diff --git a/resources/_gen/images/sword-leftlean_hu41090797079796bbc84fbb5a918d9263_57134_727b702de51c556c9c26b26fb242edfe.webp b/resources/_gen/images/sword-leftlean_hu41090797079796bbc84fbb5a918d9263_57134_727b702de51c556c9c26b26fb242edfe.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/two-girls_hud9d0547e77537c53e26a0a1ee4dd2bf3_64252_4b25452ad4f295a891328308587cb1ab.webp b/resources/_gen/images/two-girls_hud9d0547e77537c53e26a0a1ee4dd2bf3_64252_4b25452ad4f295a891328308587cb1ab.webp new file mode 100644 index 0000000..a9ea7eb Binary files /dev/null and b/resources/_gen/images/two-girls_hud9d0547e77537c53e26a0a1ee4dd2bf3_64252_4b25452ad4f295a891328308587cb1ab.webp differ diff --git a/resources/_gen/images/underwear_huf5f2d2a71528a8f7b1e3c57a9cea79e7_102092_1169c089406ea12b59f34a61caab7409.webp b/resources/_gen/images/underwear_huf5f2d2a71528a8f7b1e3c57a9cea79e7_102092_1169c089406ea12b59f34a61caab7409.webp new file mode 100644 index 0000000..bc19bd9 Binary files /dev/null and b/resources/_gen/images/underwear_huf5f2d2a71528a8f7b1e3c57a9cea79e7_102092_1169c089406ea12b59f34a61caab7409.webp differ diff --git a/resources/_gen/images/viera1_hu049669c90ed3da5a5602163349ba13bf_170770_c3ecf2ea6b539ff110f69f83e3c27aa3.webp b/resources/_gen/images/viera1_hu049669c90ed3da5a5602163349ba13bf_170770_c3ecf2ea6b539ff110f69f83e3c27aa3.webp new file mode 100644 index 0000000..0fad08a Binary files /dev/null and b/resources/_gen/images/viera1_hu049669c90ed3da5a5602163349ba13bf_170770_c3ecf2ea6b539ff110f69f83e3c27aa3.webp differ diff --git a/resources/_gen/images/viera2_hube414db9176dd275c47d877df458214a_87600_e2f6abfdc278adc3eaca809fd0f6d134.webp b/resources/_gen/images/viera2_hube414db9176dd275c47d877df458214a_87600_e2f6abfdc278adc3eaca809fd0f6d134.webp new file mode 100644 index 0000000..729a50b Binary files /dev/null and b/resources/_gen/images/viera2_hube414db9176dd275c47d877df458214a_87600_e2f6abfdc278adc3eaca809fd0f6d134.webp differ diff --git a/resources/_gen/images/vinesauce_huae52fca0d2d6901038b87d8b5fb4876e_67128_d5cbc6dc7a32772919df8ef7b4794e6a.webp b/resources/_gen/images/vinesauce_huae52fca0d2d6901038b87d8b5fb4876e_67128_d5cbc6dc7a32772919df8ef7b4794e6a.webp new file mode 100644 index 0000000..e69de29 diff --git a/resources/_gen/images/working-out_hub994383856df4f25fc5463ba32b5d14e_57046_c5e37be2cd240d9406a0df5e28d2059d.webp b/resources/_gen/images/working-out_hub994383856df4f25fc5463ba32b5d14e_57046_c5e37be2cd240d9406a0df5e28d2059d.webp new file mode 100644 index 0000000..2bca673 Binary files /dev/null and b/resources/_gen/images/working-out_hub994383856df4f25fc5463ba32b5d14e_57046_c5e37be2cd240d9406a0df5e28d2059d.webp differ diff --git a/scripts/gen_art.py b/scripts/gen_art.py index 32feaba..279237f 100644 --- a/scripts/gen_art.py +++ b/scripts/gen_art.py @@ -6,13 +6,15 @@ import json def write_field(f, key, value): f.write(key + ": " + value + "\n") -def parse_art(title, year, date, original_filename, filename, file): +def parse_art(title, year, date, nsfw, original_filename, filename, file): with open(original_filename + '.md', 'w') as f: document = enolib.parse(file) f.write('---\n') - write_field(f, 'title', title) + if title is not None: + write_field(f, 'title', title) + write_field(f, 'layout', 'art-detail') write_field(f, 'filename', '/art/' + filename + '.webp') write_field(f, 'alt_text', "\"" + document.field('Alt Text').required_string_value().replace('\n','') + "\"") @@ -37,13 +39,16 @@ def parse_art(title, year, date, original_filename, filename, file): for tag in document.list('Tags').items(): f.write("- " + tag.required_string_value().lower() + "\n") + if nsfw is not None: + write_field(f, 'nsfw', str(nsfw).lower()) + f.write('---\n') if document.optional_field('Description'): f.write(document.field('Description').required_string_value()) f.write('\n') -def parse_art_piece(json, year, date): +def parse_art_piece(json, year, date, nsfw): filename_without_ext = os.path.splitext(json["filename"])[0] with open(art_output_directory + "/" + filename_without_ext + '.md', 'w') as f: @@ -68,6 +73,9 @@ def parse_art_piece(json, year, date): write_field(f, 'layout', 'art-detail') write_field(f, 'filename', '/art/' + json['filename']) + if nsfw is not None: + write_field(f, 'nsfw', str(nsfw).lower()) + f.write('---\n') art_data_directory = '../art' @@ -140,19 +148,27 @@ with open('../data/art.json', 'r') as f: path = os.path.join(art_data_directory, filename_without_ext + ".eno") + nsfw = None + if "nsfw" in piece.keys(): + nsfw = piece["nsfw"] + + title = None + if "title" in piece.keys(): + title = piece["title"] + if os.path.isfile(path): num_eno = num_eno + 1 with open(path) as f: if "date" in piece.keys(): - parse_art(piece["title"], year["year"], piece["date"], art_output_directory + "/" + filename_without_ext, filename_without_ext, f.read()) + parse_art(title, year["year"], piece["date"], nsfw, art_output_directory + "/" + filename_without_ext, filename_without_ext, f.read()) else: - parse_art(piece["title"], year["year"], None, art_output_directory + "/" + filename_without_ext, filename_without_ext, f.read()) + parse_art(title, year["year"], None, nsfw, art_output_directory + "/" + filename_without_ext, filename_without_ext, f.read()) else: num_noneno = num_noneno + 1 if "date" in piece.keys(): - parse_art_piece(piece, year["year"], piece["date"]) + parse_art_piece(piece, year["year"], piece["date"], nsfw) else: - parse_art_piece(piece, year["year"], None) + parse_art_piece(piece, year["year"], None, nsfw) print("Art coverage: {}/{}".format(num_eno, num_eno + num_noneno)); diff --git a/themes/red/layouts/partials/render-art.html b/themes/red/layouts/partials/render-art.html index e54bdd4..2dbd621 100644 --- a/themes/red/layouts/partials/render-art.html +++ b/themes/red/layouts/partials/render-art.html @@ -16,6 +16,11 @@ {{ $path := printf "/art/%d/%.2d/%s" (int $year) (int $month) $filename_without_ext}} {{ $title := .Params.title }} {{ $image := (resources.Get (printf "art/%s.webp" .Params.slug)).Resize "300x" }} + + {{ if .Params.nsfw }} + {{ $image = $image | images.Filter (images.GaussianBlur 6) (images.Pixelate 8) }} + {{ end }} + {{ with $image }} {{ $title }} {{ else }} @@ -27,3 +32,4 @@ CANNOT FIND {{.Params.slug }} {{ end }} +`