File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 303303 document . body . classList . remove ( 'loading' ) ;
304304 } ) ;
305305
306- image . src = decodeURI ( settings . src ) ;
306+ image . src = settings . src ;
307307
308308 window . addEventListener ( 'message' , e => {
309309 switch ( e . data . type ) {
Original file line number Diff line number Diff line change @@ -231,18 +231,18 @@ class Preview extends Disposable implements vscode.WebviewEditorEditingCapabilit
231231 private getResourcePath ( webviewEditor : vscode . WebviewPanel , resource : vscode . Uri , version : string ) {
232232 switch ( resource . scheme ) {
233233 case 'data' :
234- return encodeURI ( resource . toString ( true ) ) ;
234+ return resource . toString ( true ) ;
235235
236236 case 'git' :
237237 // Show blank image
238- return encodeURI ( 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAEElEQVR42gEFAPr/AP///wAI/AL+Sr4t6gAAAABJRU5ErkJggg==' ) ;
238+ return 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAEElEQVR42gEFAPr/AP///wAI/AL+Sr4t6gAAAABJRU5ErkJggg==' ;
239239
240240 default :
241241 // Avoid adding cache busting if there is already a query string
242242 if ( resource . query ) {
243- return encodeURI ( webviewEditor . webview . asWebviewUri ( resource ) . toString ( true ) ) ;
243+ return encodeURI ( webviewEditor . webview . asWebviewUri ( resource ) . toString ( ) ) ;
244244 }
245- return encodeURI ( webviewEditor . webview . asWebviewUri ( resource ) . toString ( true ) + `?version=${ version } ` ) ;
245+ return encodeURI ( webviewEditor . webview . asWebviewUri ( resource ) . toString ( ) + `?version=${ version } ` ) ;
246246 }
247247 }
248248
You can’t perform that action at this time.
0 commit comments