1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-16 15:19:06 +00:00

[seaf]modified editor padding, btn and etc.

This commit is contained in:
llj
2012-11-23 11:29:02 +08:00
parent fa23039c2b
commit 43ff32acb2
2 changed files with 15 additions and 8 deletions

View File

@@ -175,13 +175,14 @@ p {
.no-deco:hover {
text-decoration:none;
}
.input-disabled {/* for type="password"/"text" etc*/
.input-disabled {/* for type="password/text" etc*/
background:#ebebe4;
}
input.btn-disabled { /*for <input type="submit" disabled="disabled" />*/
.btn-disabled { /*for <input type="submit" />, <button>*/
color:#999;
}
input.btn-disabled:hover {
.btn-disabled:hover,
input.btn-disabled:hover {/*for input*/
cursor:default;
background: #efefef;
}
@@ -589,7 +590,7 @@ textarea:-moz-placeholder {/* for FF */
}
/* for article */
.article {
padding:40px 200px 40px 60px;
padding:40px 130px;
font-size:14px;
line-height:1.6;
color:#333;
@@ -1354,7 +1355,7 @@ textarea:-moz-placeholder {/* for FF */
background:#fff;
}
#md-view {
min-height:120px;
min-height:200px;
}
#svg-view {
min-height:500px;/*for ff*/
@@ -1391,6 +1392,9 @@ textarea:-moz-placeholder {/* for FF */
#op-after-edit {
margin-top:1em;
}
#op-after-edit button {
margin-left:5px;
}
#file-edit-cancel {
color:#900;
}

View File

@@ -32,12 +32,12 @@
{% endfor %}
</p>
<div id="op-after-edit" class="fright hide">
<button id="file-edit-submit">{% trans "Submit" %}</button>
<button data="{{ SITE_ROOT }}repo/{{ repo.id }}/files/?p={{ path }}" id="file-edit-cancel">{% trans "Cancel" %}</button>
{% if filetype == 'Markdown' %}
<button id="source-code-btn" class="hide">{% trans "Continue editing" %}</button>
<button id="preview-btn">{% trans "Preview" %}</button>
{% endif %}
<button data="{{ SITE_ROOT }}repo/{{ repo.id }}/files/?p={{ path }}" id="file-edit-cancel">{% trans "Cancel" %}</button>
<button id="file-edit-submit">{% trans "Submit" %}</button>
</div>
</div>
<div id="file-edit">
@@ -114,6 +114,8 @@ $('#preview-btn').click(function() {
{% endif %}
$('#file-edit-submit').click(function () {
var submit_btn = $(this);
disable(submit_btn);
{% if filetype == 'Sf' %}
var content = $('#sf').html();
{% else %}
@@ -134,6 +136,7 @@ $('#file-edit-submit').click(function () {
error: function(xhr, ajaxOptions, thrownError) {
var jsonVal = jQuery.parseJSON(xhr.responseText);
$('#op-after-edit').prepend('<p class="error">' + jsonVal['error'] + '</p>');
enable(submit_btn);
}
});
});
@@ -143,7 +146,7 @@ $('#file-edit-cancel').click(function() {
{% endifnotequal %}
{% if err %}
$('#file-edit').html('<p class="error">{{ err }}</p>');
$('#file-edit').html('<div id="sf" class="article"><p class="error">{{ err }}</p></div>');
{% endif %}
</script>
{% endblock %}