Skip to content

Commit

Permalink
Merge pull request #78 from phel-lang/feat/45-edit-me-links
Browse files Browse the repository at this point in the history
Add "Edit me" links to two-column-layout
  • Loading branch information
Chemaclass committed May 6, 2024
2 parents b196448 + f12a3eb commit e7bebfb
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@ extra_syntaxes_and_themes = ["syntaxes"]
[extra]
# Put all your custom variables here

repo_content_url = "https://github.com/phel-lang/phel-lang.org/blob/master/content/"

4 changes: 4 additions & 0 deletions sass/_one-column-layout.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,7 @@
max-width: 800px;
padding: 2em 2em;
}

.found-a-typo {
float: right;
}
4 changes: 4 additions & 0 deletions templates/layouts/two-column-layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
{% include "navigation/site-navigation.html" %}
</aside>
<main class="two-column-layout__content">
<span class="found-a-typo">
{% set url = config.extra.repo_content_url ~ page.relative_path %}
<a href="{{url}}">Edit me</a>
</span>
{% block content %} {% endblock %}

{% include "footer.html" %}
Expand Down

0 comments on commit e7bebfb

Please sign in to comment.