Skip to content

Commit 8fd2b82

Browse files
committed
Style material lists
1 parent e0c86e7 commit 8fd2b82

6 files changed

Lines changed: 34 additions & 16 deletions

File tree

naucse/static/css/body.css

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -19,18 +19,6 @@ p kbd {
1919
font-style: normal;
2020
}
2121

22-
svg.icon {
23-
width: 1em;
24-
height: 1em;
25-
transform: translate(0px, 0.1em);
26-
overflow: visible;
27-
stroke-width: 2.5px;
28-
stroke: currentColor;
29-
fill: none;
30-
stroke-linecap: butt;
31-
stroke-linejoin: miter;
32-
}
33-
3422
/*** Credits ***/
3523

3624
.lesson-attribution {

naucse/static/css/nausce.css

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,18 @@ a:hover {
127127
margin-top: 1em;
128128
}
129129

130+
svg.icon {
131+
width: 1em;
132+
height: 1em;
133+
transform: translate(0px, 0.1em);
134+
overflow: visible;
135+
stroke-width: 2.5px;
136+
stroke: currentColor;
137+
fill: none;
138+
stroke-linecap: butt;
139+
stroke-linejoin: miter;
140+
}
141+
130142
/*************************/
131143

132144
pre {
@@ -155,3 +167,21 @@ code {
155167
padding: 2px 4px;
156168
white-space: pre-wrap;
157169
}
170+
171+
/*** Material lists ***/
172+
173+
ul.material-list {
174+
padding: 0;
175+
padding-left: 1.5em;
176+
}
177+
178+
ul.material-list > li {
179+
list-style-type: none;
180+
text-indent: -1.5em;
181+
}
182+
183+
ul.material-list > li svg.icon {
184+
padding-right: 0.5em;
185+
box-sizing: content-box;
186+
color: black;
187+
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
{%- endmacro -%}
2828

2929
{%- macro material_list(materials, filter_type=None) %}
30-
<ul>
30+
<ul class="material-list">
3131
{% for mat in materials %}
3232
{% if filter_type == None or mat.url_type == filter_type %}
3333
{{ material_li(mat) }}

naucse/templates/backpage.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{% extends "_base.html" %}
2-
{% from "_macros.html" import material_list with context %}
2+
{% from "_material_macros.html" import material_list with context %}
33

44
{% block content %}
55

naucse/templates/course.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{% extends "_base.html" %}
2-
{% from "_macros.html" import material_list with context %}
2+
{% from "_material_macros.html" import material_list with context %}
33

44
{% macro session_heading(session, index, plan) %}
55
{% if plan|length > 1 %}

naucse/templates/coverpage.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{% extends "_base.html" %}
2-
{% from "_macros.html" import material_list with context %}
2+
{% from "_material_macros.html" import material_list with context %}
33

44
{% block content %}
55

0 commit comments

Comments
 (0)