From 3fdf06ced74fdc63de9fcadbdfb8f4677bdccb2a Mon Sep 17 00:00:00 2001 From: "Mark W. Kidd" Date: Mon, 17 Feb 2025 13:46:23 -0500 Subject: [PATCH] add gallery css --- _includes/embed_image.html | 6 ++++-- _sass/custom/custom.scss | 6 ++++++ growing/harvesting.md | 12 ++++++------ growing/selection.md | 6 +++--- growing/site-and-planting.md | 2 +- growing/thinning.md | 4 ++-- index.md | 2 +- recipes/cushaw-pumpkin-pie.md | 2 +- recipes/roasted-cushaw-and-puree.md | 16 ++++++++-------- resources.md | 2 +- 10 files changed, 33 insertions(+), 25 deletions(-) diff --git a/_includes/embed_image.html b/_includes/embed_image.html index 4116451..bb6dce4 100644 --- a/_includes/embed_image.html +++ b/_includes/embed_image.html @@ -8,6 +8,7 @@ {%- assign img-style = false -%} {%- assign img-src = false -%} {%- assign img-link = false -%} +{%- assign display-mode = false -%} {%- if include.width or include.height -%} {%- assign img-style = true -%} @@ -36,11 +37,12 @@ {%- else -%} {% assign img-link = downcase-link | relative_url %} {%- endif -%} -{%- elsif include.thumbnail == "true" -%} +{%- elsif include.mode == "thumbnail" or include.mode == "gallery" -%} {%- assign img-link = img-src -%} + {%- assign display-mode = {{include.mode}} -%} {%- endif -%} -
+
{%- if img-link -%} diff --git a/_sass/custom/custom.scss b/_sass/custom/custom.scss index 13ed1da..a95f407 100644 --- a/_sass/custom/custom.scss +++ b/_sass/custom/custom.scss @@ -176,6 +176,12 @@ footer { width: calc(33% - 1rem); } +.gallery { + float: left; + margin: 0.5rem 0.5rem 0 0; + width: calc(33% - 1rem); +} + .clear-right { clear: right; } diff --git a/growing/harvesting.md b/growing/harvesting.md index d94bc96..4303615 100644 --- a/growing/harvesting.md +++ b/growing/harvesting.md @@ -62,39 +62,39 @@ Winter squash cushaws can be cut and frozen raw. You might store a large fruit f {: .important } >Select for good "winter squash" traits such as good eating quality and long storage by saving seeds from the best-tasting, longest-lasting fruits. -## Gallery +## Image gallery {% include embed_image.html src="assets/images/growing/immature-c-argyrosperma-fruit-early.jpg" alt="A young C. argyrosperma cushaw fruit grows on the vine with female flower still attached." - thumbnail="true" + mode="gallery" caption="An immature cushaw near the earliest possible use as a summer squash" %} {% include embed_image.html src="assets/images/growing/immature-c-argyrosperma-fruit-late.jpg" alt="A young C. argyrosperma cushaw fruit grows on the vine" - thumbnail="true" + mode="gallery" caption="An immature cushaw near the end of the harvest window for use as summer squash." %} {% include embed_image.html src="assets/images/growing/c-argyrosperma-near-harvest.jpg" alt="A cushaw nears full size, hanging from the vine" - thumbnail="true" + mode="gallery" caption="The peduncle is starting to turn corky, but is still fleshy and hydrated. Therefore the fruit is not fully mature." %} {% include embed_image.html src="assets/images/growing/c-argyrosperma-harvest-peduncle.jpg" alt="A corky cushaw peduncle, 2 inches long, on a squash in storage" - thumbnail="true" + mode="gallery" caption="1-3 inches of peduncle should be left attached to each harvested fruit." %} {% include embed_image.html src="assets/images/growing/c-argyrsperma-fruit-in-storage.jpg" alt="A loose pile of cushaw squash in storage" - thumbnail="true" + mode="gallery" caption="Cushaw squash stored indoors over the winter." %} \ No newline at end of file diff --git a/growing/selection.md b/growing/selection.md index 6aac91f..8c382dc 100644 --- a/growing/selection.md +++ b/growing/selection.md @@ -61,18 +61,18 @@ Pollen is transferred by insects or humans from male flowers to female flowers i [Sprouted Garden has a useful article about squash pollination](https://sproutedgarden.com/hand-pollinate-squash/), including manual pollination, with side-by-side photos of female and male flowers. Pollination information written for any of the domesticated squash species in the Cucurbita genus can be applied to cushaws. -## Gallery +## Image gallery {% include embed_image.html src="assets/images/growing/c-argyrosperma-male-flower.jpg" alt="Male cushaw flower on the vine" caption="This male flower of C. argyrosperma could be collected for manual pollination." - thumbnail="true" + mode="gallery" %} {% include embed_image.html src="assets/images/growing/immature-c-argyrosperma-fruit-early.jpg" alt="Very young cushaw fruit with flower still attached" caption="The female flower can be identified because it grows with the fruit attached. This flower was likely fertilized within the last 48 hours." - thumbnail="true" + mode="gallery" %} \ No newline at end of file diff --git a/growing/site-and-planting.md b/growing/site-and-planting.md index 2c5dc6a..eecd452 100644 --- a/growing/site-and-planting.md +++ b/growing/site-and-planting.md @@ -34,7 +34,7 @@ Cushaw vines can benefit from fertile soil and amendments like aged compost, but {% include embed_image.html src="assets/images/growing/microbial-course-cover.jpg" alt="A cross section showing extensive roots under a seedling" - thumbnail="true" + mode="thumbnail" caption="Free Course: How Microbes Help Local Adaptation" link="https://goingtoseed.org/products/1734455" %} diff --git a/growing/thinning.md b/growing/thinning.md index c4f4ceb..aa09bac 100644 --- a/growing/thinning.md +++ b/growing/thinning.md @@ -42,11 +42,11 @@ Use scissors or secateurs to cut the vine just above the soil to avoid disturbin Squash plants can provide you with food even before the first fruit has matured. If you’ve been fortunate and have too many seedlings, try eating the culled plants. The section on _Harvesting_ includes more information about using the cushaw plants for shoots and greens. -## Gallery +## Image gallery {% include embed_image.html src="assets/images/growing/c-argyrosperma-thinning-size.jpg" alt="A healthy young vine with two sets of true leaves" - thumbnail="true" + mode="gallery" caption="A healthy young vine has just produced its second set of true leaves. This vine would be kept if there is room." %} \ No newline at end of file diff --git a/index.md b/index.md index 20f648d..b9db9c4 100644 --- a/index.md +++ b/index.md @@ -13,7 +13,7 @@ This guide is intended to help people grow, use, and save seeds from tasty, nutr {% include embed_image.html src="assets/images/zine-cover-1200x1400.jpg" alt="Front cover of the printed zine version" - thumbnail="true" + mode="thumbnail" link="/resources" caption="Browse or download the zine version of this guide." %} diff --git a/recipes/cushaw-pumpkin-pie.md b/recipes/cushaw-pumpkin-pie.md index 4b06dbe..06abcd0 100644 --- a/recipes/cushaw-pumpkin-pie.md +++ b/recipes/cushaw-pumpkin-pie.md @@ -50,5 +50,5 @@ Pies should be stored in the refrigerator and will keep for a few days. You can src="/assets/images/recipes/cushaw-pumpkin-pie/cushaw-pumpkin-pie.jpg" alt="Two cushaw pumpkin pies cooling in the oven." caption="In areas where cushaws are traditionally grown they are often the 'pumpkin' in pumpkin pies." - thumbnail="true" + mode="gallery" %} diff --git a/recipes/roasted-cushaw-and-puree.md b/recipes/roasted-cushaw-and-puree.md index 8022c44..f790c48 100644 --- a/recipes/roasted-cushaw-and-puree.md +++ b/recipes/roasted-cushaw-and-puree.md @@ -56,54 +56,54 @@ Raw squash pieces and puree can both be frozen. For a large winter squash fruit, src="assets/images/growing/c-argyrosperma-cut-fruit-with-seeds.jpg" alt="Saved seeds in a colander." caption="Saving the seeds from fruits with good qualities." - thumbnail="true" + mode="gallery" %} {% include embed_image.html src="assets/images/recipes/roasted-cushaw-puree/cut-cushaw-neck.jpg" alt="The cut neck of a large cushaw squash fruit" caption="The dense flesh of the neck is processed separately from the flesh around the seed cavity." - thumbnail="true" + mode="gallery" %} {% include embed_image.html src="assets/images/recipes/roasted-cushaw-puree/cushaw-pumpkin-pieces.jpg" alt="The cut neck of a large cushaw squash fruit." caption="The dense flesh of the neck is processed separately from the flesh around the seed cavity." - thumbnail="true" + mode="gallery" %} {% include embed_image.html src="assets/images/recipes/roasted-cushaw-puree/cutting-hardshell-cushaw.jpg" alt="Squash with hard shells are difficult to cut." caption="Cutting the flesh of a hardshell fruit starting from the inside allows the cook to use their hands to split the pieces if the knife doesn't completely separate the rind." - thumbnail="true" + mode="gallery" %} {% include embed_image.html src="assets/images/recipes/roasted-cushaw-puree/pre-roasting-cushaw-tray.jpg" alt="Pieces of cut squash, coated in oil and salt, laid with the inside down on aluminum foil or parchment paper." caption="Place the fruit pieces with the inside down on paper or aluminum foil plus a light coating of oil and salt." - thumbnail="true" + mode="gallery" %} {% include embed_image.html src="assets/images/recipes/roasted-cushaw-puree/roasted-cushaw-tray.jpg" alt="Roasted cushaw pieces after approximately an hour roasting in the oven." caption="These cushaw pieces are finished roasting." - thumbnail="true" + mode="gallery" %} {% include embed_image.html src="assets/images/recipes/roasted-cushaw-puree/scooping-cushaw-puree.jpg" alt="Scooping roasted cushaw into bowl." caption="A large spoon, or in this case an ice cream scoop, can be used to separate the cooked flesh." - thumbnail="true" + mode="gallery" %} {% include embed_image.html src="assets/images/recipes/roasted-cushaw-puree/cushaw-puree-in-freezer-bag.jpg" alt="Finished cushaw puree in a labelled freezer bag." caption="Surplus puree can be frozen for later use." - thumbnail="true" + mode="gallery" %} diff --git a/resources.md b/resources.md index 6496639..348c136 100644 --- a/resources.md +++ b/resources.md @@ -21,7 +21,7 @@ You can browse the embedded digital copy of the zine below, or access one of the {% include embed_image.html src="assets/images/zine-cover-cropped-1400x430.jpg" alt="Front cover of the printed zine version" - thumbnail="true" + mode="thumbnail" link="https://heyzine.com/flip-book/c5d5b4b224.html" caption="The interactive digital version is formatted by HeyZine" %}