File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import { Extensions, IConfigurationRegistry } from "vs/platform/configuration/co
55import { registerSingleton } from "vs/platform/instantiation/common/extensions" ;
66import { ServiceCollection } from "vs/platform/instantiation/common/serviceCollection" ;
77import { ILocalizationsService } from "vs/platform/localizations/common/localizations" ;
8+ import { INotificationService , Severity } from "vs/platform/notification/common/notification" ;
89import { Registry } from "vs/platform/registry/common/platform" ;
910import { PersistentConnectionEventType } from "vs/platform/remote/common/remoteAgentConnection" ;
1011import { ITelemetryService } from "vs/platform/telemetry/common/telemetry" ;
@@ -85,6 +86,27 @@ export const initialize = async (services: ServiceCollection): Promise<void> =>
8586 ( event as any ) . ide = target . ide ;
8687 ( event as any ) . vscode = target . vscode ;
8788 window . dispatchEvent ( event ) ;
89+
90+ if ( ! window . isSecureContext ) {
91+ ( services . get ( INotificationService ) as INotificationService ) . notify ( {
92+ severity : Severity . Warning ,
93+ message : "code-server is being accessed over an insecure domain. Some functionality may not work as expected." ,
94+ actions : {
95+ primary : [ {
96+ id : "understand" ,
97+ label : "I understand" ,
98+ tooltip : "" ,
99+ class : undefined ,
100+ enabled : true ,
101+ checked : true ,
102+ dispose : ( ) => undefined ,
103+ run : ( ) => {
104+ return Promise . resolve ( ) ;
105+ }
106+ } ] ,
107+ }
108+ } ) ;
109+ }
88110} ;
89111
90112export interface Query {
You can’t perform that action at this time.
0 commit comments