add 'edit this page' button; closes #1004

This commit is contained in:
Dean Attali 2022-07-07 18:00:37 +00:00
parent f2c2a4b810
commit 33032c4895
3 changed files with 10 additions and 0 deletions

View file

@ -1,6 +1,7 @@
## Unreleased version
- Added `post_search` config setting that creates a Search button in the navbar (older websites need to set `post_search: true` to enable this feature) (#770)
- Added `edit_page_button` config setting that adds a "Edit page" button to the footer (to edit the current page on GitHub) (#1004)
- BREAKING CHANGE: More control over RSS feed sharing: previously, an RSS feed was *always* generated, and if the config setting `rss-description` was set then there was an RSS icon in the footer. Now, an RSS feed is only generated when the config setting `rss-description` exists, and an RSS footer icon is only shown if `rss: true` is set in the `social-network-links` config settings
- Fixed page titles, subtitles, and excerpts rendering correctly when there are special characeters in them (#856)
- Slightly reworked margins and position for avatar image to resolve an alignment issue on Safari.

View file

@ -96,6 +96,9 @@ feed_show_tags: true
# Add a search button to the navbar
post_search: true
# Add a button in the footer to edit the current page. Only works if your website is hosted on GitHub
edit_page_button: true
# The keywords to associate with your website, for SEO purposes
#keywords: "my,list,of,keywords"

View file

@ -30,6 +30,12 @@
<a href="http://{{- site.matomo.uri -}}/index.php?module=CoreAdminHome&action=optOut" target="_blank" class="text_muted">Do-not-Track</a>
{% endif %}
{% endif%}
{% if site.edit_page_button and site.github.repository_url %}
&nbsp;&bull;&nbsp;
<a title="Edit this page on GitHub" href="{{ site.github.repository_url }}/edit/{{ site.github.source.branch }}/{{ page.path }}" class="text_muted">Edit page</a>
{% endif%}
</p>
{% unless site.remove-ads %}<p class="theme-by text-muted">
Powered by