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
5
5
import { registerSingleton } from "vs/platform/instantiation/common/extensions" ;
6
6
import { ServiceCollection } from "vs/platform/instantiation/common/serviceCollection" ;
7
7
import { ILocalizationsService } from "vs/platform/localizations/common/localizations" ;
8
+ import { INotificationService , Severity } from "vs/platform/notification/common/notification" ;
8
9
import { Registry } from "vs/platform/registry/common/platform" ;
9
10
import { PersistentConnectionEventType } from "vs/platform/remote/common/remoteAgentConnection" ;
10
11
import { ITelemetryService } from "vs/platform/telemetry/common/telemetry" ;
@@ -85,6 +86,27 @@ export const initialize = async (services: ServiceCollection): Promise<void> =>
85
86
( event as any ) . ide = target . ide ;
86
87
( event as any ) . vscode = target . vscode ;
87
88
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
+ }
88
110
} ;
89
111
90
112
export interface Query {
You can’t perform that action at this time.
0 commit comments