mirror of https://github.com/BTCPrivate/copay.git
Whitelist chrome-extension: URL schema for images
By default Angular will prefix such image URLs with ``unsafe:`` thus stopping images to appear Related reading: http://stackoverflow.com/questions/15606751/angular-changes-urls-to-unsafe-in-extension-page?lq=1
This commit is contained in:
parent
be61c3039c
commit
83db31a9f0
|
@ -16,7 +16,7 @@ if (window && window.navigator) {
|
||||||
//Setting up route
|
//Setting up route
|
||||||
angular
|
angular
|
||||||
.module('copayApp')
|
.module('copayApp')
|
||||||
.config(function(historicLogProvider, $provide, $logProvider, $stateProvider, $urlRouterProvider) {
|
.config(function(historicLogProvider, $provide, $logProvider, $stateProvider, $urlRouterProvider, $compileProvider) {
|
||||||
$urlRouterProvider.otherwise('/');
|
$urlRouterProvider.otherwise('/');
|
||||||
|
|
||||||
$logProvider.debugEnabled(true);
|
$logProvider.debugEnabled(true);
|
||||||
|
@ -70,6 +70,10 @@ angular
|
||||||
}
|
}
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
// whitelist 'chrome-extension:' for chromeApp to work with image URLs processed by Angular
|
||||||
|
// link: http://stackoverflow.com/questions/15606751/angular-changes-urls-to-unsafe-in-extension-page?lq=1
|
||||||
|
$compileProvider.imgSrcSanitizationWhitelist(/^\s*((https?|ftp|file|blob|chrome-extension):|data:image\/)/);
|
||||||
|
|
||||||
$stateProvider
|
$stateProvider
|
||||||
.state('splash', {
|
.state('splash', {
|
||||||
url: '/splash',
|
url: '/splash',
|
||||||
|
|
Loading…
Reference in New Issue