sanitize_html_v3.patch

Marius BALTEANU, 2020-10-16 08:01

Download (878 Bytes)

View differences:

public/javascripts/application.js
8 8
  }
9 9
});
10 10

  
11
function sanitizeHTML(string) {
12
  var temp = document.createElement('span');
13
  temp.textContent = string;
14
  return temp.innerHTML;
15
}
16

  
11 17
function checkAll(id, checked) {
12 18
  $('#'+id).find('input[type=checkbox]:enabled').prop('checked', checked);
13 19
}
......
1084 1090
      selectTemplate: function (issue) {
1085 1091
        return '#' + issue.original.id;
1086 1092
      },
1093
      menuItemTemplate: function (issue) {
1094
        return sanitizeHTML(issue.original.label);
1095
      },
1087 1096
      noMatchTemplate: function () {
1088 1097
        return '<span style:"visibility: hidden;"></span>';
1089 1098
      }