diff --git a/.vscode/tasks.json b/.vscode/tasks.json index a9a59d65e4..e4d2138e1d 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -73,6 +73,14 @@ "close": true, "clear": false } + }, + { + "label": "Update TS references CE", + "type": "shell", + "command": "yarn lerna run update-ts-references --stream", + "options": { + "cwd": "${workspaceFolder}/webapp" + } } ], "inputs": [ diff --git a/webapp/packages/core-administration/package.json b/webapp/packages/core-administration/package.json index dea20a2daf..a8208e3e31 100644 --- a/webapp/packages/core-administration/package.json +++ b/webapp/packages/core-administration/package.json @@ -18,7 +18,6 @@ "update-ts-references": "rimraf --glob dist && typescript-resolve-references" }, "dependencies": { - "@cloudbeaver/core-authentication": "~0.1.0", "@cloudbeaver/core-data-context": "~0.1.0", "@cloudbeaver/core-di": "~0.1.0", "@cloudbeaver/core-events": "~0.1.0", @@ -32,8 +31,7 @@ "@cloudbeaver/core-settings": "~0.1.0", "@cloudbeaver/core-theming": "~0.1.0", "@cloudbeaver/core-utils": "~0.1.0", - "mobx": "^6.12.0", - "reshadow": "^0.0.1" + "mobx": "^6.12.0" }, "peerDependencies": {}, "devDependencies": { diff --git a/webapp/packages/core-administration/src/AdministrationScreen/AdministrationScreenService.ts b/webapp/packages/core-administration/src/AdministrationScreen/AdministrationScreenService.ts index cf14bf35d8..1948153ade 100644 --- a/webapp/packages/core-administration/src/AdministrationScreen/AdministrationScreenService.ts +++ b/webapp/packages/core-administration/src/AdministrationScreen/AdministrationScreenService.ts @@ -7,11 +7,10 @@ */ import { computed, makeObservable, observable } from 'mobx'; -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { injectable } from '@cloudbeaver/core-di'; import { NotificationService } from '@cloudbeaver/core-events'; import { Executor, IExecutor } from '@cloudbeaver/core-executor'; -import { PermissionsService, ServerConfigResource, SessionPermissionsResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, PermissionsService, ServerConfigResource, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { RouterState, ScreenService } from '@cloudbeaver/core-routing'; import { LocalStorageSaveService } from '@cloudbeaver/core-settings'; import { GlobalConstants } from '@cloudbeaver/core-utils'; diff --git a/webapp/packages/core-administration/tsconfig.json b/webapp/packages/core-administration/tsconfig.json index f426de9229..1587831354 100644 --- a/webapp/packages/core-administration/tsconfig.json +++ b/webapp/packages/core-administration/tsconfig.json @@ -6,9 +6,6 @@ "tsBuildInfoFile": "dist/tsconfig.tsbuildinfo" }, "references": [ - { - "path": "../core-authentication/tsconfig.json" - }, { "path": "../core-data-context/tsconfig.json" }, diff --git a/webapp/packages/core-app/package.json b/webapp/packages/core-app/package.json index ad0aa8a0c2..8ff5cf9c37 100644 --- a/webapp/packages/core-app/package.json +++ b/webapp/packages/core-app/package.json @@ -31,7 +31,8 @@ "@cloudbeaver/core-ui": "~0.1.0", "@cloudbeaver/core-version": "~0.1.0", "mobx-react-lite": "^4.0.5", - "react": "^18.2.0" + "react": "^18.2.0", + "@cloudbeaver/core-utils": "~0.1.0" }, "peerDependencies": {}, "devDependencies": { diff --git a/webapp/packages/core-app/tsconfig.json b/webapp/packages/core-app/tsconfig.json index 5b0ec4ac55..58c432283c 100644 --- a/webapp/packages/core-app/tsconfig.json +++ b/webapp/packages/core-app/tsconfig.json @@ -44,6 +44,9 @@ }, { "path": "../core-version/tsconfig.json" + }, + { + "path": "../core-utils/tsconfig.json" } ], "include": [ diff --git a/webapp/packages/core-authentication/src/AuthConfigurationParametersResource.ts b/webapp/packages/core-authentication/src/AuthConfigurationParametersResource.ts index 0a1533220d..19f223b322 100644 --- a/webapp/packages/core-authentication/src/AuthConfigurationParametersResource.ts +++ b/webapp/packages/core-authentication/src/AuthConfigurationParametersResource.ts @@ -7,15 +7,13 @@ */ import { injectable } from '@cloudbeaver/core-di'; import { CachedMapResource, isResourceAlias, type ResourceKey, ResourceKeyUtils } from '@cloudbeaver/core-resource'; -import { SessionDataResource, SessionPermissionsResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, SessionDataResource, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { AuthProviderConfigurationParametersFragment, GetAuthProviderConfigurationParametersQueryVariables, GraphQLService, } from '@cloudbeaver/core-sdk'; -import { EAdminPermission } from './EAdminPermission'; - @injectable() export class AuthConfigurationParametersResource extends CachedMapResource< string, diff --git a/webapp/packages/core-authentication/src/AuthConfigurationsResource.ts b/webapp/packages/core-authentication/src/AuthConfigurationsResource.ts index 41b18aff73..be4acb05d7 100644 --- a/webapp/packages/core-authentication/src/AuthConfigurationsResource.ts +++ b/webapp/packages/core-authentication/src/AuthConfigurationsResource.ts @@ -17,11 +17,10 @@ import { type ResourceKeySimple, ResourceKeyUtils, } from '@cloudbeaver/core-resource'; -import { SessionPermissionsResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { AdminAuthProviderConfiguration, GetAuthProviderConfigurationsQueryVariables, GraphQLService } from '@cloudbeaver/core-sdk'; import type { AuthProviderConfiguration } from './AuthProvidersResource'; -import { EAdminPermission } from './EAdminPermission'; const NEW_CONFIGURATION_SYMBOL = Symbol('new-configuration'); diff --git a/webapp/packages/core-authentication/src/AuthRolesResource.ts b/webapp/packages/core-authentication/src/AuthRolesResource.ts index 6b1fc69d22..0cf05b8ef7 100644 --- a/webapp/packages/core-authentication/src/AuthRolesResource.ts +++ b/webapp/packages/core-authentication/src/AuthRolesResource.ts @@ -7,11 +7,9 @@ */ import { injectable } from '@cloudbeaver/core-di'; import { CachedDataResource } from '@cloudbeaver/core-resource'; -import { SessionPermissionsResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { GraphQLService } from '@cloudbeaver/core-sdk'; -import { EAdminPermission } from './EAdminPermission'; - @injectable() export class AuthRolesResource extends CachedDataResource { constructor(private readonly graphQLService: GraphQLService, sessionPermissionsResource: SessionPermissionsResource) { diff --git a/webapp/packages/core-authentication/src/UsersResource.ts b/webapp/packages/core-authentication/src/UsersResource.ts index d54bc87a3a..b51f0d1454 100644 --- a/webapp/packages/core-authentication/src/UsersResource.ts +++ b/webapp/packages/core-authentication/src/UsersResource.ts @@ -21,13 +21,12 @@ import { type ResourceKeySimple, ResourceKeyUtils, } from '@cloudbeaver/core-resource'; -import { ServerConfigResource, SessionPermissionsResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, ServerConfigResource, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { AdminConnectionGrantInfo, AdminUserInfo, AdminUserInfoFragment, GetUsersListQueryVariables, GraphQLService } from '@cloudbeaver/core-sdk'; import { AUTH_PROVIDER_LOCAL_ID } from './AUTH_PROVIDER_LOCAL_ID'; import { AuthInfoService } from './AuthInfoService'; import { AuthProviderService } from './AuthProviderService'; -import { EAdminPermission } from './EAdminPermission'; import type { IAuthCredentials } from './IAuthCredentials'; const NEW_USER_SYMBOL = Symbol('new-user'); diff --git a/webapp/packages/core-authentication/src/index.ts b/webapp/packages/core-authentication/src/index.ts index 53b32aef3c..c97900ecf7 100644 --- a/webapp/packages/core-authentication/src/index.ts +++ b/webapp/packages/core-authentication/src/index.ts @@ -18,6 +18,5 @@ export * from './UserInfoResource'; export * from './UserMetaParametersResource'; export * from './UsersResource'; export * from './TeamMetaParametersResource'; -export * from './EAdminPermission'; export * from './AUTH_SETTINGS_GROUP'; export * from './PasswordPolicyService'; diff --git a/webapp/packages/core-blocks/package.json b/webapp/packages/core-blocks/package.json index 8406535ad6..19d23a66db 100644 --- a/webapp/packages/core-blocks/package.json +++ b/webapp/packages/core-blocks/package.json @@ -33,7 +33,7 @@ "mobx": "^6.12.0", "mobx-react-lite": "^4.0.5", "react": "^18.2.0", - "reakit": "~1.x.x", + "reakit": "~1.3.11", "reakit-utils": "^0.15.2", "reshadow": "^0.0.1" }, diff --git a/webapp/packages/core-blocks/src/ResourcesHooks/useResource.ts b/webapp/packages/core-blocks/src/ResourcesHooks/useResource.ts index 43f4f455ad..dee7488790 100644 --- a/webapp/packages/core-blocks/src/ResourcesHooks/useResource.ts +++ b/webapp/packages/core-blocks/src/ResourcesHooks/useResource.ts @@ -349,10 +349,6 @@ export function useResource< return true; } - if (this.isError()) { - return true; - } - return this.resource.isLoaded(propertiesRef.key, propertiesRef.includes); }, get loading(): boolean { @@ -461,7 +457,7 @@ export function useResource< useEffect(() => { refObj.use(loadKey); - if (canLoad && !result.isError()) { + if (canLoad) { result.load(); } }, [canLoad, loadKey]); diff --git a/webapp/packages/core-blocks/src/useAdministrationSettings.ts b/webapp/packages/core-blocks/src/useAdministrationSettings.ts index 575d343af3..9bfc5f6879 100644 --- a/webapp/packages/core-blocks/src/useAdministrationSettings.ts +++ b/webapp/packages/core-blocks/src/useAdministrationSettings.ts @@ -5,8 +5,7 @@ * Licensed under the Apache License, Version 2.0. * you may not use this file except in compliance with the License. */ -import { EAdminPermission } from '@cloudbeaver/core-authentication'; -import { ServerConfigResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, ServerConfigResource } from '@cloudbeaver/core-root'; import { useResource } from './ResourcesHooks/useResource'; import { usePermission } from './usePermission'; diff --git a/webapp/packages/core-bootstrap/package.json b/webapp/packages/core-bootstrap/package.json index d41172a3cf..c309e2acb3 100644 --- a/webapp/packages/core-bootstrap/package.json +++ b/webapp/packages/core-bootstrap/package.json @@ -47,12 +47,12 @@ "@cloudbeaver/core-view": "~0.1.0", "mobx": "^6.12.0", "react": "^18.2.0", - "react-dom": "^18.2.0", - "reshadow": "^0.0.1" + "react-dom": "^18.2.0" }, "peerDependencies": {}, "devDependencies": { "@types/react": "^18.2.42", - "typescript": "^5.3.2" + "typescript": "^5.3.2", + "typescript-plugin-css-modules": "^5.0.2" } } diff --git a/webapp/packages/core-notifications/package.json b/webapp/packages/core-notifications/package.json index 9ddd1570f9..8375dbc479 100644 --- a/webapp/packages/core-notifications/package.json +++ b/webapp/packages/core-notifications/package.json @@ -19,17 +19,15 @@ "dependencies": { "@cloudbeaver/core-blocks": "~0.1.0", "@cloudbeaver/core-di": "~0.1.0", - "@cloudbeaver/core-dialogs": "~0.1.0", "@cloudbeaver/core-events": "~0.1.0", - "mobx": "^6.12.0", "mobx-react-lite": "^4.0.5", "react": "^18.2.0", - "reakit": "~1.x.x", - "reshadow": "^0.0.1" + "reakit": "~1.3.11" }, "peerDependencies": {}, "devDependencies": { "@types/react": "^18.2.42", - "typescript": "^5.3.2" + "typescript": "^5.3.2", + "typescript-plugin-css-modules": "^5.0.2" } } diff --git a/webapp/packages/core-notifications/tsconfig.json b/webapp/packages/core-notifications/tsconfig.json index b2bb6a4bfb..6344f58a9c 100644 --- a/webapp/packages/core-notifications/tsconfig.json +++ b/webapp/packages/core-notifications/tsconfig.json @@ -12,9 +12,6 @@ { "path": "../core-di/tsconfig.json" }, - { - "path": "../core-dialogs/tsconfig.json" - }, { "path": "../core-events/tsconfig.json" } diff --git a/webapp/packages/core-resource-manager/package.json b/webapp/packages/core-resource-manager/package.json index 7828d7b674..16fdaf42f1 100644 --- a/webapp/packages/core-resource-manager/package.json +++ b/webapp/packages/core-resource-manager/package.json @@ -18,7 +18,6 @@ }, "dependencies": { "@cloudbeaver/core-administration": "~0.1.0", - "@cloudbeaver/core-authentication": "~0.1.0", "@cloudbeaver/core-di": "~0.1.0", "@cloudbeaver/core-executor": "~0.1.0", "@cloudbeaver/core-navigation-tree": "~0.1.0", diff --git a/webapp/packages/core-resource-manager/src/ProjectPermissionsResource.ts b/webapp/packages/core-resource-manager/src/ProjectPermissionsResource.ts index 5b0acb423b..f43f32cb59 100644 --- a/webapp/packages/core-resource-manager/src/ProjectPermissionsResource.ts +++ b/webapp/packages/core-resource-manager/src/ProjectPermissionsResource.ts @@ -8,19 +8,15 @@ import type { PermissionInfo } from '@cloudbeaver/core-administration'; import { injectable } from '@cloudbeaver/core-di'; import { CachedDataResource } from '@cloudbeaver/core-resource'; -import { ServerConfigResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { GraphQLService } from '@cloudbeaver/core-sdk'; @injectable() export class ProjectPermissionsResource extends CachedDataResource { - constructor(private readonly graphQLService: GraphQLService, serverConfigResource: ServerConfigResource) { + constructor(private readonly graphQLService: GraphQLService, permissionsResource: SessionPermissionsResource) { super(() => []); - this.sync( - serverConfigResource, - () => {}, - () => {}, - ); + permissionsResource.require(this, EAdminPermission.admin).outdateResource(this); } protected async loader(): Promise { diff --git a/webapp/packages/core-resource-manager/src/SharedProjectsResource.ts b/webapp/packages/core-resource-manager/src/SharedProjectsResource.ts index beed7bb0ef..537fb515da 100644 --- a/webapp/packages/core-resource-manager/src/SharedProjectsResource.ts +++ b/webapp/packages/core-resource-manager/src/SharedProjectsResource.ts @@ -8,7 +8,6 @@ import { runInAction } from 'mobx'; import type { AdminObjectGrantInfo } from '@cloudbeaver/core-administration'; -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { injectable } from '@cloudbeaver/core-di'; import { ProjectInfoResource } from '@cloudbeaver/core-projects'; import { @@ -19,7 +18,7 @@ import { resourceKeyList, ResourceKeyUtils, } from '@cloudbeaver/core-resource'; -import { SessionPermissionsResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { GraphQLService, RmProject, RmProjectPermissions, RmSubjectProjectPermissions } from '@cloudbeaver/core-sdk'; import { isArraysEqual } from '@cloudbeaver/core-utils'; diff --git a/webapp/packages/core-resource-manager/tsconfig.json b/webapp/packages/core-resource-manager/tsconfig.json index 8d245a3fd3..0d0bd22212 100644 --- a/webapp/packages/core-resource-manager/tsconfig.json +++ b/webapp/packages/core-resource-manager/tsconfig.json @@ -9,9 +9,6 @@ { "path": "../core-administration/tsconfig.json" }, - { - "path": "../core-authentication/tsconfig.json" - }, { "path": "../core-di/tsconfig.json" }, diff --git a/webapp/packages/core-authentication/src/EAdminPermission.ts b/webapp/packages/core-root/src/EAdminPermission.ts similarity index 100% rename from webapp/packages/core-authentication/src/EAdminPermission.ts rename to webapp/packages/core-root/src/EAdminPermission.ts diff --git a/webapp/packages/core-root/src/FeaturesResource.ts b/webapp/packages/core-root/src/FeaturesResource.ts index de6c14b658..cab98e6e7d 100644 --- a/webapp/packages/core-root/src/FeaturesResource.ts +++ b/webapp/packages/core-root/src/FeaturesResource.ts @@ -9,20 +9,17 @@ import { injectable } from '@cloudbeaver/core-di'; import { CachedDataResource } from '@cloudbeaver/core-resource'; import { GraphQLService, WebFeatureSet } from '@cloudbeaver/core-sdk'; -import { ServerConfigResource } from './ServerConfigResource'; +import { EAdminPermission } from './EAdminPermission'; +import { SessionPermissionsResource } from './SessionPermissionsResource'; export type ApplicationFeature = WebFeatureSet; @injectable() export class FeaturesResource extends CachedDataResource { - constructor(private readonly graphQLService: GraphQLService, serverConfigResource: ServerConfigResource) { + constructor(private readonly graphQLService: GraphQLService, permissionsResource: SessionPermissionsResource) { super(() => []); - this.sync( - serverConfigResource, - () => {}, - () => {}, - ); + permissionsResource.require(this, EAdminPermission.admin).outdateResource(this); } protected async loader(): Promise { diff --git a/webapp/packages/core-root/src/index.ts b/webapp/packages/core-root/src/index.ts index dd83fdde62..8869c33f54 100644 --- a/webapp/packages/core-root/src/index.ts +++ b/webapp/packages/core-root/src/index.ts @@ -18,6 +18,7 @@ export * from './SessionResource'; export * from './ServerService'; export * from './ServerSettingsService'; export * from './SessionActionService'; +export * from './EAdminPermission'; export * from './SessionDataResource'; export * from './SessionSettingsService'; export * from './SessionExpireService'; diff --git a/webapp/packages/core-ui/package.json b/webapp/packages/core-ui/package.json index 4784e50d7a..6e6d866653 100644 --- a/webapp/packages/core-ui/package.json +++ b/webapp/packages/core-ui/package.json @@ -34,7 +34,7 @@ "react": "^18.2.0", "react-dnd": "^16.0.1", "react-dnd-html5-backend": "^16.0.1", - "reakit": "~1.x.x", + "reakit": "~1.3.11", "reshadow": "^0.0.1" }, "peerDependencies": {}, diff --git a/webapp/packages/core-view/package.json b/webapp/packages/core-view/package.json index 0c2bba1665..eb88fa5269 100644 --- a/webapp/packages/core-view/package.json +++ b/webapp/packages/core-view/package.json @@ -27,12 +27,12 @@ "mobx": "^6.12.0", "mobx-react-lite": "^4.0.5", "react": "^18.2.0", - "react-hotkeys-hook": "^4.4.1", - "reshadow": "^0.0.1" + "react-hotkeys-hook": "^4.4.1" }, "peerDependencies": {}, "devDependencies": { "@types/react": "^18.2.42", - "typescript": "^5.3.2" + "typescript": "^5.3.2", + "typescript-plugin-css-modules": "^5.0.2" } } diff --git a/webapp/packages/plugin-administration/src/AdministrationScreen/AdministrationScreen.tsx b/webapp/packages/plugin-administration/src/AdministrationScreen/AdministrationScreen.tsx index e60e78c02f..724ec6fe16 100644 --- a/webapp/packages/plugin-administration/src/AdministrationScreen/AdministrationScreen.tsx +++ b/webapp/packages/plugin-administration/src/AdministrationScreen/AdministrationScreen.tsx @@ -9,9 +9,9 @@ import { observer } from 'mobx-react-lite'; import { useCallback } from 'react'; import { AdministrationScreenService } from '@cloudbeaver/core-administration'; -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { usePermission } from '@cloudbeaver/core-blocks'; import { useService } from '@cloudbeaver/core-di'; +import { EAdminPermission } from '@cloudbeaver/core-root'; import type { ScreenComponent } from '@cloudbeaver/core-routing'; import { Administration } from '../Administration/Administration'; diff --git a/webapp/packages/plugin-administration/src/AdministrationScreen/ConfigurationWizard/ConfigurationWizardScreen.tsx b/webapp/packages/plugin-administration/src/AdministrationScreen/ConfigurationWizard/ConfigurationWizardScreen.tsx index 6a853eb20e..67b33de0b4 100644 --- a/webapp/packages/plugin-administration/src/AdministrationScreen/ConfigurationWizard/ConfigurationWizardScreen.tsx +++ b/webapp/packages/plugin-administration/src/AdministrationScreen/ConfigurationWizard/ConfigurationWizardScreen.tsx @@ -9,10 +9,9 @@ import { observer } from 'mobx-react-lite'; import { useCallback } from 'react'; import { AdministrationItemService, AdministrationScreenService } from '@cloudbeaver/core-administration'; -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { Translate, usePermission, useResource } from '@cloudbeaver/core-blocks'; import { useService } from '@cloudbeaver/core-di'; -import { SessionPermissionsResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { Administration } from '../../Administration/Administration'; import { WizardStepper } from './WizardStepper'; diff --git a/webapp/packages/plugin-administration/src/PluginBootstrap.ts b/webapp/packages/plugin-administration/src/PluginBootstrap.ts index 82b12c842c..94bf06dbcd 100644 --- a/webapp/packages/plugin-administration/src/PluginBootstrap.ts +++ b/webapp/packages/plugin-administration/src/PluginBootstrap.ts @@ -8,9 +8,8 @@ import { lazy } from 'react'; import { AdministrationScreenService } from '@cloudbeaver/core-administration'; -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { Bootstrap, injectable } from '@cloudbeaver/core-di'; -import { PermissionsService } from '@cloudbeaver/core-root'; +import { PermissionsService, EAdminPermission } from '@cloudbeaver/core-root'; import { ScreenService } from '@cloudbeaver/core-routing'; import { DATA_CONTEXT_MENU, MenuBaseItem, MenuService } from '@cloudbeaver/core-view'; import { TOP_NAV_BAR_SETTINGS_MENU } from '@cloudbeaver/plugin-settings-menu'; diff --git a/webapp/packages/plugin-authentication-administration/package.json b/webapp/packages/plugin-authentication-administration/package.json index 6f3fbb21e0..6483450f0a 100644 --- a/webapp/packages/plugin-authentication-administration/package.json +++ b/webapp/packages/plugin-authentication-administration/package.json @@ -39,7 +39,8 @@ "mobx": "^6.12.0", "mobx-react-lite": "^4.0.5", "react": "^18.2.0", - "reshadow": "^0.0.1" + "reshadow": "^0.0.1", + "reakit": "~1.3.11" }, "peerDependencies": {}, "devDependencies": { diff --git a/webapp/packages/plugin-codemirror6/package.json b/webapp/packages/plugin-codemirror6/package.json index f980174f2d..114ab40b39 100644 --- a/webapp/packages/plugin-codemirror6/package.json +++ b/webapp/packages/plugin-codemirror6/package.json @@ -35,8 +35,7 @@ "@lezer/highlight": "^1.2.0", "mobx-react-lite": "^4.0.5", "react": "^18.2.0", - "react-dom": "^18.2.0", - "reshadow": "^0.0.1" + "react-dom": "^18.2.0" }, "peerDependencies": {}, "devDependencies": { diff --git a/webapp/packages/plugin-connection-custom/package.json b/webapp/packages/plugin-connection-custom/package.json index 0b37b0ace1..d8abfb19ea 100644 --- a/webapp/packages/plugin-connection-custom/package.json +++ b/webapp/packages/plugin-connection-custom/package.json @@ -26,7 +26,6 @@ "@cloudbeaver/core-plugin": "~0.1.0", "@cloudbeaver/core-projects": "~0.1.0", "@cloudbeaver/core-resource": "~0.1.0", - "@cloudbeaver/core-utils": "~0.1.0", "@cloudbeaver/core-view": "~0.1.0", "@cloudbeaver/plugin-connections": "~0.1.0", "mobx": "^6.12.0", diff --git a/webapp/packages/plugin-connection-custom/tsconfig.json b/webapp/packages/plugin-connection-custom/tsconfig.json index d97ec04fab..665c309c6c 100644 --- a/webapp/packages/plugin-connection-custom/tsconfig.json +++ b/webapp/packages/plugin-connection-custom/tsconfig.json @@ -33,9 +33,6 @@ { "path": "../core-resource/tsconfig.json" }, - { - "path": "../core-utils/tsconfig.json" - }, { "path": "../core-view/tsconfig.json" }, diff --git a/webapp/packages/plugin-connection-search/package.json b/webapp/packages/plugin-connection-search/package.json index 50d7f44521..84b09a1860 100644 --- a/webapp/packages/plugin-connection-search/package.json +++ b/webapp/packages/plugin-connection-search/package.json @@ -17,7 +17,6 @@ "update-ts-references": "rimraf --glob dist && typescript-resolve-references" }, "dependencies": { - "@cloudbeaver/core-authentication": "~0.1.0", "@cloudbeaver/core-blocks": "~0.1.0", "@cloudbeaver/core-connections": "~0.1.0", "@cloudbeaver/core-di": "~0.1.0", @@ -35,12 +34,12 @@ "@cloudbeaver/plugin-connections": "~0.1.0", "mobx": "^6.12.0", "mobx-react-lite": "^4.0.5", - "react": "^18.2.0", - "reshadow": "^0.0.1" + "react": "^18.2.0" }, "peerDependencies": {}, "devDependencies": { "@types/react": "^18.2.42", - "typescript": "^5.3.2" + "typescript": "^5.3.2", + "typescript-plugin-css-modules": "^5.0.2" } } diff --git a/webapp/packages/plugin-connection-search/src/SearchConnectionPluginBootstrap.ts b/webapp/packages/plugin-connection-search/src/SearchConnectionPluginBootstrap.ts index 33e66a97f7..70c9eaa64d 100644 --- a/webapp/packages/plugin-connection-search/src/SearchConnectionPluginBootstrap.ts +++ b/webapp/packages/plugin-connection-search/src/SearchConnectionPluginBootstrap.ts @@ -5,12 +5,11 @@ * Licensed under the Apache License, Version 2.0. * you may not use this file except in compliance with the License. */ -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { ConnectionsManagerService } from '@cloudbeaver/core-connections'; import { Bootstrap, injectable } from '@cloudbeaver/core-di'; import { ProjectInfoResource } from '@cloudbeaver/core-projects'; import { CachedMapAllKey, getCachedMapResourceLoaderState } from '@cloudbeaver/core-resource'; -import { PermissionsService } from '@cloudbeaver/core-root'; +import { EAdminPermission, PermissionsService } from '@cloudbeaver/core-root'; import { ActionService, DATA_CONTEXT_MENU, MenuService } from '@cloudbeaver/core-view'; import { MENU_CONNECTIONS } from '@cloudbeaver/plugin-connections'; @@ -52,9 +51,7 @@ export class SearchConnectionPluginBootstrap extends Bootstrap { return false; }, - getLoader: (context, action) => { - return getCachedMapResourceLoaderState(this.projectInfoResource, () => CachedMapAllKey); - }, + getLoader: (context, action) => getCachedMapResourceLoaderState(this.projectInfoResource, () => CachedMapAllKey), handler: async (context, action) => { switch (action) { case ACTION_CONNECTION_SEARCH: { diff --git a/webapp/packages/plugin-connection-search/tsconfig.json b/webapp/packages/plugin-connection-search/tsconfig.json index 64e73c95da..d83e8854b7 100644 --- a/webapp/packages/plugin-connection-search/tsconfig.json +++ b/webapp/packages/plugin-connection-search/tsconfig.json @@ -6,9 +6,6 @@ "tsBuildInfoFile": "dist/tsconfig.tsbuildinfo" }, "references": [ - { - "path": "../core-authentication/tsconfig.json" - }, { "path": "../core-blocks/tsconfig.json" }, diff --git a/webapp/packages/plugin-connections-administration/src/ConnectionForm/ConnectionAccess/ConnectionAccessTabService.ts b/webapp/packages/plugin-connections-administration/src/ConnectionForm/ConnectionAccess/ConnectionAccessTabService.ts index 2b77f0ce7d..26523da307 100644 --- a/webapp/packages/plugin-connections-administration/src/ConnectionForm/ConnectionAccess/ConnectionAccessTabService.ts +++ b/webapp/packages/plugin-connections-administration/src/ConnectionForm/ConnectionAccess/ConnectionAccessTabService.ts @@ -8,12 +8,11 @@ import React from 'react'; import { AdministrationScreenService } from '@cloudbeaver/core-administration'; -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { ConnectionInfoResource, createConnectionParam, IConnectionInfoParams } from '@cloudbeaver/core-connections'; import { Bootstrap, injectable } from '@cloudbeaver/core-di'; import { executorHandlerFilter, IExecutionContextProvider } from '@cloudbeaver/core-executor'; import { isGlobalProject, ProjectInfoResource } from '@cloudbeaver/core-projects'; -import { PermissionsService } from '@cloudbeaver/core-root'; +import { PermissionsService, EAdminPermission } from '@cloudbeaver/core-root'; import { formStateContext } from '@cloudbeaver/core-ui'; import type { MetadataValueGetter } from '@cloudbeaver/core-utils'; import { diff --git a/webapp/packages/plugin-connections/src/ConnectionForm/Options/Options.tsx b/webapp/packages/plugin-connections/src/ConnectionForm/Options/Options.tsx index b8727b3623..ec25a5f123 100644 --- a/webapp/packages/plugin-connections/src/ConnectionForm/Options/Options.tsx +++ b/webapp/packages/plugin-connections/src/ConnectionForm/Options/Options.tsx @@ -8,7 +8,7 @@ import { observer } from 'mobx-react-lite'; import { useCallback, useRef } from 'react'; -import { AUTH_PROVIDER_LOCAL_ID, EAdminPermission } from '@cloudbeaver/core-authentication'; +import { AUTH_PROVIDER_LOCAL_ID } from '@cloudbeaver/core-authentication'; import { ColoredContainer, Combobox, @@ -35,7 +35,7 @@ import { import { DatabaseAuthModelsResource, DBDriverResource, isLocalConnection } from '@cloudbeaver/core-connections'; import { useService } from '@cloudbeaver/core-di'; import { CachedResourceListEmptyKey, resourceKeyList } from '@cloudbeaver/core-resource'; -import { ServerConfigResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, ServerConfigResource } from '@cloudbeaver/core-root'; import { DriverConfigurationType } from '@cloudbeaver/core-sdk'; import { type TabContainerPanelComponent, useAuthenticationAction } from '@cloudbeaver/core-ui'; import { isSafari } from '@cloudbeaver/core-utils'; diff --git a/webapp/packages/plugin-connections/src/ContextMenu/ConnectionMenuBootstrap.ts b/webapp/packages/plugin-connections/src/ContextMenu/ConnectionMenuBootstrap.ts index d2bd3dc7f2..713af2e3a1 100644 --- a/webapp/packages/plugin-connections/src/ContextMenu/ConnectionMenuBootstrap.ts +++ b/webapp/packages/plugin-connections/src/ContextMenu/ConnectionMenuBootstrap.ts @@ -5,7 +5,6 @@ * Licensed under the Apache License, Version 2.0. * you may not use this file except in compliance with the License. */ -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { Connection, ConnectionInfoResource, @@ -20,6 +19,7 @@ import { DATA_CONTEXT_NAV_NODE, EObjectFeature, NavNodeManagerService } from '@c import { getCachedMapResourceLoaderState } from '@cloudbeaver/core-resource'; import { CONNECTION_NAVIGATOR_VIEW_SETTINGS, + EAdminPermission, isNavigatorViewSettingsEqual, NavigatorViewSettings, PermissionsService, diff --git a/webapp/packages/plugin-data-export/package.json b/webapp/packages/plugin-data-export/package.json index 44107aeb0d..a08be134e7 100644 --- a/webapp/packages/plugin-data-export/package.json +++ b/webapp/packages/plugin-data-export/package.json @@ -37,14 +37,12 @@ "mobx": "^6.12.0", "mobx-react-lite": "^4.0.5", "react": "^18.2.0", - "reshadow": "^0.0.1", - "@cloudbeaver/core-authentication": "~0.1.0" + "reshadow": "^0.0.1" }, "peerDependencies": {}, "devDependencies": { "@cloudbeaver/core-administration": "~0.1.0", "@cloudbeaver/core-app": "~0.1.0", - "@cloudbeaver/core-authentication": "~0.1.0", "@cloudbeaver/core-browser": "~0.1.0", "@cloudbeaver/core-connections": "~0.1.0", "@cloudbeaver/core-dialogs": "~0.1.0", @@ -71,6 +69,7 @@ "@types/jest": "^29.5.10", "@types/react": "^18.2.42", "typescript": "^5.3.2", - "typescript-plugin-css-modules": "^5.0.2" + "typescript-plugin-css-modules": "^5.0.2", + "@cloudbeaver/core-authentication": "~0.1.0" } } diff --git a/webapp/packages/plugin-data-export/src/DataExportMenuService.ts b/webapp/packages/plugin-data-export/src/DataExportMenuService.ts index 738cc20264..e057ed4399 100644 --- a/webapp/packages/plugin-data-export/src/DataExportMenuService.ts +++ b/webapp/packages/plugin-data-export/src/DataExportMenuService.ts @@ -5,13 +5,12 @@ * Licensed under the Apache License, Version 2.0. * you may not use this file except in compliance with the License. */ -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { createConnectionParam, DATA_CONTEXT_CONNECTION } from '@cloudbeaver/core-connections'; import { injectable } from '@cloudbeaver/core-di'; import { CommonDialogService } from '@cloudbeaver/core-dialogs'; import { LocalizationService } from '@cloudbeaver/core-localization'; import { DATA_CONTEXT_NAV_NODE, EObjectFeature } from '@cloudbeaver/core-navigation-tree'; -import { SessionPermissionsResource } from '@cloudbeaver/core-root'; +import { EAdminPermission, SessionPermissionsResource } from '@cloudbeaver/core-root'; import { withTimestamp } from '@cloudbeaver/core-utils'; import { ACTION_EXPORT, ActionService, DATA_CONTEXT_MENU, DATA_CONTEXT_MENU_NESTED, menuExtractItems, MenuService } from '@cloudbeaver/core-view'; import { diff --git a/webapp/packages/plugin-data-export/tsconfig.json b/webapp/packages/plugin-data-export/tsconfig.json index 7d59bb68b0..c53fc9930f 100644 --- a/webapp/packages/plugin-data-export/tsconfig.json +++ b/webapp/packages/plugin-data-export/tsconfig.json @@ -54,18 +54,12 @@ { "path": "../plugin-sql-editor/tsconfig.json" }, - { - "path": "../core-authentication/tsconfig.json" - }, { "path": "../core-administration/tsconfig.json" }, { "path": "../core-app/tsconfig.json" }, - { - "path": "../core-authentication/tsconfig.json" - }, { "path": "../core-browser/tsconfig.json" }, @@ -131,6 +125,9 @@ }, { "path": "../tests-runner/tsconfig.json" + }, + { + "path": "../core-authentication/tsconfig.json" } ], "include": [ diff --git a/webapp/packages/plugin-data-viewer/package.json b/webapp/packages/plugin-data-viewer/package.json index 6d7fc64a96..caee26f3b3 100644 --- a/webapp/packages/plugin-data-viewer/package.json +++ b/webapp/packages/plugin-data-viewer/package.json @@ -18,7 +18,6 @@ "update-ts-references": "rimraf --glob dist && typescript-resolve-references" }, "dependencies": { - "@cloudbeaver/core-authentication": "~0.1.0", "@cloudbeaver/core-blocks": "~0.1.0", "@cloudbeaver/core-connections": "~0.1.0", "@cloudbeaver/core-data-context": "~0.1.0", @@ -50,7 +49,6 @@ "devDependencies": { "@cloudbeaver/core-administration": "~0.1.0", "@cloudbeaver/core-app": "~0.1.0", - "@cloudbeaver/core-authentication": "~0.1.0", "@cloudbeaver/core-browser": "~0.1.0", "@cloudbeaver/core-connections": "~0.1.0", "@cloudbeaver/core-dialogs": "~0.1.0", @@ -76,6 +74,7 @@ "@types/jest": "^29.5.10", "@types/react": "^18.2.42", "typescript": "^5.3.2", - "typescript-plugin-css-modules": "^5.0.2" + "typescript-plugin-css-modules": "^5.0.2", + "@cloudbeaver/core-authentication": "~0.1.0" } } diff --git a/webapp/packages/plugin-data-viewer/src/ValuePanelPresentation/QuotaPlaceholder.tsx b/webapp/packages/plugin-data-viewer/src/ValuePanelPresentation/QuotaPlaceholder.tsx index 19a606e151..dd95cf78a4 100644 --- a/webapp/packages/plugin-data-viewer/src/ValuePanelPresentation/QuotaPlaceholder.tsx +++ b/webapp/packages/plugin-data-viewer/src/ValuePanelPresentation/QuotaPlaceholder.tsx @@ -8,8 +8,8 @@ import { observer } from 'mobx-react-lite'; import styled, { css } from 'reshadow'; -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { Link, usePermission, useTranslate } from '@cloudbeaver/core-blocks'; +import { EAdminPermission } from '@cloudbeaver/core-root'; interface Props { limit?: string; diff --git a/webapp/packages/plugin-data-viewer/tsconfig.json b/webapp/packages/plugin-data-viewer/tsconfig.json index 55752367c5..75094644d5 100644 --- a/webapp/packages/plugin-data-viewer/tsconfig.json +++ b/webapp/packages/plugin-data-viewer/tsconfig.json @@ -6,9 +6,6 @@ "tsBuildInfoFile": "dist/tsconfig.tsbuildinfo" }, "references": [ - { - "path": "../core-authentication/tsconfig.json" - }, { "path": "../core-blocks/tsconfig.json" }, @@ -81,9 +78,6 @@ { "path": "../core-app/tsconfig.json" }, - { - "path": "../core-authentication/tsconfig.json" - }, { "path": "../core-browser/tsconfig.json" }, @@ -146,6 +140,9 @@ }, { "path": "../tests-runner/tsconfig.json" + }, + { + "path": "../core-authentication/tsconfig.json" } ], "include": [ diff --git a/webapp/packages/plugin-devtools/package.json b/webapp/packages/plugin-devtools/package.json index edc1b59a50..6473e7b519 100644 --- a/webapp/packages/plugin-devtools/package.json +++ b/webapp/packages/plugin-devtools/package.json @@ -17,7 +17,6 @@ "update-ts-references": "rimraf --glob dist && typescript-resolve-references" }, "dependencies": { - "@cloudbeaver/core-authentication": "~0.1.0", "@cloudbeaver/core-blocks": "~0.1.0", "@cloudbeaver/core-data-context": "~0.1.0", "@cloudbeaver/core-di": "~0.1.0", diff --git a/webapp/packages/plugin-devtools/src/PluginBootstrap.ts b/webapp/packages/plugin-devtools/src/PluginBootstrap.ts index 0bc89b9a9a..850d9b30dc 100644 --- a/webapp/packages/plugin-devtools/src/PluginBootstrap.ts +++ b/webapp/packages/plugin-devtools/src/PluginBootstrap.ts @@ -5,10 +5,9 @@ * Licensed under the Apache License, Version 2.0. * you may not use this file except in compliance with the License. */ -import { EAdminPermission } from '@cloudbeaver/core-authentication'; import { App, Bootstrap, DIService, injectable, IServiceConstructor } from '@cloudbeaver/core-di'; import { CachedResource } from '@cloudbeaver/core-resource'; -import { PermissionsService } from '@cloudbeaver/core-root'; +import { PermissionsService, EAdminPermission } from '@cloudbeaver/core-root'; import { ActionService, DATA_CONTEXT_MENU, DATA_CONTEXT_SUBMENU_ITEM, MenuBaseItem, MenuService } from '@cloudbeaver/core-view'; import { TOP_NAV_BAR_SETTINGS_MENU } from '@cloudbeaver/plugin-settings-menu'; import { MENU_USER_PROFILE } from '@cloudbeaver/plugin-user-profile'; diff --git a/webapp/packages/plugin-devtools/tsconfig.json b/webapp/packages/plugin-devtools/tsconfig.json index f45fb0c6a6..5e4f868cf7 100644 --- a/webapp/packages/plugin-devtools/tsconfig.json +++ b/webapp/packages/plugin-devtools/tsconfig.json @@ -6,9 +6,6 @@ "tsBuildInfoFile": "dist/tsconfig.tsbuildinfo" }, "references": [ - { - "path": "../core-authentication/tsconfig.json" - }, { "path": "../core-blocks/tsconfig.json" }, diff --git a/webapp/packages/plugin-object-viewer/package.json b/webapp/packages/plugin-object-viewer/package.json index c558b46eab..6dedc48de1 100644 --- a/webapp/packages/plugin-object-viewer/package.json +++ b/webapp/packages/plugin-object-viewer/package.json @@ -40,7 +40,7 @@ "mobx": "^6.12.0", "mobx-react-lite": "^4.0.5", "react": "^18.2.0", - "reakit": "~1.x.x", + "reakit": "~1.3.11", "reshadow": "^0.0.1" }, "peerDependencies": {}, diff --git a/webapp/packages/plugin-root/package.json b/webapp/packages/plugin-root/package.json index 6287e60eef..6dbb0bacf6 100644 --- a/webapp/packages/plugin-root/package.json +++ b/webapp/packages/plugin-root/package.json @@ -26,8 +26,7 @@ "@cloudbeaver/core-routing": "~0.1.0", "@cloudbeaver/core-utils": "~0.1.0", "mobx-react-lite": "^4.0.5", - "react": "^18.2.0", - "reshadow": "^0.0.1" + "react": "^18.2.0" }, "peerDependencies": {}, "devDependencies": { diff --git a/webapp/packages/plugin-settings-panel/package.json b/webapp/packages/plugin-settings-panel/package.json index 5c2fde07e0..a9c0fee248 100644 --- a/webapp/packages/plugin-settings-panel/package.json +++ b/webapp/packages/plugin-settings-panel/package.json @@ -33,6 +33,7 @@ "peerDependencies": {}, "devDependencies": { "@types/react": "^18.2.42", - "typescript": "^5.3.2" + "typescript": "^5.3.2", + "typescript-plugin-css-modules": "^5.0.2" } } diff --git a/webapp/packages/plugin-sql-generator/package.json b/webapp/packages/plugin-sql-generator/package.json index eb5e2f9283..90b2dedb90 100644 --- a/webapp/packages/plugin-sql-generator/package.json +++ b/webapp/packages/plugin-sql-generator/package.json @@ -34,7 +34,8 @@ "@cloudbeaver/plugin-sql-editor-new": "~0.1.0", "mobx": "^6.12.0", "mobx-react-lite": "^4.0.5", - "react": "^18.2.0" + "react": "^18.2.0", + "@cloudbeaver/core-utils": "~0.1.0" }, "peerDependencies": {}, "devDependencies": { diff --git a/webapp/packages/plugin-sql-generator/tsconfig.json b/webapp/packages/plugin-sql-generator/tsconfig.json index 282bb1c6ea..95e262f7f5 100644 --- a/webapp/packages/plugin-sql-generator/tsconfig.json +++ b/webapp/packages/plugin-sql-generator/tsconfig.json @@ -47,6 +47,9 @@ }, { "path": "../plugin-sql-editor-new/tsconfig.json" + }, + { + "path": "../core-utils/tsconfig.json" } ], "include": [ diff --git a/webapp/packages/plugin-tools-panel/package.json b/webapp/packages/plugin-tools-panel/package.json index 70ee7449f8..ea318c2ffa 100644 --- a/webapp/packages/plugin-tools-panel/package.json +++ b/webapp/packages/plugin-tools-panel/package.json @@ -34,6 +34,7 @@ "peerDependencies": {}, "devDependencies": { "@types/react": "^18.2.42", - "typescript": "^5.3.2" + "typescript": "^5.3.2", + "typescript-plugin-css-modules": "^5.0.2" } } diff --git a/webapp/packages/plugin-version-update-administration/package.json b/webapp/packages/plugin-version-update-administration/package.json index 3b132c84d0..37b3c35caf 100644 --- a/webapp/packages/plugin-version-update-administration/package.json +++ b/webapp/packages/plugin-version-update-administration/package.json @@ -30,7 +30,8 @@ "react-markdown": "^9.0.1", "reshadow": "^0.0.1", "semver": "^7.5.4", - "@cloudbeaver/core-localization": "~0.1.0" + "@cloudbeaver/core-localization": "~0.1.0", + "@cloudbeaver/core-utils": "~0.1.0" }, "peerDependencies": {}, "devDependencies": { diff --git a/webapp/packages/plugin-version-update-administration/tsconfig.json b/webapp/packages/plugin-version-update-administration/tsconfig.json index e377e7f465..99db8e5e49 100644 --- a/webapp/packages/plugin-version-update-administration/tsconfig.json +++ b/webapp/packages/plugin-version-update-administration/tsconfig.json @@ -32,6 +32,9 @@ }, { "path": "../core-localization/tsconfig.json" + }, + { + "path": "../core-utils/tsconfig.json" } ], "include": [ diff --git a/webapp/packages/product-default/tsconfig.json b/webapp/packages/product-default/tsconfig.json index ab07dce875..ade28e5f1b 100644 --- a/webapp/packages/product-default/tsconfig.json +++ b/webapp/packages/product-default/tsconfig.json @@ -15,9 +15,15 @@ { "path": "../core-di/tsconfig.json" }, + { + "path": "../core-localization/tsconfig.json" + }, { "path": "../core-product/tsconfig.json" }, + { + "path": "../core-task-manager/tsconfig.json" + }, { "path": "../core-version-update/tsconfig.json" }, @@ -147,6 +153,9 @@ { "path": "../plugin-sso/tsconfig.json" }, + { + "path": "../plugin-task-manager/tsconfig.json" + }, { "path": "../plugin-theme/tsconfig.json" }, @@ -170,15 +179,6 @@ }, { "path": "../plugin-version-update-administration/tsconfig.json" - }, - { - "path": "../core-localization/tsconfig.json" - }, - { - "path": "../core-task-manager/tsconfig.json" - }, - { - "path": "../plugin-task-manager/tsconfig.json" } ], "include": [ diff --git a/webapp/yarn.lock b/webapp/yarn.lock index e6e1acc243..b02befe5c5 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -15537,7 +15537,7 @@ reakit-warning@^0.6.2: dependencies: reakit-utils "^0.15.2" -reakit@~1.3.11, reakit@~1.x.x: +reakit@~1.3.11: version "1.3.11" resolved "https://registry.yarnpkg.com/reakit/-/reakit-1.3.11.tgz#c15360ac43e94fbe4291d233af3ac5040428252e" integrity sha512-mYxw2z0fsJNOQKAEn5FJCPTU3rcrY33YZ/HzoWqZX0G7FwySp1wkCYW79WhuYMNIUFQ8s3Baob1RtsEywmZSig==