Compare commits
	
		
			3 Commits
		
	
	
		
			12f231aa41
			...
			f41dfc9be2
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| f41dfc9be2 | |||
| 74437fdc20 | |||
| df2b660b75 | 
| @@ -1,6 +1,6 @@ | |||||||
| { | { | ||||||
|     "name": "kdb-web", |     "name": "kdb-web", | ||||||
|     "version": "1.1.0.rc5", |     "version": "1.1.0.rc6", | ||||||
|     "scripts": { |     "scripts": { | ||||||
|         "ng": "ng", |         "ng": "ng", | ||||||
|         "update-version": "ts-node-esm update-version.ts", |         "update-version": "ts-node-esm update-version.ts", | ||||||
|   | |||||||
| @@ -5,7 +5,7 @@ | |||||||
|  |  | ||||||
|     <section class="app"> |     <section class="app"> | ||||||
|       <div> |       <div> | ||||||
|         <section class="sidebar" [style.width]="sidebarWidth"> |         <section [ngClass]="{'sidebar-open': isSidebarOpen, 'sidebar-closed': !isSidebarOpen}"> | ||||||
|           <app-sidebar></app-sidebar> |           <app-sidebar></app-sidebar> | ||||||
|         </section> |         </section> | ||||||
|       </div> |       </div> | ||||||
|   | |||||||
| @@ -16,7 +16,7 @@ import { takeUntil } from "rxjs/operators"; | |||||||
| export class AppComponent implements OnInit, OnDestroy { | export class AppComponent implements OnInit, OnDestroy { | ||||||
|  |  | ||||||
|   themeName: string = Themes.Default; |   themeName: string = Themes.Default; | ||||||
|   sidebarWidth: string = '175px'; |   isSidebarOpen: boolean = true; | ||||||
|  |  | ||||||
|   isLoggedIn: boolean = false; |   isLoggedIn: boolean = false; | ||||||
|  |  | ||||||
| @@ -29,10 +29,10 @@ export class AppComponent implements OnInit, OnDestroy { | |||||||
|     private translateService: TranslateService, |     private translateService: TranslateService, | ||||||
|     private config: PrimeNGConfig, |     private config: PrimeNGConfig, | ||||||
|   ) { |   ) { | ||||||
|     this.themeService.sidebarWidth$.pipe( |     this.themeService.isSidebarOpen$.pipe( | ||||||
|       takeUntil(this.unsubscriber) |       takeUntil(this.unsubscriber) | ||||||
|     ).subscribe(value => { |     ).subscribe(value => { | ||||||
|       this.sidebarWidth = value; |       this.isSidebarOpen = value; | ||||||
|     }); |     }); | ||||||
|     this.themeService.themeName$.pipe( |     this.themeService.themeName$.pipe( | ||||||
|       takeUntil(this.unsubscriber) |       takeUntil(this.unsubscriber) | ||||||
|   | |||||||
| @@ -1,5 +1,5 @@ | |||||||
| <div class="client"> | <div class="client"> | ||||||
|   <div class="client-info"> |   <div class="client-info client-info-small"> | ||||||
|     <label class="client-info-header">{{'common.id' | translate}}</label> |     <label class="client-info-header">{{'common.id' | translate}}</label> | ||||||
|     <label class="client-info-value">{{client.id}}</label> |     <label class="client-info-value">{{client.id}}</label> | ||||||
|   </div> |   </div> | ||||||
|   | |||||||
| @@ -30,7 +30,6 @@ | |||||||
|  |  | ||||||
|             <div class="client-data" |             <div class="client-data" | ||||||
|                  *ngFor="let client of server.clients"> |                  *ngFor="let client of server.clients"> | ||||||
|               <i class="pi pi-discord"></i> |  | ||||||
|               <app-client class="client-component" [client]="client"></app-client> |               <app-client class="client-component" [client]="client"></app-client> | ||||||
|             </div> |             </div> | ||||||
|           </div> |           </div> | ||||||
|   | |||||||
| @@ -69,7 +69,7 @@ export class SidebarService { | |||||||
|  |  | ||||||
|   async buildMenu(user: UserDTO | null, hasPermission: boolean, isTechnician: boolean = false) { |   async buildMenu(user: UserDTO | null, hasPermission: boolean, isTechnician: boolean = false) { | ||||||
|     this.dashboard = { |     this.dashboard = { | ||||||
|       label: this.isSidebarOpen ? this.translateService.instant("sidebar.dashboard") : "", |       label: this.translateService.instant("sidebar.dashboard"), | ||||||
|       icon: "pi pi-th-large", |       icon: "pi pi-th-large", | ||||||
|       routerLink: "dashboard" |       routerLink: "dashboard" | ||||||
|     }; |     }; | ||||||
|   | |||||||
| @@ -9,13 +9,10 @@ import { AuthService } from "../auth/auth.service"; | |||||||
| export class ThemeService { | export class ThemeService { | ||||||
|  |  | ||||||
|   themeName: string = Themes.Default; |   themeName: string = Themes.Default; | ||||||
|  |  | ||||||
|   sidebarWidth = "150px"; |  | ||||||
|   isSidebarOpen = false; |   isSidebarOpen = false; | ||||||
|  |  | ||||||
|   themeName$ = new BehaviorSubject<string>(Themes.Default); |   themeName$ = new BehaviorSubject<string>(Themes.Default); | ||||||
|   isSidebarOpen$ = new BehaviorSubject<boolean>(true); |   isSidebarOpen$ = new BehaviorSubject<boolean>(true); | ||||||
|   sidebarWidth$ = new BehaviorSubject<string>("175px"); |  | ||||||
|  |  | ||||||
|   constructor( |   constructor( | ||||||
|     private authService: AuthService |     private authService: AuthService | ||||||
| @@ -25,10 +22,6 @@ export class ThemeService { | |||||||
|     }); |     }); | ||||||
|     this.isSidebarOpen$.subscribe(isSidebarOpen => { |     this.isSidebarOpen$.subscribe(isSidebarOpen => { | ||||||
|       this.isSidebarOpen = isSidebarOpen; |       this.isSidebarOpen = isSidebarOpen; | ||||||
|       this.sidebarWidth$.next(isSidebarOpen ? "175px" : "75px"); |  | ||||||
|     }); |  | ||||||
|     this.sidebarWidth$.subscribe(sidebarWidth => { |  | ||||||
|       this.sidebarWidth = sidebarWidth; |  | ||||||
|     }); |     }); | ||||||
|  |  | ||||||
|     this.loadTheme(); |     this.loadTheme(); | ||||||
|   | |||||||
| @@ -2,6 +2,6 @@ | |||||||
|     "WebVersion": { |     "WebVersion": { | ||||||
|         "Major": "1", |         "Major": "1", | ||||||
|         "Minor": "1", |         "Minor": "1", | ||||||
|         "Micro": "0.rc5" |         "Micro": "0.rc6" | ||||||
|     } |     } | ||||||
| } | } | ||||||
| @@ -115,8 +115,14 @@ header { | |||||||
|   display: flex; |   display: flex; | ||||||
|   flex: 1; |   flex: 1; | ||||||
|  |  | ||||||
|   .sidebar { |   .sidebar-open { | ||||||
|     height: 100%; |     height: 100%; | ||||||
|  |     width: 175px; | ||||||
|  |   } | ||||||
|  |  | ||||||
|  |   .sidebar-closed { | ||||||
|  |     height: 100%; | ||||||
|  |     width: 75px; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   h1 { |   h1 { | ||||||
| @@ -372,19 +378,23 @@ header { | |||||||
|                         flex-wrap: wrap; |                         flex-wrap: wrap; | ||||||
|                         gap: 10px; |                         gap: 10px; | ||||||
|  |  | ||||||
|  |                         .client-info-small { | ||||||
|  |                           flex: 0.25 !important; | ||||||
|  |                         } | ||||||
|  |  | ||||||
|                         .client-info { |                         .client-info { | ||||||
|                           display: flex; |                           display: flex; | ||||||
|                           flex-direction: column; |                           flex-direction: column; | ||||||
|                           margin-left: 2%; |                           flex: 1; | ||||||
|  |  | ||||||
|                           .client-info-header { |                           .client-info-header { | ||||||
|                             margin-bottom: 5px; |                             margin-bottom: 5px; | ||||||
|                             white-space: nowrap; |                             white-space: break-spaces; | ||||||
|                             font-weight: bold |                             font-weight: bold | ||||||
|                           } |                           } | ||||||
|  |  | ||||||
|                           .client-info-value { |                           .client-info-value { | ||||||
|                             white-space: nowrap; |                             word-break: break-word; | ||||||
|                           } |                           } | ||||||
|                         } |                         } | ||||||
|                       } |                       } | ||||||
| @@ -654,11 +664,31 @@ p-inputNumber { | |||||||
|       } |       } | ||||||
|     } |     } | ||||||
|   } |   } | ||||||
|  |  | ||||||
|  |  | ||||||
|  |   .p-panelmenu { | ||||||
|  |     .p-menuitem-text { | ||||||
|  |       display: none; | ||||||
|  |     } | ||||||
|  |   } | ||||||
|  |  | ||||||
|   .app { |   .app { | ||||||
|  |     .sidebar-open { | ||||||
|  |       width: 65px; | ||||||
|  |     } | ||||||
|  |  | ||||||
|  |     .sidebar-closed { | ||||||
|  |       display: none; | ||||||
|  |     } | ||||||
|  |  | ||||||
|     .component-wrapper { |     .component-wrapper { | ||||||
|       .component { |       .component { | ||||||
|         .content-wrapper { |         .content-wrapper { | ||||||
|           .content { |           .content { | ||||||
|  |             .client { | ||||||
|  |               flex-direction: column !important; | ||||||
|  |             } | ||||||
|  |  | ||||||
|             .server-list-wrapper { |             .server-list-wrapper { | ||||||
|               .server-list { |               .server-list { | ||||||
|                 .server { |                 .server { | ||||||
| @@ -749,6 +779,7 @@ p-inputNumber { | |||||||
|   .p-column-title { |   .p-column-title { | ||||||
|     min-width: 50%; |     min-width: 50%; | ||||||
|     font-weight: 600; |     font-weight: 600; | ||||||
|  |     word-break: break-word; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   p-cellEditor { |   p-cellEditor { | ||||||
|   | |||||||
| @@ -40,6 +40,7 @@ header, | |||||||
|     white-space: nowrap; |     white-space: nowrap; | ||||||
|     overflow: hidden; |     overflow: hidden; | ||||||
|     text-overflow: ellipsis; |     text-overflow: ellipsis; | ||||||
|  |     line-height: normal !important; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   .p-panelmenu-header > a { |   .p-panelmenu-header > a { | ||||||
| @@ -53,10 +54,6 @@ header, | |||||||
|     border: none !important; |     border: none !important; | ||||||
|     background: none !important; |     background: none !important; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   .p-menuitem-text { |  | ||||||
|     line-height: normal !important; |  | ||||||
|   } |  | ||||||
| } | } | ||||||
|  |  | ||||||
| ui-menu .ui-menu-parent .ui-menu-child { | ui-menu .ui-menu-parent .ui-menu-child { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user