Skip to content

Commit

Permalink
fix(resources): svg images didn't load dynamically in chrome extension
Browse files Browse the repository at this point in the history
  • Loading branch information
beregovoy68 committed Dec 6, 2016
1 parent 07afdf1 commit e01c143
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,19 @@
-->

<!doctype html>
<html ng-app="app">
<html ng-app="app" ng-csp>
<head>
<meta charset="utf-8">
<title>Waves Lite Client</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- CSS BEGIN -->
<link rel="stylesheet" href="../bower_components/angular/angular-csp.css">
<link rel="stylesheet" href="../bower_components/angular-material/angular-material.css">
<!-- CSS END -->
<link rel="stylesheet" href="css/jquery.modal.css">
<link rel="stylesheet" href="css/jquery.growl.css">
<link rel="stylesheet" href="css/tooltipster.min.css">
<link rel="stylesheet" href="css/style.css">
<!-- CSS END -->
<link href="img/favicon.ico" type="image/x-icon" rel="shortcut icon"/>
</head>

Expand Down
8 changes: 6 additions & 2 deletions src/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ var app = angular.module('app', [
'app.portfolio'
]).config(AngularApplicationConfig).run(AngularApplicationRun);

function AngularApplicationConfig($provide, $validatorProvider, networkConstants, applicationSettings) {
function AngularApplicationConfig($provide, $compileProvider, $validatorProvider,
networkConstants, applicationSettings) {
$provide.constant(networkConstants,
angular.extend(networkConstants, {
NETWORK_NAME: 'devel',
Expand All @@ -40,6 +41,8 @@ function AngularApplicationConfig($provide, $validatorProvider, networkConstants
NODE_ADDRESS: 'http://52.30.47.67:6869'
}));

$compileProvider.imgSrcSanitizationWhitelist(/^\s*(https?|local|data|file|chrome-extension):/);

$validatorProvider.setDefaults({
errorClass: 'wInput-error',
onkeyup: false,
Expand Down Expand Up @@ -102,7 +105,8 @@ function AngularApplicationConfig($provide, $validatorProvider, networkConstants
}, 'String is too long. Please remove some characters.');
}

AngularApplicationConfig.$inject = ['$provide', '$validatorProvider', 'constants.network', 'constants.application'];
AngularApplicationConfig.$inject = ['$provide', '$compileProvider', '$validatorProvider',
'constants.network', 'constants.application'];

function AngularApplicationRun(rest, applicationConstants, notificationService, addressService) {
// restangular configuration
Expand Down

0 comments on commit e01c143

Please sign in to comment.