jekyll-heroicons 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/README.md +4 -2
- data/lib/jekyll-heroicons/version.rb +1 -1
- data/lib/jekyll-heroicons.rb +6 -2
- 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: 1dae35ec57464428cb9ef7b5a914489ed06fa4f0f0be2ad43bacfd4845447b34
|
4
|
+
data.tar.gz: d577ef931e1ea5cae714f6a185f1666d870617e8eeceb8cdc43c6d07c9105b33
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 22753cd62b78f18d50b0619a5adb8de03d1a636129c3eba68d9bc8f857cc1770b54d114b1617de71e835b0df38024b2054c9857ce8bf170dd4adc341b6739dfd
|
7
|
+
data.tar.gz: 4bd29bcfc2442e0828a717e2430b8f9b915d0420a6ca8fbfda41231b8fa328fb5275f752a113c204c173b230652cd4d41d79972b9e2f4b36612ad78ca1687984
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,9 @@
|
|
1
1
|
# Jekyll-Heroicons
|
2
2
|
|
3
|
+
## 0.4.1
|
4
|
+
- Don't reload configuration on every change
|
5
|
+
- Improve comments and code around picking default variants.
|
6
|
+
|
3
7
|
## 0.4.0
|
4
8
|
- Add default variant as solid.
|
5
9
|
- Adding "disable_default_class" attribute to a tag, to avoid adding default classes to the icon.
|
data/README.md
CHANGED
@@ -10,6 +10,8 @@ This gem has no official affiliation with Tailwind CSS or the Heroicons team. Ch
|
|
10
10
|
|
11
11
|
This is heavily inspired by https://github.com/jclusso/heroicons
|
12
12
|
|
13
|
+
If you are looking to build a Jekyll website with Tailwind and no-build, take a look at [Jekyll CLI Template](https://github.com/skatkov/jekyll-tailwind-cli-template) that contains already this gem.
|
14
|
+
|
13
15
|
## Installation
|
14
16
|
|
15
17
|
1. Add this to `Gemfile`:
|
@@ -79,7 +81,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
79
81
|
|
80
82
|
## Contributing
|
81
83
|
|
82
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
84
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/skatkov/jekyll-heroicons. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/skatkov/jekyll-heroicons/blob/master/CODE_OF_CONDUCT.md).
|
83
85
|
|
84
86
|
## License
|
85
87
|
|
@@ -87,4 +89,4 @@ The gem is available as open source under the terms of the [MIT License](https:/
|
|
87
89
|
|
88
90
|
## Code of Conduct
|
89
91
|
|
90
|
-
Everyone interacting in the Jekyll::Heroicons project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/
|
92
|
+
Everyone interacting in the Jekyll::Heroicons project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/skatkov/jekyll-heroicons/blob/master/CODE_OF_CONDUCT.md).
|
data/lib/jekyll-heroicons.rb
CHANGED
@@ -13,6 +13,9 @@ module Jekyll
|
|
13
13
|
File.dirname(__dir__)
|
14
14
|
end
|
15
15
|
|
16
|
+
# In case no variant is specified, use solid as default
|
17
|
+
DEFAULT_VARIANT = "solid"
|
18
|
+
|
16
19
|
# Syntax for the heroicon symbol
|
17
20
|
SYNTAX = /\A(#{Liquid::VariableSignature}+)/
|
18
21
|
|
@@ -44,7 +47,7 @@ module Jekyll
|
|
44
47
|
private
|
45
48
|
|
46
49
|
def config
|
47
|
-
|
50
|
+
@@config ||= begin
|
48
51
|
Jekyll.configuration.dig("heroicons")
|
49
52
|
rescue NoMethodError
|
50
53
|
{}
|
@@ -58,13 +61,14 @@ module Jekyll
|
|
58
61
|
prepend_default_classes
|
59
62
|
end
|
60
63
|
|
64
|
+
# This method checks if heroicons liquid tag has a variant specified. If not, it check default variant in the config file. If both of those are not defined, it falls back to the default variant.
|
61
65
|
def variant(markup)
|
62
66
|
if @options.key?(:variant)
|
63
67
|
@options[:variant]
|
64
68
|
elsif config["variant"]
|
65
69
|
config["variant"]
|
66
70
|
else
|
67
|
-
|
71
|
+
DEFAULT_VARIANT
|
68
72
|
end
|
69
73
|
end
|
70
74
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-heroicons
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stanislav (Stas) Katkov
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-11-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jekyll
|