diff --git a/version.txt b/version.txt index 1cc5f65..867e524 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -1.1.0 \ No newline at end of file +1.2.0 \ No newline at end of file diff --git a/web/src/app/app.component.html b/web/src/app/app.component.html index d0a5c7a..be4ad3a 100644 --- a/web/src/app/app.component.html +++ b/web/src/app/app.component.html @@ -1,4 +1,4 @@ -
+
diff --git a/web/src/app/app.component.ts b/web/src/app/app.component.ts index 33e0a6b..b7dc7b5 100644 --- a/web/src/app/app.component.ts +++ b/web/src/app/app.component.ts @@ -1,16 +1,17 @@ -import { Component, OnDestroy } from "@angular/core"; -import { SidebarService } from "src/app/service/sidebar.service"; -import { Subject } from "rxjs"; -import { takeUntil } from "rxjs/operators"; -import { AuthService } from "src/app/service/auth.service"; -import { GuiService } from "src/app/service/gui.service"; +import { Component, OnDestroy } from '@angular/core'; +import { SidebarService } from 'src/app/service/sidebar.service'; +import { Subject } from 'rxjs'; +import { takeUntil } from 'rxjs/operators'; +import { AuthService } from 'src/app/service/auth.service'; +import { GuiService } from 'src/app/service/gui.service'; @Component({ - selector: "app-root", - templateUrl: "./app.component.html", - styleUrl: "./app.component.scss", + selector: 'app-root', + templateUrl: './app.component.html', + styleUrl: './app.component.scss', }) export class AppComponent implements OnDestroy { + theme = 'open-redirect'; showSidebar = false; hideUI = false; isLoggedIn = false; @@ -19,23 +20,27 @@ export class AppComponent implements OnDestroy { constructor( private sidebar: SidebarService, private auth: AuthService, - private gui: GuiService, + private gui: GuiService ) { this.auth.loadUser(); - this.auth.user$.pipe(takeUntil(this.unsubscribe$)).subscribe((user) => { + this.auth.user$.pipe(takeUntil(this.unsubscribe$)).subscribe(user => { this.isLoggedIn = user !== null && user !== undefined; }); this.sidebar.visible$ .pipe(takeUntil(this.unsubscribe$)) - .subscribe((visible) => { + .subscribe(visible => { this.showSidebar = visible; }); - this.gui.hideGui$.pipe(takeUntil(this.unsubscribe$)).subscribe((hide) => { + this.gui.hideGui$.pipe(takeUntil(this.unsubscribe$)).subscribe(hide => { this.hideUI = hide; }); + + this.gui.theme$.pipe(takeUntil(this.unsubscribe$)).subscribe(theme => { + this.theme = theme; + }); } ngOnDestroy() { diff --git a/web/src/app/components/header/header.component.html b/web/src/app/components/header/header.component.html index d5fed22..aad6f93 100644 --- a/web/src/app/components/header/header.component.html +++ b/web/src/app/components/header/header.component.html @@ -17,6 +17,18 @@
+
+ + +
(); @@ -29,22 +32,30 @@ export class HeaderComponent implements OnInit, OnDestroy { private guiService: GuiService, private auth: AuthService, private sidebarService: SidebarService, + private settings: SettingsService ) { this.guiService.isMobile$ .pipe(takeUntil(this.unsubscribe$)) - .subscribe((isMobile) => { + .subscribe(isMobile => { this.isMobile = isMobile; if (isMobile) { this.sidebarService.hide(); } }); - this.auth.user$ - .pipe(takeUntil(this.unsubscribe$)) - .subscribe(async (user) => { - this.user = user; - await this.initMenuLists(); - }); + this.auth.user$.pipe(takeUntil(this.unsubscribe$)).subscribe(async user => { + this.user = user; + await this.initMenuLists(); + }); + + this.themeList = this.settings.settings.themes.map(theme => { + return { + label: theme.label, + command: () => { + this.guiService.theme$.next(theme.name); + }, + }; + }); } async ngOnInit() { @@ -69,17 +80,17 @@ export class HeaderComponent implements OnInit, OnDestroy { async initLangMenuList() { this.langList = [ { - label: "English", + label: 'English', command: () => { - this.translate("en"); - this.setLang("en"); + this.translate('en'); + this.setLang('en'); }, }, { - label: "Deutsch", + label: 'Deutsch', command: () => { - this.translate("de"); - this.setLang("de"); + this.translate('de'); + this.setLang('de'); }, }, ]; @@ -96,13 +107,13 @@ export class HeaderComponent implements OnInit, OnDestroy { separator: true, }, { - label: this.translateService.instant("header.logout"), + label: this.translateService.instant('header.logout'), command: () => { this.auth.logout().then(() => { - console.log("logout"); + console.log('logout'); }); }, - icon: "pi pi-sign-out", + icon: 'pi pi-sign-out', }, ]; } @@ -110,19 +121,19 @@ export class HeaderComponent implements OnInit, OnDestroy { translate(lang: string) { this.translateService.use(lang); this.translateService - .get("primeng") - .subscribe((res) => this.config.setTranslation(res)); + .get('primeng') + .subscribe(res => this.config.setTranslation(res)); } async loadLang() { - const lang = "en"; + const lang = 'en'; this.setLang(lang); this.translate(lang); } setLang(lang: string) { // this.settings.setSetting(`lang`, lang); - console.log("setLang", lang); + console.log('setLang', lang); } toggleSidebar() { diff --git a/web/src/app/service/gui.service.ts b/web/src/app/service/gui.service.ts index 565f058..bc67b06 100644 --- a/web/src/app/service/gui.service.ts +++ b/web/src/app/service/gui.service.ts @@ -3,6 +3,7 @@ import { BehaviorSubject, filter } from 'rxjs'; import { Logger } from 'src/app/service/logger.service'; import { NavigationEnd, Router } from '@angular/router'; import { SidebarService } from 'src/app/service/sidebar.service'; +import { SettingsService } from 'src/app/service/settings.service'; const logger = new Logger('GuiService'); @@ -14,10 +15,14 @@ export class GuiService { isTablet$ = new BehaviorSubject(this.isTabletByWindowWith()); hideGui$ = new BehaviorSubject(false); + theme$ = new BehaviorSubject( + this.settingsService.settings.themes[0].name + ); constructor( private router: Router, - private sidebarService: SidebarService + private sidebarService: SidebarService, + private settingsService: SettingsService ) { this.router.events .pipe(filter(event => event instanceof NavigationEnd)) diff --git a/web/src/app/service/settings.service.ts b/web/src/app/service/settings.service.ts index de948e3..f921396 100644 --- a/web/src/app/service/settings.service.ts +++ b/web/src/app/service/settings.service.ts @@ -1,12 +1,12 @@ -import { HttpClient } from "@angular/common/http"; -import { Injectable } from "@angular/core"; -import { throwError } from "rxjs"; -import { catchError } from "rxjs/operators"; -import { AppSettings } from "src/app/model/config/app-settings"; -import { environment } from "src/environments/environment"; +import { HttpClient } from '@angular/common/http'; +import { Injectable } from '@angular/core'; +import { throwError } from 'rxjs'; +import { catchError } from 'rxjs/operators'; +import { AppSettings } from 'src/app/model/config/app-settings'; +import { environment } from 'src/environments/environment'; @Injectable({ - providedIn: "root", + providedIn: 'root', }) export class SettingsService { settings!: AppSettings; @@ -18,13 +18,19 @@ export class SettingsService { this.http .get(`/assets/config/${environment.config}`) .pipe( - catchError((error) => { + catchError(error => { reject(error); return throwError(() => error); - }), + }) ) - .subscribe((settings) => { + .subscribe(settings => { this.settings = settings; + if (this.settings.themes.length === 0) { + this.settings.themes.push({ + label: 'Open-redirect', + name: 'open-redirect', + }); + } resolve(); }); }); diff --git a/web/src/assets/config/config.json b/web/src/assets/config/config.json index e605683..fef294d 100644 --- a/web/src/assets/config/config.json +++ b/web/src/assets/config/config.json @@ -5,7 +5,11 @@ "themes": [ { "label": "Open-redirect", - "name": "Open-redirect" + "name": "open-redirect" + }, + { + "label": "Maxlan", + "name": "maxlan" } ], "api": { diff --git a/web/src/styles.scss b/web/src/styles.scss index c823e30..ce42dc9 100644 --- a/web/src/styles.scss +++ b/web/src/styles.scss @@ -10,6 +10,7 @@ @import 'tailwindcss/utilities'; @import 'styles/theme'; +@import 'styles/theme_maxlan'; @import 'styles/tablet'; @import 'styles/mobile'; @@ -58,7 +59,6 @@ body { input, .p-checkbox-box, .p-dropdown { - border: 1px solid $accentColor; padding: 10px; } @@ -70,16 +70,6 @@ body { } } -@layer utilities { - .divider { - border-bottom: 1px solid $accentColor; - } - - .v-divider { - border-left: 1px solid $accentColor; - } -} - header { height: $headerHeight; display: flex; @@ -129,7 +119,6 @@ main { .component { margin: 0 10px; overflow: auto; - background-color: $backgroundColor; flex: 1; padding: 10px; } @@ -141,7 +130,6 @@ footer { display: flex; justify-content: center; align-items: center; - color: $textColor; } .btn { diff --git a/web/src/styles/theme.scss b/web/src/styles/theme.scss index 1ccb21d..6c9f760 100644 --- a/web/src/styles/theme.scss +++ b/web/src/styles/theme.scss @@ -1,406 +1,407 @@ -$headerColor: #a2271f; +.open-redirect { + $headerColor: #ef9d0d; -// generated with https://colorffy.com/dark-theme-generator?colors=314390-121212 -$textColor: #fff; -$textColorHighlight: #314390; -$textColorHighlight2: #a2271f; + // generated with https://colorffy.com/dark-theme-generator?colors=314390-121212 + $textColor: #fff; + $textColorHighlight: #ef9d0d; + $textColorHighlight2: #b76f00; -// https://tailwindcss.com/docs/customizing-colors -$backgroundColor: #1e293b; // slate-800 -$backgroundColor2: #0f172a; // slate-900 -$backgroundColor3: #334155; // slate-700 + // https://tailwindcss.com/docs/customizing-colors + $backgroundColor: #1e293b; // slate-800 + $backgroundColor2: #0f172a; // slate-900 + $backgroundColor3: #334155; // slate-700 -$accentColor: #475569; // slate-600 -$infoColor: #1ea97c; -$warningColor: #ffc107; -$errorColor: #ff5252; + $accentColor: #475569; // slate-600 + $infoColor: #1ea97c; + $warningColor: #ffc107; + $errorColor: #ff5252; -body { background-color: $backgroundColor2; -} -@layer utilities { - .highlight { - color: $textColorHighlight; - } - .highlight2 { - color: $textColorHighlight2 !important; - } - - .bg { - background-color: $backgroundColor; - } - - .bg2 { - background-color: $backgroundColor2; - } - - .bg3 { - background-color: $backgroundColor3; - } - - .accent { - color: $accentColor; - } - - .info { - color: $infoColor; - } - - .warning { - color: $warningColor; - } - - .error { - color: $errorColor; - } - - .deleted { - color: $accentColor !important; - } -} - -h1, -h2, -h3 { - color: $headerColor; -} - -.app { - .component { - background-color: $backgroundColor; - } -} - -.btn-base { - color: $textColor; - background: $textColorHighlight !important; - border: 1px solid $textColorHighlight; - - &:focus { - box-shadow: none !important; - } - - &:hover { - background: transparent !important; - } -} - -.btn { - .p-button { - @extend .btn-base; - } -} - -.icon-btn { - background-color: transparent !important; - border: none; - - .p-button { - color: $textColor; - background: transparent !important; - padding: 0; - - &:hover { + @layer utilities { + .highlight { color: $textColorHighlight; } - } -} -.text-btn { - background-color: transparent !important; - - .p-button { - color: $textColor; - background: transparent !important; - border: none !important; - - &:hover { - color: $textColorHighlight; - background-color: transparent !important; + .highlight2 { + color: $textColorHighlight2 !important; } - } -} -.icon-btn-without-hover { - &:hover { - background-color: transparent !important; - } -} - -.icon-btn { - &:hover { - background-color: transparent !important; - } -} - -.danger-btn, -.danger-icon-btn { - background-color: transparent !important; - - .p-button { - color: $textColor; - background: transparent !important; - - &:hover { - color: $errorColor; - } - } -} - -.hidden-columns-select { - .active-while-panel-open { - .p-button { - color: $textColorHighlight; - } - } -} - -.custom-spinner { - .p-progress-spinner-circle { - stroke: $textColorHighlight !important; - } -} - -p-paginator { - .p-paginator-element { - &:hover { - color: $textColorHighlight; - } - } -} - -.p-highlight { - color: $textColorHighlight2; - box-shadow: none !important; - - &:hover { - color: $textColorHighlight2 !important; - } -} - -.p-multiselect, -.p-paginator, -.p-dropdown, -input { - background-color: $backgroundColor; -} - -.p-inputtext:enabled:focus, -.p-inputtext:enabled:hover, -.p-multiselect:not(.p-disabled):hover, -.p-multiselect:not(.p-disabled).p-focus, -.p-dropdown:not(.p-disabled):hover, -.p-checkbox:not(.p-checkbox-disabled) .p-checkbox-box:hover, -.p-checkbox:not(.p-checkbox-disabled) .p-checkbox-box.p-focus { - border-color: $textColorHighlight; - box-shadow: none !important; -} - -.p-checkbox .p-checkbox-box.p-highlight { - border-color: $textColorHighlight; - background: $textColorHighlight; - box-shadow: none !important; -} - -p-checkbox { - .p-checkbox { - .p-checkbox-box { + .bg { background-color: $backgroundColor; } - .p-checkbox-box.p-highlight { - border-color: $textColorHighlight; - background-color: $textColorHighlight; + .bg2 { + background-color: $backgroundColor2; + } + + .bg3 { + background-color: $backgroundColor3; + } + + .accent { + color: $accentColor; + } + + .info { + color: $infoColor; + } + + .warning { + color: $warningColor; + } + + .error { + color: $errorColor; + } + + .deleted { + color: $accentColor !important; } } -} -p-inputSwitch { - .p-inputswitch { - &.p-focus .p-inputswitch-slider { + h1, + h2, + h3 { + color: $headerColor; + } + + .app { + .component { + background-color: $backgroundColor; + } + } + + .btn-base { + color: $textColor; + background: $textColorHighlight !important; + border: 1px solid $textColorHighlight; + + &:focus { box-shadow: none !important; } - .p-inputswitch-slider { - background-color: $headerColor; + &:hover { + background: transparent !important; + } + } - &.p-highlight { - border-color: $textColorHighlight; - background: $textColorHighlight; - box-shadow: none !important; + .btn { + .p-button { + @extend .btn-base; + } + } + + .icon-btn { + background-color: transparent !important; + border: none; + + .p-button { + color: $textColor; + background: transparent !important; + padding: 0; + + &:hover { + color: $textColorHighlight; } } + } + + .text-btn { + background-color: transparent !important; + + .p-button { + color: $textColor; + background: transparent !important; + border: none !important; + + &:hover { + color: $textColorHighlight; + background-color: transparent !important; + } + } + } + + .icon-btn-without-hover { + &:hover { + background-color: transparent !important; + } + } + + .icon-btn { + &:hover { + background-color: transparent !important; + } + } + + .danger-btn, + .danger-icon-btn { + background-color: transparent !important; + + .p-button { + color: $textColor; + background: transparent !important; + + &:hover { + color: $errorColor; + } + } + } + + .hidden-columns-select { + .active-while-panel-open { + .p-button { + color: $textColorHighlight; + } + } + } + + .custom-spinner { + .p-progress-spinner-circle { + stroke: $textColorHighlight !important; + } + } + + p-paginator { + .p-paginator-element { + &:hover { + color: $textColorHighlight; + } + } + } + + .p-highlight { + color: $textColorHighlight2; + box-shadow: none !important; + + &:hover { + color: $textColorHighlight2 !important; + } + } + + .p-multiselect, + .p-paginator, + .p-dropdown, + input { + background-color: $backgroundColor; + } + + .p-inputtext:enabled:focus, + .p-inputtext:enabled:hover, + .p-multiselect:not(.p-disabled):hover, + .p-multiselect:not(.p-disabled).p-focus, + .p-dropdown:not(.p-disabled):hover, + .p-checkbox:not(.p-checkbox-disabled) .p-checkbox-box:hover, + .p-checkbox:not(.p-checkbox-disabled) .p-checkbox-box.p-focus { + border-color: $textColorHighlight; + box-shadow: none !important; + } + + .p-checkbox .p-checkbox-box.p-highlight { + border-color: $textColorHighlight; + background: $textColorHighlight; + box-shadow: none !important; + } + + p-checkbox { + .p-checkbox { + .p-checkbox-box { + background-color: $backgroundColor; + } + + .p-checkbox-box.p-highlight { + border-color: $textColorHighlight; + background-color: $textColorHighlight; + } + } + } + + p-inputSwitch { + .p-inputswitch { + &.p-focus .p-inputswitch-slider { + box-shadow: none !important; + } - &.p-inputswitch-checked { .p-inputswitch-slider { background-color: $headerColor; - &:before { - background-color: $textColor; + &.p-highlight { + border-color: $textColorHighlight; + background: $textColorHighlight; + box-shadow: none !important; + } + } + + &.p-inputswitch-checked { + .p-inputswitch-slider { + background-color: $headerColor; + + &:before { + background-color: $textColor; + } } } } } -} -p-panel-menu { - .p-panelmenu { - .p-panelmenu-content + p-panel-menu { + .p-panelmenu { + .p-panelmenu-content .p-menuitem:not(.p-highlight):not(.p-disabled) > .p-menuitem-content:hover .p-menuitem-link .p-menuitem-text, - .p-panelmenu-content + .p-panelmenu-content .p-menuitem:not(.p-highlight):not(.p-disabled) > .p-menuitem-content:hover .p-menuitem-link .p-menuitem-icon, - .p-panelmenu + .p-panelmenu .p-panelmenu-content .p-menuitem:not(.p-highlight):not(.p-disabled) > .p-menuitem-content:hover .p-menuitem-link .p-submenu-icon { - color: $textColorHighlight; - } + color: $textColorHighlight; + } - .p-panelmenu-header-content { - &:hover { - .p-panelmenu-header-action { - color: $textColorHighlight; + .p-panelmenu-header-content { + &:hover { + .p-panelmenu-header-action { + color: $textColorHighlight; + } } } } } -} -p-menubar { - .p-menubar { - background-color: $backgroundColor2; - } + p-menubar { + .p-menubar { + background-color: $backgroundColor2; + } - .p-menubar-root-list { - display: flex; - gap: 10px; - } + .p-menubar-root-list { + display: flex; + gap: 10px; + } - .p-menuitem { - border-radius: 0.5rem; + .p-menuitem { + border-radius: 0.5rem; - &:hover { - .p-menuitem-content .p-menuitem-link .p-menuitem-text { - color: $textColorHighlight2; + &:hover { + .p-menuitem-content .p-menuitem-link .p-menuitem-text { + color: $textColorHighlight2; + } + } + } + + .p-focus { + background-color: $backgroundColor2; + + .p-menuitem-content { + background-color: $backgroundColor2; } } } - .p-focus { - background-color: $backgroundColor2; + p-dropdown { + .p-dropdown:not(.p-disabled).p-focus { + box-shadow: none !important; + border-color: $headerColor !important; + } - .p-menuitem-content { + .p-dropdown-panel { background-color: $backgroundColor2; } } -} -p-dropdown { - .p-dropdown:not(.p-disabled).p-focus { - box-shadow: none !important; - border-color: $headerColor !important; + p-multiselect { + .p-multiselect-panel, + .p-multiselect-panel .p-multiselect-header { + background-color: $backgroundColor2; + } } - .p-dropdown-panel { - background-color: $backgroundColor2; - } -} + p-table { + .p-datatable { + .p-datatable-header, + .p-datatable-footer, + .p-datatable-thead > tr > th, + .p-datatable-tbody > tr { + background-color: $backgroundColor; + border-bottom: 1px solid $accentColor; + } -p-multiselect { - .p-multiselect-panel, - .p-multiselect-panel .p-multiselect-header { - background-color: $backgroundColor2; - } -} + .p-sortable-column.p-highlight, + .p-sortable-column:not(.p-highlight):hover { + background-color: transparent !important; + } -p-table { - .p-datatable { - .p-datatable-header, - .p-datatable-footer, - .p-datatable-thead > tr > th, - .p-datatable-tbody > tr { + .p-sortable-column:not(.p-highlight):hover, + .p-sortable-column:not(.p-highlight):hover .p-sortable-column-icon { + color: $textColorHighlight; + } + } + } + + p-sidebar { + .p-sidebar { background-color: $backgroundColor; - border-bottom: 1px solid $accentColor; - } - - .p-sortable-column.p-highlight, - .p-sortable-column:not(.p-highlight):hover { - background-color: transparent !important; - } - - .p-sortable-column:not(.p-highlight):hover, - .p-sortable-column:not(.p-highlight):hover .p-sortable-column-icon { - color: $textColorHighlight; } } -} -p-sidebar { - .p-sidebar { - background-color: $backgroundColor; - } -} - -.p-steps .p-steps-item.p-highlight .p-steps-number { - background-color: $headerColor; - color: $textColor; -} - -.p-dialog { - .p-dialog-header { - background-color: $backgroundColor; + .p-steps .p-steps-item.p-highlight .p-steps-number { + background-color: $headerColor; + color: $textColor; } - .p-dialog-content { - background-color: $backgroundColor; - padding-top: 1rem; + .p-dialog { + .p-dialog-header { + background-color: $backgroundColor; + } + + .p-dialog-content { + background-color: $backgroundColor; + padding-top: 1rem; + } + + .p-dialog-footer { + background-color: $backgroundColor; + } } - .p-dialog-footer { - background-color: $backgroundColor; + .p-badge { + background: $headerColor; + color: $textColor; } -} -.p-badge { - background: $headerColor; - color: $textColor; -} - -p-password { - background-color: transparent; - border: none; - - .p-password-panel { + p-password { background-color: transparent; - } -} + border: none; -p-slider { - .p-slider { - .p-slider-range { - background: $headerColor; + .p-password-panel { + background-color: transparent; } + } - .p-slider-handle { - border-color: $headerColor; - - &:hover { + p-slider { + .p-slider { + .p-slider-range { background: $headerColor; } - &:focus { - box-shadow: none !important; + .p-slider-handle { + border-color: $headerColor; + + &:hover { + background: $headerColor; + } + + &:focus { + box-shadow: none !important; + } } } } -} +} \ No newline at end of file diff --git a/web/src/styles/theme_maxlan.scss b/web/src/styles/theme_maxlan.scss new file mode 100644 index 0000000..f1ee3cb --- /dev/null +++ b/web/src/styles/theme_maxlan.scss @@ -0,0 +1,407 @@ +.maxlan { + $headerColor: #a2271f; + + // generated with https://colorffy.com/dark-theme-generator?colors=314390-121212 + $textColor: #fff; + $textColorHighlight: #314390; + $textColorHighlight2: #a2271f; + + // https://tailwindcss.com/docs/customizing-colors + $backgroundColor: #1e293b; // slate-800 + $backgroundColor2: #0f172a; // slate-900 + $backgroundColor3: #334155; // slate-700 + + $accentColor: #475569; // slate-600 + $infoColor: #1ea97c; + $warningColor: #ffc107; + $errorColor: #ff5252; + + background-color: $backgroundColor2; + + + @layer utilities { + .highlight { + color: $textColorHighlight; + } + + .highlight2 { + color: $textColorHighlight2 !important; + } + + .bg { + background-color: $backgroundColor; + } + + .bg2 { + background-color: $backgroundColor2; + } + + .bg3 { + background-color: $backgroundColor3; + } + + .accent { + color: $accentColor; + } + + .info { + color: $infoColor; + } + + .warning { + color: $warningColor; + } + + .error { + color: $errorColor; + } + + .deleted { + color: $accentColor !important; + } + } + + h1, + h2, + h3 { + color: $headerColor; + } + + .app { + .component { + background-color: $backgroundColor; + } + } + + .btn-base { + color: $textColor; + background: $textColorHighlight !important; + border: 1px solid $textColorHighlight; + + &:focus { + box-shadow: none !important; + } + + &:hover { + background: transparent !important; + } + } + + .btn { + .p-button { + @extend .btn-base; + } + } + + .icon-btn { + background-color: transparent !important; + border: none; + + .p-button { + color: $textColor; + background: transparent !important; + padding: 0; + + &:hover { + color: $textColorHighlight; + } + } + } + + .text-btn { + background-color: transparent !important; + + .p-button { + color: $textColor; + background: transparent !important; + border: none !important; + + &:hover { + color: $textColorHighlight; + background-color: transparent !important; + } + } + } + + .icon-btn-without-hover { + &:hover { + background-color: transparent !important; + } + } + + .icon-btn { + &:hover { + background-color: transparent !important; + } + } + + .danger-btn, + .danger-icon-btn { + background-color: transparent !important; + + .p-button { + color: $textColor; + background: transparent !important; + + &:hover { + color: $errorColor; + } + } + } + + .hidden-columns-select { + .active-while-panel-open { + .p-button { + color: $textColorHighlight; + } + } + } + + .custom-spinner { + .p-progress-spinner-circle { + stroke: $textColorHighlight !important; + } + } + + p-paginator { + .p-paginator-element { + &:hover { + color: $textColorHighlight; + } + } + } + + .p-highlight { + color: $textColorHighlight2; + box-shadow: none !important; + + &:hover { + color: $textColorHighlight2 !important; + } + } + + .p-multiselect, + .p-paginator, + .p-dropdown, + input { + background-color: $backgroundColor; + } + + .p-inputtext:enabled:focus, + .p-inputtext:enabled:hover, + .p-multiselect:not(.p-disabled):hover, + .p-multiselect:not(.p-disabled).p-focus, + .p-dropdown:not(.p-disabled):hover, + .p-checkbox:not(.p-checkbox-disabled) .p-checkbox-box:hover, + .p-checkbox:not(.p-checkbox-disabled) .p-checkbox-box.p-focus { + border-color: $textColorHighlight; + box-shadow: none !important; + } + + .p-checkbox .p-checkbox-box.p-highlight { + border-color: $textColorHighlight; + background: $textColorHighlight; + box-shadow: none !important; + } + + p-checkbox { + .p-checkbox { + .p-checkbox-box { + background-color: $backgroundColor; + } + + .p-checkbox-box.p-highlight { + border-color: $textColorHighlight; + background-color: $textColorHighlight; + } + } + } + + p-inputSwitch { + .p-inputswitch { + &.p-focus .p-inputswitch-slider { + box-shadow: none !important; + } + + .p-inputswitch-slider { + background-color: $headerColor; + + &.p-highlight { + border-color: $textColorHighlight; + background: $textColorHighlight; + box-shadow: none !important; + } + } + + &.p-inputswitch-checked { + .p-inputswitch-slider { + background-color: $headerColor; + + &:before { + background-color: $textColor; + } + } + } + } + } + + p-panel-menu { + .p-panelmenu { + .p-panelmenu-content + .p-menuitem:not(.p-highlight):not(.p-disabled) + > .p-menuitem-content:hover + .p-menuitem-link + .p-menuitem-text, + .p-panelmenu-content + .p-menuitem:not(.p-highlight):not(.p-disabled) + > .p-menuitem-content:hover + .p-menuitem-link + .p-menuitem-icon, + .p-panelmenu + .p-panelmenu-content + .p-menuitem:not(.p-highlight):not(.p-disabled) + > .p-menuitem-content:hover + .p-menuitem-link + .p-submenu-icon { + color: $textColorHighlight; + } + + .p-panelmenu-header-content { + &:hover { + .p-panelmenu-header-action { + color: $textColorHighlight; + } + } + } + } + } + + p-menubar { + .p-menubar { + background-color: $backgroundColor2; + } + + .p-menubar-root-list { + display: flex; + gap: 10px; + } + + .p-menuitem { + border-radius: 0.5rem; + + &:hover { + .p-menuitem-content .p-menuitem-link .p-menuitem-text { + color: $textColorHighlight2; + } + } + } + + .p-focus { + background-color: $backgroundColor2; + + .p-menuitem-content { + background-color: $backgroundColor2; + } + } + } + + p-dropdown { + .p-dropdown:not(.p-disabled).p-focus { + box-shadow: none !important; + border-color: $headerColor !important; + } + + .p-dropdown-panel { + background-color: $backgroundColor2; + } + } + + p-multiselect { + .p-multiselect-panel, + .p-multiselect-panel .p-multiselect-header { + background-color: $backgroundColor2; + } + } + + p-table { + .p-datatable { + .p-datatable-header, + .p-datatable-footer, + .p-datatable-thead > tr > th, + .p-datatable-tbody > tr { + background-color: $backgroundColor; + border-bottom: 1px solid $accentColor; + } + + .p-sortable-column.p-highlight, + .p-sortable-column:not(.p-highlight):hover { + background-color: transparent !important; + } + + .p-sortable-column:not(.p-highlight):hover, + .p-sortable-column:not(.p-highlight):hover .p-sortable-column-icon { + color: $textColorHighlight; + } + } + } + + p-sidebar { + .p-sidebar { + background-color: $backgroundColor; + } + } + + .p-steps .p-steps-item.p-highlight .p-steps-number { + background-color: $headerColor; + color: $textColor; + } + + .p-dialog { + .p-dialog-header { + background-color: $backgroundColor; + } + + .p-dialog-content { + background-color: $backgroundColor; + padding-top: 1rem; + } + + .p-dialog-footer { + background-color: $backgroundColor; + } + } + + .p-badge { + background: $headerColor; + color: $textColor; + } + + p-password { + background-color: transparent; + border: none; + + .p-password-panel { + background-color: transparent; + } + } + + p-slider { + .p-slider { + .p-slider-range { + background: $headerColor; + } + + .p-slider-handle { + border-color: $headerColor; + + &:hover { + background: $headerColor; + } + + &:focus { + box-shadow: none !important; + } + } + } + } +} \ No newline at end of file