diff --git a/rhodecode/public/css/helpers.less b/rhodecode/public/css/helpers.less --- a/rhodecode/public/css/helpers.less +++ b/rhodecode/public/css/helpers.less @@ -52,6 +52,16 @@ a { cursor: pointer; } } } +.noselect { + -webkit-touch-callout: none; /* iOS Safari */ + -webkit-user-select: none; /* Safari */ + -khtml-user-select: none; /* Konqueror HTML */ + -moz-user-select: none; /* Firefox */ + -ms-user-select: none; /* Internet Explorer/Edge */ + user-select: none; /* Non-prefixed version, currently + supported by Chrome and Opera */ +} + //--- DEVICE-SPECIFIC CLASSES ---------------// //regular tablet and up @media (min-width:768px) { diff --git a/rhodecode/public/css/main.less b/rhodecode/public/css/main.less --- a/rhodecode/public/css/main.less +++ b/rhodecode/public/css/main.less @@ -434,7 +434,8 @@ ul.auth_plugins { input { border: 1px transparent; color: black; - opacity: 1 + opacity: 1; + background: #fff; } } @@ -507,13 +508,21 @@ ul.auth_plugins { vertical-align: top; } +#open_edit_pullrequest { + padding: 0; +} + #close_edit_pullrequest { - padding-left: 1em + } #delete_pullrequest { clear: inherit; - padding: 0 + + form { + display: inline; + } + } .perms_section_head { @@ -820,6 +829,11 @@ label { padding: 0 0 0 .17em; line-height: 1em; } + + & + .no-margin { + margin: 0 + } + } .user-inline-data { @@ -836,7 +850,7 @@ label { max-width: 200px; min-height: (@gravatar-size + @border-thickness * 2); // account for border display: block; - padding: 0 0 0 (@gravatar-size + @basefontsize/2 + @border-thickness * 2); + padding: 0 0 0 (@gravatar-size + @basefontsize/4); .gravatar { @@ -1566,14 +1580,52 @@ table.integrations { } } .pr-details-content { - margin-top: @textmargin; - margin-bottom: @textmargin; + margin-top: @textmargin - 5; + margin-bottom: @textmargin - 5; } .pr-reviewer-rules { padding: 10px 0px 20px 0px; } +.todo-resolved { + text-decoration: line-through; +} + +.todo-table { + width: 100%; + + td { + padding: 5px 0px; + } + + .td-todo-number { + text-align: left; + white-space: nowrap; + width: 15%; + } + + .td-todo-gravatar { + width: 5%; + + img { + margin: -3px 0; + } + } + +} + +.todo-comment-text-wrapper { + display: inline-grid; +} + +.todo-comment-text { + margin-left: 5px; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + .group_members { margin-top: 0; padding: 0; diff --git a/rhodecode/public/js/src/rhodecode/comments.js b/rhodecode/public/js/src/rhodecode/comments.js --- a/rhodecode/public/js/src/rhodecode/comments.js +++ b/rhodecode/public/js/src/rhodecode/comments.js @@ -511,15 +511,17 @@ var CommentsController = function() { node = $('comment-current') } } + $wrapper = $(node).closest('div.comment'); - $comment = $(node).closest(klass); - $comments = $(klass); // show hidden comment when referenced. if (!$wrapper.is(':visible')){ $wrapper.show(); } + $comment = $(node).closest(klass); + $comments = $(klass); + $('.comment-selected').removeClass('comment-selected'); var nextIdx = $(klass).index($comment) + offset; @@ -629,7 +631,7 @@ var CommentsController = function() { var cm = commentForm.getCmInstance(); if (resolvesCommentId){ - var placeholderText = _gettext('Leave a comment, or click resolve button to resolve TODO comment #{0}').format(resolvesCommentId); + var placeholderText = _gettext('Leave a resolution comment, or click resolve button to resolve TODO comment #{0}').format(resolvesCommentId); } setTimeout(function() { diff --git a/rhodecode/templates/base/base.mako b/rhodecode/templates/base/base.mako --- a/rhodecode/templates/base/base.mako +++ b/rhodecode/templates/base/base.mako @@ -198,7 +198,7 @@ %def> -<%def name="gravatar(email, size=16, tooltip=False, tooltip_alt=None, user=None)"> +<%def name="gravatar(email, size=16, tooltip=False, tooltip_alt=None, user=None, extra_class=None)"> <% if size > 16: gravatar_class = ['gravatar','gravatar-large'] @@ -210,7 +210,8 @@ if tooltip: gravatar_class += ['tooltip-hovercard'] - + if extra_class: + gravatar_class += extra_class if tooltip and user: if user.username == h.DEFAULT_USER: gravatar_class.pop(-1) diff --git a/rhodecode/templates/codeblocks/diffs.mako b/rhodecode/templates/codeblocks/diffs.mako --- a/rhodecode/templates/codeblocks/diffs.mako +++ b/rhodecode/templates/codeblocks/diffs.mako @@ -50,7 +50,10 @@ return '%s_%s_%i' % (h.md5_safe(commit+f inline_comments=None, # additional menu for PRs - pull_request_menu=None + pull_request_menu=None, + + # show/hide todo next to comments + show_todos=True, )"> @@ -128,12 +131,12 @@ return '%s_%s_%i' % (h.md5_safe(commit+f ## todos - % if getattr(c, 'at_version', None): + % if show_todos and getattr(c, 'at_version', None):
${_('unresolved TODOs unavailable in this view')}. | +
${_('No unresolved TODOs')}. | +