summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEvgeny Fadeev <evgeny.fadeev@gmail.com>2013-04-21 01:28:54 -0400
committerEvgeny Fadeev <evgeny.fadeev@gmail.com>2013-04-21 01:28:54 -0400
commit0ca7e110bad0c45f37f88354757bcea296dc03bc (patch)
treeaab5b04741225499cca569fd19b0072780a43fdb
parent065a92439cb788e0570dc2ebf749e4b7f7a36fed (diff)
downloadaskbot-0ca7e110bad0c45f37f88354757bcea296dc03bc.tar.gz
askbot-0ca7e110bad0c45f37f88354757bcea296dc03bc.tar.bz2
askbot-0ca7e110bad0c45f37f88354757bcea296dc03bc.zip
improved responsive design of edit question and edit answer pages
-rw-r--r--askbot/media/style/style.css16
-rw-r--r--askbot/media/style/style.less28
-rw-r--r--askbot/templates/answer_edit.html13
-rw-r--r--askbot/templates/question_edit.html9
-rw-r--r--askbot/templates/widgets/edit_post.html5
5 files changed, 43 insertions, 28 deletions
diff --git a/askbot/media/style/style.css b/askbot/media/style/style.css
index 0f873790..fc2373db 100644
--- a/askbot/media/style/style.css
+++ b/askbot/media/style/style.css
@@ -1872,6 +1872,9 @@ ul#related-tags li {
.edit-answer-page .retagger-buttons button {
margin: 8px 10px 5px 0;
}
+.edit-answer-page .wmd-container {
+ margin-top: 13px;
+}
#editor {
/* adjustment for editor preview */
@@ -1969,9 +1972,6 @@ ul#related-tags li {
line-height: 13px;
margin-bottom: 5px;
}
-.question-options label {
- vertical-align: text-top;
-}
.edit-content-html {
border-top: 1px dotted #D8D2A9;
border-bottom: 1px dotted #D8D2A9;
@@ -4087,15 +4087,20 @@ textarea.tipped-input {
/* category selector */
.category-selector {
border-spacing: 0;
+ width: 100%;
}
.category-selector ul.select-box {
height: 150px;
- width: 235px;
+ width: 100%;
overflow: auto;
border: #ccc 3px solid;
+ box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ -webkit-box-sizing: border-box;
}
.category-selector td {
vertical-align: top;
+ width: 33.333%;
}
.category-selector li {
position: relative;
@@ -4319,6 +4324,9 @@ textarea.tipped-input {
.edit-question-page #fmedit #id_title {
margin: 15px 0 0 0;
}
+ .edit-answer-page .after-editor {
+ margin-top: 8px;
+ }
.question-page .comment-votes {
display: none;
}
diff --git a/askbot/media/style/style.less b/askbot/media/style/style.less
index 96b826cf..28b2ee67 100644
--- a/askbot/media/style/style.less
+++ b/askbot/media/style/style.less
@@ -1974,6 +1974,12 @@ ul#related-tags li {
}
}
+.edit-answer-page {
+ .wmd-container {
+ margin-top: 13px;
+ }
+}
+
#editor { /* adjustment for editor preview */
display: block;
font-size: 100%;
@@ -2083,10 +2089,6 @@ ul#related-tags li {
color: #666;
line-height: 13px;
margin-bottom:5px;
-
- label {
- vertical-align: text-top;
- }
}
.edit-content-html {
@@ -2095,7 +2097,9 @@ ul#related-tags li {
margin: 5px 0 5px 0;
}
-.edit-question-page, #fmedit, .wmd-preview{
+.edit-question-page,
+#fmedit,
+.wmd-preview {
color:@info-text-dark;
#id_revision{
@@ -4271,14 +4275,20 @@ textarea.tipped-input {
/* category selector */
.category-selector {
border-spacing: 0;
+ width: 100%;
+
ul.select-box {
height: 150px;
- width: 235px;
+ width: 100%;
overflow: auto;
border: #ccc 3px solid;
+ box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ -webkit-box-sizing: border-box;
}
td {
vertical-align: top;
+ width: 33.333%
}
li {
position: relative;
@@ -4511,6 +4521,12 @@ textarea.tipped-input {
}
}
+ .edit-answer-page {
+ .after-editor {
+ margin-top: 8px;
+ }
+ }
+
.question-page {
.comment-votes {
display: none;
diff --git a/askbot/templates/answer_edit.html b/askbot/templates/answer_edit.html
index 875eec5b..042a63aa 100644
--- a/askbot/templates/answer_edit.html
+++ b/askbot/templates/answer_edit.html
@@ -6,19 +6,14 @@
<link rel="stylesheet" type="text/css" href="{{"/js/wmd/wmd.css"|media}}" />
{% endblock %}
{% block content %}
-<h1 class="section-title">
+<div class="section-title">
{% trans %}Edit answer{% endtrans %} [<a href="{{ answer.thread._question_post().get_absolute_url() }}#{{ answer.id }}">{% trans %}back{% endtrans %}</a>]
-</h1>
+</div>
<div id="main-body" class="ask-body">
<form id="fmedit" action="{% url edit_answer answer.id %}" method="post" >{% csrf_token %}
- <label for="id_revision" >{% trans %}revision{% endtrans %}:</label> <br/>
{% if revision_form.revision.errors %}{{ revision_form.revision.errors.as_ul() }}{% endif %}
- <div style="vertical-align:middle">
- {{ revision_form.revision }} <input type="hidden"
- id="select_revision"
- name="select_revision"
- value="false">
- </div>
+ {{ revision_form.revision }}
+ <input type="hidden" id="select_revision" name="select_revision" value="false"/>
{{ macros.edit_post(
form,
post_html = revision.text,
diff --git a/askbot/templates/question_edit.html b/askbot/templates/question_edit.html
index ee979fb8..19808dae 100644
--- a/askbot/templates/question_edit.html
+++ b/askbot/templates/question_edit.html
@@ -8,14 +8,9 @@
{% block content %}
<div class="section-title">{% trans %}Edit question{% endtrans %} [<a href="{{ question.get_absolute_url() }}">{% trans %}back{% endtrans %}</a>]</div>
<form id="fmedit" action="{% url edit_question question.id %}" method="post" >{% csrf_token %}
-
{% if revision_form.revision.errors %}{{ revision_form.revision.errors.as_ul() }}{% endif %}
- <div style="vertical-align:middle">
- {{ revision_form.revision }} <input type="hidden"
- id="select_revision"
- name="select_revision"
- value="false">
- </div>
+ {{ revision_form.revision }}
+ <input type="hidden" id="select_revision" name="select_revision" value="false"/>
<div class="form-item">
<label for="id_title" >
{% trans %}Question - in one sentence{% endtrans %}
diff --git a/askbot/templates/widgets/edit_post.html b/askbot/templates/widgets/edit_post.html
index ad01cc68..b3c231cc 100644
--- a/askbot/templates/widgets/edit_post.html
+++ b/askbot/templates/widgets/edit_post.html
@@ -52,7 +52,8 @@
{% endif %}
</div>
{% endif %}
-{% if 'summary' in post_form['fields'] %}
+{#% if 'summary' in post_form['fields'] %}
+ <!-- todo: either remove this field or make it folded by default -->
<div class="form-item revision-comment">
<strong>{{ post_form.summary.label_tag() }}</strong> <br/>
{{ post_form.summary }}
@@ -61,7 +62,7 @@
</div>
<div class="form-error" >{{ post_form.summary.errors }}</div>
</div>
-{% endif %}
+{% endif %#}
{% if editor_type == 'markdown' %}
<div class="preview-toggle">