Skip to content

Commit

Permalink
Use css variables for navbar customization
Browse files Browse the repository at this point in the history
  • Loading branch information
pehala committed Dec 29, 2023
1 parent cf9e9b7 commit fd793c1
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 107 deletions.
11 changes: 9 additions & 2 deletions backend/templates/songs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ <h6 class="d-inline" ><%:author%></h6>
<input type="text" class="form-control" id="searchInput" placeholder="{% trans "Number, text or author" %}">
</div>
</div>
<table id="datatable" class="accordion accordion-flush w-100 table table-borderless">
<table id="datatable" class="accordion accordion-flush w-100 h-100 table table-borderless">
<thead class="d-none"></thead>
<tbody class="w-100 m-0"></tbody>
</table>
Expand Down Expand Up @@ -156,7 +156,14 @@ <h6 class="d-inline" ><%:author%></h6>
}
],
data: JSON.parse("{{ songs|escapejs }}"),
pageLength: 50,
//pageLength: 50,
//scrollResize: true,
scrollX: false,
scrollY: "90vh",
scrollCollapse: true,
paging: true,
scroller: true,
lengthChange: true,
{% datatables_language %}
});

Expand Down
4 changes: 0 additions & 4 deletions frontend/static/_colors.sass

This file was deleted.

97 changes: 0 additions & 97 deletions frontend/static/navbar4.sass

This file was deleted.

15 changes: 14 additions & 1 deletion frontend/static/styles.sass
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
@import colors
$bgDefault : #f9f9f9
$bgHighlight : #c4c2bd
$colDefault : #7793f3
$colHighlight : #e81c1c
$border-color: $bgHighlight

.navbar
--bs-navbar-color: #{$colDefault}
--bs-navbar-hover-color: #{$colHighlight}
--bs-navbar-active-color: #{$colHighlight}
--bs-navbar-brand-color: #{$colDefault}
--bs-navbar-brand-hover-color: #{$colHighlight}

.dropdown-menu
--bs-dropdown-link-color: #{$colDefault}

.chord
position: absolute
line-height: 0
Expand Down
5 changes: 2 additions & 3 deletions frontend/templates/base/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,12 @@
defer></script>
<link rel="stylesheet" type="text/css" href="{% static 'icons/css/songs.css' %}">
<link rel="stylesheet" type="text/css" href="{% sass_src 'styles.sass' %}">
<link rel="stylesheet" type="text/css" href="{% sass_src 'navbar4.sass' %}">
{% block extra_head %} {% endblock %}
</head>
<body>
<div>
<nav class="navbar navbar-expand-lg navbar-light">
<a class="navbar-brand ms-3" href="#">{{ request.tenant.display_name }}</a>
<nav class="navbar navbar-expand-lg">
<a class="navbar-brand ms-3" href="{{ reqeust.tenant.index_redirect }}">{{ request.tenant.display_name }}</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent"
aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
Expand Down

0 comments on commit fd793c1

Please sign in to comment.