Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: resolve npm dependencies #2050

Merged
merged 7 commits into from
Oct 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .github/workflows/frontend-cache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ on:
paths:
- "webapp/**"

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
build_and_test:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -64,10 +67,10 @@ jobs:
uses: borales/actions-yarn@v4
with:
dir: webapp/packages/product-default
cmd: build
cmd: build # build tyescript source code

- name: test
uses: borales/actions-yarn@v4
with:
dir: webapp
cmd: lerna run test
cmd: lerna run test # build packages that have test script
2 changes: 1 addition & 1 deletion .github/workflows/frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ jobs:
uses: borales/actions-yarn@v4
with:
dir: webapp/packages/product-default
cmd: build
cmd: bundle

- name: test
uses: borales/actions-yarn@v4
Expand Down
2 changes: 1 addition & 1 deletion deploy/build.bat
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ cd ..\cloudbeaver\webapp

call yarn
call yarn lerna bootstrap
call yarn lerna run build --no-bail --stream --scope=@cloudbeaver/product-default &::-- -- --env source-map
call yarn lerna run bundle --no-bail --stream --scope=@cloudbeaver/product-default &::-- -- --env source-map

cd ..\deploy

Expand Down
2 changes: 1 addition & 1 deletion deploy/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ cd ../cloudbeaver/webapp

