jekyll-theme-amethyst 2.9.0 → 2.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/_includes/sidebar.html +2 -1
- data/_sass/amethyst.scss +1 -6
- data/lib/jekyll-theme-amethyst.rb +32 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1b22d1bb69031cfc035ce2b6cf25bbac1e102680c6273cb48720be2d47a5edbf
|
4
|
+
data.tar.gz: 1ed0d004d5325d317b6390f353e9688847c341a6b84d1d82c96e3c4c0b2396a2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 23d463c73ad25d5d2377ac14940511eec40cf1802b5f05b33a36a5868368101a83f49ba69878b0689ab1ed66f698e999ddfdf3898cc49043504c94aacdf43a47
|
7
|
+
data.tar.gz: '09b564b23fe54a9b5c72434087807a0c28518dfd83578a9a29a0c464b5b1720c40350f3ad96d2971aafc46a85b068abc900709e0df481992c5162cfbaf43e5d7'
|
data/_includes/sidebar.html
CHANGED
@@ -73,7 +73,8 @@ Block data:
|
|
73
73
|
{%- elsif block_type == "recent" -%}
|
74
74
|
{%- assign group_page = site.pages | where: "layout", "posts" | first -%}
|
75
75
|
{%- assign block_url = block.url | default: group_page.url -%}
|
76
|
-
{%- assign
|
76
|
+
{%- assign tags_excluded = site.pages | where: "layout", "posts-tag" | where: "amethyst.exclude_tag_from_recent", true | map: "tag" %}
|
77
|
+
{%- assign block_contents = site.posts | reject_include: "tags", tags_excluded | slice: 0, 5 -%}
|
77
78
|
{%- elsif block_type == "archive" -%}
|
78
79
|
{%- assign block_contents = site.pages | where: "layout", "posts-year" | sort_natural: 'date' | reverse -%}
|
79
80
|
{%- assign group_page = site.pages | where: "layout", "posts-archive" | first -%}
|
data/_sass/amethyst.scss
CHANGED
@@ -145,7 +145,7 @@ hr {
|
|
145
145
|
}
|
146
146
|
|
147
147
|
iframe {
|
148
|
-
width: 100%;
|
148
|
+
max-width: 100%;
|
149
149
|
border: 1px solid #ddd;
|
150
150
|
border-radius: 3px;
|
151
151
|
}
|
@@ -698,11 +698,6 @@ typesense-minibar input[type="search"] {
|
|
698
698
|
text-align: center;
|
699
699
|
}
|
700
700
|
|
701
|
-
.example-result iframe,
|
702
|
-
.example-result pre {
|
703
|
-
height: 360px;
|
704
|
-
}
|
705
|
-
|
706
701
|
/* Layout: post, posts */
|
707
702
|
|
708
703
|
article > header {
|
@@ -1,3 +1,6 @@
|
|
1
|
+
require "digest"
|
2
|
+
require "set"
|
3
|
+
|
1
4
|
# The "file_version_query" Liquid filter appends a query parameter with a file hash.
|
2
5
|
#
|
3
6
|
# Example: Basic
|
@@ -16,9 +19,29 @@
|
|
16
19
|
# <link href="/assets/style.css?v=01234567">
|
17
20
|
# ```
|
18
21
|
#
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
+
# The "reject_include" Liquid filter applies to an iterable collection of items
|
23
|
+
# that may have a given `property` with an array as value. It removes items
|
24
|
+
# where `property` contains one or more values from `values`.
|
25
|
+
#
|
26
|
+
# This is similar to the built-in "where" filter, except negated, and for array
|
27
|
+
# properties rather than string properties.
|
28
|
+
#
|
29
|
+
# Example: Exclude posts where "tags" contains an excluded tag
|
30
|
+
#
|
31
|
+
# ```
|
32
|
+
# tags_excluded = [ "foo", "bar" ]
|
33
|
+
# posts = [
|
34
|
+
# { id: 1 }, // property may not exist
|
35
|
+
# { id: 2, tags: [ "quux" ] }, // property does not include "foo" or "bar"
|
36
|
+
# { id: 2, tags: [ "quux", "bar" ] // rejected
|
37
|
+
# }
|
38
|
+
# filtered = posts | reject_include: "tags", tags_excluded
|
39
|
+
#
|
40
|
+
# filtered === [
|
41
|
+
# { id: 1 },
|
42
|
+
# { id: 2, tags: [ "quux" ] }
|
43
|
+
# }
|
44
|
+
# ```
|
22
45
|
module Jekyll
|
23
46
|
module AmethystFilters
|
24
47
|
def file_version_query(input, *filenames)
|
@@ -34,6 +57,12 @@ module Jekyll
|
|
34
57
|
hex = hexes.length > 1 ? Digest::MD5.hexdigest(hexes.join(" ")) : hexes[0]
|
35
58
|
"#{input}?v=#{hex[0..7]}"
|
36
59
|
end
|
60
|
+
def reject_include(input, property, values)
|
61
|
+
ary = Liquid::StandardFilters::InputIterator.new(input)
|
62
|
+
ary.reject do |item|
|
63
|
+
values.intersect? item[property]
|
64
|
+
end
|
65
|
+
end
|
37
66
|
end
|
38
67
|
end
|
39
68
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-theme-amethyst
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.10.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Timo Tijhof
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2025-10-
|
12
|
+
date: 2025-10-07 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: jekyll
|