code:
html
{
    font-size:14px;
}

.disabled a {
    pointer-events: none;
    color: #808080;
}

.nav-tabs
{
    border-bottom:none;
}

.repo-header
{
    background:#f3f3f3;
    border-bottom:1px solid #DDD;
}

.notification-spacer
{
    background:#f3f3f3;
}

.code_table {
    background: #FDF6E3;
    min-width: 100%;
    display:block;
    overflow-x: auto;
}

.code_table tr td{
    padding: 0;
}

.code_table tr td pre{
    padding: 0;
    margin: 0;
}

.code_table tr .cell1{
    width: 20px;
    background: #eee8d5;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    text-align:center;
}

.code_table tr .cell2{
    padding-left:15px;
}

.code_table tr .cell1 a::before {
    content: attr(data-line-number);
    color:#91a1a1!important;
    font-family: Hack;
    padding-left:3px;
    padding-right:3px;
}

.alert-info pre
{
    background-color:#CFE5F0;
}

.card-header > .breadcrumb
{
padding:0;
background:none;
margin-bottom:0;
display:inline-block;
}

.card-header > .breadcrumb .oi
{
font-size:0.8rem;
}

.file-button-bar
{
background:#ededed;
padding: 0.3rem;
}

#issue-title, .stretch-table-column
{
    min-width:99%;
}

.btn-group-sm.issues-tagbar > .btn-sm {
    padding: 0.2rem 0.55rem;
    font-size: 0.75rem;
    border-radius: 0.2rem;
    line-height: 1.2;
}

#pagure-issues-list .td-open_date, .nowrap
{
white-space: nowrap;
}

#preview
{
    min-height: 16rem;
    background:#efefef;
    padding:1em;
    border:1px solid #aaa;
}

.form-control#initial_comment
{
  min-height: 16rem;
}

.issue-metadata-form
{
display:none;
}

.bodycontent
{
min-height: 85vh;
}

.oi-spin {
  -webkit-animation: spin 2s infinite linear;
  -moz-animation: spin 2s infinite linear;
  -o-animation: spin 2s infinite linear;
  animation: spin 2s infinite linear;
}
@-moz-keyframes spin {
  0% {
    -moz-transform: rotate(0deg);
  }
  100% {
    -moz-transform: rotate(359deg);
  }
}
@-webkit-keyframes spin {
  0% {
    -webkit-transform: rotate(0deg);
  }
  100% {
    -webkit-transform: rotate(359deg);
  }
}
@-o-keyframes spin {
  0% {
    -o-transform: rotate(0deg);
  }
  100% {
    -o-transform: rotate(359deg);
  }
}
@keyframes spin {
  0% {
    -webkit-transform: rotate(0deg);
    transform: rotate(0deg);
  }
  100% {
    -webkit-transform: rotate(359deg);
    transform: rotate(359deg);
  }
}
.oi
{
    position: relative;
    top: 1px;
    font-size: 0.8em;
}

.pr-toplabel
{
    background: #eee;
    padding-left: 10px;
    padding-top: 4px;
    padding-bottom: 4px;
    border-radius: 5px;
    padding-right: 10px;
}

.selectize-control.pr-toplabel-select {
    display: inline;
}

.selectize-control.pr-toplabel-select .selectize-input {
    display: inline!important;
    padding: 4px 20px 4px 10px;
    border:0;
    background: #eee;
}

.selectize-control.pr-toplabel-select .selectize-input:after
{
right:6px!important;
}

.button-label{
  padding: .25rem .75rem;
  font-size: .875rem;
  line-height: 1.5;
  border-radius: .2rem;
  display: inline-block;
  font-weight: 400;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
  border: 1px solid transparent;
}

.button-label-default
{
  background-color:#eee;
}

.ellipsis {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-overflow: ellipsis;
  text-overflow: ellipsis;
}

.ellipsis-left
{
  direction:rtl;
}

.projecticon .oi
{
font-size: 3.5rem;
line-height: 5rem;
padding-left: 0.5rem;
color: #bbb;
}

.projecticon-search .oi
{
  font-size: 2.5rem;
  line-height: 3rem;
  color: #bbb;
}

.repo_desc
{
  height:2.5em;
  line-height:1;
  padding-left:65px;
}

