-
-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide "you are logged in" UI element #5
Comments
No obvious hooks in https://github.com/simonw/datasette/blob/master/datasette/templates/base.html - also the Datasette design doesn't actually have any universal navigation that would be a good fit for a "you are logged in as" widget. Not obvious how to proceed with this one. |
For the moment I could put this in the footer? That's not easy to customize right now - it's hard-coded into the |
If I'm going to need to modify the core templates for this anyway, it's probably time to introduce a universal navigation bar at the top of the page, rather than mess around too much with the footer. It's fine to couple this to a new Datasette release because this plugin already uses a new plugin hook which will need to be released with Datasette 0.29. |
Here's a {% extends "default:base.html" %}
{% block extra_head %}
<style type="text/css">
.hd .logout {
float: right;
text-align: right;
padding-left: 1em;
}
</style>
{% endblock %}
{% block nav %}
{{ super() }}
<p class="logout">
<a href="/-/logout">Log out</a>
</p>
{% endblock %} |
Can the plugin add this to the template without needing to first modify Datasette core?
The text was updated successfully, but these errors were encountered: