@adminide-stack/core 10.3.1-alpha.6 → 10.5.1-alpha.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/interfaces/index.d.ts +0 -2
- package/lib/interfaces/preferences-service.d.ts +1 -23
- package/package.json +5 -10
- package/lib/interfaces/apollo-context.d.ts +0 -66
- package/lib/interfaces/log/index.d.ts +0 -1
- package/lib/interfaces/log/log-service.d.ts +0 -16
- package/lib/templates/modules/IConfigurationModel.ts.template +0 -92
@@ -2,7 +2,6 @@ export * from './enum';
|
|
2
2
|
export * from './common';
|
3
3
|
export * from './nav-items';
|
4
4
|
export * from './page-store';
|
5
|
-
export * from './apollo-context';
|
6
5
|
export * from './configuration';
|
7
6
|
export * from './policy';
|
8
7
|
export * from './organization';
|
@@ -13,7 +12,6 @@ export * from './lifecycle-service';
|
|
13
12
|
export * from './database-migration';
|
14
13
|
export * from './permissions';
|
15
14
|
export * from './service';
|
16
|
-
export * from './log';
|
17
15
|
export * from './environment';
|
18
16
|
export * from './platform';
|
19
17
|
export * from './reduxStore';
|
@@ -1,31 +1,9 @@
|
|
1
1
|
import { URI } from '@vscode-alt/monaco-editor/esm/vs/base/common/uri';
|
2
|
-
import type {
|
3
|
-
import { ConfigurationTarget } from 'common/lib/generated/generated-models.js';
|
2
|
+
import type { IPreferencesInput, IPreferencesOpenOptionsInput as IPreferencesOpenOptions, IContributionSettings, ConfigurationTarget } from 'common';
|
4
3
|
export type IPrefFragment = {
|
5
4
|
fragmentName?: string;
|
6
5
|
fragmentDoc?: string;
|
7
6
|
};
|
8
|
-
export interface IPageResourceSettingWithTarget<T> extends IPageResourceSetting {
|
9
|
-
target: ConfigurationTarget;
|
10
|
-
settings: T;
|
11
|
-
resourceUri: URI;
|
12
|
-
updateTimestamp: Date;
|
13
|
-
subjects: IPageResourceSettingWithTarget<T>[];
|
14
|
-
}
|
15
|
-
export interface IPreferencesService {
|
16
|
-
initiateSettingsFile(resource: URI): Promise<any>;
|
17
|
-
defaultViewerSettingsSubject(target: ConfigurationTarget, options: IPreferencesOpenOptions, context: IConfigurationNodeContextInput): Promise<ISettingsSubject>;
|
18
|
-
/**
|
19
|
-
* Viewer Settings for an Organization and its resources.
|
20
|
-
* @param params
|
21
|
-
* @param context
|
22
|
-
*/
|
23
|
-
viewerSettings<T = IViewerSettingsSubject>(input: IViewerSettingsInput, context: IConfigurationNodeContextInput): Promise<T>;
|
24
|
-
viewerSettings2<T = IPreferences>(input: ICdecodeUriInput, context: IConfigurationNodeContextInput): Promise<IPageResourceSettingWithTarget<T>>;
|
25
|
-
viewerPolicies<T = IPolicySubject>(input: IViewerPoliciesInput, context: IConfigurationNodeContextInput): Promise<T>;
|
26
|
-
viewerPermissions<T = IPermissionSubject>(input: IPreferenceRoleInput, context: IConfigurationNodeContextInput): Promise<T>;
|
27
|
-
writeSettings(cdecodeUri: URI, settings: Record<string, any>, arg3: IConfigurationOverrides, arg4: ConfigurationTarget, donotNotifyError?: boolean): Promise<IIConfigurationModel>;
|
28
|
-
}
|
29
7
|
export interface IPreferenceClientService {
|
30
8
|
readonly defaultKeybindingsResource: URI;
|
31
9
|
userSettingsResource: URI;
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@adminide-stack/core",
|
3
|
-
"version": "10.
|
3
|
+
"version": "10.5.1-alpha.20",
|
4
4
|
"description": "AdminIDE core for higher packages to depend on",
|
5
5
|
"license": "UNLICENSED",
|
6
6
|
"author": "CDMBase LLC",
|
@@ -23,11 +23,13 @@
|
|
23
23
|
"dependencies": {
|
24
24
|
"@vscode-alt/monaco-editor": "^0.21.4",
|
25
25
|
"@workbench-stack/core": "3.9.7",
|
26
|
-
"common": "10.3.1-alpha.6",
|
27
26
|
"query-string": "^9.0.0",
|
28
27
|
"sort-keys": "^5.0.0",
|
29
28
|
"vscode-uri": "^3.0.8"
|
30
29
|
},
|
30
|
+
"devDependencies": {
|
31
|
+
"common": "10.5.1-alpha.20"
|
32
|
+
},
|
31
33
|
"peerDependencies": {
|
32
34
|
"@common-stack/server-core": ">=0.5.21",
|
33
35
|
"vscode-uri": "*"
|
@@ -35,15 +37,8 @@
|
|
35
37
|
"publishConfig": {
|
36
38
|
"access": "public"
|
37
39
|
},
|
38
|
-
"cdecode": {
|
39
|
-
"common": {
|
40
|
-
"modules": [
|
41
|
-
"./${libDir}/templates/modules/IConfigurationModel.ts.template"
|
42
|
-
]
|
43
|
-
}
|
44
|
-
},
|
45
40
|
"typescript": {
|
46
41
|
"definition": "lib/index.d.ts"
|
47
42
|
},
|
48
|
-
"gitHead": "
|
43
|
+
"gitHead": "29608d550fc361a6b14a1c26486d345548fae126"
|
49
44
|
}
|
@@ -1,66 +0,0 @@
|
|
1
|
-
import { DataProxy } from '@apollo/client/cache';
|
2
|
-
import { ApolloClient } from '@apollo/client/index.js';
|
3
|
-
import { CdmLogger } from '@cdm-logger/core';
|
4
|
-
import express from 'express';
|
5
|
-
import { IPreferncesTransformed } from '@common-stack/server-core';
|
6
|
-
import { IUserContext, IUserProfile, IIAuth0Token, AuthStrategy, ICdecodeParsedUri } from 'common/lib/generated/generated-models.js';
|
7
|
-
import { IClientService } from './service';
|
8
|
-
import { IEnvironmentService } from './environment';
|
9
|
-
import { IPreferencesService } from './preferences-service';
|
10
|
-
/**
|
11
|
-
*
|
12
|
-
* Context
|
13
|
-
* @export
|
14
|
-
* @interface MyContext
|
15
|
-
*/
|
16
|
-
export interface MyContext extends ClientContext, ServerContext {
|
17
|
-
}
|
18
|
-
export interface ClientContext {
|
19
|
-
/**
|
20
|
-
* Only application on the client side
|
21
|
-
*/
|
22
|
-
cache: DataProxy;
|
23
|
-
/**
|
24
|
-
* Only application on the client side
|
25
|
-
*/
|
26
|
-
getCacheKey: (options: {
|
27
|
-
__typename: string;
|
28
|
-
id?: string;
|
29
|
-
}) => string;
|
30
|
-
/**
|
31
|
-
* Only applicable on the client side
|
32
|
-
*/
|
33
|
-
apolloClient: ApolloClient<any>;
|
34
|
-
client: ApolloClient<any>;
|
35
|
-
getClientServices: () => IClientService;
|
36
|
-
}
|
37
|
-
export interface IDataSources {
|
38
|
-
}
|
39
|
-
export interface IHttpMiddlewareContext {
|
40
|
-
req?: express.Request & {
|
41
|
-
authStrategy: AuthStrategy | string;
|
42
|
-
permissions?: any;
|
43
|
-
cdecodeuri?: any;
|
44
|
-
currentPageUriSegments: ICdecodeParsedUri;
|
45
|
-
logger?: CdmLogger.ILogger;
|
46
|
-
user?: IIAuth0Token;
|
47
|
-
errors?: any;
|
48
|
-
profile?: IUserProfile;
|
49
|
-
};
|
50
|
-
res: express.Response;
|
51
|
-
}
|
52
|
-
export interface ServerContext extends IHttpMiddlewareContext {
|
53
|
-
accessRoleService: any;
|
54
|
-
user?: IIAuth0Token;
|
55
|
-
userContext?: IUserContext;
|
56
|
-
orgname?: string;
|
57
|
-
profile?: IUserProfile;
|
58
|
-
/** Backend Datasource */
|
59
|
-
dataSources: IDataSources;
|
60
|
-
orgRole?: string;
|
61
|
-
teamName?: string;
|
62
|
-
preferences: IPreferncesTransformed[];
|
63
|
-
environmentService: IEnvironmentService;
|
64
|
-
preferenceService?: IPreferencesService;
|
65
|
-
accountService?: any;
|
66
|
-
}
|
@@ -1 +0,0 @@
|
|
1
|
-
export * from './log-service';
|
@@ -1,16 +0,0 @@
|
|
1
|
-
import { Event } from '@vscode-alt/monaco-editor/esm/vs/base/common/event';
|
2
|
-
import { IDisposable } from '@vscode-alt/monaco-editor/esm/vs/base/common/lifecycle';
|
3
|
-
import { CdmLogger } from '@cdm-logger/core';
|
4
|
-
type LogLevel = CdmLogger.LoggerLevel;
|
5
|
-
export interface ILogService extends IDisposable {
|
6
|
-
onDidChangeLogLevel: Event<LogLevel>;
|
7
|
-
getLevel(): LogLevel;
|
8
|
-
setLevel(level: LogLevel): void;
|
9
|
-
trace(message: string, ...args: any[]): void;
|
10
|
-
debug(message: string, ...args: any[]): void;
|
11
|
-
info(message: string, ...args: any[]): void;
|
12
|
-
warn(message: string, ...args: any[]): void;
|
13
|
-
error(message: string | Error, ...args: any[]): void;
|
14
|
-
critical(message: string | Error, ...args: any[]): void;
|
15
|
-
}
|
16
|
-
export {};
|
@@ -1,92 +0,0 @@
|
|
1
|
-
import { IOverrides, IIConfigurationModel } from 'common';
|
2
|
-
|
3
|
-
export interface IConfigurationModel extends IIConfigurationModel {
|
4
|
-
/**
|
5
|
-
* Gets the configuration contents
|
6
|
-
*/
|
7
|
-
contents: any;
|
8
|
-
|
9
|
-
/**
|
10
|
-
* Gets the override configurations
|
11
|
-
*/
|
12
|
-
overrides: IOverrides[];
|
13
|
-
|
14
|
-
/**
|
15
|
-
* Gets the configuration keys
|
16
|
-
*/
|
17
|
-
keys: string[];
|
18
|
-
|
19
|
-
/**
|
20
|
-
* Checks if the configuration is empty
|
21
|
-
*/
|
22
|
-
isEmpty(): boolean;
|
23
|
-
|
24
|
-
/**
|
25
|
-
* Checks if the configuration is frozen
|
26
|
-
*/
|
27
|
-
isFrozen(): boolean;
|
28
|
-
|
29
|
-
/**
|
30
|
-
* Gets a value from the configuration
|
31
|
-
* @param section The configuration section
|
32
|
-
*/
|
33
|
-
getValue<V>(section: string | undefined): V;
|
34
|
-
|
35
|
-
/**
|
36
|
-
* Gets an override value from the configuration
|
37
|
-
* @param section The configuration section
|
38
|
-
* @param overrideIdentifier The override identifier
|
39
|
-
*/
|
40
|
-
getOverrideValue<V>(section: string | undefined, overrideIdentifier: string): V | undefined;
|
41
|
-
|
42
|
-
/**
|
43
|
-
* Gets keys for a specific override identifier
|
44
|
-
* @param identifier The override identifier
|
45
|
-
*/
|
46
|
-
getKeysForOverrideIdentifier(identifier: string): string[];
|
47
|
-
|
48
|
-
/**
|
49
|
-
* Gets all override identifiers
|
50
|
-
*/
|
51
|
-
getAllOverrideIdentifiers(): string[];
|
52
|
-
|
53
|
-
/**
|
54
|
-
* Creates a new configuration model with overrides
|
55
|
-
* @param identifier The override identifier
|
56
|
-
*/
|
57
|
-
override(identifier: string): IConfigurationModel;
|
58
|
-
|
59
|
-
/**
|
60
|
-
* Merges multiple configuration models
|
61
|
-
* @param others The configuration models to merge
|
62
|
-
*/
|
63
|
-
merge(...others: IConfigurationModel[]): IConfigurationModel;
|
64
|
-
|
65
|
-
/**
|
66
|
-
* Freezes the configuration model
|
67
|
-
*/
|
68
|
-
freeze(): IConfigurationModel;
|
69
|
-
|
70
|
-
/**
|
71
|
-
* Creates a clone of the configuration model
|
72
|
-
*/
|
73
|
-
clone(): IConfigurationModel;
|
74
|
-
|
75
|
-
/**
|
76
|
-
* Converts the configuration model to JSON
|
77
|
-
*/
|
78
|
-
toJSON(): IIConfigurationModel;
|
79
|
-
|
80
|
-
/**
|
81
|
-
* Sets a value in the configuration
|
82
|
-
* @param key The configuration key
|
83
|
-
* @param value The value to set
|
84
|
-
*/
|
85
|
-
setValue(key: string, value: any): void;
|
86
|
-
|
87
|
-
/**
|
88
|
-
* Removes a value from the configuration
|
89
|
-
* @param key The configuration key to remove
|
90
|
-
*/
|
91
|
-
removeValue(key: string): void;
|
92
|
-
}
|