.repo_name
{
  padding-top:4px;
  width: 78%;
  padding-left: 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.repo_date
{
  background-color: #eee;
  padding-left: 1.25rem;
  font-size: 90%;
}

.project_wrapper
{
  border:1px solid #ddd;
  position:relative;
  border-radius: .25rem;
  overflow: hidden;
}

.project_metadata
{

   bottom:0;
   background:#eee;
   width:100%;
  margin-top:10px;
}

/*@media (min-width:768px) {
    .container {
        max-width:55pc
    }
}*/

.nav-tabs .nav-link {
    padding: 0.5em 0.6em;
}

.red-icon {
    color: #d9534f;
}

.pagination > li {
    display: inline;
}

.prc {
    min-width: 13px;
}

.prc p {
    padding:0!important;
    margin:0!important;
}

.prc_img {
    display: none;
    cursor: pointer;
}

.highlighted-line,
.highlighted-line td,
.highlighted-line td pre {
     background-color: #FFFABA;
}

/* Added */
.nav {
    list-style: outside none none;
}
.nav-pills > li.active > a, .nav-pills > li.active > a:focus, .nav-pills > li.active > a:hover {
    background-color: #337ab7;
    color: #fff;
}
.nav > li {
    display: block;
    position: relative;
}
.nav-pills > li {
    float: left;
}
.nav-pills > li > a {
    border-radius: 4px;
}
.nav > li > a {
    display: block;
    padding: 10px 15px;
    position: relative;
}

btn-group-vertical > .btn-group::after, .btn-group-vertical > .btn-group::before, .btn-toolbar::after, .btn-toolbar::before, .clearfix::after, .clearfix::before, .container-fluid::after, .container-fluid::before, .container::after, .container::before, .dl-horizontal dd::after, .dl-horizontal dd::before, .form-horizontal .form-group::after, .form-horizontal .form-group::before, .modal-footer::after, .modal-footer::before, .modal-header::after, .modal-header::before, .nav::after, .nav::before, .navbar-collapse::after, .navbar-collapse::before, .navbar-header::after, .navbar-header::before, .navbar::after, .navbar::before, .pager::after, .pager::before, .panel-body::after, .panel-body::before, .row::after, .row::before {
    content: " ";
    display: table;
}
*::after, *::before {
    box-sizing: border-box;
}
.btn-group-vertical > .btn-group::after, .btn-toolbar::after, .clearfix::after, .container-fluid::after, .container::after, .dl-horizontal dd::after, .form-horizontal .form-group::after, .modal-footer::after, .modal-header::after, .nav::after, .navbar-collapse::after, .navbar-header::after, .navbar::after, .pager::after, .panel-body::after, .row::after {
    clear: both;
}
.btn-group-vertical > .btn-group::after, .btn-group-vertical > .btn-group::before, .btn-toolbar::after, .btn-toolbar::before, .clearfix::after, .clearfix::before, .container-fluid::after, .container-fluid::before, .container::after, .container::before, .dl-horizontal dd::after, .dl-horizontal dd::before, .form-horizontal .form-group::after, .form-horizontal .form-group::before, .modal-footer::after, .modal-footer::before, .modal-header::after, .modal-header::before, .nav::after, .nav::before, .navbar-collapse::after, .navbar-collapse::before, .navbar-header::after, .navbar-header::before, .navbar::after, .navbar::before, .pager::after, .pager::before, .panel-body::after, .panel-body::before, .row::after, .row::before {
    content: " ";
    display: table;
}
*::after, *::before {
    box-sizing: border-box;
}
.bs-example > .alert:last-child, .bs-example > .form-control:last-child, .bs-example > .jumbotron:last-child, .bs-example > .list-group:last-child, .bs-example > .navbar:last-child, .bs-example > .panel:last-child, .bs-example > .progress:last-child, .bs-example > .table-responsive:last-child > .table, .bs-example > .table:last-child, .bs-example > .well:last-child, .bs-example > blockquote:last-child, .bs-example > ol:last-child, .bs-example > p:last-child, .bs-example > ul:last-child {
    margin-bottom: 0;
}
.nav {
    list-style: outside none none;
    margin-bottom: 0;
    padding-left: 0;
}

#pr-tabs
{
 border-bottom: 1px solid #ddd;
 margin-bottom:1.5em;
 margin-top:2em;
}

.commit_message_body
{
  font-family: "Open Sans";
  background: transparent;
  padding: 0;
}

.card pre
{
margin-bottom:0;
}

a.notblue {
    color: inherit;
    text-decoration:none;
}

#headerSearch .selectize-control.single .selectize-input::after
{
  content: "\e08f";
  font-family: "Icons";
  border:none;
  top:30%;
  right:22px;
  color:#aaa;
}

.footer a, .footer a:hover { color: #d9d9d9; }

#user_graph {
    background-image: url("images/spinner.gif");
    background-position: center center;
    background-repeat: no-repeat;
    min-height: 150px;
}
.content-loading {
    background-image: url("images/spinner.gif");
    background-position: center center;
    background-repeat: no-repeat;
    min-height: 30px;
}

.repoinfo-branchlistitem
{
 padding:3px 5px 3px 5px;
}

.branch_name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.branch_del {
  padding: 0px 0px;
  margin: 0px 0px;
  text-align: right;
}

.branch_del .label{
  padding: 0.25em 0.3em;
}

.branch_del .del_icon {
  display:inline;
}

.branch_del .btn-secondary{
  border: 0px;
  color: #0275d8;
}

.repoinfo-activebranch
{
  background:#eee;
  border:1px solid #ccc;
}

.api code {
  padding: 0rem 0.4rem;
}

.api h3 {
  padding-left: 1em;
}

.addrem_bar {
    display: inline-block;
    width: 100%;
    padding: 0px !important;
    text-indent:4px;
    text-align: left;
    background-color: #FDD;
}

.addrem_bar > span {
    display: block;
    background-color: #DBFFDB;
}

.comment_body img {
    max-width: 100%;
    border: 5px solid #fff;
    box-shadow: 0 0 5px #999;
}

pre.softwrap
{
  white-space: pre-wrap;
  word-wrap: break-word;
}

.inline-comments {
  padding: 1rem 1rem;
  background-color: white;
  text-indent:4px;
  border-radius: 0.25rem 0.25rem 0 0;
}

.inline-btn {
  cursor: pointer;
}

blockquote {
  background: #f3f5f6;
  color: #586e75;
  padding: 1em 1em 0.1em 1em;
}

.messagetitle{
  border-top: 1px solid #eee;
}

.messageitem{
  padding-left: 2em;
}

.messageicon{
float: left;
font-size: 1.5em;
padding-right: 0.5em;
margin-top: -4px;
color: #999;
}
.msg-git-hash{
  font-family:monospace;
  background-color:#eee;
  color:#777;
}

th[data-sort] {
    cursor: pointer;
}

.pr-changes-description
{
  font-size: 0.8em;
}

.readme dd{
	margin-left:2em;
}

/*Our specific responsive overrides*/

@media (min-width:544px) {
.pr_comment_form .card, .inline-pr-comment .card{max-width:500px}
}
@media (min-width:768px) {
.pr_comment_form .card, .inline-pr-comment .card{max-width:400px}
}
@media (min-width:992px) {
.pr_comment_form .card, .inline-pr-comment .card{max-width:550px}
}
@media (min-width:1200px) {
.pr_comment_form .card, .inline-pr-comment .card{max-width:680px}

#watch_project a {
  cursor: pointer;
}

.btn-align {
    padding: 6px 0;
    line-height: 1.42857143;
    vertical-align: middle;
}

repo_name: bill/auger

license: mit


code:
add_comment = function(data, username) {
  console.log('Adding comment ' + data.comment_added);
  var field = $('#comments');
  var edit_btn = ' \
         \
    ';
  var inline = false;
  if (data.commit_id){
    inline = true;
    edit_btn = '';
  }

  if (data.notification){
      var _data = '
 \

 \

 \
                ' + emojione.toImage(data.comment_added) + '\

 \
                  \
                    Just now
\

 \

 \

';

  } else if (inline) {
    var _data = '
	 \
         \

 \

 \

 \
         \
         ' + data.comment_user + ' commented  \
         \
        Just now \

 \

 \

 \
        ' + emojione.toImage(data.comment_added) + ' \

 \

 \

 \
         \

 \
               \
                 \
              ';
        if ( data.comment_user == username) {
          _data += edit_btn +
              '<button class="btn btn-secondary btn-sm" type="submit" name="drop_comment" value="' + data.comment_id + '" \
                  onclick="return confirm(\'Do you really want to remove this comment?\');" \
                  title="Remove comment"> \
                   \
                </button>';
            }
        _data += '
 \
         \

 \

';
  } else {
  var _data = '
 \

 \
     \
     ' + data.comment_user + '\
       \
       \
        seconds ago \
       \

\

\

 \

 \
           \
          '
        + emojione.toImage(data.comment_added) + '\

 \

 \

 \

 \

 \
             \
               \
            ';
    if ( data.comment_user == username) {
        _data += edit_btn +
            '<button class="btn btn-secondary btn-sm" type="submit" name="drop_comment" value="' + data.comment_id + '" \
                onclick="return confirm(\'Do you really want to remove this comment?\');" \
                title="Remove comment"> \
                 \
            </button>';
    }
    _data += '
 \

 \

';
  }

  if (inline){
    // Inline comment
    console.log('Inline');
    var field = $('[data-commit="' + data.commit_id + '"]').parent();
    var id = field.children().children().attr('id').split('_')[0];
    var row = $('#' + id + '_' + (parseInt(data.line) + 1)).parent().parent();
    row.before(_data);
  } else {
    // Generic comment
    console.log('generic');
    var field = $('#request_comment');
    field.html(field.html() + _data);
  }
}

update_comment = function(data) {
  console.log('Updating comment ' + data.comment_id);
  var field = $('#comment-' + data.comment_id).parent();
  var edited = field.find('.text-muted');
  if (edited.length == 0) {
    $(field.find('aside')).before(
        'Edited a just now by '
        + data.comment_editor + '');
  } else {
    edited.html('Edited a just now by ' + data.comment_editor)
  }
  field.find('.comment_body').html(data.comment_updated);
  field.find('.issue_actions').show();
  field.find('.issue_comment').show();
}

process_event = function(data, requestid, username){
  console.log(data);
  var category = null;
  var originalTitle = document.title;
  if (data.comment_added){
    add_comment(data, username);
    category = 'comment';
  } else if (data.comment_updated){
    update_comment(data);
    category = 'Comment updated';
  } else {
    console.log('Unknown data');
  }

  if (category && !document.hasFocus()) {
    var int = setInterval(function(){
      var title = document.title;
      document.title = (title === originalTitle) ? category : originalTitle;
    }, 750);

    $(window).focus(function () {
      clearInterval(int);
      document.title = originalTitle;
    });
  }
}


code:
/**
 * selectize.bootstrap3.css (v0.12.1) - Bootstrap 3 Theme
 * Copyright (c) 2013–2015 Brian Reavis & contributors
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this
 * file except in compliance with the License. You may obtain a copy of the License at:
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software distributed under
 * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
 * ANY KIND, either express or implied. See the License for the specific language
 * governing permissions and limitations under the License.
 *
 * @author Brian Reavis <brian@thirdroute.com>
 */
.selectize-control.plugin-drag_drop.multi > .selectize-input > div.ui-sortable-placeholder {
  visibility: visible !important;
  background: #f2f2f2 !important;
  background: rgba(0, 0, 0, 0.06) !important;
  border: 0 none !important;
  -webkit-box-shadow: inset 0 0 12px 4px #ffffff;
  box-shadow: inset 0 0 12px 4px #ffffff;
}
.selectize-control.plugin-drag_drop .ui-sortable-placeholder::after {
  content: '!';
  visibility: hidden;
}
.selectize-control.plugin-drag_drop .ui-sortable-helper {
  -webkit-box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}
.selectize-dropdown-header {
  position: relative;
  padding: 3px 12px;
  border-bottom: 1px solid #d0d0d0;
  background: #f8f8f8;
  -webkit-border-radius: 4px 4px 0 0;
  -moz-border-radius: 4px 4px 0 0;
  border-radius: 4px 4px 0 0;
}
.selectize-dropdown-header-close {
  position: absolute;
  right: 12px;
  top: 50%;
  color: #333333;
  opacity: 0.4;
  margin-top: -12px;
  line-height: 20px;
  font-size: 20px !important;
}
.selectize-dropdown-header-close:hover {
  color: #000000;
}
.selectize-dropdown.plugin-optgroup_columns .optgroup {
  border-right: 1px solid #f2f2f2;
  border-top: 0 none;
  float: left;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}
.selectize-dropdown.plugin-optgroup_columns .optgroup:last-child {
  border-right: 0 none;
}
.selectize-dropdown.plugin-optgroup_columns .optgroup:before {
  display: none;
}
.selectize-dropdown.plugin-optgroup_columns .optgroup-header {
  border-top: 0 none;
}
.selectize-control.plugin-remove_button [data-value] {
  position: relative;
  padding-right: 24px !important;
}
.selectize-control.plugin-remove_button [data-value] .remove {
  z-index: 1;
  /* fixes ie bug (see #392) */
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 17px;
  text-align: center;
  font-weight: bold;
  font-size: 12px;
  color: inherit;
  text-decoration: none;
  vertical-align: middle;
  display: inline-block;
  padding: 1px 0 0 0;
  border-left: 1px solid rgba(0, 0, 0, 0);
  -webkit-border-radius: 0 2px 2px 0;
  -moz-border-radius: 0 2px 2px 0;
  border-radius: 0 2px 2px 0;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}
.selectize-control.plugin-remove_button [data-value] .remove:hover {
  background: rgba(0, 0, 0, 0.05);
}
.selectize-control.plugin-remove_button [data-value].active .remove {
  border-left-color: rgba(0, 0, 0, 0);
}
.selectize-control.plugin-remove_button .disabled [data-value] .remove:hover {
  background: none;
}
.selectize-control.plugin-remove_button .disabled [data-value] .remove {
  border-left-color: rgba(77, 77, 77, 0);
}
.selectize-control {
  position: relative;
}
.selectize-dropdown,
.selectize-input,
.selectize-input input {
  color: #333333;
  font-family: inherit;
  font-size: inherit;
  line-height: 20px;
  -webkit-font-smoothing: inherit;
}
.selectize-input,
.selectize-control.single .selectize-input.input-active {
  background: #ffffff;
  cursor: text;
  display: inline-block;
}
.selectize-input {
  border: 1px solid #cccccc;
  padding: 6px 12px;
  display: inline-block;
  width: 100%;
  overflow: hidden;
  position: relative;
  z-index: 1;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  -webkit-box-shadow: none;
  box-shadow: none;
  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  border-radius: 4px;
}
.selectize-control.multi .selectize-input.has-items {
  padding: 5px 12px 2px;
}
.selectize-input.full {
  background-color: #ffffff;
}
.selectize-input.disabled,
.selectize-input.disabled * {
  cursor: default !important;
}
.selectize-input.focus {
  -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15);
}
.selectize-input.dropdown-active {
  -webkit-border-radius: 4px 4px 0 0;
  -moz-border-radius: 4px 4px 0 0;
  border-radius: 4px 4px 0 0;
}
.selectize-input > * {
  vertical-align: baseline;
  display: -moz-inline-stack;
  display: inline-block;
  zoom: 1;
  *display: inline;
}
.selectize-control.multi .selectize-input > div {
  cursor: pointer;
  margin: 0 3px 3px 0;
  padding: 1px 3px;
  background: #efefef;
  color: #333333;
  border: 0 solid rgba(0, 0, 0, 0);
}
.selectize-control.multi .selectize-input > div.active {
  background: #428bca;
  color: #ffffff;
  border: 0 solid rgba(0, 0, 0, 0);
}
.selectize-control.multi .selectize-input.disabled > div,
.selectize-control.multi .selectize-input.disabled > div.active {
  color: #808080;
  background: #ffffff;
  border: 0 solid rgba(77, 77, 77, 0);
}
.selectize-input > input {
  display: inline-block !important;
  padding: 0 !important;
  min-height: 0 !important;
  max-height: none !important;
  max-width: 100% !important;
  margin: 0 !important;
  text-indent: 0 !important;
  border: 0 none !important;
  background: none !important;
  line-height: inherit !important;
  -webkit-user-select: auto !important;
  -webkit-box-shadow: none !important;
  box-shadow: none !important;
}
.selectize-input > input::-ms-clear {
  display: none;
}
.selectize-input > input:focus {
  outline: none !important;
}
.selectize-input::after {
  content: ' ';
  display: block;
  clear: left;
}
.selectize-input.dropdown-active::before {
  content: ' ';
  display: block;
  position: absolute;
  background: #ffffff;
  height: 1px;
  bottom: 0;
  left: 0;
  right: 0;
}
.selectize-dropdown {
  position: absolute;
  z-index: 10;
  border: 1px solid #d0d0d0;
  background: #ffffff;
  margin: -1px 0 0 0;
  border-top: 0 none;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  -webkit-border-radius: 0 0 4px 4px;
  -moz-border-radius: 0 0 4px 4px;
  border-radius: 0 0 4px 4px;
}
.selectize-dropdown [data-selectable] {
  cursor: pointer;
  overflow: hidden;
}
.selectize-dropdown [data-selectable] .highlight {
  background: rgba(255, 237, 40, 0.4);
  -webkit-border-radius: 1px;
  -moz-border-radius: 1px;
  border-radius: 1px;
}
.selectize-dropdown [data-selectable],
.selectize-dropdown .optgroup-header {
  padding: 3px 12px;
}
.selectize-dropdown .optgroup:first-child .optgroup-header {
  border-top: 0 none;
}
.selectize-dropdown .optgroup-header {
  color: #777777;
  background: #ffffff;
  cursor: default;
}
.selectize-dropdown .active {
  background-color: #f5f5f5;
  color: #262626;
}
.selectize-dropdown .active.create {
  color: #262626;
}
.selectize-dropdown .create {
  color: rgba(51, 51, 51, 0.5);
}
.selectize-dropdown-content {
  overflow-y: auto;
  overflow-x: hidden;
  max-height: 200px;
}
.selectize-control.single .selectize-input,
.selectize-control.single .selectize-input input {
  cursor: pointer;
}
.selectize-control.single .selectize-input.input-active,
.selectize-control.single .selectize-input.input-active input {
  cursor: text;
}
.selectize-control.single .selectize-input:after {
  content: ' ';
  display: block;
  position: absolute;
  top: 50%;
  right: 17px;
  margin-top: -3px;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 5px 5px 0 5px;
  border-color: #333333 transparent transparent transparent;
}
.selectize-control.single .selectize-input.dropdown-active:after {
  margin-top: -4px;
  border-width: 0 5px 5px 5px;
  border-color: transparent transparent #333333 transparent;
}
.selectize-control.rtl.single .selectize-input:after {
  left: 17px;
  right: auto;
}
.selectize-control.rtl .selectize-input > input {
  margin: 0 4px 0 -2px !important;
}
.selectize-control .selectize-input.disabled {
  opacity: 0.5;
  background-color: #ffffff;
}
.selectize-dropdown,
.selectize-dropdown.form-control {
  height: auto;
  padding: 0;
  margin: 2px 0 0 0;
  z-index: 1000;
  background: #ffffff;
  border: 1px solid #cccccc;
  border: 1px solid rgba(0, 0, 0, 0.15);
  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  border-radius: 4px;
  -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
}
.selectize-dropdown .optgroup-header {
  font-size: 12px;
  line-height: 1.42857143;
}
.selectize-dropdown .optgroup:first-child:before {
  display: none;
}
.selectize-dropdown .optgroup:before {
  content: ' ';
  display: block;
  height: 1px;
  margin: 9px 0;
  overflow: hidden;
  background-color: #e5e5e5;
  margin-left: -12px;
  margin-right: -12px;
}
.selectize-dropdown-content {
  padding: 5px 0;
}
.selectize-dropdown-header {
  padding: 6px 12px;
}
.selectize-input {
  min-height: 34px;
}
.selectize-input.dropdown-active {
  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  border-radius: 4px;
}
.selectize-input.dropdown-active::before {
  display: none;
}
.selectize-input.focus {
  border-color: #66afe9;
  outline: 0;
  -webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, 0.6);
  box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, 0.6);
}
.has-error .selectize-input {
  border-color: #a94442;
  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
}
.has-error .selectize-input:focus {
  border-color: #843534;
  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ce8483;
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ce8483;
}
.selectize-control.multi .selectize-input.has-items {
  padding-left: 9px;
  padding-right: 9px;
}
.selectize-control.multi .selectize-input > div {
  -webkit-border-radius: 3px;
  -moz-border-radius: 3px;
  border-radius: 3px;
}
.form-control.selectize-control {
  padding: 0;
  height: auto;
  border: none;
  background: none;
  -webkit-box-shadow: none;
  box-shadow: none;
  -webkit-border-radius: 0;
  -moz-border-radius: 0;
  border-radius: 0;
}


code:
/*
 * Copyright (c) 2012-2013 Thibaut Courouble
 * http://www.cssflow.com
 *
 * Licensed under the MIT License:
 * http://www.opensource.org/licenses/mit-license.php
 */

label {
 margin:0;
 padding:0;
}

.switch {
  position: relative;
  display: inline-block;
  vertical-align: top;
  width: 75px;
  height: 20px;
  padding: 3px;
  background-color: white;
  border-radius: 18px;
  box-shadow: inset 0 -1px white, inset 0 1px 1px rgba(0, 0, 0, 0.05);
  cursor: pointer;
  background-image: -webkit-linear-gradient(top, #eeeeee, white 25px);
  background-image: -moz-linear-gradient(top, #eeeeee, white 25px);
  background-image: -o-linear-gradient(top, #eeeeee, white 25px);
  background-image: linear-gradient(to bottom, #eeeeee, white 25px);
}

.switch-input {
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
}

.switch-label {
  position: relative;
  display: block;
  height: inherit;
  font-size: 10px;
  text-transform: uppercase;
  background: #eceeef;
  border-radius: inherit;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.12), inset 0 0 2px rgba(0, 0, 0, 0.15);
  -webkit-transition: 0.15s ease-out;
  -moz-transition: 0.15s ease-out;
  -o-transition: 0.15s ease-out;
  transition: 0.15s ease-out;
  -webkit-transition-property: opacity background;
  -moz-transition-property: opacity background;
  -o-transition-property: opacity background;
  transition-property: opacity background;
}

.switch-label:before, .switch-label:after {
  position: absolute;
  top: 50%;
  margin-top: -.5em;
  line-height: 1;
  -webkit-transition: inherit;
  -moz-transition: inherit;
  -o-transition: inherit;
  transition: inherit;
}

.switch-label:before {
  content: attr(data-off);
  right: 11px;
  color: #aaa;
  text-shadow: 0 1px rgba(255, 255, 255, 0.5);
}

.switch-label:after {
  content: attr(data-on);
  left: 11px;
  color: white;
  text-shadow: 0 1px rgba(0, 0, 0, 0.2);
  opacity: 0;
}

.switch-input:checked ~ .switch-label {
  background: #3b6eb4;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15), inset 0 0 3px rgba(0, 0, 0, 0.2);
}

.switch-input:checked ~ .switch-label:before {
  opacity: 0;
}

.switch-input:checked ~ .switch-label:after {
  opacity: 1;
}

.switch-handle {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 18px;
  height: 18px;
  background: white;
  border-radius: 10px;
  box-shadow: 1px 1px 5px rgba(0, 0, 0, 0.2);
  background-image: -webkit-linear-gradient(top, white 40%, #f0f0f0);
  background-image: -moz-linear-gradient(top, white 40%, #f0f0f0);
  background-image: -o-linear-gradient(top, white 40%, #f0f0f0);
  background-image: linear-gradient(to bottom, white 40%, #f0f0f0);
  -webkit-transition: left 0.15s ease-out;
  -moz-transition: left 0.15s ease-out;
  -o-transition: left 0.15s ease-out;
  transition: left 0.15s ease-out;
}

.switch-handle:before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  margin: -6px 0 0 -6px;
  width: 12px;
  height: 12px;
  background: #f9f9f9;
  border-radius: 6px;
  box-shadow: inset 0 1px rgba(0, 0, 0, 0.02);
  background-image: -webkit-linear-gradient(top, #eeeeee, white);
  background-image: -moz-linear-gradient(top, #eeeeee, white);
  background-image: -o-linear-gradient(top, #eeeeee, white);
  background-image: linear-gradient(to bottom, #eeeeee, white);
}

.switch-input:checked ~ .switch-handle {
  left: 59px;
  box-shadow: -1px 1px 5px rgba(0, 0, 0, 0.2);
}

.switch-green > .switch-input:checked ~ .switch-label {
  background: #4fb845;
}


code:
/**
 * HTML5 Drag and Drop uploader
 *
 * This file has been adapted for the needs of pagures from the work done by
 * Noah Petherbridge in https://github.com/kirsle/flask-multi-upload/
 * (released under public domain).
 *
 */

function doUpload(csrf_token, files) {
  $("#progress").show();
  var $progressBar   = $("#progress-bar");

  // Gray out the form.
  //$("#upload-form :input").attr("disabled", "disabled");

  // Initialize the progress bar.
  $progressBar.css({"width": "0%"});
  var fd = new FormData();
  fd.append('csrf_token', csrf_token);

  // Attach the files.
  for (var i = 0, ie = files.length; i < ie; i++) {
    // Collect the other form data.
    fd.append("filestream", files[i]);
  }

  var xhr = $.ajax({
    xhr: function() {
      var xhrobj = $.ajaxSettings.xhr();
      if (xhrobj.upload) {
        xhrobj.upload.addEventListener("progress", function(event) {
          var percent = 0;
          var position = event.loaded || event.position;
          var total    = event.total;
          if (event.lengthComputable) {
            percent = Math.ceil(position / total * 100);
          }

          // Set the progress bar.
          if (percent > 2){
            $progressBar.css({"color": "white"});
          }
          $progressBar.css({"width": percent + "%"});
          $progressBar.text(percent + "%");
        }, false)
      }
      return xhrobj;
    },
    url: UPLOAD_URL,
    method: "POST",
    contentType: false,
    processData: false,
    cache: false,
    data: fd,
    success: function(data) {
      $progressBar.css({"width": "100%", "color": "white"});

      // How'd it go?
      if (data.output === "notok") {
        // Uh-oh.
        window.alert(data);
        return;
      }
      else {
        console.log(data);
        var _txt = $("#comment").val();
        if (_txt) {
          _txt += '\n';
        }
        $("#comment").val(
           _txt
           + '[![' + data.filename + '](' + data.filelocation + ')]('
            + data.filelocation + ')'
        )
      }
      setTimeout(
        function(){
          $("#progress").hide()
        },
        1000  /* 1 000ms = 2 s */
      );
    },
    error: function(data) {
      $("#progress").hide();
      var text = data.responseText;
      if ( !text || text === "" ) {
        text = '
 An error occured when uploading your file. Could it be '
          + 'that it exceeds the maximum limit allowed?
'
          + '
Please contact an admin if this problem persist or is '
          + 'blocking you. Thanks!
';
      }
      var _elt = $('
' + text + '
');
      _elt.dialog({
        height: 'auto',
        width: '50%',
        modal: true,
        cache: false,
        close: function() {
            $(this).html("");
        },
      });
    }
  });
}

function initDropbox(csrf_token, id, upload) {
  if(typeof upload === 'undefined'){
    upload = true;
  }
  var $dropbox = $(id);

  // On drag enter...
  $dropbox.on("dragenter", function(e) {
    console.log('dragenter');
    e.stopPropagation();
    e.preventDefault();
    $(this).addClass("active");
  });

  // On drag over...
  $dropbox.on("dragover", function(e) {
    console.log('dragover');
    e.stopPropagation();
    e.preventDefault();
  });

  // On drop...
  $dropbox.on("drop", function(e) {
    console.log('drop');
    e.preventDefault();
    $(this).removeClass("active");

    // Get the files.
    var files = e.originalEvent.dataTransfer.files;

    if (upload == true) {
        doUpload(csrf_token, files);
    };
});

  // If the files are dropped outside of the drop zone, the browser will
  // redirect to show the files in the window. To avoid that we can prevent
  // the 'drop' event on the document.
  function stopDefault(e) {
    e.stopPropagation();
    e.preventDefault();
  }
  $(document).on("dragenter", stopDefault);
  $(document).on("dragover", stopDefault);
  $(document).on("drop", stopDefault);
}


code:
{% macro browse_header(select) -%}

    <form action="{{url_for('search')}}" id="headerSearch" class="m-y-2">

      <select name="type" class="c-select" style="display:none;">
        <option value="projects"{% if select=='projects' %} selected {% endif %}>Projects</option>
        <option value="projects_forks"{% if select=='projects_forks' %} selected {% endif %}>Projects & Forks</option>
        <option value="user"{% if select=='users' %} selected {% endif %}>Users</option>
      </select>

      <input type="text" name="term" id="term" placeholder="{%
        if select=='projects' %}Search projects{%
        elif select=='users' %} Search Users {%
        elif select=='groups'%} Search Groups{%
        endif %}" class="form-control" title="Search" />
      <input type="submit" style="display:none;" value="Search" class="btn btn-primary" />
    </form>

    Projects

    Users

  {% if config.get('ENABLE_USER_MNGT', True) %}

    Groups

  {% endif %}

{%- endmacro %}


code:
{% macro render_field(field, after="") %}

  {{ field.label }}{{ field(**kwargs)|safe }}
  {% if after %} {{ after }}{% endif %}
  {% if field.errors %}

    {% for error in field.errors %}

{{ error }}

    {% endfor %}

  {% endif %}

{% endmacro %}

{% macro render_bootstrap_field(field, field_description="", formclass="") %}
  <fieldset class="form-group {% if field.errors %}has-error{% endif %} {% if formclass %}issue-metadata-form{% endif %}">
    {% set formclasses = "form-control"%}
    {% if field.errors %} {% set formclasses = formclasses + " form-control-error" %} {% endif %}
    {% if field.type == "SelectField" %} {% set formclasses = formclasses + " c-select" %} {% endif %}

    {% if field.type == 'BooleanField' %}
      {% set formclasses = formclasses + " checkbox-inline" %}

          {{ field(type='checkbox', **kwargs) }}

          {{ field.label }}

        {% if field_description %}
          {{ field_description }}
        {% endif %}
    {% else %}
      {{ field.label }}
      {{ field(class_=formclasses)|safe }}

        {% if field_description %}
          {{field_description}}
        {% endif %}
        {% if field.errors %}

          {% for error in field.errors %}
            {{ error }}
          {% endfor %}

        {% endif %}

    {% endif %}
  </fieldset>
{% endmacro %}

(class_="c-select")

{% macro render_field_invert(field, after="") %}

  {{ field(**kwargs)|safe }}{{ field.label }}
  {% if after %} {{ after }}{% endif %}
  {% if field.errors %}

    {% for error in field.errors %}

{{ error }}

    {% endfor %}

  {% endif %}

{% endmacro %}

{% macro render_field_in_row(field, after="") %}

    {{ field.label }}
    {{ field(**kwargs)|safe }}
{% if after %} {{ after }}	{% endif %}
{% if field.errors %}
{% for error in field.errors %}
{{ error }}
{% endfor %}
{% endif %}

{% endmacro %}

{% macro render_field_in_cell(field, after="") %}
    {{ field.label }}
    {{ field(**kwargs)|safe }}
{% if after %} {{ after }}	{% endif %}
{% if field.errors %}
{% for error in field.errors %}
{{ error }}
{% endfor %}
{% endif %}
{% endmacro %}

{% macro render_field_in_list(field) %}

{{ field.label }}

{{ field(**kwargs)|safe }}

{% if field.errors %}
{% for error in field.errors %}

{{ error }}

{% endfor %}
{% endif %}
{% endmacro %}

{% macro show_comment(comment, id, repo, username, issueid, form, repo_admin) %}

    {{ comment.user.default_email | avatar(16) | safe }}

      {{ comment.user.user }}

      {{ comment.date_created | humanize}}

        {%- if id == 0 -%}
{{ comment.content | markdown | noJS | safe }}
        {%- else -%}
{{ comment.comment | markdown | noJS | safe }}
        {%- endif -%}

      {% if comment.edited_on %}
          Edited {{ comment.edited_on | humanize }} by {{ comment.editor.username }}
      {% endif %}

          {% if id != 0 and g.fas_user and comment.parent.status in [True, 'Open'] %}

          {% endif %}
          {% if id != 0 and g.fas_user and repo_admin or (
              comment.parent.status in [True, 'Open']
              and g.fas_user.username == comment.user.username) %}

          {% endif %}
          {% if id != 0 and g.fas_user and repo_admin or (
              comment.parent.status in [True, 'Open']
              and g.fas_user.username == comment.user.username) %}
          <button class="btn btn-secondary btn-sm" type="submit"
              name="drop_comment" value="{{ comment.id }}"
              onclick="return confirm('Do you really want to remove this comment?');"
              title="Remove comment">

          </button>
          {% endif %}

{% endmacro %}

{% macro show_initial_comment(comment, username, repo, issueid, repo_admin, form) %}

{{ comment.content | markdown | noJS | safe }}

      {% if g.fas_user %}

      {% endif %}
      {% if repo_admin or (
        g.fas_user and g.fas_user.username == comment.user.username) %}

      {% endif %}
      {% if repo_admin %}
        <button class="btn btn-danger btn-sm" type="submit" id="closeticket"
            title="Delete this ticket">

        </button>
      {% endif %}

{% endmacro %}


code:
{% macro render_row(items) -%}
    {% for repo in items %}
        {% if repo.is_fork %}
        {% set url = url_for('view_repo', username=repo.user.username, repo=repo.name) %}
        {% else %}
        {% set url = url_for('view_repo', repo=repo.name) %}
        {% endif %}

      {% if repo.avatar_email %}

      {% else %}

      {% endif %}

{{ repo.name }}

        {% if repo.description %}{{ repo.description }}{%else%}no description{% endif %}

        created {{repo.date_created|humanize}}

{{repo.forks|count}}

    {% else %}

No projects found

    {% endfor %}
{%- endmacro %}

{% macro pagination_link(pagetitle, page, total, sorting=None) -%}
{% set prev_page = "%s?%s=%s" % (request.base_url, pagetitle, page - 1) %}
{% set next_page = "%s?%s=%s" % (request.base_url, pagetitle, page + 1) %}
{% if sorting %}
{% set prev_page = "%s&sorting=%s" % (prev_page, sorting) %}
{% set next_page = "%s&sorting=%s" % (next_page, sorting) %}
{% endif %}

        <li {% if page <= 1%} class="disabled" {% endif %}>

            «
            Newer

page {{ page }} of {{ total }}

= total %}class="disabled"{%endif%}>

            »
            Older

{%- endmacro %}

{% macro render_repos(
        list, total, pagetitle, page, title, count, id,
        username=None, hide=True, sorting=None) %}

{{
            title
            }} {{ count }}
            {%- if username -%}

            <button type="button" class="btn btn-success pull-xs-right">
              New Project
            </button>

            {%- endif -%}

            {% if total and total > 1 %}
            {{ pagination_link(pagetitle, page, total, sorting) }}
            {% endif %}

              <button type="button" class="btn btn-secondary dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                Sort
              </button>

                  {% if not sorting or sorting == 'name'%}

                  {%endif%}
                  Name

                  {% if sorting == 'latest'%}

                  {%endif%}
                  Recent First

                  {% if sorting == 'oldest'%}

                  {%endif%}
                  Oldest First

            {{ render_row(list) }}

        {% if total and total > 1 %}
        {{ pagination_link(pagetitle, page, total, sorting) }}
        {% endif %}

{% endmacro %}

{% macro render_user_repos(
        list, total, pagetitle, page, title, count, id, username=None, hide=True) %}

              {{ title }} {{ count }}

          {% if total and total > 1 %}
          {{ pagination_link(pagetitle, page, total) }}
          {% endif %}

            {% for repo in list %}

{{ repo.name }}

            {% else %}

No projects found

            {% endfor %}

          {% if total and total > 1 %}
          {{ pagination_link(pagetitle, page, total) }}
          {% endif %}

{% endmacro %}

{% macro repos_switch(all=True, hide=True) %}

            {% if all %}My repos:{% else %}Repos:{% endif %}

            <input type="checkbox" class="switch-input"
                name="{% if all %}my{% endif %}repos"
                {%- if (
                    (all and 'myrepos' in config.get('SHOW_PROJECTS_INDEX', []))
                    or
                    (not all and 'repos' not in config.get('SHOW_PROJECTS_INDEX', []))
                  )
                  or not hide %} checked {% endif %}/>

        Forks:

            <input type="checkbox" class="switch-input"
                name="{% if all %}my{% endif %}forks" {%
                if 'myforks' in config.get('SHOW_PROJECTS_INDEX', []) or not hide
                %} checked {% endif %}/>

        {% if all %}
        All repos:

            <input type="checkbox" class="switch-input"
                name="repos" id="allrepos" {%
                if 'repos' in config.get('SHOW_PROJECTS_INDEX', []) or not hide
                %} checked {% endif %}/>

        {% endif %}

{% endmacro %}

{% macro render_repos_as_card(list, total, name, pagetitle, page, total_page) %}
        {% if total_page and total_page > 1 %}
        {{ pagination_link(pagetitle, page, total_page) }}
        {% endif %}

            {{name}} {{total}}

          {% if list %}

            {% for repo in list %}

                {% if repo.is_fork %}
                  {% set url = url_for('view_repo', username=repo.user.username, repo=repo.name) %}
                {% else %}
                  {% set url = url_for('view_repo', repo=repo.name) %}
                {% endif %}

                {% if repo.avatar_email %}

                {% else %}

                {% endif %}

                      {{ repo.name }}

                  {% if
                    repo.description %}{{ repo.description }}{%
                    else %}no description{%
                    endif %}

            {% endfor %}

        {% else %}

No projects found

        {% endif %}

        {% if total_page and total_page > 1 %}
        {{ pagination_link(pagetitle, page, total_page) }}
        {% endif %}
{% endmacro %}

{% macro render_contributions_graph(username) %}
  {% if config.get('DATAGREPPER_URL') %}

      Contributions View List

  {% endif %}
{% endmacro%}


code:
{% extends "repo_master.html" %}

{% block title %}Activity - {{ repo.name }}{% endblock %}
{% set tag = "home" %}

{% block repo %}

    No activity reported on the {{repo.name}} project

  <button class="btn btn-secondary" style="display:none;" id='loadmore'>
    Load more
  </button>

{% endblock %}

{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% extends "master.html" %}
{% from "_formhelper.html" import render_field_in_row %}

{% set tag = "groups" %}
{% block title %}Create group{% endblock %}

{% block content %}

Create group

    <form action="{{ url_for('.add_group') }}" method="post">

      {{ render_field_in_row(form.group_name) }}
      {%- if admin %}
      {{ render_field_in_row(form.group_type) }}
      {%- endif %}

      <input type="submit" class="submit positive button" value="Add">
      <input type="button" value="Cancel" class="button"
       onclick="history.back();">
      {{ form.csrf_token }}

  </form>

{% endblock %}


code:
{% extends "repo_master.html" %}
{% from "_formhelper.html" import render_field_in_row %}

{% set tag = "groups" %}

{% block header %}
<link href="{{ url_for('static', filename='selectize.bootstrap3.css') }}"
  rel="stylesheet" />
{% endblock %}

{% block title %}Add group - {{ repo.name }}{% endblock %}

{% block repo %}

      Add group to the {{repo.name}} project

      <form action="{{ url_for('.add_group_project',
                       username=username, repo=repo.name) }}" method="post">

      <fieldset class="form-group">
        Username
        <input class="form-control" name="group" id="group"
          placeholder="Start typing to search groups"
          value="" />
      </fieldset>

        <input type="button" value="Cancel" class="btn btn-secondary" onclick="history.back();">
        <input type="submit" class="btn btn-primary" value="Add">
        {{ form.csrf_token }}

    </form>

{% endblock %}

{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% extends "repo_master.html" %}
{% from "_formhelper.html" import render_field_in_row %}

{% set tag = "home" %}
{% block title %}Create token{% endblock %}

{% block repo %}

          Create a new token

          <form action="{{
              url_for('.add_token', username=username, repo=repo.name)
          }}" method="post">
            {% for acl in acls %}

                <input type="checkbox" name="acls" value="{{ acl.name }}">

                {{ acl.description }}

            {% endfor %}

            <input type="submit" class="btn btn-primary" value="Add">
            <input type="button" value="Cancel" class="btn btn-secondary"
             onclick="history.back();">
            {{ form.csrf_token }}

        </form>

{% endblock %}


code:
{% extends "repo_master.html" %}
{% from "_formhelper.html" import render_field_in_row %}

{% set tag = "home" %}

{% block header %}
<link href="{{ url_for('static', filename='selectize.bootstrap3.css') }}"
  rel="stylesheet" />
{% endblock %}

{% block title %}Add user - {{ repo.name }}{% endblock %}

{% block repo %}

      Add user to the {{repo.name}} project

      <form action="{{ url_for('.add_user',
                       username=username, repo=repo.name) }}" method="post">

      <fieldset class="form-group">
        Username
        <input class="form-control" name="user" id="user"
          placeholder="Start typing to search users"
          value="" />
      </fieldset>

        <input type="button" value="Cancel" class="btn btn-secondary" onclick="history.back();">
        <input type="submit" class="btn btn-primary" value="Add">
        {{ form.csrf_token }}

    </form>

{% endblock %}

{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% extends "master.html" %}

{% block title %}Home{% endblock %}
{% set tag = "admin" %}

{% block content %}

Admin section

    <form action="{{ url_for('admin_generate_acl') }}" method="post">
    <input type="submit" class="submit positive button"
        value="Re-generate gitolite ACLs file">
    {{ form.csrf_token }}
    </form>

    <form action="{{ url_for('admin_refresh_ssh') }}" method="post">
    <input type="submit" class="submit positive button"
        value="Re-generate user ssh key files">
    {{ form.csrf_token }}
    </form>

    <form action="{{ url_for('admin_generate_hook_token') }}"
        method="post"
        onsubmit="return confirm('Are you sure to re-generate the hook-token'
            + ' of every projects?\nThis will break every web-hook in place '
            + 'and cannot be un-done.');">
    <input type="submit" class="submit positive button"
        value="Re-generate hook-token for every projects">
    {{ form.csrf_token }}
    </form>

      This action can be used in case you need to change the hook-token for
      *all* the projects hosted on this pagure instance. This can be due to
      security reason. Beware that using it will break every web-hook
      consumer of every project hosted.

     Groups/Users management

{% endblock %}


code:
{% extends "master.html" %}

{% block title %} API | pagure {% endblock %}

{% set tag = "index" %}

{% block content %}

              Pagure API Reference

          This documentation describes the Pagure API v{{ version[0] }}
          revision {{ version[1] }}.

        {{ api_doc |replace('h1', 'h2') }}

List of the API endpoints:

            Projects

        {% for html in projects %}
        {{ html | InsertDiv | safe }}
        {% endfor %}

        {% if issues %}

            Issues

        {% for html in issues %}
        {{ html | InsertDiv | safe }}
        {% endfor %}

        {% endif %}

            Pull-requests

        {% for html in requests %}
        {{ html | InsertDiv | safe }}
        {% endfor %}

            Users

        {% for html in users %}
        {{ html | InsertDiv | safe }}
        {% endfor %}

            Extras

        {% for html in extras %}
        {{ html | InsertDiv |safe }}
        {% endfor %}

{% endblock %}

{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% if not is_js %}
{% extends "repo_master.html" %}
{% endif %}

{% block repo %}

  <form action="{{ request.base_url }}" method="post"
    onsubmit="return try_async_comment(this, null)" >

        <textarea class="form-control" id="update_comment" name="update_comment" style="width:100%;">
          {{- comment.comment -}}
        </textarea>

  {{ form.csrf_token }}

      <input type="hidden" name="edit_comment" value="{{ comment.id }}" />
      <input type="submit" class="btn btn-primary" value="Update" />
      <input type="button" id="comment_update_cancel" class="btn btn-secondary cancel" value="Cancel" {% if not is_js -%}
        onclick="history.back();"{% endif %} />

  </form>

{% endblock %}


code:
{% extends "repo_master.html" %}

{% block title %}Commit - {{ repo.name }} - {{ commitid }}{% endblock %}
{% set tag = "commit"%}

{% block repo %}

{% set splitted_message = commit.message.split('\n') %}

    Commit {{ commitid|short }}
    {{ splitted_message[0] }}

      raw
      patch
      tree
      {% if commit.parents|length == 1 %}
      parent
      {% elif commit.parents|length > 1 %}

        <button id="parentsDrop" type="button" class="btn btn-secondary btn-sm dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
          parents
        </button>

          {% for parent in commit.parents %}
            {{parent.oid.hex}}
          {% endfor %}

      {% endif%}

    {% if commit.author| author2user == commit.committer| author2user %}
      {{diff|count}} file{{'s' if diff|count > 1}} Authored and Committed by {{ commit.author | author2user |safe }}
      {{commit.commit_time | humanize}}
    {% else %}
    {{diff|count}} file{{'s' if diff|count > 1}} Authored by {{ commit.author | author2user |safe }}
      {{commit.commit_time | humanize}},
    Committed by {{ commit.committer | author2user |safe }}
      {{commit.commit_time | humanize}},
    {% endif%}

  {% set filecount = 0 %}
  {% for patch in diff %}
      {% set filecount = filecount + 1 %}
      {% if patch | hasattr('new_file_path') %}

          {{  patch.new_file_path | unicode}}
      {% elif patch | hasattr('delta') %}

          {{  patch.delta.new_file.path | unicode }}
      {% endif %}

        {% if not patch.is_binary  %}
        {% if patch | hasattr('additions') %}
        {% if (patch.additions + patch.deletions) %}

            {% if patch.additions > 0 %}+{{ patch.additions }}{% endif %}
            {% if patch.deletions > 0 %}-{{ patch.deletions }}{% endif %}

        {% endif %}
        {% else %}
        {% if (patch.line_stats[1] + patch.line_stats[2]) %}

            {% if patch.line_stats[1] > 0 %}+{{ patch.line_stats[1] }}{% endif %}
            {% if patch.line_stats[2] > 0 %}-{{ patch.line_stats[2] }}{% endif %}

        {% endif %}
        {% endif %}
        {% endif %}

      {{ patch.new_file_path | unicode }}

  {% endfor %}

    {% if splitted_message|length > 1 %}

        {% for message in splitted_message %}
{{ message }}
        {% endfor %}

    {% endif %}

{% set filecount = 0 %}
{% for patch in diff %}
  {% set filecount = filecount + 1 %}

    {% if patch | hasattr('new_file_path') %}

        {{  patch.new_file_path | unicode }}

    {% elif patch | hasattr('delta') %}

        {{  patch.delta.new_file.path | unicode }}

    {% endif %}
        {% if not patch.is_binary  %}
          {% if patch | hasattr('additions') %}
          {% if (patch.additions + patch.deletions) %}

              {% if patch.additions > 0 %}+{{ patch.additions }} {% endif %}
              {% if patch.deletions > 0 %}-{{ patch.deletions }}{% endif %}

          {% endif %}
          {% else %}
          {% if (patch.line_stats[1] + patch.line_stats[2]) %}

              {% if patch.line_stats[1] > 0 %}+{{ patch.line_stats[1] }} {% endif %}
              {% if patch.line_stats[2] > 0 %}-{{ patch.line_stats[2] }}{% endif %}

          {% endif %}
          {% endif %}
          {% endif %}

    {% if patch.is_binary %}

Binary diffs cannot be rendered.

    {% else %}
        {% autoescape false %}
        {{ patch|patch_to_diff|html_diff}}
        {% endautoescape %}
    {% endif %}

{% endfor %}

{% endblock %}

{% block jscripts %}
    {{ super() }}

{% endblock %}


code:
{% extends "repo_master.html" %}

{% block title %}{{ select.capitalize() }} - {{ repo.name }}{% endblock %}
{% set tag = "home" %}

{% block repo %}

    {% if repo_obj and repo_obj.is_empty %}

This repo is brand new!

There are no commits to this project yet

    {% else %}

      Commits  {{number_of_commits}}

        {% if repo.is_fork %}

        {{ repo.user.user }}/{{ repo.name }}
        {% else %}
         {{ repo.name }}
        {% endif %}

      {% if branchname %}

          <button type="button" class="btn btn-secondary btn-sm dropdown-toggle"
                  data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                    {{ branchname }}
          </button>

            {% for branch in branches %}

                  {{ branch }}

            {% endfor %}

      {% endif %}

    {% if diff_commits|count > 0 %}

      This branch contains
      {{ diff_commits|count }} commits not in
      {% if repo.is_fork %}
        the upstream project

          {{ repo.name }}

      {% else %}
        the main branch
      {% endif %}

        {{head}}

      {% if diff_commits and authenticated and
        (repo.is_fork or repo.settings.get('pull_requests', True)) %}

              {% if repo_admin %}Request pull{% else %}Compare{% endif %}

      {% endif %}

        {% for diff_commit_full in diff_commits_full %}

                {{ diff_commit_full.message.split('\n')[0] }}

                    {{ diff_commit_full.commit_time|humanize }}

              {{ diff_commit_full.author | author2avatar(20) | safe }}
              {{ diff_commit_full.author.name }}

                  {{ diff_commit_full.hex|short }}

        {% endfor %}

    {% endif %}

        {% for commit in last_commits %}

            {% if diff_commits and commit.oid.hex in diff_commits %}

            {% endif %}

              {{ commit.message.split('\n')[0] }}

                  {{ commit.commit_time|humanize }}

            {{ commit.author | author2avatar(20) | safe }} {{ commit.author.name }}

              {{ commit.hex|short }}

        {% endfor %}

      {% if total_page %}

            <li {% if page <= 1%} class="disabled" {% endif %}>

                «
                Newer

page {{ page }} of {{total_page}}

= total_page %}class="disabled"{%endif%}>

                »
                Older

      {% endif %}
    {% endif %}

{% endblock %}

{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% extends "master.html" %}

{% block title %}Doc: SSH hostkeys/Fingerprints{% endblock %}
{% set tag = "home" %}

{% block content %}

SSH Hostkeys/Fingerprints

{% if config.get('SSH_KEYS') %}

    SSH host keys and fingerprints can be use to ensure you are connecting to
pagure's server and not someone else's.

Here below are the SSH Hostkey and the Fingerprint of this current pagure
instance:

{% for cert in config.get('SSH_KEYS') %}
  {% for type in config['SSH_KEYS'][cert] %}

      {{ cert }} {{ type | title }}

{{ config['SSH_KEYS'][cert][type] }}

  {% endfor %}
{% endfor %}

{% else %}

No SSH keys have been specified in the configuration file.
You should ask an admin to fill this information.

{% endif %}

{% endblock %}


code:
{% extends "repo_master.html" %}

{% block title %}Docs - {{ repo.name }}{% endblock %}
{% set tag = "home" %}

{% block repo %}

Your browser does not support iframe, please visit
  the documentation directly

{% endblock %}


code:
{% extends "repo_master.html" %}
{% from "_formhelper.html" import render_field %}

{% block title %}Edit - {{ repo.name }}{% endblock %}
{% set tag = "home" %}
{% block header %}

<link rel="stylesheet" href="{{ url_for('static', filename='codemirror/codemirror.css') }}">
{% endblock%}

{% block repo %}

  {{ branchname }}
{%
    for file in filename.split('/') %}
      {% if loop.first %}
      {% set path = file %}
      {% else %}
      {% set path = path + '/' + file %}
      {% endif %}
      {% if loop.index != loop.length %}
  {{ file }}
{% elif file %}
  {{ file }}
{% endif %}
    {% endfor %}

    <form action="{{ url_for(
          'edit_file', username=username, repo=repo.name,
          branchname=branchname, filename=filename) }}"
          method="post">
    {{ form.csrf_token }}

    <textarea id="textareaCode" name="content">{{ data }}</textarea>

      <fieldset class="form-group">
        Committing as

          <select id="email" name="email" class="c-select">
            {% for email in user.emails %}
            <option value="{{ email.email }}" {%
                if form.email.data == email.email %}selected{%
                endif %}>{{ email.email }}</option>
            {% endfor %}
          </select>
          {{ user.default_email | avatar(16) | safe }}
          {{ user.fullname }}

      </fieldset>
      <fieldset class="form-group">
        Branch

          <select name="branch" class="c-select">
            {% for branch in branches %}
            <option value="{{ branch }}" {%
                if form.branch.data or branchname == branch %}selected{%
                endif %}>{{ branch }}</option>
            {% endfor %}
          </select>
          <input type="radio" name="braction" value="existing" checked />Existing branch
          <input type="radio" name="braction" value="new" />New branch

      </fieldset>
      <fieldset class="form-group">
        Commit Title
        <input type="text" class="form-control" id="commit_title" name="commit_title"
            placeholder="Update {{ filename }}"
            value="{{ form.commit_title.data if form.commit_title.data else
            'Update %s' % filename }}" />
      </fieldset>
      <fieldset class="form-group">
        Commit Description
        <textarea rows="5" class="form-control" type="text" id="commit_message"
            name="commit_message"
            placeholder="An optional description of the change">
        {{- form.commit_message.data if form.commit_message.data -}}
        </textarea>
      </fieldset>

        <input type="submit" class="btn btn-primary" value="Commit changes">
        <input type="button" class="btn btn-secondary" value="Clear" id="clear_comment" />

    </form>

{% endblock %}

{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% extends "repo_master.html" %}
{% from "_formhelper.html" import render_field_in_row %}

{% block title %}Edit tag: {{ tag }} - {{ repo.name }}{% endblock %}
{% set tag = "home" %}

{% block repo %}

Edit tag: {{ edit_tag }}

    <form action="{{ url_for('.edit_tag',
                     username=username, repo=repo.name, tag=edit_tag) }}" method="post">

Enter in the field below the new name for the tag: "{{ edit_tag }}"

      {{ render_field_in_row(form.tag) }}

      <input type="submit" class="submit positive button" value="Edit">
      <input type="button" value="Cancel" class="button" onclick="history.back();">
      {{ form.csrf_token }}

  </form>

{% endblock %}


code:
{% extends "master.html" %}

{% block title %}A fatal error occured :'({% endblock %}
{% set tag = "error" %}

{% block content %}

Fatal Error (500)

A fatal error has occurred, we're sorry :(

{% endblock %}


code:
{% extends "repo_master.html" %}

{% block title %}Tree - {{ repo.name }}{% endblock %}
{% set tag = "home" %}

{% block repo %}

      Files

        {% if repo.is_fork %}

        {{ repo.user.user }}/{{ repo.name }}
        {% else %}
         {{ repo.name }}
        {% endif %}

      {% if branchname %}

          <button type="button" class="btn btn-secondary btn-sm dropdown-toggle"
                  data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                    {{ branchname }}
          </button>

            {% for branch in branches %}
              {% if origin == 'view_tree' %}

                  {{ branch }}

              {% elif origin == 'view_file' %}

                  {{ branch }}

              {% endif %}
            {% endfor %}

      {% endif %}

                {{ branchname }}

        {% for file in filename.split('/') %}
          {% if loop.first %}
          {% set path = file %}
          {% else %}
          {% set path = path + '/' + file %}
          {% endif %}
          {% if loop.index != loop.length %}

              {{ file }}

          {% elif file %}

              {{ file }}

          {% endif %}
        {% endfor %}

{% if content %}
  {% if output_type in ('file','binary','image','markup') %}

        {% if content %}
          {% if output_type in ('file','binary','image','markup') %}

                {% if output_type in ('file','markup') and repo_admin %}
                Edit
                {% endif %}
                {% if output_type in ('file','markup') %}
                <form class="btn btn-sm" method="POST" name="fork_project"
                    action="{{ url_for('.fork_edit_file', repo=repo.name,
                        username=username, branchname=branchname, filename=filename) }}">
                    <button class="btn btn-sm btn-secondary"
                        onclick="fork_project.submit();">
                            Fork and Edit
                    </button>
                    {{ forkbuttonform.csrf_token }}
                </form>
                {% endif %}
                {% if output_type == 'markup'  %}
                Text
                {% else %}
                Blob
                {% endif %}
                Raw

          {% endif %}
        {% endif %}

    {% if output_type=='file' %}
        {% autoescape false %}
        {{ content | format_loc }}
        {% endautoescape %}
    {% elif output_type == 'markup' %}

        {% autoescape false %}
        {{ content | noJS }}
        {% endautoescape %}

    {% elif output_type == 'image' %}

    {% elif output_type == 'binary' %}

          Binary files cannot be rendered.

          Please
          view the raw version

    {% endif %}

  {% else %}

          {% for entry in content %}

                {% if entry.filemode == 16384 %}

                {% elif entry.filemode == 40960 %}

                {% elif entry.filemode == 57344 %}

                {% else %}

                {% endif %}

                {% if entry.filemode == 16384 %}{% endif -%}

                   {{ entry.name | unicode }}
                {% if entry.filemode == 16384 %}{% endif%}

          {% endfor %}

  {% endif %}
{% else %}
No content found in this repository
{% endif %}

 {% if readme %}

     README{{readme_ext}}

   {% if safe %}
     {{ readme | noJS |safe }}
   {% else %}
     {{ readme | noJS }}
   {% endif %}

 {% endif %}

{% endblock %}

{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% extends "repo_master.html" %}

{% block title %}Forks - {{ repo.name }}{% endblock %}
{% set tag = "home" %}

{% block repo %}

Forks {{repo.forks | count}}

  {% if repo.forks %}

    {% for fork in repo.forks %}

              {{ fork.user.user }}/{{ fork.name }}

              {{ fork.user.default_email | avatar(20) | safe }}
                  {{ fork.user.fullname }} forked this project

                {{ fork.date_created|humanize }}

    {% endfor %}

  {% else %}

    This project has not been forked.

  {% endif %}

{% endblock %}


code:
{% extends "master.html" %}
{% from "_render_repo.html" import render_repos_as_card %}

{% block title %}Group {{ group.name }}{% endblock %}
{% set tag = "groups" %}
{% from "_browseheader.html" import browse_header %}

{% block header %}
<link href="{{ url_for('static', filename='selectize.bootstrap3.css') }}"
  rel="stylesheet" />
{% endblock %}

