Multiple enhancements and bugfixes
!Breaking change! - The updated version will not be able to read your old database file Major improvements: - Added editable pastas - Added private pastas - Added line numbers - Added support for wide mode (1080p instead of 720p) - Added syntax highlighting support - Added read-only mode - Added built-in help page - Added option to remove logo, change title and footer text Minor improvements: - Improved looks in pure html mode - Removed link to GitHub repo from navbar - Broke up 7km long main.rs file into smaller modules - Moved water.css into a template instead of serving it as an external resource - Made Save button a bit bigger - Updated README.MD Bugfixes: - Fixed a bug where an incorrect animal ID in a request would cause a crash - Fixed a bug where an empty or corrupt JSON database would cause a crash
This commit is contained in:
parent
1c873d23b5
commit
4cc737731a
27 changed files with 1343 additions and 494 deletions
|
@ -1,9 +1,44 @@
|
|||
{% include "header.html" %}
|
||||
<a style="margin-right: 0.5rem" href="/raw/{{pasta.id_as_animals()}}">Raw Text Content</a>
|
||||
<a style="margin-right: 0.5rem" href="/raw/{{pasta.id_as_animals()}}">Raw Text Content</a>
|
||||
{% if pasta.file != "no-file" %}
|
||||
<a style="margin-right: 0.5rem; margin-left: 0.5rem" href="/file/{{pasta.id_as_animals()}}/{{pasta.file}}">Attached file '{{pasta.file}}'</a>
|
||||
<a style="margin-right: 0.5rem; margin-left: 0.5rem" href="/file/{{pasta.id_as_animals()}}/{{pasta.file}}">Attached file
|
||||
'{{pasta.file}}'</a>
|
||||
{%- endif %}
|
||||
{% if pasta.editable %}
|
||||
<a style="margin-right: 0.5rem; margin-left: 0.5rem" href="/edit/{{pasta.id_as_animals()}}">Edit</a>
|
||||
{%- endif %}
|
||||
<a style="margin-right: 0.5rem; margin-left: 0.5rem" href="/remove/{{pasta.id_as_animals()}}">Remove</a>
|
||||
<pre><code>{{pasta}}</code></pre>
|
||||
{% if args.highlightsyntax %}
|
||||
<pre><code>{{pasta.content_syntax_highlighted()}}</code></pre>
|
||||
{%- else %}
|
||||
<pre><code>{{pasta.content_not_highlighted()}}</code></pre>
|
||||
{%- endif %}
|
||||
|
||||
<style>
|
||||
code-line {
|
||||
counter-increment: listing;
|
||||
text-align: right;
|
||||
float: left;
|
||||
clear: left;
|
||||
}
|
||||
|
||||
code-line::before {
|
||||
content: counter(listing);
|
||||
display: inline-block;
|
||||
float: left;
|
||||
padding-left: auto;
|
||||
margin-left: auto;
|
||||
text-align: left;
|
||||
width: 1.6rem;
|
||||
border-right: 1px solid lightgrey;
|
||||
color: grey;
|
||||
margin-right: 0.4rem;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
{% include "footer.html" %}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue