From 75c0cf2fc3616f175ec19939818507d89c02d548 Mon Sep 17 00:00:00 2001 From: "max.mehl" Date: Mon, 9 Mar 2020 14:59:10 +0100 Subject: [PATCH] improve size classes --- README.md | 2 +- static/css/snap-gallery.css | 12 ++++++++---- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 67638c3..8800e6e 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,7 @@ Specifying your image files: Optional parameters: - All the [features/parameters](https://gohugo.io/content-management/shortcodes/#figure) of Hugo's built-in `figure` shortcode work as normal, i.e. src, link, rel, title, caption, class, attr (attribution), attrlink, alt. width and height might lead to strange results when used inside `{{< gallery >}}`. -- `class` allows you to set any custom classes you want on the `
` tag. The values `no-border`, `small`, `medium`, `pull-left` and `pull-right` are made available by this project. +- `class` allows you to set any custom classes you want on the `
` tag. The values `no-border`, `sm`, `md`, `lg`, `pull-left` and `pull-right` are made available by this project. - `lightbox` allows you to control the lightbox. The value `none` will disable the lightbox completely. Optional parameters work for standalone `{{< figure >}}` shortcodes and inside of `{{< gallery >}}`. However, they cannot be applied to `{{< snap-dir >}}`. diff --git a/static/css/snap-gallery.css b/static/css/snap-gallery.css index 9993a4b..ca9e5ca 100644 --- a/static/css/snap-gallery.css +++ b/static/css/snap-gallery.css @@ -27,12 +27,16 @@ figure img { max-height: 100%; } -figure.small img { - max-height: 150px; +figure.sm { + max-width: 30%; } -figure.medium img { - max-height: 225px; +figure.md { + max-width: 50%; +} + +figure.lg { + max-width: 70%; } figure.pull-right {