yarn
yarn lerna run bootstrap
yarn lerna run build --no-bail --stream --scope=@cloudbeaver/product-default #-- -- --env source-map
yarn lerna run bundle --no-bail --stream --scope=@cloudbeaver/product-default #-- -- --env source-map
if [[ "$?" -ne 0 ]] ; then
echo 'Application build failed'; exit $rc
fi
Expand Down
23 changes: 11 additions & 12 deletions webapp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,31 +12,30 @@
},
"scripts": {
"prebuild": "lerna run gql:gen --stream --parallel",
"pretest": "lerna run gql:gen --stream --parallel && yarn lerna run test --scope @cloudbeaver/tests-runner",
"clean-dist": "rimraf --glob lib/*"
"pretest": "lerna run gql:gen --stream --parallel && yarn lerna run test --scope @cloudbeaver/tests-runner"
},
"devDependencies": {
"@testing-library/dom": "^9.3.1",
"@testing-library/dom": "^9.3.3",
"@testing-library/jest-dom": "^6.1.3",
"@testing-library/react": "^14.0.0",
"@testing-library/user-event": "^14.4.3",
"@types/jest": "^29.5.4",
"@types/react": "~18.0.28",
"@types/react-dom": "~18.2.7",
"@types/jest": "^29.5.5",
"@types/react": "^18.2.25",
"@types/react-dom": "^18.2.11",
"concurrently": "^8.2.1",
"lerna": "5.5.4",
"mobx": "~6.8.0",
"mobx-react-lite": "~4.0.3",
"msw": "^1.3.0",
"mobx": "^6.10.2",
"mobx-react-lite": "^4.0.5",
"msw": "^1.3.2",
"path-browserify": "~1.0.1",
"prettier": "^2.8.8",
"react": "~18.2.0",
"react-dom": "~18.2.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"reakit": "~1.3.11",
"reflect-metadata": "~0.1.13",
"reshadow": "^0.0.1",
"rimraf": "~5.0.1",
"typescript": "5.2.2",
"typescript": "^5.2.2",
"typescript-plugin-css-modules": "^5.0.1"
},
"dependencies": {},
Expand Down
32 changes: 19 additions & 13 deletions webapp/packages/core-administration/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,12 @@
"license": "Apache-2.0",
"main": "dist/index.js",
"scripts": {
"build": "core-cli-build --mode=production --config ../core-cli/configs/webpack.plugin.config.js",
"build": "tsc -b",
"lint": "eslint ./src/ --ext .ts,.tsx",
"lint-fix": "eslint ./src/ --ext .ts,.tsx --fix",
"pretest": "tsc -b",
"test": "core-cli-test",
"test": "yarn build && core-cli-test",
"validate-dependencies": "core-cli-validate-dependencies",
"update-ts-references": "rimraf --glob dist/* && typescript-resolve-references"
"update-ts-references": "rimraf --glob dist && typescript-resolve-references"
},
"dependencies": {
"@cloudbeaver/core-authentication": "~0.1.0",
Expand All @@ -32,16 +31,23 @@
"@cloudbeaver/core-sdk": "~0.1.0",
"@cloudbeaver/core-settings": "~0.1.0",
"@cloudbeaver/core-theming": "~0.1.0",
"@cloudbeaver/core-utils": "~0.1.0"
},
"peerDependencies": {
"react": "~18.x.x",
"mobx": "~6.x.x",
"mobx-react-lite": "~3.x.x",
"reshadow": "~0.x.x",
"@testing-library/jest-dom": "^6.x.x"
"@cloudbeaver/core-utils": "~0.1.0",
"mobx": "^6.10.2",
"reshadow": "~0.x.x"
},
"peerDependencies": {},
"devDependencies": {
"@cloudbeaver/tests-runner": "~0.1.0"
"@cloudbeaver/core-browser": "~0.1.0",
"@cloudbeaver/core-events": "~0.1.0",
"@cloudbeaver/core-localization": "~0.1.0",
"@cloudbeaver/core-plugin": "~0.1.0",
"@cloudbeaver/core-product": "~0.1.0",
"@cloudbeaver/core-root": "~0.1.0",
"@cloudbeaver/core-sdk": "~0.1.0",
"@cloudbeaver/core-settings": "~0.1.0",
"@cloudbeaver/tests-runner": "~0.1.0",
"@testing-library/jest-dom": "^6.1.3",
"@types/jest": "^29.5.5",
"typescript": "^5.2.2"
}
}
24 changes: 24 additions & 0 deletions webapp/packages/core-administration/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,30 @@
{
"path": "../core-utils/tsconfig.json"
},
{
"path": "../core-browser/tsconfig.json"
},
{
"path": "../core-events/tsconfig.json"
},
{
"path": "../core-localization/tsconfig.json"
},
{
"path": "../core-plugin/tsconfig.json"
},
{
"path": "../core-product/tsconfig.json"
},
{
"path": "../core-root/tsconfig.json"
},
{
"path": "../core-sdk/tsconfig.json"
},
{
"path": "../core-settings/tsconfig.json"
},
{
"path": "../tests-runner/tsconfig.json"
}
Expand Down
24 changes: 12 additions & 12 deletions webapp/packages/core-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,13 @@
"license": "Apache-2.0",
"main": "dist/index.js",
"scripts": {
"build": "core-cli-build --mode=production --config ../core-cli/configs/webpack.plugin.config.js",
"build": "tsc -b",
"lint": "eslint ./src/ --ext .ts,.tsx",
"lint-fix": "eslint ./src/ --ext .ts,.tsx --fix",
"validate-dependencies": "core-cli-validate-dependencies",
"update-ts-references": "rimraf --glob dist/* && typescript-resolve-references"
"update-ts-references": "rimraf --glob dist && typescript-resolve-references"
},
"dependencies": {
"@cloudbeaver/plugin-version": "~0.1.0",
"@cloudbeaver/core-blocks": "~0.1.0",
"@cloudbeaver/core-di": "~0.1.0",
"@cloudbeaver/core-executor": "~0.1.0",
Expand All @@ -29,14 +28,15 @@
"@cloudbeaver/core-root": "~0.1.0",
"@cloudbeaver/core-routing": "~0.1.0",
"@cloudbeaver/core-theming": "~0.1.0",
"@cloudbeaver/core-ui": "~0.1.0"
"@cloudbeaver/core-ui": "~0.1.0",
"@cloudbeaver/core-version": "~0.1.0",
"mobx-react-lite": "^4.0.5",
"react": "^18.2.0"
},
"peerDependencies": {
"react": "~18.x.x",
"react-dom": "~18.x.x",
"mobx": "~6.x.x",
"mobx-react-lite": "~3.x.x",
"reshadow": "~0.x.x"
},
"devDependencies": {}
"peerDependencies": {},
"devDependencies": {
"@types/react": "^18.2.25",
"typescript": "^5.2.2",
"typescript-plugin-css-modules": "^5.0.1"
}
}
4 changes: 2 additions & 2 deletions webapp/packages/core-app/src/Body.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import { observer } from 'mobx-react-lite';
import { useLayoutEffect, useRef } from 'react';

import { DialogsPortal, Loader, s, useResource, useS, useStyles } from '@cloudbeaver/core-blocks';
import { DialogsPortal, Loader, s, useResource, useS } from '@cloudbeaver/core-blocks';
import { useService } from '@cloudbeaver/core-di';
import { Notifications } from '@cloudbeaver/core-notifications';
import { ProjectInfoResource } from '@cloudbeaver/core-projects';
Expand All @@ -17,7 +17,7 @@ import { SessionPermissionsResource } from '@cloudbeaver/core-root';
import { ScreenService } from '@cloudbeaver/core-routing';
import { ThemeService } from '@cloudbeaver/core-theming';
import { DNDProvider } from '@cloudbeaver/core-ui';
import { useAppVersion } from '@cloudbeaver/plugin-version';
import { useAppVersion } from '@cloudbeaver/core-version';

