Skip to content

Commit

Permalink
Fix #1908: Add tags amount option (#662)
Browse files Browse the repository at this point in the history
  • Loading branch information
stevenjoezhang authored Mar 7, 2019
1 parent 1312c49 commit 71d5980
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,7 @@ tagcloud:
enable: false

# All values below are same as default, change them by yourself
amount: 200 # amount of tags, set `enable` to `true` and edit this option if you have more than 200 tags
min: 12 # min font size in px
max: 30 # max font size in px
start: '#ccc' # start color (hex, rgba, hsla or color keywords)
Expand Down
4 changes: 2 additions & 2 deletions layout/page.swig
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@
</div>
<div class="tag-cloud-tags">
{% if not theme.tagcloud %}
{{ tagcloud({min_font: 12, max_font: 30, amount: 300, color: true, start_color: '#ccc', end_color: '#111'}) }}
{{ tagcloud({min_font: 12, max_font: 30, amount: 200, color: true, start_color: '#ccc', end_color: '#111'}) }}
{% else %}
{{ tagcloud({min_font: theme.tagcloud.min, max_font: theme.tagcloud.max, amount: 300, color: true, start_color: theme.tagcloud.start, end_color: theme.tagcloud.end}) }}
{{ tagcloud({min_font: theme.tagcloud.min, max_font: theme.tagcloud.max, amount: theme.tagcloud.amount, color: true, start_color: theme.tagcloud.start, end_color: theme.tagcloud.end}) }}
{% endif %}
</div>
</div>
Expand Down

0 comments on commit 71d5980

Please sign in to comment.