pelican-themes icon indicating copy to clipboard operation
pelican-themes copied to clipboard

gum theme: tags not listing

Open stuaxo opened this issue 6 years ago • 6 comments

Not sure if this is a duple of #526.

Using an install from git with the gum theme there is no tag cloud displaying.

screenshot from 2017-10-10 17-13-36

stuaxo avatar Oct 10 '17 16:10 stuaxo

I had the same error. When I was investigating the sidebar template on gum I found that it get the tags from a tag_cloud element. So, you have to install and use the tag_cloud plugin to works properly. If you don't want to use it:

  • Run pelican-themes --remove gum
  • Go to the sidebar.html in the gum folder and switch tag_cloud to tags
  • Then install it again

iuryt avatar Oct 20 '17 12:10 iuryt

Gum should probably not display the "Tags" header if the plugin is not available, the requirement for tag_cloud should be in the README.

Are there differences between tag_cloud and tags?
Maybe Gum should switch to tags ?

stuaxo avatar Oct 20 '17 20:10 stuaxo

The tag_cloud plugin seems to be the current way of doing this so I've added a patch to document installing it.

stuaxo avatar Oct 24 '17 14:10 stuaxo

@iuryt & @stuaxo

I had the same kind of result

To hide Tags when you have no tag in templates/sidebar.html

you could move

<h4>Tags</h4>

after

{% if tags and tags %}

and add |length > 1

to the if

the result should be something like this


{% if tags and tags|length > 1 %}
<h4>Tags</h4>

which is result of copying the IF categories for tags

JOduMonT avatar Nov 23 '17 15:11 JOduMonT

The 'tag_cloud' to 'tags' method really helps, thanks!

dakshsriv avatar Jul 25 '21 20:07 dakshsriv

Pip installing the pelican tag cloud worked for me.

python -m pip install pelican-tag-cloud make html pelican --listen

Source: https://github.com/pelican-plugins/tag-cloud

amitshankar avatar Feb 11 '22 21:02 amitshankar