mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
Mention completion for issue editor. (#3136)
* new issue mention * Mention completion on new issue and view issue page. * Code format. * Require tribute in pull request page.
This commit is contained in:
@@ -570,6 +570,7 @@ function initRepository() {
|
||||
if ($editContentZone.html().length == 0) {
|
||||
$editContentZone.html($('#edit-content-form').html());
|
||||
$textarea = $segment.find('textarea');
|
||||
issuesTribute.attach($textarea.get());
|
||||
|
||||
// Give new write/preview data-tab name to distinguish from others
|
||||
var $editContentForm = $editContentZone.find('.ui.comment.form');
|
||||
|
40
public/vendor/plugins/tribute/tribute.css
vendored
Executable file
40
public/vendor/plugins/tribute/tribute.css
vendored
Executable file
@@ -0,0 +1,40 @@
|
||||
.tribute-container {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: auto;
|
||||
max-height: 300px;
|
||||
max-width: 500px;
|
||||
overflow: auto;
|
||||
display: block;
|
||||
box-shadow: 0px 1px 3px 1px #c7c7c7;
|
||||
z-index: 999999; }
|
||||
.tribute-container ul {
|
||||
margin: 0;
|
||||
margin-top: 2px;
|
||||
padding: 0;
|
||||
list-style: none;
|
||||
background: #ffffff; }
|
||||
.tribute-container li {
|
||||
padding: 8px 12px;
|
||||
border-bottom: 1px solid #dcdcdc;
|
||||
cursor: pointer; }
|
||||
.tribute-container li.highlight, .tribute-container li:hover {
|
||||
background: #2185D0;
|
||||
color: #ffffff;}
|
||||
.tribute-container li img {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
width: 28px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
.tribute-container li span {
|
||||
font-weight: bold; }
|
||||
.tribute-container li span.fullname {
|
||||
font-weight: normal;
|
||||
font-size: 0.8rem;
|
||||
margin-left: 3px;}
|
||||
.tribute-container li.no-match {
|
||||
cursor: default; }
|
||||
.tribute-container .menu-highlighted {
|
||||
font-weight: bold; }
|
2
public/vendor/plugins/tribute/tribute.min.js
vendored
Executable file
2
public/vendor/plugins/tribute/tribute.min.js
vendored
Executable file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user