Remove maxheight param
This commit is contained in:
@@ -354,7 +354,6 @@ The `paige/figure` shortcode provides a figure with content.
|
||||
float="left"
|
||||
height="10rem"
|
||||
horizontal="center"
|
||||
maxheight="10rem"
|
||||
maxwidth="10rem"
|
||||
number=0
|
||||
numbered=false
|
||||
@@ -378,8 +377,6 @@ Parameters:
|
||||
<dd>Optional. String. CSS value. Total height.</dd>
|
||||
<dt><code>horizontal</code></dt>
|
||||
<dd>Optional. String. Horizontal alignment. Must be <code>start</code>, <code>center</code>, or <code>end</code>. Default is <code>center</code>.</dd>
|
||||
<dt><code>maxheight</code></dt>
|
||||
<dd>Optional. String. CSS value. Maximum total height.</dd>
|
||||
<dt><code>maxwidth</code></dt>
|
||||
<dd>Optional. String. CSS value. Maximum total width.</dd>
|
||||
<dt><code>number</code></dt>
|
||||
@@ -495,7 +492,6 @@ The `paige/gallery` shortcode provides a figure with a collection of images.
|
||||
height="10rem"
|
||||
images="*.jpg"
|
||||
justify="center"
|
||||
maxheight="10rem"
|
||||
maxwidth="10rem"
|
||||
method="resize"
|
||||
options="550x webp picture Lanczos"
|
||||
@@ -508,7 +504,6 @@ The `paige/gallery` shortcode provides a figure with a collection of images.
|
||||
caption="My caption"
|
||||
height="10rem"
|
||||
image="me.jpg"
|
||||
maxheight="10rem"
|
||||
maxwidth="10rem"
|
||||
method="resize"
|
||||
options="550x webp picture Lanczos"
|
||||
@@ -519,7 +514,6 @@ The `paige/gallery` shortcode provides a figure with a collection of images.
|
||||
caption="My caption"
|
||||
height="10rem"
|
||||
image="you.jpg"
|
||||
maxheight="10rem"
|
||||
maxwidth="10rem"
|
||||
method="resize"
|
||||
options="550x webp picture Lanczos"
|
||||
@@ -546,8 +540,6 @@ Parameters:
|
||||
<dd>Optional. Position 0. String. Page, site, or remote images glob. Default is all image page resources.</dd>
|
||||
<dt><code>justify</code></dt>
|
||||
<dd>Optional. String. Main axis space distribution. Must be <code>around</code>, <code>between</code>, <code>center</code>, <code>end</code>, <code>evenly</code>, or <code>start</code>. Must not be used when nested.</dd>
|
||||
<dt><code>maxheight</code></dt>
|
||||
<dd>Optional. String. CSS value. Maximum image height.</dd>
|
||||
<dt><code>maxwidth</code></dt>
|
||||
<dd>Optional. String. CSS value. Maximum image width.</dd>
|
||||
<dt><code>method</code></dt>
|
||||
|
@@ -119,22 +119,6 @@ I made a huge tiny mistake. In fact, it was a box of Oscar's legally obtained me
|
||||
|
||||
Code:
|
||||
|
||||
```go-text-template
|
||||
{{</* paige/figure caption="Hickory Dickory Dock" height="5rem" */>}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{</* /paige/figure */>}}
|
||||
```
|
||||
|
||||
Result:
|
||||
|
||||
{{< paige/figure caption="Hickory Dickory Dock" height="5rem" >}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{< /paige/figure >}}
|
||||
|
||||
---
|
||||
|
||||
Code:
|
||||
|
||||
```go-text-template
|
||||
{{</* paige/figure caption="Hickory Dickory Dock" height="20rem" */>}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
@@ -179,38 +163,6 @@ Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{< /paige/figure >}}
|
||||
|
||||
## Maxheight parameter
|
||||
|
||||
Code:
|
||||
|
||||
```go-text-template
|
||||
{{</* paige/figure caption="Hickory Dickory Dock" maxheight="5rem" */>}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{</* /paige/figure */>}}
|
||||
```
|
||||
|
||||
Result:
|
||||
|
||||
{{< paige/figure caption="Hickory Dickory Dock" maxheight="5rem" >}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{< /paige/figure >}}
|
||||
|
||||
---
|
||||
|
||||
Code:
|
||||
|
||||
```go-text-template
|
||||
{{</* paige/figure caption="Hickory Dickory Dock" maxheight="20rem" */>}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{</* /paige/figure */>}}
|
||||
```
|
||||
|
||||
Result:
|
||||
|
||||
{{< paige/figure caption="Hickory Dickory Dock" maxheight="20rem" >}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{< /paige/figure >}}
|
||||
|
||||
## Maxwidth parameter
|
||||
|
||||
Code:
|
||||
@@ -406,13 +358,13 @@ I made a huge tiny mistake. In fact, it was a box of Oscar's legally obtained me
|
||||
Code:
|
||||
|
||||
```go-text-template
|
||||
{{</* paige/figure caption="Hickory Dickory Dock" horizontal="end" maxheight="20rem" maxwidth="10rem" number=7 vertical="center" */>}}
|
||||
{{</* paige/figure caption="Hickory Dickory Dock" height="20rem" horizontal="end" maxwidth="10rem" number=7 vertical="center" */>}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{</* /paige/figure */>}}
|
||||
```
|
||||
|
||||
Result:
|
||||
|
||||
{{< paige/figure caption="Hickory Dickory Dock" horizontal="end" maxheight="20rem" maxwidth="10rem" number=7 vertical="center" >}}
|
||||
{{< paige/figure caption="Hickory Dickory Dock" height="20rem" horizontal="end" maxwidth="10rem" number=7 vertical="center" >}}
|
||||
Hickory dickory dock.<br>The mouse ran up the clock.<br>The clock struck one,<br>The mouse ran down,<br>Hickory dickory dock.
|
||||
{{< /paige/figure >}}
|
||||
|
@@ -7,7 +7,6 @@
|
||||
{{ $gap := $params.gap }}
|
||||
{{ $height := $params.height }}
|
||||
{{ $horizontal := $params.horizontal | default "center" }}
|
||||
{{ $maxheight := $params.maxheight }}
|
||||
{{ $maxwidth := $params.maxwidth }}
|
||||
{{ $number := $params.number }}
|
||||
{{ $numbered := $params.numbered }}
|
||||
@@ -28,10 +27,6 @@
|
||||
{{ $heights = $heights | append (printf "height: %v" $height) }}
|
||||
{{ end }}
|
||||
|
||||
{{ if $maxheight }}
|
||||
{{ $heights = $heights | append (printf "max-height: %v" $maxheight) }}
|
||||
{{ end }}
|
||||
|
||||
{{ $heights = delimit ($heights | sort) "; " }}
|
||||
|
||||
{{ if $maxwidth }}
|
||||
|
@@ -7,7 +7,6 @@
|
||||
{{ $height := $params.height }}
|
||||
{{ $horizontal := $params.horizontal }}
|
||||
{{ $link := $params.link }}
|
||||
{{ $maxheight := $params.maxheight }}
|
||||
{{ $maxwidth := $params.maxwidth }}
|
||||
{{ $method := $params.method }}
|
||||
{{ $number := $params.number }}
|
||||
@@ -47,7 +46,6 @@
|
||||
"float" $float
|
||||
"height" $height
|
||||
"horizontal" $horizontal
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"number" $number
|
||||
"numbered" $numbered
|
||||
|
@@ -7,7 +7,6 @@
|
||||
{{ $fingerprint := $params.fingerprint | default true }}
|
||||
{{ $height := $params.height }}
|
||||
{{ $loading := $params.loading | default "lazy" }}
|
||||
{{ $maxheight := $params.maxheight }}
|
||||
{{ $maxwidth := $params.maxwidth }}
|
||||
{{ $method := $params.method }}
|
||||
{{ $options := $params.options }}
|
||||
@@ -57,11 +56,11 @@
|
||||
{{ $src = $resource.RelPermalink }}
|
||||
{{ end }}
|
||||
|
||||
{{ if and (or $height $maxheight) (not (or $maxwidth $width)) }}
|
||||
{{ if and $height (not (or $maxwidth $width)) }}
|
||||
{{ $width = "auto" }}
|
||||
{{ end }}
|
||||
|
||||
{{ if and (or $maxwidth $width) (not (or $height $maxheight)) }}
|
||||
{{ if and (or $maxwidth $width) (not $height) }}
|
||||
{{ $height = "auto" }}
|
||||
{{ end }}
|
||||
|
||||
@@ -75,16 +74,6 @@
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ if $maxheight }}
|
||||
{{ with printf "max-height: %v" $maxheight }}
|
||||
{{ if $style }}
|
||||
{{ $style = printf "%v; %v" $style . }}
|
||||
{{ else }}
|
||||
{{ $style = . }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ if $maxwidth }}
|
||||
{{ with printf "max-width: %v" $maxwidth }}
|
||||
{{ if $style }}
|
||||
|
@@ -3,7 +3,6 @@
|
||||
{{ $height := .Get "height" }}
|
||||
{{ $horizontal := .Get "horizontal" }}
|
||||
{{ $lang := .Get 0 | default (.Get "lang") | default "plaintext" }}
|
||||
{{ $maxheight := .Get "maxheight" }}
|
||||
{{ $maxwidth := .Get "maxwidth" }}
|
||||
{{ $number := .Get "number" }}
|
||||
{{ $numbered := .Get "numbered" }}
|
||||
@@ -20,7 +19,6 @@
|
||||
"gap" 2
|
||||
"height" $height
|
||||
"horizontal" $horizontal
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"number" $number
|
||||
"numbered" $numbered
|
||||
|
@@ -3,7 +3,6 @@
|
||||
{{ $float := .Get "float" }}
|
||||
{{ $height := .Get "height" }}
|
||||
{{ $horizontal := .Get "horizontal" }}
|
||||
{{ $maxheight := .Get "maxheight" }}
|
||||
{{ $maxwidth := .Get "maxwidth" }}
|
||||
{{ $number := .Get "number" }}
|
||||
{{ $numbered := .Get "numbered" }}
|
||||
@@ -17,7 +16,6 @@
|
||||
"gap" 2
|
||||
"height" $height
|
||||
"horizontal" $horizontal
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"number" $number
|
||||
"numbered" $numbered
|
||||
|
@@ -4,7 +4,6 @@
|
||||
{{ $image := .Get "image" }}
|
||||
{{ $images := .Get 0 | default (.Get "images") }}
|
||||
{{ $justify := .Get "justify" | default "center" }}
|
||||
{{ $maxheight := .Get "maxheight" }}
|
||||
{{ $maxwidth := .Get "maxwidth" }}
|
||||
{{ $method := .Get "method" | default "resize" }}
|
||||
{{ $number := .Get "number" }}
|
||||
@@ -33,7 +32,6 @@
|
||||
"gap" 2
|
||||
"height" $height
|
||||
"link" $link
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"method" $method
|
||||
"options" $options
|
||||
@@ -49,7 +47,6 @@
|
||||
"content" (partial "paige/img.html" (dict
|
||||
"class" "img-fluid"
|
||||
"height" $height
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"method" $method
|
||||
"options" $options
|
||||
@@ -105,7 +102,6 @@
|
||||
"content" (partial "paige/img.html" (dict
|
||||
"class" "img-fluid"
|
||||
"height" $height
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"method" $method
|
||||
"options" $options
|
||||
@@ -129,7 +125,6 @@
|
||||
"content" (partial "paige/img.html" (dict
|
||||
"class" "img-fluid"
|
||||
"height" $height
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"method" $method
|
||||
"options" $options
|
||||
|
@@ -4,7 +4,6 @@
|
||||
{{ $height := .Get "height" }}
|
||||
{{ $horizontal := .Get "horizontal" }}
|
||||
{{ $link := .Get "link" }}
|
||||
{{ $maxheight := .Get "maxheight" }}
|
||||
{{ $maxwidth := .Get "maxwidth" }}
|
||||
{{ $method := .Get "method" }}
|
||||
{{ $number := .Get "number" }}
|
||||
@@ -24,7 +23,6 @@
|
||||
"height" $height
|
||||
"horizontal" $horizontal
|
||||
"link" $link
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"method" $method
|
||||
"number" $number
|
||||
|
@@ -3,7 +3,6 @@
|
||||
{{ $float := .Get "float" }}
|
||||
{{ $height := .Get "height" }}
|
||||
{{ $horizontal := .Get "horizontal" }}
|
||||
{{ $maxheight := .Get "maxheight" }}
|
||||
{{ $maxwidth := .Get "maxwidth" }}
|
||||
{{ $number := .Get "number" }}
|
||||
{{ $numbered := .Get "numbered" }}
|
||||
@@ -18,7 +17,6 @@
|
||||
"float" $float
|
||||
"height" $height
|
||||
"horizontal" $horizontal
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"number" $number
|
||||
"numbered" $numbered
|
||||
|
@@ -13,7 +13,6 @@
|
||||
{{ $horizontal := .Get "horizontal" }}
|
||||
{{ $keyboard := .Get "keyboard" | default true }}
|
||||
{{ $loop := .Get "loop" }}
|
||||
{{ $maxheight := .Get "maxheight" }}
|
||||
{{ $maxwidth := .Get "maxwidth" }}
|
||||
{{ $muted := .Get "muted" }}
|
||||
{{ $number := .Get "number" }}
|
||||
@@ -130,7 +129,6 @@
|
||||
"gap" 2
|
||||
"height" $height
|
||||
"horizontal" $horizontal
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"number" $number
|
||||
"numbered" $numbered
|
||||
|
@@ -9,7 +9,6 @@
|
||||
{{ $horizontal := .Get "horizontal" }}
|
||||
{{ $list := .Get "list" }}
|
||||
{{ $loop := .Get "loop" }}
|
||||
{{ $maxheight := .Get "maxheight" }}
|
||||
{{ $maxwidth := .Get "maxwidth" }}
|
||||
{{ $mute := .Get "mute" }}
|
||||
{{ $number := .Get "number" }}
|
||||
@@ -84,7 +83,6 @@
|
||||
"gap" 2
|
||||
"height" $height
|
||||
"horizontal" $horizontal
|
||||
"maxheight" $maxheight
|
||||
"maxwidth" $maxwidth
|
||||
"number" $number
|
||||
"numbered" $numbered
|
||||
|
Reference in New Issue
Block a user