Show More
@@ -13,24 +13,7 b' html {' | |||
|
13 | 13 | color: #ffcc00; |
|
14 | 14 | } |
|
15 | 15 | |
|
16 | .post-form { | |
|
17 | text-align: left; | |
|
18 | display: table; | |
|
19 | border-radius: 5px; | |
|
20 | padding: 5px; | |
|
21 | margin: 5px; | |
|
22 | background: #334; | |
|
23 | } | |
|
24 | ||
|
25 | .form-row { | |
|
26 | display: table-row; | |
|
27 | } | |
|
28 | ||
|
29 | .form-input { | |
|
30 | display: table-cell; | |
|
31 | } | |
|
32 | ||
|
33 | .link { | |
|
16 | .link, a { | |
|
34 | 17 | color: #afdcec; |
|
35 | 18 | } |
|
36 | 19 | |
@@ -66,10 +49,6 b' html {' | |||
|
66 | 49 | border-radius: 5px; |
|
67 | 50 | } |
|
68 | 51 | |
|
69 | .form-title { | |
|
70 | font-weight: bolder; | |
|
71 | } | |
|
72 | ||
|
73 | 52 | .metadata { |
|
74 | 53 | padding: 2px; |
|
75 | 54 | margin-top: 10px; |
@@ -86,6 +65,88 b' html {' | |||
|
86 | 65 | color: #eee; |
|
87 | 66 | } |
|
88 | 67 | |
|
68 | #navigation_panel .link { | |
|
69 | border-right: 1px solid #fff; | |
|
70 | font-weight: bold; | |
|
71 | margin-right: 1ex; | |
|
72 | padding-right: 1ex; | |
|
73 | } | |
|
89 | 74 | #navigation_panel .link:last-child { |
|
75 | border-left: 1px solid #fff; | |
|
76 | border-right: none; | |
|
90 | 77 | float: right; |
|
78 | margin-left: 1ex; | |
|
79 | margin-right: 0; | |
|
80 | padding-left: 1ex; | |
|
81 | padding-right: 0; | |
|
82 | } | |
|
83 | ||
|
84 | #navigation_panel::after { | |
|
85 | clear: both; | |
|
86 | content: "."; | |
|
87 | display: block; | |
|
88 | height: 0; | |
|
89 | line-height: 0; | |
|
90 | visibility: hidden; | |
|
91 | } | |
|
92 | ||
|
93 | p { | |
|
94 | margin-top: .5em; | |
|
95 | margin-bottom: .5em; | |
|
96 | } | |
|
97 | ||
|
98 | .post-form-w { | |
|
99 | display: table; | |
|
100 | background: #333344; | |
|
101 | border-radius: 5px; | |
|
102 | color: #fff; | |
|
103 | padding: 10px; | |
|
104 | margin: 5px | |
|
105 | } | |
|
106 | ||
|
107 | .form-row { | |
|
108 | display: table-row; | |
|
109 | } | |
|
110 | ||
|
111 | .form-label, .form-input { | |
|
112 | display: table-cell; | |
|
113 | } | |
|
114 | ||
|
115 | .form-label { | |
|
116 | padding: .25em 1ex .25em 0; | |
|
117 | } | |
|
118 | ||
|
119 | .form-input { | |
|
120 | padding: .25em 0; | |
|
121 | } | |
|
122 | ||
|
123 | .post-form input, .post-form textarea { | |
|
124 | background: #333; | |
|
125 | color: #fff; | |
|
126 | border: solid 1px; | |
|
127 | padding: 0; | |
|
128 | width: 100%; | |
|
129 | } | |
|
130 | ||
|
131 | .form-submit { | |
|
132 | border-bottom: 2px solid #ddd; | |
|
133 | margin-bottom: .5em; | |
|
134 | padding-bottom: .5em; | |
|
135 | } | |
|
136 | ||
|
137 | .form-title { | |
|
138 | font-weight: bold; | |
|
139 | } | |
|
140 | ||
|
141 | input[type="submit"] { | |
|
142 | background: #222; | |
|
143 | border: solid 1px #fff; | |
|
144 | color: #fff; | |
|
145 | } | |
|
146 | ||
|
147 | blockquote { | |
|
148 | border-left: solid 2px; | |
|
149 | padding-left: 5px; | |
|
150 | color: #B1FB17; | |
|
151 | margin: 0; | |
|
91 | 152 | } No newline at end of file |
@@ -64,38 +64,58 b' a {' | |||
|
64 | 64 | font-weight: bold; |
|
65 | 65 | } |
|
66 | 66 | |
|
67 | .post-form { | |
|
67 | .post-form-w { | |
|
68 | 68 | background: #182F6F; |
|
69 | 69 | border-radius: 1ex; |
|
70 | 70 | color: #fff; |
|
71 | display: table; | |
|
72 | 71 | margin: 1em 1ex; |
|
73 | 72 | padding: 1ex; |
|
74 | text-align: left; | |
|
75 | 73 | } |
|
74 | .post-form { | |
|
75 | display: table; | |
|
76 | border-collapse: collapse; | |
|
77 | width: 100%; | |
|
76 | 78 | |
|
77 | .post-form .form-row { | |
|
79 | } | |
|
80 | .form-row { | |
|
78 | 81 | display: table-row; |
|
79 | 82 | } |
|
80 | ||
|
81 | .post-form .form-input { | |
|
83 | .form-label, .form-input { | |
|
82 | 84 | display: table-cell; |
|
85 | vertical-align: top; | |
|
86 | } | |
|
87 | .form-label { | |
|
88 | padding: .25em 1ex .25em 0; | |
|
89 | } | |
|
90 | .form-input { | |
|
83 | 91 | padding: .25em 0; |
|
84 | 92 | } |
|
85 | ||
|
86 | .post-form input[type="submit"] { | |
|
93 | .form-input > * { | |
|
94 | background: #fff; | |
|
95 | color: #000; | |
|
96 | border: none; | |
|
97 | padding: 0; | |
|
98 | resize: vertical; | |
|
99 | width: 100%; | |
|
100 | } | |
|
101 | .form-submit { | |
|
102 | border-bottom: 1px solid #666; | |
|
103 | margin-bottom: .5em; | |
|
104 | padding-bottom: .5em; | |
|
105 | } | |
|
106 | .form-title { | |
|
107 | font-weight: bold; | |
|
108 | margin-bottom: .5em; | |
|
109 | } | |
|
110 | .post-form .settings_item { | |
|
111 | margin: .5em 0; | |
|
112 | } | |
|
113 | .form-submit input { | |
|
114 | margin-top: .5em; | |
|
87 | 115 | padding: .2em 1ex; |
|
88 | 116 | } |
|
89 | ||
|
90 | .post-form .form-row input, .post-form .form-row textarea { | |
|
91 | background: #fff; | |
|
92 | border: none; | |
|
93 | color: #000; | |
|
94 | width: 100%; | |
|
95 | } | |
|
96 | ||
|
97 | .post-form hr { | |
|
98 | margin: 1em 0; | |
|
117 | .form-label { | |
|
118 | text-align: right; | |
|
99 | 119 | } |
|
100 | 120 | |
|
101 | 121 | .block { |
@@ -115,10 +135,6 b' a {' | |||
|
115 | 135 | padding-bottom: 1em; |
|
116 | 136 | } |
|
117 | 137 | |
|
118 | .form-title { | |
|
119 | font-weight: bolder; | |
|
120 | } | |
|
121 | ||
|
122 | 138 | .metadata { |
|
123 | 139 | background: #C0E4E8; |
|
124 | 140 | border: 1px solid #7F9699; |
@@ -126,4 +142,22 b' a {' | |||
|
126 | 142 | display: table; |
|
127 | 143 | margin-top: .5em; |
|
128 | 144 | padding: .4em; |
|
145 | } | |
|
146 | ||
|
147 | .post ul, .post ol { | |
|
148 | margin: .5em 0 .5em 3ex; | |
|
149 | } | |
|
150 | .post li { | |
|
151 | margin: .2em 0; | |
|
152 | } | |
|
153 | .post p { | |
|
154 | margin: .5em 0; | |
|
155 | } | |
|
156 | .post blockquote { | |
|
157 | border-left: 3px solid #182F6F; | |
|
158 | margin: .5em 0 .5em 3ex; | |
|
159 | padding-left: 1ex; | |
|
160 | } | |
|
161 | .post blockquote > blockquote { | |
|
162 | padding-top: .1em; | |
|
129 | 163 | } No newline at end of file |
@@ -133,6 +133,7 b' INSTALLED_APPS = (' | |||
|
133 | 133 | 'django.contrib.admin', |
|
134 | 134 | # Uncomment the next line to enable admin documentation: |
|
135 | 135 | # 'django.contrib.admindocs', |
|
136 | 'django.contrib.markup', | |
|
136 | 137 | 'boards', |
|
137 | 138 | ) |
|
138 | 139 |
@@ -5,7 +5,8 b'' | |||
|
5 | 5 | <html> |
|
6 | 6 | <head> |
|
7 | 7 | <link rel="stylesheet" type="text/css" |
|
8 |
href="{{ STATIC_URL }} |
|
|
8 | href="{{ STATIC_URL }}css/{{ theme }}/base_page.css" media="all"/> | |
|
9 | <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/> | |
|
9 | 10 | {% block head %}{% endblock %} |
|
10 | 11 | </head> |
|
11 | 12 | <body> |
@@ -1,6 +1,7 b'' | |||
|
1 | 1 | {% extends "base.html" %} |
|
2 | 2 | |
|
3 | 3 | {% load i18n %} |
|
4 | {% load markup %} | |
|
4 | 5 | |
|
5 | 6 | {% block head %} |
|
6 | 7 | <title>Neboard</title> |
@@ -23,9 +24,8 b'' | |||
|
23 | 24 | <span class="post_id">(#{{ thread.id }})</span> |
|
24 | 25 | [{{ thread.pub_time }}] |
|
25 | 26 | [<a class="link" href="{% url 'thread' thread.id %}" |
|
26 |
>{% trans "View" %}</a>] |
|
|
27 |
{{ thread.get_parsed_text| |
|
|
28 | /> | |
|
27 | >{% trans "View" %}</a>] | |
|
28 | {{ thread.get_parsed_text|markdown|truncatechars:300 }} | |
|
29 | 29 | </div> |
|
30 | 30 | <div class="metadata"> |
|
31 | 31 | {{ thread.get_reply_count }} {% trans 'replies' %}, |
@@ -48,29 +48,35 b'' | |||
|
48 | 48 | <hr /> |
|
49 | 49 | {% endif %} |
|
50 | 50 | |
|
51 | <div class="post-form"> | |
|
52 | <span class="form-title">{% trans "Create new thread" %}</span> | |
|
53 | <form enctype="multipart/form-data" method="post">{% csrf_token %} | |
|
54 |
|
|
|
55 | <div class="form-input">{% trans 'Title' %}</div> | |
|
56 |
|
|
|
57 | </div> | |
|
58 | <div class="form-row"> | |
|
59 | <div class="form-input">{% trans 'Text' %}</div> | |
|
60 |
|
|
|
51 | <form enctype="multipart/form-data" method="post">{% csrf_token %} | |
|
52 | <div class="post-form-w"> | |
|
53 | <div class="form-title">{% trans "Create new thread" %}</div> | |
|
54 | <div class="post-form"> | |
|
55 | <div class="form-row"> | |
|
56 | <div class="form-label">{% trans 'Title' %}</div> | |
|
57 | <div class="form-input">{{ form.title }}</div> | |
|
58 | </div> | |
|
59 | <div class="form-row"> | |
|
60 | <div class="form-label">{% trans 'Text' %}</div> | |
|
61 | <div class="form-input">{{ form.text }}</div> | |
|
62 | </div> | |
|
63 | <div class="form-row"> | |
|
64 | <div class="form-label">{% trans 'Image' %}</div> | |
|
65 | <div class="form-input">{{ form.image }}</div> | |
|
66 | </div> | |
|
67 | <div class="form-row"> | |
|
68 | <div class="form-label">{% trans 'Tags' %}</div> | |
|
69 | <div class="form-input">{{ form.tags }}</div> | |
|
70 | </div> | |
|
71 | </div> | |
|
72 | <div class="form-submit"><input type="submit" | |
|
73 | value="{% trans "Post" %}"/></div> | |
|
74 | <div>Tags must be delimited by spaces. Text or image is required | |
|
61 | 75 | </div> |
|
62 | <div class="form-row"> | |
|
63 | <div class="form-input">{% trans 'Image' %}</div> | |
|
64 | <div class="form-input">{{ form.image }}</div> | |
|
65 | </div> | |
|
66 | <div class="form-row"> | |
|
67 | <div class="form-input">{% trans 'Tags' %}</div> | |
|
68 | <div class="form-input">{{ form.tags }}</div> | |
|
69 | </div> | |
|
70 | <input type="submit" value="{% trans 'Post' %}" /> | |
|
71 | <hr /> | |
|
72 | {% trans "Tags must be delimited by spaces. Text or image is required." %} | |
|
73 | </form> | |
|
76 | <div>Use <a | |
|
77 | href="http://daringfireball.net/projects/markdown/basics"> | |
|
78 | markdown</a> syntax for posting.</div> | |
|
74 | 79 | </div> |
|
80 | </form> | |
|
75 | 81 | |
|
76 | 82 | {% endblock %} No newline at end of file |
@@ -8,22 +8,27 b'' | |||
|
8 | 8 | |
|
9 | 9 | {% block content %} |
|
10 | 10 | |
|
11 | <div class="post-form-w"> | |
|
11 | 12 | <div class="post-form"> |
|
12 | 13 | <span class="form-title">{% trans "Theme" %}</span> |
|
13 | 14 | <form method="post">{% csrf_token %} |
|
14 | 15 | {% for choice in form.fields.theme.choices %} |
|
15 | <input type="radio" name="theme" | |
|
16 |
|
|
|
17 | value="{{ choice.0 }}" | |
|
18 |
|
|
|
19 |
|
|
|
20 |
{% |
|
|
21 |
|
|
|
22 | <label for="{{ choice.0 }}">{{ choice.1 }} | |
|
23 |
|
|
|
16 | <div class="settings_item"> | |
|
17 | <label for="{{ choice.0 }}"> | |
|
18 | <input type="radio" name="theme" | |
|
19 | id="{{ choice.0 }}" | |
|
20 | value="{{ choice.0 }}" | |
|
21 | {% ifequal form.initial.theme choice.0 %} | |
|
22 | checked | |
|
23 | {% endifequal %} | |
|
24 | /> | |
|
25 | {{ choice.1 }} | |
|
26 | </label> | |
|
27 | </div> | |
|
24 | 28 | {% endfor %} |
|
25 | 29 | <input type="submit" value="{% trans "Save" %}" /> |
|
26 | 30 | </form> |
|
27 | 31 | </div> |
|
32 | </div> | |
|
28 | 33 | |
|
29 | 34 | {% endblock %} No newline at end of file |
@@ -1,6 +1,7 b'' | |||
|
1 | 1 | {% extends "base.html" %} |
|
2 | 2 | |
|
3 | 3 | {% load i18n %} |
|
4 | {% load markup %} | |
|
4 | 5 | |
|
5 | 6 | {% block head %} |
|
6 | 7 | <title>Neboard</title> |
@@ -23,8 +24,8 b'' | |||
|
23 | 24 | <span class="title">{{ post.title }}</span> |
|
24 | 25 | <a class="post_id" href="#{{ post.id }}"> |
|
25 | 26 | (#{{ post.id }})</a> |
|
26 |
[{{ post.pub_time }}] |
|
|
27 |
{{ post.get_parsed_text| |
|
|
27 | [{{ post.pub_time }}] | |
|
28 | {{ post.get_parsed_text|markdown:"safe" }} | |
|
28 | 29 | </div> |
|
29 | 30 | {% if post.tags.all %} |
|
30 | 31 | <div class="metadata"> |
@@ -43,23 +44,31 b'' | |||
|
43 | 44 | <hr /> |
|
44 | 45 | {% endif %} |
|
45 | 46 | |
|
46 | <div class="post-form"> | |
|
47 | <span class="form-title">{% trans "Reply to the thread" %}</span> | |
|
48 | <form enctype="multipart/form-data" method="post">{% csrf_token %} | |
|
49 |
<div class="form |
|
|
50 |
<div class="form- |
|
|
51 |
<div class="form- |
|
|
47 | <form enctype="multipart/form-data" method="post">{% csrf_token %} | |
|
48 | <div class="post-form-w"> | |
|
49 | <div class="form-title">{% trans "Create new thread" %}</div> | |
|
50 | <div class="post-form"> | |
|
51 | <div class="form-row"> | |
|
52 | <div class="form-label">{% trans 'Title' %}</div> | |
|
53 | <div class="form-input">{{ form.title }}</div> | |
|
54 | </div> | |
|
55 | <div class="form-row"> | |
|
56 | <div class="form-label">{% trans 'Text' %}</div> | |
|
57 | <div class="form-input">{{ form.text }}</div> | |
|
58 | </div> | |
|
59 | <div class="form-row"> | |
|
60 | <div class="form-label">{% trans 'Image' %}</div> | |
|
61 | <div class="form-input">{{ form.image }}</div> | |
|
62 | </div> | |
|
52 | 63 | </div> |
|
53 |
<div class="form- |
|
|
54 | <div class="form-input">{% trans 'Text' %}</div> | |
|
55 | <div class="form-input">{{ form.text }}</div> | |
|
56 | </div> | |
|
57 | <div class="form-row"> | |
|
58 | <div class="form-input">{% trans 'Image' %}</div> | |
|
59 | <div class="form-input">{{ form.image }}</div> | |
|
60 |
|
|
|
61 | <input type="submit" value="{% trans 'Post' %}" /> | |
|
62 | </form> | |
|
63 | </div> | |
|
64 | <div class="form-submit"><input type="submit" | |
|
65 | value="{% trans "Post" %}"/></div> | |
|
66 | <div>Use <a | |
|
67 | href="http://daringfireball.net/projects/markdown/basics"> | |
|
68 | markdown</a> syntax for posting.</div> | |
|
69 | <div>Example: *<i>italic</i>*, **<b>bold</b>**</div> | |
|
70 | <div>Insert quotes with ">"</div> | |
|
71 | </div> | |
|
72 | </form> | |
|
64 | 73 | |
|
65 | 74 | {% endblock %} No newline at end of file |
General Comments 0
You need to be logged in to leave comments.
Login now