Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Amount option to tagcloud #662

Merged
merged 3 commits into from
Mar 7, 2019
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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'}) }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

default 300 -> 200?

{% 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