Commit d70c81f0 by Torkel Ödegaard

more angular 1.3 upgrade fixes

parent 387ec89b
<div ng-controller='text' ng-init="init()" style="min-height:{{panel.height || row.height}}" ng-dblclick="openEditor()">
<p ng-bind-html-unsafe="content">
<p ng-bind-html="content">
</p>
</div>
......@@ -23,7 +23,7 @@ function (angular, app, _, require) {
var module = angular.module('grafana.panels.text', []);
app.useModule(module);
module.controller('text', function($scope, filterSrv) {
module.controller('text', function($scope, filterSrv, $sce) {
$scope.panelMeta = {
description : "A static text panel that can use plain text, markdown, or (sanitized) HTML"
......@@ -81,7 +81,7 @@ function (angular, app, _, require) {
$scope.updateContent = function(html) {
try {
$scope.content = filterSrv.applyTemplateToTarget(html);
$scope.content = $sce.trustAsHtml(filterSrv.applyTemplateToTarget(html));
if(!$scope.$$phase) {
$scope.$apply();
......
......@@ -58,7 +58,6 @@ module.exports = function(config,grunt) {
'angular-strap',
'directives/all',
'jquery.flot.pie',
'angular-sanitize',
'angular-dragdrop',
]
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment