This fixes an issue when the website is deployed to a subdirectory of
the web server (e.g., `SITEURL` is set to a value like
`https://example.com/john.doe/`).
With this commit, `.sidebar-nav` is renamed to `.sidebar-social`. Then a
new class `.sidebar-nav` is created and used for the menu items. This
change more or less restores `.sidebar-nav` originally was in the
`hyde.css` file.
Since `DISPLAY_PAGES_ON_MENU` defaults to `True`, this commit will
modify the appearance of your site. To go back to the previous behavior,
add this to your pelicanconf.py:
DISPLAY_PAGES_ON_MENU = False
References:
- <https://docs.getpelican.com/en/stable/settings.html#basic-settings>
- <https://docs.getpelican.com/en/stable/settings.html#MENUITEMS>
In 16e3058, a FONT_AWESOME setting was introduced and used as such:
"https://kit.fontawesome.com/{{ FONT_AWESOME }}.js"
Also in 16e3058, the default way to fetch Font Awesome was changed to
Javascript (before we used to load is as CSS).
The present commit does several changes:
- Revert the default back to CSS (instead of JS), as I think that for a
font, there's no need for Javascript. A font is a static asset, so
it's enough to load it as a static CSS file, both for privacy and
security. Also, think about those who disable JS in their browser.
- Remove the `FONT_AWESOME` setting, as it's a bit too limiting to force
users into `kit.fontawesome.com`, it doesn't leave much space for
configuration.
- Instead, introduce two variables `FONT_AWESOME_CSS` and
`FONT_AWESOME_JS`, so that users have more freedom to define how they
want to load the Font Awesome.
- Use Fork Awesome as the default, if no setting is given by user.
Meaning that we get back to the `fa` css classes (instead of `fas` or
`fab`)
Per https://docs.getpelican.com/en/stable/settings.html#feed-settings:
FEED_DOMAIN = None, i.e. base URL is "/"
The domain prepended to feed URLs. Since feed URLs should always be
absolute, it is highly recommended to define this (e.g.,
“https://feeds.example.com”). If you have already explicitly defined
SITEURL (see above) and want to use the same domain for your feeds, you
can just set: FEED_DOMAIN = SITEURL.
Using `href="{{ FEED_DOMAIN }}/{{ FEED_ALL_ATOM }}"` in the template
seems to be the right way to do things, by looking at other themes, eg
the default theme in Pelican itself:
https://github.com/getpelican/pelican/blob/master/pelican/themes/simple/templates/base.html
Obviously, this change might break things for some users of the theme.
If someone used to have this definition in `publishconf.py`:
FEED_ALL_ATOM = SITEURL + '/feeds/all.atom.xml'
Then they should update to:
FEED_DOMAIN = SITEURL
FEED_ALL_ATOM = 'feeds/all.atom.xml'