{% block content %}

        {{browse_header(select=tag)}}

              {{ group.group_name }}
            {% if authenticated and (member or admin)
                and config.get('ENABLE_GROUP_MNGT') %}
              <form class="pull-xs-right" method="POST"
                action="{{ url_for('group_delete',
                    group=group.group_name) }}">
                {{ form.csrf_token }}
                <button
                  onclick="return confirm('Are you sure you want to delete the group `{{group.group_name}}`?');"
                  title="Delete group"
                  class="btn btn-danger">
                    Delete group
                </button>
              </form>
             {% endif %}

          created {{ group.created |humanize }}
          by {{ group.creator.fullname }} ({{ group.creator.user }})

            {{ render_repos_as_card(
                group.projects, group.projects|count, 'Projects') }}

            Group Members {{group.users|count}}
            {% if authenticated and (member or admin) and config.get('ENABLE_GROUP_MNGT') %}

            {% endif %}

            {% if authenticated and (member or admin) and config.get('ENABLE_GROUP_MNGT') %}

              <form action="{{ url_for('.view_group', group=group.group_name)
                }}" method="post" id="add_user_form">
                  <input placeholder="search for user" class="form-control" id="user" name="user" title="User name"/>

                {{ form.csrf_token }}
              </form>

            {% endif %}

            {% for user in group.users %}

                {{ user.default_email | avatar(28) | safe }}
                {{ user.user }}

              {% if authenticated and user != group.creator and (member or admin)
                    and config.get('ENABLE_GROUP_MNGT') %}
               <form class="pull-xs-right" method="POST" style="display: inline-block"
                action="{{ url_for('group_user_delete',
                    group=group.group_name, user=user.user) }}">
                {{ form.csrf_token }}
                <button
                  onclick="return confirm('Are you sure to remove user `{{
                    user.user}}` from the group `{{group.group_name}}`?');"
                  title="Remove user from group"
                  class="btn btn-sm btn-danger">

                </button>
              </form>
              {% endif %}

            {% endfor %}

{% endblock %}

{% block jscripts %}
  {{ super() }}

{% endblock %}


code:
{% extends "master.html" %}

{% block title %}Groups{% endblock %}
{% set tag = "groups" %}

{% from "_browseheader.html" import browse_header %}

{% block header %}
<link href="{{ url_for('static', filename='selectize.bootstrap3.css') }}"
  rel="stylesheet" />
{% endblock %}

{% block content %}

        {{browse_header(select=tag)}}

    Groups {{ groups | length }}
    {% if authenticated and config.get('ENABLE_GROUP_MNGT', False) %}

      <button type="button" id="new_user_btn" data-target="#add_group"
        class="btn btn-success pull-xs-right" data-toggle="modal">
        New Group
      </button>

    {% endif %}

  {% if authenticated %}

          <button type="button" class="close" data-dismiss="modal" aria-label="Close">
            ×
          </button>

Create New Group

        <form action="{{ url_for('.add_group') }}" method="post">

            <fieldset>
              Group Name:
              <input class="form-control" id="group_name" name="group_name" title="Group name" />
              {%- if admin %}
              {{ form.group_type()|safe }}
              {%- endif %}
              {{ form.csrf_token }}
            </fieldset>

            <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
            <input type="submit" class="btn btn-primary" value="Add">

        </form>

  {% endif %}

  {% if total_page and total_page > 1 %}

      <li {% if page <= 1%} class="disabled" {% endif %}>

          «
          Newer

page {{ page }} of {{total_page}}

= total_page %}class="disabled"{%endif%}>

          »
          Older

  {% endif %}

    {% if groups %}
      {% for group in groups %}

{{ group.group_name }}

              Formed {{ group.created |humanize }}

 {{group.projects | count }}   {{group.users | count}}

      {% endfor %}
    {% else %}

No groups have been created on this pagure instance yet

    {% endif %}

{% endblock %}

{% block jscripts %}
    {{ super() }}

{% endblock %}


code:
{% extends "master.html" %}

{% block title %}Home{% endblock %}
{% set tag = "home" %}i

{% from "_render_repo.html" import render_repos, render_user_repos%}
{% from "_browseheader.html" import browse_header %}

{% block header %}
<link href="{{ url_for('static', filename='selectize.bootstrap3.css') }}"
  rel="stylesheet" />
{% endblock %}

{% block content %}

    {{browse_header(select=select)}}

    {{ render_repos(
        repos, total_page, 'page', page,
        'All Projects', repos_length, 'repos', username, sorting=sorting) }}

{% endblock %}

{% block jscripts %}
    {{ super() }}

{% if username %}

{% endif %}

{% endblock %}


code:
{% extends "master.html" %}

{% block title %}Home{% endblock %}
{% set tag = "projects" %}
{% from "_browseheader.html" import browse_header %}

{% block header %}
  <link rel="stylesheet" type="text/css" media="screen"
      href="{{ url_for('static', filename='toggle.css') }}"/>
{% endblock %}

{% from "_render_repo.html" import render_repos_as_card, render_contributions_graph %}

{% block content %}

            My Projects {{repos | count}}
            {% if config.get('ENABLE_NEW_PROJECTS', True) and repos %}

          {% endif %}

          {% if repos %}

            {% for repo in repos %}

                {% if repo.is_fork %}
                  {% set url = url_for('view_repo', username=repo.user.username, repo=repo.name) %}
                {% else %}
                  {% set url = url_for('view_repo', repo=repo.name) %}
                {% endif %}

                  {% if repo.avatar_email %}

                  {% else %}

                  {% endif %}
                  {{ repo.name }}

                    {% if config.get('ENABLE_TICKETS', True) and repo.settings.get('issue_tracker', True) %}
                      {% if repo.open_tickets_public == 0 %}

                          {{- repo.open_tickets_public }}

                      {% else %}

                          {{- repo.open_tickets_public }}

                      {% endif %}
                    {% endif %}

                    {% if repo.open_requests == 0 %}

                        {{- repo.open_requests}}

                    {% else %}

                        {{- repo.open_requests}}

                    {% endif %}

            {% endfor %}

        {% else %}

You have no projects

              {% if config.get('ENABLE_NEW_PROJECTS', True) %}

                 Create a Project

              {% endif %}

        {% endif %}

            My Forks {{forks | count}}

          {% if forks %}

            {% for fork in forks %}

                {% if fork.is_fork %}
                  {% set url = url_for('view_repo', username=fork.user.username, repo=fork.name) %}
                {% else %}
                  {% set url = url_for('view_repo', repo=fork.name) %}
                {% endif %}

                  {{username}}/{{ fork.name }}

                  forked from

                    {{fork.parent.name}}

                  {% if fork.settings.get('issue_tracker', True) %}
                    {% if fork.open_tickets_public == 0 %}

                        {{- fork.open_tickets_public }}

                    {% else %}

                        {{- fork.open_tickets_public }}

                    {% endif %}
                  {% endif %}
                  {% if fork.settings.get('pull_requests', True) %}
                    {% if fork.open_requests == 0 %}

                        {{- fork.open_requests}}

                    {% else %}

                        {{- fork.open_requests}}

                    {% endif %}
                  {% endif %}

            {% endfor %}

        {% else %}

You have no forks

        {% endif %}

        {{render_contributions_graph(username)}}

                My Groups {{ user.groups | length }}

            {% for group in user.groups %}

                      {{ group }}

            {% else %}

No group found

            {% endfor %}

{% endblock %}

{% block jscripts %}
    {{ super() }}

{% endblock %}


code:
{% extends "repo_master.html" %}
{% from "_formhelper.html"
    import render_field, render_bootstrap_field,
           show_comment, show_initial_comment %}

{% block title %}Issue #{{ issueid }}: {{issue.title | noJS(ignore="img") | safe }} - {{ repo.name }}{% endblock %}
{% set tag = "home"%}

{% block header %}
<link href="{{ url_for('static', filename='emoji/emojione.sprites.css') }}"
  rel="stylesheet" />
<link href="{{ url_for('static', filename='selectize.bootstrap3.css') }}"
  rel="stylesheet" />
<link href="{{ url_for('static', filename='atwho/jquery.atwho.min.css') }}"
  rel="stylesheet" />
{% endblock %}

{% block repo %}

  <form action="{{ url_for('update_issue', username=username,
               repo=repo.name, issueid=issueid) }}" method="post"
               onsubmit="return try_async_comment(this)">
  {{ form.csrf_token }}

    #{{ issueid }}
    {{issue.title | noJS("img") | safe }}
    {% if issue.private %}

    {% endif %}

    Created
    {{ issue.date_created | humanize}} by {{ issue.user.user }}

    {{ show_initial_comment(issue, username, repo,issueid, repo_admin, form) }}

      {% if issue.comments %}
        {% for comment in issue.comments %}
        {% if comment.notification %}

                    {{
                        comment.date_created | humanize }}

                {{ comment.comment | markdown | noJS | safe }}

        {% else %}
          {{ show_comment(comment, comment.id, repo, username, issueid, form, repo_admin) }}
        {% endif %}
        {% endfor %}
      {% endif %}

        {% if authenticated and form %}

          <fieldset class="form-group">
            Add new comment

              Preview

            <textarea class="form-control" rows=8 id="comment" name="comment"
                placeholder="Enter your comment here" tabindex=1></textarea>

          </fieldset>

          Select files OR drag them into the comment field below.
          <input id="file-picker" type="file" name="file" accept="image/*"
            multiple tabindex=3 />
          <fieldset id="progress" style="display: none">

0%

          </fieldset>
          Markdown Syntax

            <input type="submit" class="btn btn-primary"
              value="Update Issue" tabindex=2 />
            <input type="button" class="btn btn-secondary"
              value="Clear" id="clear_comment" tabindex=4 />

        {% else %}

            Login
            to comment on this ticket.

        {% endif %}

          <fieldset class="form-group issue-metadata-display">
            Status

              {{ issue.status }}

          </fieldset>

          {% if authenticated and repo_admin %}
            {{ render_bootstrap_field(form.status,
              formclass="issue-metadata-form") }}
          {% endif%}

          <fieldset class="form-group issue-metadata-display">
            Tags

                {% for tag in issue.tags %}

                    {{ tag.tag }}

                {% endfor %}

          </fieldset>

          {% if authenticated and repo_admin %}
          <fieldset class="form-group issue-metadata-form">
            Tags
             <input id="tag" type="text" placeholder="tag1, tag2" name="tag"
                title="comma separated list of tags"
                value="{{ issue.tags_text | join(',') }}" />
          </fieldset>
          {% endif%}

          <fieldset class="form-group issue-metadata-display">
            Assignee

              {% if issue.assignee %}

                    {{ issue.assignee.username }}

              {% else %}
                unassigned
              {% endif %}
              {% if authenticated and repo_admin
                and (not issue.assignee or issue.assignee.username != g.fas_user.username) %}
              <button class="btn btn-sm pull-xs-right" id="take-btn"
                title="assign this issue to you">
                  Take
              </button>
              {% endif %}

          </fieldset>

          {% if authenticated and repo_admin %}
          <fieldset class="form-group issue-metadata-form">
            Assignee
            <input class="form-control" name="assignee" id="assignee"
              placeholder="username"
              value="{{ issue.assignee.username or '' }}" />
          </fieldset>
          {% endif%}

          <fieldset class="form-group issue-metadata-display">
            Blocked

              {% for ticket in issue.parents %}
                #{{ ticket.id }}
              {% endfor %}

          </fieldset>

          {% if authenticated and repo_admin %}
                <fieldset class="form-group issue-metadata-form">
                  Blocked
                  <input class="form-control" id="blocks" type="text"
                    placeholder="issue blocked" name="blocks"
                    value="{{ issue.blocks_text | join(',') }}" />
                </fieldset>
          {% endif%}

          <fieldset class="form-group issue-metadata-display">
            Depends on

              {% for ticket in issue.children %}
                #{{ ticket.id }}
              {% endfor %}

          </fieldset>

          {% if authenticated and repo_admin %}
            <fieldset class="form-group issue-metadata-form">
              Depends on
              <input class="form-control" id="depends" type="text"
                placeholder="issue depending" name="depends"
                value="{{ issue.depends_text | join(',') }}" />
            </fieldset>
          {% endif%}

          {% if repo.priorities %}
          <fieldset class="form-group issue-metadata-display">
            Priority

              {% if issue.priority %}
              {{ repo.priorities[issue.priority | string] }}
              {% endif %}

          </fieldset>
          {% if authenticated and repo_admin %}
            {{ render_bootstrap_field(form.priority,
              formclass="issue-metadata-form") }}
          {% endif%}

          {% endif %}

          <input type="submit" class="btn btn-primary issue-metadata-form" value="Update">

              cancel

          {% if authenticated and repo_admin %}

              Edit Metadata

          {% endif %}

  </form>

{% endblock %}

{% block jscripts %}
{{ super() }}

{% if config['EVENTSOURCE_SOURCE'] and not issue.private %}

{% endif %}

{% endblock %}


code:
{% extends "repo_master.html" %}

{% block title %}Issues - {{ repo.name }}{% endblock %}
{% set tag = "home"%}

{% block repo %}

    {% if status and status != 'Open' %}
      {{ issues|count }} Closed Issues
    {% else %}
      {{ issues|count }} Open Issues
    {% endif %}

    {% if repo.milestones %}

        Roadmap

    {% endif %}

    {% if oth_issues %}

      {% if (issues | length + oth_issues) %}

            {{ (100.0 * (1 - issues | length / (issues | length + oth_issues)))|round|int }}%

      {% endif %}

    {% endif %}

    {% if status and status != 'Open' %}
      Open
      Closed
    {% else %}
      Open
      Closed
    {% endif %}

    {% for tag in tag_list %}
      {% if tag.tag in tags %}
        {% if status and status != 'Open' %}

         {% else %}

         {% endif %}
      {% else %}

      {% endif %}

        {{ tag.tag }}
    {% endfor %}

            Issue
            Opened
            {% if status and status|lower != 'open' %}
            Closed
            {% endif %}

                Priority (reset)

                Reporter (reset)

            {% if not status or status|lower == 'open' %}

              Assignee (reset)

            {% endif %}

    {% for issue in issues %}

              #{{ issue.id }}
              {% if status and status != 'Open' %}
              {{issue.status}}
              {% endif %}
              {% if issue.private %}

              {% endif %}

                {{ issue.title | noJS("img") | safe }}

              {% if issue.user_comments|count > 0 %}

                  {{issue.user_comments|count}}

              {% endif %}
              {% for tag in issue.tags%}
                {{tag.tag}}
              {% endfor%}

                {{
                        issue.date_created | humanize}}

            {% if status and status|lower != 'open' %}

                {% if issue.closed_at != None %}
                {{
                        issue.closed_at | humanize}}
                {% endif %}

            {% endif %}

              {% if issue.priority %}

                {{
                  repo.priorities[issue.priority | string] }}

              {% endif %}

            {% if not status or status|lower == 'open' %}

                    {{ issue.user.default_email | avatar(16) | safe }}
                    {{ issue.user.user }}

            {% endif %}

              {% if issue.assignee %}

                {{ issue.assignee.default_email | avatar(16) | safe }}
                {{ issue.assignee.user }}

              {% else %}
              unassigned
              {% endif %}

    {% else %}

            No issues found

    {% endfor %}

{% endblock %}
{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% extends "master.html" %}
{% from "_formhelper.html" import render_bootstrap_field %}

{% block title %}Login{% endblock %}
{% set tag = "home" %}

{% block content %}

          Login

          <form action="{{ url_for('.do_login') }}" method="post">
            <input type="hidden" value="{{ next_url }}" name="next_url" />
            {{ render_bootstrap_field(form.username) }}
            {{ render_bootstrap_field(form.password) }}
            <input class="btn btn-primary" type="submit" value="Login">
            <input type="button" value="Cancel" class="btn btn-default" onclick="history.back();">
            {{ form.csrf_token }}
          </form>

            If you do not have already an account:
            Create one!

            Forgot your password?

{% endblock %}


code:
{% extends "master.html" %}
{% from "_formhelper.html" import render_bootstrap_field %}

{% block title %}Lost password{% endblock %}
{% set tag = "home" %}

{% block content %}

          Lost password

          <form action="{{ url_for('.lost_password') }}" method="post">
            {{ render_bootstrap_field(form.username) }}
            <input class="btn btn-primary" type="submit" value="Send email">
            <input type="button" value="Cancel" class="btn btn-default" onclick="history.back();">
            {{ form.csrf_token }}
          </form>

{% endblock %}


code:
{% extends "master.html" %}
{% from "_formhelper.html" import render_bootstrap_field %}

{% block title %}Change password{% endblock %}
{%block tag %}home{% endblock %}

{% block content %}

          Change password

          <form action="{{ url_for('change_password')}}" method="post">
            {{ render_bootstrap_field(form.old_password) }}
            {{ render_bootstrap_field(form.password) }}
            {{ render_bootstrap_field(form.confirm_password) }}
            {{ form.csrf_token }}
            <input class="btn btn-primary" type="submit" value="Update"
              title="Update description">
            <input type="button" value="Cancel" class="btn btn-default"
              onclick="history.back();">
          </form>

{% endblock %}


code:
{% extends "master.html" %}
{% from "_formhelper.html" import render_bootstrap_field %}

{% block title %}Change password{% endblock %}
{% set tag = "home" %}

{% block content %}

          Change password

          <form action="{{ url_for('.reset_password', token=token)
                }}" method="post">
            {{ render_bootstrap_field(form.password) }}
            {{ render_bootstrap_field(form.confirm_password) }}
            <input class="btn btn-primary" type="submit" value="Update">
            <input type="button" value="Cancel" class="btn btn-default" onclick="history.back();">
            {{ form.csrf_token }}
          </form>

{% endblock %}


code:
{% extends "master.html" %}
{% from "_formhelper.html" import render_bootstrap_field %}

{% block title %}New user{% endblock %}
{% set tag = "home" %}

{% block content %}

          Create new User

          <form action="{{ url_for('.new_user') }}" method="post">
            {{ render_bootstrap_field(
                form.user, field_description="username of the user") }}
            {{ render_bootstrap_field(
                form.fullname, field_description="full name of the user") }}
            {{ render_bootstrap_field(
                form.email_address, field_description="email address of the user") }}
            {{ render_bootstrap_field(
                form.password, field_description="password of the user") }}
            {{ render_bootstrap_field(
                form.confirm_password, field_description="confirm the password") }}
            <input class="btn btn-primary" type="submit" value="Create" title="Update description">
            <input type="button" value="Cancel" class="btn btn-default" onclick="history.back();">
            {{ form.csrf_token }}
          </form>

{% endblock %}


code:
<!DOCTYPE html>

    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
    <title>{% block title %}{% endblock %} - Pagure</title>
    <link rel="shortcut icon" type="image/vnd.microsoft.icon"
        href="{{ url_for('static', filename='favicon.ico')}}"/>
    <link href="{{ config['BOOTSTRAP_URLS_CSS'] }}"
        type="text/css" rel="stylesheet" />
    <link href="{{ url_for('static', filename='pagure.css') }}"
        type="text/css" rel="stylesheet" />
    <link href="{{ url_for('static', filename='open_iconic_1.1.0/css/open-iconic.min.css') }}"
        type="text/css" rel="stylesheet" />
    <link href="{{ url_for('static', filename='fonts/fonts.css') }}"
        rel="stylesheet" type="text/css" />
    <link href="{{ url_for('static', filename='hack_fonts/css/hack-extended.min.css') }}"
        type="text/css" rel="stylesheet" />
    {% block header %}{% endblock %}

            Browse

          {% if admin %}

            Admin

          {% endif %}
          {% if config.get('ENABLE_NEW_PROJECTS', True) %}

          {% endif %}
          {% if not nologin %}
            {% if g.fas_user %}

                    {{ g.fas_user.username | avatar(24) | safe }}

                    My Public Profile
                My Settings

                Log Out

            {% else %}

            {% endif %}
         {% endif %}

            {% with messages = get_flashed_messages(with_categories=true) %}
                {% if messages %}

                    {% for category, message in messages %}

                      <button type="button" class="close" data-dismiss="alert" aria-label="Close">
                        ×
                        Close
                      </button>
                      {{ message }}

                    {% endfor %}

                {% endif %}
            {% endwith %}

            {% block content %}{% endblock %}

         Copyright © 2014-2016 Red Hat
          pagure --
          {{version}}

SSH Hostkey/Fingerprint

    {% block jscripts %}

    {% endblock %}

{% if config['FEDMENU_URL'] %}

{% endif %}


code:
{% extends "repo_master.html" %}
{% from "_formhelper.html" import render_bootstrap_field %}

{% block title %}{% if not type or type == 'new'
    %}New issue{% elif type and type == 'edit'
    %}Edit issue #{{ issueid }} {% endif %} - {{ repo.name }}{% endblock %}
{% set tag = "home" %}

{% block header %}
<link href="{{ url_for('static', filename='emoji/emojione.sprites.css') }}"
  rel="stylesheet" />
{% endblock %}

{% block repo %}

        {% if not type or type == 'new' %}
        New issue
        {% elif type and type == 'edit' %}
        Edit issue #{{ issueid }}
        {% endif %}

        {% if not type or type == 'new' %}
          <form action="{{ url_for('.new_issue',
                           username=username, repo=repo.name) }}" method="post"
                enctype="multipart/form-data">

        {% elif type and type == 'edit' %}
          <form action="{{ url_for('.edit_issue', username=username,
                             repo=repo.name, issueid=issueid) }}" method="post"
                enctype="multipart/form-data">
        {% endif %}
        {{ render_bootstrap_field(form.title, field_description="Gist of your issue") }}
        {% if type == 'edit' %}
            {{ render_bootstrap_field(form.status, field_description="bug status") }}
        {% endif %}
        {% if types %}
        <fieldset class="form-group  ">
          Type
          <select class="form-control c-select" id="type" name="type">
            {% for type in types %}
            <option selected value="{{ type }}">{{ type }}</option>
            {% endfor %}
          </select>

            Ticket type

        </fieldset>
        {% endif %}
        {{ render_bootstrap_field(form.private, field_description="Do you want to keep the issue private?") }}
          <fieldset class="form-group">
            Description

              Preview

            <textarea class="form-control" rows="8" id="issue_content" name="issue_content"
                placeholder="Describe your issue">
              {%- if issue %}{{ issue.content }}{%
                  elif form.issue_content.data %}{{ form.issue_content.data }}{%
                  elif default %}{{ default }}{%
              endif -%}
            </textarea>

              {% if form.issue_content.errors %}

                {% for error in form.issue_content.errors %}
                  {{ error }}
                {% endfor %}

              {% endif %}

          </fieldset>
        Attach file <input id="file-picker" type="file" name="filestream" accept="image/*" multiple>

          {% if not type or type == 'new' %}
          <input type="submit" class="btn btn-primary" value="Create">
          {% elif type and type == 'edit' %}
          <input type="submit" class="btn btn-primary" value="Update">
          {% endif %}
          <input type="button" value="Cancel" class="btn btn-secondary" onclick="history.back();">
          {{ form.csrf_token }}
          Markdown Syntax

      </form>

    {% if authenticated and repo_admin and type and type == 'edit' %}
    <form method="post" class="pull-xs-right" action="{{
        url_for('.delete_issue',
                username=username, repo=repo.name, issueid=issueid) }}">
      <button class="btn btn-danger" type="submit"
          onclick="return confirm('Are you sure to delete this ticket? \nThis is final and cannot be un-done.');"
          title="Delete this ticket">

        Delete issue
      </button>
      {{ form.csrf_token }}
    </form>
    {% endif %}

{% endblock %}

{% block jscripts %}
{{ super() }}

{% endblock %}


code:
{% extends "master.html" %}
{% from "_formhelper.html" import render_bootstrap_field %}

{% block title %}New project{% endblock %}
{% set tag = "new_project" %}

{% block content %}

          Create new Project

          <form action="{{ url_for('.new_project') }}" method="post">
            {{ render_bootstrap_field(form.name, field_description="the name of your project") }}
            {{ render_bootstrap_field(form.description, field_description="short description of the project") }}
            {{ render_bootstrap_field(form.url, field_description="url of the project's website") }}
            {{ render_bootstrap_field(form.avatar_email, field_description="libravatar email address avatar email") }}
            {{ render_bootstrap_field(form.create_readme, field_description="Create a README file automatically") }}
            <input class="btn btn-primary" type="submit" value="Create" title="Update description">
            <input type="button" value="Cancel" class="btn btn-default" onclick="history.back();">
            {{ form.csrf_token }}
          </form>

{% endblock %}


code:
{% extends "repo_master.html" %}

{% block title %}New release - {{ repo.name }}{% endblock %}
{% set tag = "home" %}

{% block repo %}

Upload a new release

  You can upload your tarball to pagure. This tarball can be as big as
  {{ config['MAX_CONTENT_LENGTH'] / 1024 /1024 }}MB.

<form action="{{ url_for('new_release', username=username, repo=repo.name) }}"
    method="post" enctype="multipart/form-data">
{{ form.csrf_token }}
<input id="file-picker" type="file" name="filestream" multiple>

  <input type="submit" class="submit positive button" value="Upload">

</form>

  After the upload the source will be available in the

    release folder
  .

{% endblock %}


code:
{% extends "master.html" %}

{% block title %}Page not found :'({% endblock %}
{% set tag = "error" %}

{% block content %}

Page not found (404)

      {% if error and error.description %}

With the message:

{{ error.description }}

      {% else %}

The requested page cannot be found, we're sorry :(

      {% endif %}

Maybe you enter a bad URL, or the page has moved or has been removed, or...

      Use the main navigation menu to get (re)started.

{% endblock %}


code:
{% from "_formhelper.html" import render_field_in_row %}

{% if full %}
{% extends "repo_master.html" %}

{% block title %}{{ select.capitalize() }} {{ plugin.name }} - {{ repo.name }}{% endblock %}
{% set tag = "home" %}
{% endif %}

{% block repo %}
{% if full %}

{{ plugin.name }} settings

{% endif %}

  <form action="{{ url_for('.view_plugin',
                  username=username, repo=repo.name, plugin=plugin.name,
                  ) }}" method="post">
  {{ plugin.description | markdown | noJS | safe }}

  {% if pagure_ci_token and (plugin.name == 'Pagure CI') %}

    Report results via
      POST to this URL
    <input class="form-control" readonly type="text" value="{{
        config.get('APP_URL')[:-1]}}{{
        url_for('hook_finished', pagure_ci_token=pagure_ci_token)}}">

  {% endif %}

    {% for field in fields %}
      {{ render_field_in_row(field) }}
    {% endfor %}

      <input type="button" value="Cancel" class="btn btn-secondary" onclick="history.back();">
      <input type="submit" class="btn btn-primary" value="Update">
      {{ form.csrf_token }}

  </form>

{% endblock %}