Skip to content

Commit

Permalink
Add a "pagetitle" block to Silky templates so that when multiply Silk…
Browse files Browse the repository at this point in the history
…y browser tabs are open, it's easier to tell which is which.
  • Loading branch information
vsajip committed Jun 19, 2023
1 parent ed3e326 commit b204e2c
Show file tree
Hide file tree
Showing 10 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion silk/templates/silk/base/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<!DOCTYPE html>
<html>
<head>
<title>Silky</title>
<title>{% block pagetitle %}Silky{% endblock %}</title>
<link rel="stylesheet" href="{% static "silk/css/components/fonts.css" %}"/>
<link rel="stylesheet" href="{% static "silk/css/components/colors.css" %}"/>
<link rel="stylesheet" href="{% static "silk/lib/jquery-ui-1.13.1.min.css" %}"/>
Expand Down
2 changes: 2 additions & 0 deletions silk/templates/silk/clear_db.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{% extends 'silk/base/root_base.html' %}
{% load silk_inclusion %}
{% load static %}
{% block pagetitle %}Silky - Clear DB{% endblock %}

{% block menu %}
{% root_menu request %}
{% endblock %}
Expand Down
4 changes: 3 additions & 1 deletion silk/templates/silk/cprofile.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
{% load silk_inclusion %}
{% load static %}

{% block pagetitle %}Silky - CProfile{% endblock %}

{% block js %}
<script type="text/javascript" src="{% static 'silk/lib/viz-lite.js' %}"></script>
<script type="text/javascript" src="{% static 'silk/lib/svg-pan-zoom.min.js' %}"></script>
Expand All @@ -23,7 +25,7 @@

{% block data %}
<div class="wrapper">
<div id="query-div">
<div id="query-div">
{% if silk_request.pyprofile %}
<div id="pyprofile-div">
<div class="heading">
Expand Down
2 changes: 2 additions & 0 deletions silk/templates/silk/profile_detail.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
{% load silk_inclusion %}
{% load static %}

{% block pagetitle %}Silky - Profile Detail{% endblock %}

{% block js %}
<script type="text/javascript" src="{% static 'silk/lib/viz-lite.js' %}"></script>
<script type="text/javascript" src="{% static 'silk/lib/svg-pan-zoom.min.js' %}"></script>
Expand Down
2 changes: 2 additions & 0 deletions silk/templates/silk/profiling.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
{% load static %}
{% load silk_inclusion %}

{% block pagetitle %}Silky - Profiling{% endblock %}

{% block menu %}
{% if silk_request %}
{% request_menu request silk_request %}
Expand Down
2 changes: 2 additions & 0 deletions silk/templates/silk/request.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
{% load silk_filters %}
{% load silk_inclusion %}
{% load static %}
{% block pagetitle %}Silky - Request{% endblock %}

{% block style %}
<link rel="stylesheet" href="{% static 'silk/css/components/cell.css' %}"/>
<link rel="stylesheet" href="{% static 'silk/css/components/numeric.css' %}"/>
Expand Down
2 changes: 2 additions & 0 deletions silk/templates/silk/requests.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
{% load silk_inclusion %}
{% load static %}

{% block pagetitle %}Silky - Requests{% endblock %}

{% block style %}
{{ block.super }}
<link rel="stylesheet" href="{% static 'silk/css/pages/requests.css' %}"/>
Expand Down
2 changes: 2 additions & 0 deletions silk/templates/silk/sql.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
{% load static %}
{% load silk_inclusion %}

{% block pagetitle %}Silky - SQL{% endblock %}

{% block js %}
<script type="text/javascript" src="{% static 'silk/lib/sortable.js' %}"></script>
{{ block.super }}
Expand Down
2 changes: 2 additions & 0 deletions silk/templates/silk/sql_detail.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
{% load silk_nav %}
{% load silk_inclusion %}

{% block pagetitle %}Silky - SQL Detail{% endblock %}

{% block js %}
{{ block.super }}
<script src="{% static 'silk/js/pages/sql_detail.js' %}"></script>
Expand Down
2 changes: 2 additions & 0 deletions silk/templates/silk/summary.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
{% root_menu request %}
{% endblock %}

{% block pagetitle %}Silky - Summary{% endblock %}

{% block style %}
{{ block.super }}
<link rel="stylesheet" href="{% static 'silk/css/pages/summary.css' %}"/>
Expand Down

0 comments on commit b204e2c

Please sign in to comment.