-
Notifications
You must be signed in to change notification settings - Fork 386
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* CB-5918 add holidays plugin * CB-5918 add plugin-holidays as a reference to product default * CB-5918 fix holidays plugin, add icons * CB-5918 fix: don't run many renders simultaneously * CB-5918 fix: flakes respawn previously flakes kept x position that looked weird especially when user resize the window making it bigger * CB-5918 refactor: adjust flakes size and speed make flakes bigger and a little bit slower, reduce amount of flakes * CB-5918 refactor: make flakes look like flakes add shape prop to create different shapes of snowflakes add drawSnowflake to render snowflakes * CB-5918 Extract Logo registration to separate plugin In order to customize Logo for different occasions without creating circular dependencies with other plugins * CB-5918 refactor: update exports in holiday plugin * CB-5918 feat: make logo src a prop use holidays service to set custom logo * CB-5918 refactor: update logos * CB-5918 refactor: snowflakes removing faster if more flakes * CB-5918 refactor: reduce action icon rotation on click * CB-5918 fix: deps * CB-5918 fix: ts-config reference * CB-5918 refactor: use debounce for resizing * CB-5918 refactor: add throttle to handleMouseMove * CB-5918 refactor: update logo * CB-5918 fix: start date * CB-5918 feat: add rotation to snowflakes * CB-5918 fix: dep version * CB-5918: refactor: split up app logo plugin to public and admin parts * CB-5918 refactor: split holidays plugin up to two parts: admin and public * CB-5918 refactor: avoid using anonymous functions in Christmas class * CB-5918 refactor: HolidayActionButton * CB-5918 refactor: IHoliday interface naming * CB-5918 fix: update TS refs * CB-5918 fix: legacy color notation and lost this * CB-5918 refactor: remove redundant plugin bootstrap export * CB-5918 refactor: rename private property * CB-5918 refactor: use IconButton core block inside HolidayActionButton * CB-5918 refactor: add check in addHoliday method * CB-5918 refactor: simplify logoSrc condition * CB-5918 refactor: remove redundant styles * CB-5918 refactor: use descriptive names for plugins bootstrap * CB-5918 refactor: specify dep version * CB-5918 refactor: improve Christmas class readability * CB-5918 refactor: use lazy import for logo * CB-5918 refactor: export lazy components properly * CB-5918 fix: holiday end date --------- Co-authored-by: Daria Marutkina <[email protected]> Co-authored-by: Evgenia <[email protected]> Co-authored-by: mr-anton-t <[email protected]>
- Loading branch information
1 parent
285a216
commit b2a0a88
Showing
43 changed files
with
1,093 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# dependencies | ||
/node_modules | ||
|
||
# testing | ||
/coverage | ||
|
||
# production | ||
/lib | ||
|
||
# misc | ||
.DS_Store | ||
.env* | ||
|
||
# debug | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* |
30 changes: 30 additions & 0 deletions
30
webapp/packages/plugin-app-logo-administration/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"name": "@cloudbeaver/plugin-app-logo-administration", | ||
"type": "module", | ||
"sideEffects": [ | ||
"src/**/*.css", | ||
"src/**/*.scss", | ||
"public/**/*" | ||
], | ||
"version": "0.1.0", | ||
"description": "", | ||
"license": "Apache-2.0", | ||
"main": "dist/index.js", | ||
"scripts": { | ||
"build": "tsc -b", | ||
"clean": "rimraf --glob dist", | ||
"lint": "eslint ./src/ --ext .ts,.tsx", | ||
"validate-dependencies": "core-cli-validate-dependencies", | ||
"update-ts-references": "yarn run clean && typescript-resolve-references" | ||
}, | ||
"dependencies": { | ||
"@cloudbeaver/core-blocks": "^0", | ||
"@cloudbeaver/core-di": "^0", | ||
"@cloudbeaver/plugin-administration": "^0", | ||
"@cloudbeaver/plugin-app-logo": "^0" | ||
}, | ||
"peerDependencies": {}, | ||
"devDependencies": { | ||
"typescript": "^5" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
webapp/packages/plugin-app-logo-administration/src/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
/* | ||
* CloudBeaver - Cloud Database Manager | ||
* Copyright (C) 2020-2024 DBeaver Corp and others | ||
* | ||
* Licensed under the Apache License, Version 2.0. | ||
* you may not use this file except in compliance with the License. | ||
*/ | ||
import { appLogoAdministrationPlugin } from './manifest.js'; | ||
|
||
export { appLogoAdministrationPlugin }; | ||
export default appLogoAdministrationPlugin; |
15 changes: 15 additions & 0 deletions
15
webapp/packages/plugin-app-logo-administration/src/manifest.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
* CloudBeaver - Cloud Database Manager | ||
* Copyright (C) 2020-2024 DBeaver Corp and others | ||
* | ||
* Licensed under the Apache License, Version 2.0. | ||
* you may not use this file except in compliance with the License. | ||
*/ | ||
import type { PluginManifest } from '@cloudbeaver/core-di'; | ||
|
||
export const appLogoAdministrationPlugin: PluginManifest = { | ||
info: { | ||
name: 'App Logo Administration plugin', | ||
}, | ||
providers: [() => import('./PluginBootstrap.js').then(m => m.AppLogoAdministrationPluginBootstrap)], | ||
}; |
24 changes: 24 additions & 0 deletions
24
webapp/packages/plugin-app-logo-administration/tsconfig.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{ | ||
"extends": "../../tsconfig.base.json", | ||
"compilerOptions": { | ||
"rootDir": "src", | ||
"outDir": "dist", | ||
"tsBuildInfoFile": "dist/tsconfig.tsbuildinfo" | ||
}, | ||
"references": [ | ||
{ | ||
"path": "../core-blocks/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../core-di/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../plugin-administration/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../plugin-app-logo/tsconfig.json" | ||
} | ||
], | ||
"include": ["__custom_mocks__/**/*", "src/**/*", "src/**/*.json", "src/**/*.css", "src/**/*.scss"], | ||
"exclude": ["**/node_modules", "lib/**/*", "dist/**/*"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# dependencies | ||
/node_modules | ||
|
||
# testing | ||
/coverage | ||
|
||
# production | ||
/lib | ||
|
||
# misc | ||
.DS_Store | ||
.env* | ||
|
||
# debug | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ | ||
"name": "@cloudbeaver/plugin-app-logo", | ||
"type": "module", | ||
"sideEffects": [ | ||
"src/**/*.css", | ||
"src/**/*.scss", | ||
"public/**/*" | ||
], | ||
"version": "0.1.0", | ||
"description": "", | ||
"license": "Apache-2.0", | ||
"main": "dist/index.js", | ||
"scripts": { | ||
"build": "tsc -b", | ||
"clean": "rimraf --glob dist", | ||
"lint": "eslint ./src/ --ext .ts,.tsx", | ||
"validate-dependencies": "core-cli-validate-dependencies", | ||
"update-ts-references": "yarn run clean && typescript-resolve-references" | ||
}, | ||
"dependencies": { | ||
"@cloudbeaver/core-blocks": "^0", | ||
"@cloudbeaver/core-di": "^0", | ||
"@cloudbeaver/core-root": "^0", | ||
"@cloudbeaver/core-routing": "^0", | ||
"@cloudbeaver/core-version": "^0", | ||
"@cloudbeaver/core-view": "^0", | ||
"@cloudbeaver/plugin-holidays": "^0", | ||
"@cloudbeaver/plugin-top-app-bar": "^0", | ||
"mobx": "^6", | ||
"mobx-react-lite": "^4", | ||
"react": "^18" | ||
}, | ||
"peerDependencies": {}, | ||
"devDependencies": { | ||
"@types/react": "^18", | ||
"typescript": "^5", | ||
"typescript-plugin-css-modules": "^5" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/* | ||
* CloudBeaver - Cloud Database Manager | ||
* Copyright (C) 2020-2024 DBeaver Corp and others | ||
* | ||
* Licensed under the Apache License, Version 2.0. | ||
* you may not use this file except in compliance with the License. | ||
*/ | ||
import { importLazyComponent } from '@cloudbeaver/core-blocks'; | ||
|
||
export const LogoLazy = importLazyComponent(() => import('./Logo.js').then(m => m.Logo)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
/* | ||
* CloudBeaver - Cloud Database Manager | ||
* Copyright (C) 2020-2024 DBeaver Corp and others | ||
* | ||
* Licensed under the Apache License, Version 2.0. | ||
* you may not use this file except in compliance with the License. | ||
*/ | ||
import { Bootstrap, injectable } from '@cloudbeaver/core-di'; | ||
import { TopNavService } from '@cloudbeaver/plugin-top-app-bar'; | ||
import { LogoLazy } from './LogoLazy.js'; | ||
|
||
@injectable() | ||
export class AppLogoPluginBootstrap extends Bootstrap { | ||
constructor(private readonly topNavService: TopNavService) { | ||
super(); | ||
} | ||
|
||
override register() { | ||
this.topNavService.placeholder.add(LogoLazy, 0); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/* | ||
* CloudBeaver - Cloud Database Manager | ||
* Copyright (C) 2020-2024 DBeaver Corp and others | ||
* | ||
* Licensed under the Apache License, Version 2.0. | ||
* you may not use this file except in compliance with the License. | ||
*/ | ||
import { appLogoPlugin } from './manifest.js'; | ||
|
||
export * from './LogoLazy.js'; | ||
|
||
export { appLogoPlugin }; | ||
export default appLogoPlugin; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
* CloudBeaver - Cloud Database Manager | ||
* Copyright (C) 2020-2024 DBeaver Corp and others | ||
* | ||
* Licensed under the Apache License, Version 2.0. | ||
* you may not use this file except in compliance with the License. | ||
*/ | ||
import type { PluginManifest } from '@cloudbeaver/core-di'; | ||
|
||
export const appLogoPlugin: PluginManifest = { | ||
info: { | ||
name: 'App Logo plugin', | ||
}, | ||
providers: [() => import('./PluginBootstrap.js').then(m => m.AppLogoPluginBootstrap)], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
{ | ||
"extends": "../../tsconfig.base.json", | ||
"compilerOptions": { | ||
"rootDir": "src", | ||
"outDir": "dist", | ||
"tsBuildInfoFile": "dist/tsconfig.tsbuildinfo" | ||
}, | ||
"references": [ | ||
{ | ||
"path": "../core-blocks/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../core-di/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../core-root/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../core-routing/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../core-version/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../core-view/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../plugin-holidays/tsconfig.json" | ||
}, | ||
{ | ||
"path": "../plugin-top-app-bar/tsconfig.json" | ||
} | ||
], | ||
"include": [ | ||
"__custom_mocks__/**/*", | ||
"src/**/*", | ||
"src/**/*.json", | ||
"src/**/*.css", | ||
"src/**/*.scss" | ||
], | ||
"exclude": [ | ||
"**/node_modules", | ||
"lib/**/*", | ||
"dist/**/*" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# dependencies | ||
/node_modules | ||
|
||
# testing | ||
/coverage | ||
|
||
# production | ||
/lib | ||
|
||
# misc | ||
.DS_Store | ||
.env* | ||
|
||
# debug | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* |
30 changes: 30 additions & 0 deletions
30
webapp/packages/plugin-holidays-administration/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"name": "@cloudbeaver/plugin-holidays-administration", | ||
"type": "module", | ||
"sideEffects": [ | ||
"src/**/*.css", | ||
"src/**/*.scss", | ||
"public/**/*" | ||
], | ||
"version": "0.1.0", | ||
"description": "", | ||
"license": "Apache-2.0", | ||
"main": "dist/index.js", | ||
"scripts": { | ||
"build": "tsc -b", | ||
"clean": "rimraf --glob dist", | ||
"lint": "eslint ./src/ --ext .ts,.tsx", | ||
"validate-dependencies": "core-cli-validate-dependencies", | ||
"update-ts-references": "yarn run clean && typescript-resolve-references" | ||
}, | ||
"dependencies": { | ||
"@cloudbeaver/core-blocks": "^0", | ||
"@cloudbeaver/core-di": "^0", | ||
"@cloudbeaver/plugin-administration": "^0", | ||
"@cloudbeaver/plugin-holidays": "^0" | ||
}, | ||
"peerDependencies": {}, | ||
"devDependencies": { | ||
"typescript": "^5" | ||
} | ||
} |
Oops, something went wrong.