Skip to content

Commit

Permalink
Merge pull request #8111 from ever-co/develop
Browse files Browse the repository at this point in the history
Release
  • Loading branch information
evereq authored Aug 27, 2024
2 parents 8c72faf + 993b308 commit ed39e82
Show file tree
Hide file tree
Showing 859 changed files with 12,108 additions and 7,954 deletions.
10 changes: 9 additions & 1 deletion .cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,15 @@
"COMMONPROGRAMFILES",
"serverapi",
"serializables",
"drppicker"
"drppicker",
"titlebar",
"raleway",
"browserslist",
"flexbox",
"nbinput",
"nbbutton",
"xaxis",
"wdth"
],
"useGitignore": true,
"ignorePaths": [
Expand Down
8 changes: 8 additions & 0 deletions .deploy/api/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,10 @@ COPY --chown=node:node packages/plugins/job-employee-ui/package.json ./packages/
COPY --chown=node:node packages/plugins/job-matching-ui/package.json ./packages/plugins/job-matching-ui/
COPY --chown=node:node packages/plugins/job-proposal-ui/package.json ./packages/plugins/job-proposal-ui/
COPY --chown=node:node packages/plugins/job-search-ui/package.json ./packages/plugins/job-search-ui/
COPY --chown=node:node packages/plugins/legal-ui/package.json ./packages/plugins/legal-ui/
COPY --chown=node:node packages/plugins/maintenance-ui/package.json ./packages/plugins/maintenance-ui/
COPY --chown=node:node packages/plugins/onboarding-ui/package.json ./packages/plugins/onboarding-ui/
COPY --chown=node:node packages/plugins/public-layout-ui/package.json ./packages/plugins/public-layout-ui/
COPY --chown=node:node packages/ui-core/package.json ./packages/ui-core/
COPY --chown=node:node packages/ui-config/package.json ./packages/ui-config/
COPY --chown=node:node packages/ui-auth/package.json ./packages/ui-auth/
Expand Down Expand Up @@ -230,6 +234,10 @@ COPY --chown=node:node packages/plugins/job-employee-ui/package.json ./packages/
COPY --chown=node:node packages/plugins/job-matching-ui/package.json ./packages/plugins/job-matching-ui/
COPY --chown=node:node packages/plugins/job-proposal-ui/package.json ./packages/plugins/job-proposal-ui/
COPY --chown=node:node packages/plugins/job-search-ui/package.json ./packages/plugins/job-search-ui/
COPY --chown=node:node packages/plugins/public-layout-ui/package.json ./packages/plugins/public-layout-ui/
COPY --chown=node:node packages/plugins/legal-ui/package.json ./packages/plugins/legal-ui/
COPY --chown=node:node packages/plugins/maintenance-ui/package.json ./packages/plugins/maintenance-ui/
COPY --chown=node:node packages/plugins/onboarding-ui/package.json ./packages/plugins/onboarding-ui/
COPY --chown=node:node packages/ui-core/package.json ./packages/ui-core/
COPY --chown=node:node packages/ui-config/package.json ./packages/ui-config/
COPY --chown=node:node packages/ui-auth/package.json ./packages/ui-auth/
Expand Down
4 changes: 4 additions & 0 deletions .deploy/webapp/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,10 @@ COPY --chown=node:node packages/plugins/job-employee-ui/package.json ./packages/
COPY --chown=node:node packages/plugins/job-matching-ui/package.json ./packages/plugins/job-matching-ui/
COPY --chown=node:node packages/plugins/job-proposal-ui/package.json ./packages/plugins/job-proposal-ui/
COPY --chown=node:node packages/plugins/job-search-ui/package.json ./packages/plugins/job-search-ui/
COPY --chown=node:node packages/plugins/legal-ui/package.json ./packages/plugins/legal-ui/
COPY --chown=node:node packages/plugins/maintenance-ui/package.json ./packages/plugins/maintenance-ui/
COPY --chown=node:node packages/plugins/onboarding-ui/package.json ./packages/plugins/onboarding-ui/
COPY --chown=node:node packages/plugins/public-layout-ui/package.json ./packages/plugins/public-layout-ui/
COPY --chown=node:node packages/ui-core/package.json ./packages/ui-core/
COPY --chown=node:node packages/ui-config/package.json ./packages/ui-config/
COPY --chown=node:node packages/ui-auth/package.json ./packages/ui-auth/
Expand Down
144 changes: 144 additions & 0 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -433,6 +433,150 @@
}
}
},
"plugin-legal-ui": {
"projectType": "library",
"root": "packages/plugins/legal-ui",
"sourceRoot": "packages/plugins/legal-ui",
"prefix": "lib",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:ng-packagr",
"options": {
"project": "packages/plugins/legal-ui/ng-package.json"
},
"configurations": {
"production": {
"tsConfig": "packages/plugins/legal-ui/tsconfig.lib.prod.json"
},
"development": {
"tsConfig": "packages/plugins/legal-ui/tsconfig.lib.json"
}
},
"defaultConfiguration": "production"
},
"test": {
"builder": "@angular-devkit/build-angular:karma",
"options": {
"tsConfig": "packages/plugins/legal-ui/tsconfig.spec.json",
"polyfills": ["zone.js", "zone.js/testing"]
}
}
},
"schematics": {
"@nrwl/angular:component": {
"prefix": "ngx",
"style": "scss"
}
}
},
"plugin-maintenance-ui": {
"projectType": "library",
"root": "packages/plugins/maintenance-ui",
"sourceRoot": "packages/plugins/maintenance-ui",
"prefix": "lib",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:ng-packagr",
"options": {
"project": "packages/plugins/maintenance-ui/ng-package.json"
},
"configurations": {
"production": {
"tsConfig": "packages/plugins/maintenance-ui/tsconfig.lib.prod.json"
},
"development": {
"tsConfig": "packages/plugins/maintenance-ui/tsconfig.lib.json"
}
},
"defaultConfiguration": "production"
},
"test": {
"builder": "@nrwl/jest:jest",
"options": {
"jestConfig": "packages/plugins/maintenance-ui/jest.config.js",
"passWithNoTests": true
}
}
},
"schematics": {
"@nrwl/angular:component": {
"prefix": "ngx",
"style": "scss"
}
}
},
"plugin-onboarding-ui": {
"projectType": "library",
"root": "packages/plugins/onboarding-ui",
"sourceRoot": "packages/plugins/onboarding-ui",
"prefix": "lib",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:ng-packagr",
"options": {
"project": "packages/plugins/onboarding-ui/ng-package.json"
},
"configurations": {
"production": {
"tsConfig": "packages/plugins/onboarding-ui/tsconfig.lib.prod.json"
},
"development": {
"tsConfig": "packages/plugins/onboarding-ui/tsconfig.lib.json"
}
},
"defaultConfiguration": "production"
},
"test": {
"builder": "@angular-devkit/build-angular:karma",
"options": {
"tsConfig": "packages/plugins/onboarding-ui/tsconfig.spec.json",
"polyfills": ["zone.js", "zone.js/testing"]
}
}
},
"schematics": {
"@nrwl/angular:component": {
"prefix": "ngx",
"style": "scss"
}
}
},
"plugin-public-layout-ui": {
"projectType": "library",
"root": "packages/plugins/public-layout-ui",
"sourceRoot": "packages/plugins/public-layout-ui/src",
"prefix": "lib",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:ng-packagr",
"options": {
"project": "packages/plugins/public-layout-ui/ng-package.json"
},
"configurations": {
"production": {
"tsConfig": "packages/plugins/public-layout-ui/tsconfig.lib.prod.json"
},
"development": {
"tsConfig": "packages/plugins/public-layout-ui/tsconfig.lib.json"
}
},
"defaultConfiguration": "production"
},
"test": {
"builder": "@angular-devkit/build-angular:karma",
"options": {
"tsConfig": "packages/plugins/public-layout-ui/tsconfig.spec.json",
"polyfills": ["zone.js", "zone.js/testing"]
}
}
},
"schematics": {
"@nrwl/angular:component": {
"prefix": "gz",
"style": "scss"
}
}
},
"gauzy-e2e": {
"root": "apps/gauzy-e2e",
"sourceRoot": "apps/gauzy-e2e/src",
Expand Down
10 changes: 6 additions & 4 deletions apps/desktop-timer/src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ import {
TokenInterceptor,
UnauthorizedInterceptor,
UpdaterModule,
serverConnectionFactory
serverConnectionFactory,
NgxDesktopThemeModule
} from '@gauzy/desktop-ui-lib';
import { environment as gauzyEnvironment } from '@gauzy/ui-config';
import {
Expand Down Expand Up @@ -90,7 +91,8 @@ if (environment.SENTRY_DSN) {
BrowserModule,
BrowserAnimationsModule,
AppRoutingModule,
NbThemeModule.forRoot({ name: 'gauzy-light' }),
NbThemeModule,
NgxDesktopThemeModule,
NgxLoginModule,
SetupModule,
TimeTrackerModule,
Expand Down Expand Up @@ -196,7 +198,7 @@ if (environment.SENTRY_DSN) {
},
{
provide: APP_INITIALIZER,
useFactory: () => () => {},
useFactory: () => () => { },
deps: [Sentry.TraceService],
multi: true
},
Expand All @@ -212,4 +214,4 @@ if (environment.SENTRY_DSN) {
bootstrap: [AppComponent],
exports: []
})
export class AppModule {}
export class AppModule { }
4 changes: 4 additions & 0 deletions apps/desktop-timer/src/assets/styles/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -92,3 +92,7 @@
.toast-top-custom-title-bar {
margin-top: 35px !important;
}

::-webkit-scrollbar {
display: none;
}
38 changes: 30 additions & 8 deletions apps/desktop-timer/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ console.log = log.log;
Object.assign(console, log.functions);

import * as path from 'path';
import { app, BrowserWindow, ipcMain, shell, Menu, MenuItemConstructorOptions } from 'electron';
import { app, BrowserWindow, ipcMain, shell, Menu, MenuItemConstructorOptions, nativeTheme } from 'electron';
import { environment } from './environments/environment';
import * as Url from 'url';
import * as Sentry from '@sentry/electron';
Expand Down Expand Up @@ -44,7 +44,8 @@ import {
ErrorEventManager,
DialogErrorHandler,
AppError,
UIError
UIError,
DesktopThemeListener
} from '@gauzy/desktop-libs';
import {
createSetupWindow,
Expand Down Expand Up @@ -91,6 +92,18 @@ const report = new ErrorReport(new ErrorReportRepository(process.env.REPO_OWNER,
const eventErrorManager = ErrorEventManager.instance;
args.some((val) => val === '--serve');

ipcMain.handle('PREFERRED_THEME', () => {
const applicationSetting = LocalStore.getStore('appSetting');
let theme: string;
if (!applicationSetting || !applicationSetting.theme) {
theme = nativeTheme.shouldUseDarkColors ? 'dark' : 'light';
LocalStore.updateApplicationSetting({ theme });
} else {
theme = applicationSetting.theme;
}
return theme;
});

let notificationWindow = null;
let gauzyWindow: BrowserWindow = null;
let setupWindow: BrowserWindow = null;
Expand Down Expand Up @@ -236,12 +249,12 @@ async function startServer(value, restart = false) {
project: projectConfig
? projectConfig
: {
projectId: null,
taskId: null,
note: null,
aw,
organizationContactId: null
}
projectId: null,
taskId: null,
note: null,
aw,
organizationContactId: null
}
});
} catch (error) {
throw new AppError('MAINSTRSERVER', error);
Expand Down Expand Up @@ -425,6 +438,15 @@ app.on('ready', async () => {
}
removeMainListener();
ipcMainHandler(store, startServer, knex, { ...environment }, timeTrackerWindow);
new DesktopThemeListener({
timeTrackerWindow,
settingsWindow,
updaterWindow,
imageViewerWindow: imageView,
gauzyWindow,
splashScreenWindow: splashScreen.browserWindow,
alwaysOnWindow: alwaysOn.browserWindow
}).listen();
});

app.on('window-all-closed', () => {
Expand Down
12 changes: 7 additions & 5 deletions apps/desktop/src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ import {
TimeoutInterceptor,
TimeTrackerModule,
TokenInterceptor,
UpdaterModule
UpdaterModule,
NgxDesktopThemeModule
} from '@gauzy/desktop-ui-lib';
import { environment as gauzyEnvironment } from '@gauzy/ui-config';
import {
Expand Down Expand Up @@ -78,7 +79,8 @@ if (environment.SENTRY_DSN) {
BrowserAnimationsModule,
RouterModule,
AppRoutingModule,
NbThemeModule.forRoot({ name: 'gauzy-light' }),
NbThemeModule,
NgxDesktopThemeModule,
SetupModule,
TimeTrackerModule,
HttpClientModule,
Expand All @@ -90,7 +92,7 @@ if (environment.SENTRY_DSN) {
LanguageModule.forRoot(),
AboutModule,
AlwaysOnModule,
RecapModule
RecapModule,
],
providers: [
AppService,
Expand Down Expand Up @@ -129,7 +131,7 @@ if (environment.SENTRY_DSN) {
},
{
provide: APP_INITIALIZER,
useFactory: () => () => {},
useFactory: () => () => { },
deps: [Sentry.TraceService],
multi: true
},
Expand Down Expand Up @@ -174,5 +176,5 @@ if (environment.SENTRY_DSN) {
bootstrap: [AppComponent]
})
export class AppModule {
constructor() {}
constructor() { }
}
16 changes: 10 additions & 6 deletions apps/desktop/src/assets/styles/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,18 @@
@include angular-material();

// framework global styles
@include nb-theme-global();
@include nb-auth-global();
@include nb-theme-global();
@include nb-auth-global();

@include ngx-layout();
// loading progress bar
@include ngx-pace-theme();
// loading progress bar
@include ngx-pace-theme();

@include nb-overrides();
@include material-overrides();
@include gauzy-overrides();
@include material-overrides();
@include gauzy-overrides();
}

::-webkit-scrollbar {
display: none;
}
Loading

0 comments on commit ed39e82

Please sign in to comment.