aboutsummaryrefslogtreecommitdiff
path: root/public
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2018-06-26 21:16:29 +0800
committerUnknwon <u@gogs.io>2018-06-26 21:16:29 +0800
commitf6bdefe3f3937e1434b9692822e0ff6f599df758 (patch)
tree88e39cec24a63fb147886ecb715b1c3c684f3f0d /public
parentcd71077c6acb52bf564ede19cf480fddfad72c05 (diff)
public: minor fix for PR #5276
Diffstat (limited to 'public')
-rw-r--r--public/css/gogs.css3
-rw-r--r--public/js/gogs.js15
-rw-r--r--public/less/_repository.less3
3 files changed, 18 insertions, 3 deletions
diff --git a/public/css/gogs.css b/public/css/gogs.css
index 17b84a1f..83f0f33c 100644
--- a/public/css/gogs.css
+++ b/public/css/gogs.css
@@ -1731,6 +1731,9 @@ footer .ui.language .menu {
margin-left: 10px;
margin-top: 10px;
}
+.repository.view.issue .pull .merge.box #commit_description {
+ height: auto;
+}
.repository.view.issue .comment-list:before {
display: block;
content: "";
diff --git a/public/js/gogs.js b/public/js/gogs.js
index 6f091cb7..e518bde4 100644
--- a/public/js/gogs.js
+++ b/public/js/gogs.js
@@ -111,7 +111,7 @@ function initCommentForm() {
// This should be added directly to HTML but somehow just get empty <span> on this page.
$labelMenu.find('.item:not(.no-select) .octicon:not(.octicon-check)').each(function () {
$(this).html('&nbsp;');
- })
+ });
$labelMenu.find('.item:not(.no-select)').click(function () {
if ($(this).hasClass('checked')) {
$(this).removeClass('checked');
@@ -499,6 +499,15 @@ function initRepository() {
if ($('.repository.compare.pull').length > 0) {
initFilterSearchDropdown('.choose.branch .dropdown');
}
+ if ($('.repository.view.pull').length > 0) {
+ $('.comment.merge.box input[name=merge_style]').change(function () {
+ if ($(this).val() === 'create_merge_commit') {
+ $('.commit.description.field').show();
+ } else {
+ $('.commit.description.field').hide();
+ }
+ })
+ }
}
function initWikiForm() {
@@ -1143,7 +1152,7 @@ function initWebhookSettings() {
$(document).ready(function () {
csrf = $('meta[name=_csrf]').attr("content");
suburl = $('meta[name=_suburl]').attr("content");
-
+
// Set cursor to the end of autofocus input string
$('input[autofocus]').each(function () {
$(this).val($(this).val());
@@ -1469,7 +1478,7 @@ function getByteLen(normalVal) {
}
function showMessageMaxLength(maxLen, textElemId, counterId) {
- var $msg = $('#'+textElemId);
+ var $msg = $('#'+textElemId);
$('#'+counterId).html(maxLen - getByteLen($msg.val()));
var onMessageKey = function (e) {
diff --git a/public/less/_repository.less b/public/less/_repository.less
index 6090fb9a..e0ba887b 100644
--- a/public/less/_repository.less
+++ b/public/less/_repository.less
@@ -639,6 +639,9 @@
margin-left: 10px;
margin-top: 10px;
}
+ #commit_description {
+ height: auto;
+ }
}
}
.comment-list {