mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-02 19:45:57 +01:00
(refs #12)Fix styles
This commit is contained in:
@@ -1,13 +1,13 @@
|
|||||||
@(owner: String, repository: String)(textarea: Html)(implicit context: app.Context)
|
@(owner: String, repository: String)(textarea: Html)(implicit context: app.Context)
|
||||||
@import context._
|
@import context._
|
||||||
<div class="muted">
|
<div class="muted attachable">
|
||||||
@textarea
|
@textarea
|
||||||
Attach images by dragging & dropping, or selecting them.
|
<div>Attach images by dragging & dropping, or selecting them.</div>
|
||||||
</div>
|
</div>
|
||||||
@defining("(id=\")([\\w\\-]*)(\")".r.findFirstMatchIn(textarea.body).map(_.group(2))){ textareaId =>
|
@defining("(id=\")([\\w\\-]*)(\")".r.findFirstMatchIn(textarea.body).map(_.group(2))){ textareaId =>
|
||||||
<script>
|
<script>
|
||||||
$(function(){
|
$(function(){
|
||||||
$('#@textareaId').closest('div').dropzone({
|
$('#@textareaId').next('div').dropzone({
|
||||||
url: '@path/upload/image/@owner/@repository',
|
url: '@path/upload/image/@owner/@repository',
|
||||||
maxFilesize: 10,
|
maxFilesize: 10,
|
||||||
acceptedFiles: 'image/*',
|
acceptedFiles: 'image/*',
|
||||||
@@ -19,6 +19,9 @@ $(function(){
|
|||||||
$(file.previewElement).prevAll('div.dz-preview').addBack().remove();
|
$(file.previewElement).prevAll('div.dz-preview').addBack().remove();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Adjust attachment area width
|
||||||
|
$('div.attachable div').css('width', ($('div.attachable textarea').width() + 8) + 'px');
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -671,6 +671,26 @@ div.issue-comment-action {
|
|||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
div.attachable {
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.attachable textarea {
|
||||||
|
margin-bottom: 0px;
|
||||||
|
border-bottom: 1px dashed #ccc;
|
||||||
|
-webkit-border-radius: 0px;
|
||||||
|
-moz-border-radius: 0px;
|
||||||
|
border-radius: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.attachable div {
|
||||||
|
padding: 2px;
|
||||||
|
border-left: 1px solid #ccc;
|
||||||
|
border-right: 1px solid #ccc;
|
||||||
|
border-bottom: 1px solid #ccc;
|
||||||
|
background-color: white;
|
||||||
|
}
|
||||||
|
|
||||||
/****************************************************************************/
|
/****************************************************************************/
|
||||||
/* Pull Request */
|
/* Pull Request */
|
||||||
/****************************************************************************/
|
/****************************************************************************/
|
||||||
|
|||||||
Reference in New Issue
Block a user