import style from './Body.m.css';

Expand Down
6 changes: 3 additions & 3 deletions webapp/packages/core-app/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@
"tsBuildInfoFile": "dist/tsconfig.tsbuildinfo"
},
"references": [
{
"path": "../plugin-version/tsconfig.json"
},
{
"path": "../core-blocks/tsconfig.json"
},
Expand Down Expand Up @@ -44,6 +41,9 @@
},
{
"path": "../core-ui/tsconfig.json"
},
{
"path": "../core-version/tsconfig.json"
}
],
"include": [
Expand Down
32 changes: 21 additions & 11 deletions webapp/packages/core-authentication/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,12 @@
"license": "Apache-2.0",
"main": "dist/index.js",
"scripts": {
"build": "core-cli-build --mode=production --config ../core-cli/configs/webpack.plugin.config.js",
"build": "tsc -b",
"lint": "eslint ./src/ --ext .ts,.tsx",
"lint-fix": "eslint ./src/ --ext .ts,.tsx --fix",
"pretest": "tsc -b",
"test": "core-cli-test",
"test": "yarn build && core-cli-test",
"validate-dependencies": "core-cli-validate-dependencies",
"update-ts-references": "rimraf --glob dist/* && typescript-resolve-references"
"update-ts-references": "rimraf --glob dist && typescript-resolve-references"
},
"dependencies": {
"@cloudbeaver/core-data-context": "~0.1.0",
Expand All @@ -30,14 +29,25 @@
"@cloudbeaver/core-sdk": "~0.1.0",
"@cloudbeaver/core-settings": "~0.1.0",
"@cloudbeaver/core-theming": "~0.1.0",
"@cloudbeaver/core-utils": "~0.1.0"
},
"peerDependencies": {
"mobx": "~6.x.x",
"msw": "~1.x.x",
"@testing-library/jest-dom": "^6.x.x"
"@cloudbeaver/core-utils": "~0.1.0",
"mobx": "^6.10.2"
},
"peerDependencies": {},
"devDependencies": {
"@cloudbeaver/tests-runner": "~0.1.0"
"@cloudbeaver/core-browser": "~0.1.0",
"@cloudbeaver/core-events": "~0.1.0",
"@cloudbeaver/core-localization": "~0.1.0",
"@cloudbeaver/core-plugin": "~0.1.0",
"@cloudbeaver/core-product": "~0.1.0",
"@cloudbeaver/core-root": "~0.1.0",
"@cloudbeaver/core-routing": "~0.1.0",
"@cloudbeaver/core-sdk": "~0.1.0",
"@cloudbeaver/core-settings": "~0.1.0",
"@cloudbeaver/core-theming": "~0.1.0",
"@cloudbeaver/tests-runner": "~0.1.0",
"@testing-library/jest-dom": "^6.1.3",
"@types/jest": "^29.5.5",
"msw": "~1.x.x",
"typescript": "^5.2.2"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export function mockGetActiveUser(
req: GraphQLRequest<GetActiveUserQueryVariables>,
res: ResponseComposition<GetActiveUserQuery>,
ctx: GraphQLContext<GetActiveUserQuery>,
) {
): ReturnType<ResponseComposition<GetActiveUserQuery>> {
return res(
ctx.data({
user: null as unknown as undefined,
Expand Down
30 changes: 30 additions & 0 deletions webapp/packages/core-authentication/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,36 @@
{
"path": "../core-utils/tsconfig.json"
},
{
"path": "../core-browser/tsconfig.json"
},
{
"path": "../core-events/tsconfig.json"
},
{
"path": "../core-localization/tsconfig.json"
},
{
"path": "../core-plugin/tsconfig.json"
},
{
"path": "../core-product/tsconfig.json"
},
{
"path": "../core-root/tsconfig.json"
},
{
"path": "../core-routing/tsconfig.json"
},
{
"path": "../core-sdk/tsconfig.json"
},
{
"path": "../core-settings/tsconfig.json"
},
{
"path": "../core-theming/tsconfig.json"
},
{
"path": "../tests-runner/tsconfig.json"
}
Expand Down
Loading