Remove header from pages, entities, menus etc. Add custom class in items of user-mini. Slider-tabs: Emit active in dynamic type.

This commit is contained in:
Konstantinos Triantafyllou 2023-03-27 14:59:17 +03:00
parent dde8e27f65
commit acc9338ec0
12 changed files with 48 additions and 93 deletions

View File

@ -1,11 +1,5 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<div>
<div class="uk-text-background uk-text-bold uk-text-small">Manage Classes</div>
<h1 class="uk-h6 uk-margin-remove">Super Admin</h1>
</div>
</div>
<admin-tabs tab="class"></admin-tabs>
<ul class="uk-subnav uk-subnav-pill uk-margin-medium-top">
<li [class.uk-active]="filterForm.get('type').value === 'all'" class="uk-margin-small-bottom"><a

View File

@ -1,20 +1,18 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<a routerLink="../" [queryParams]=" { 'pageId': pageId }" class="uk-button uk-button-link uk-margin-medium-right">
<icon name="west" ratio="2" [flex]="true"></icon>
</a>
<div>
<div class="uk-text-background uk-text-bold uk-text-small">
Admin Dashboard - {{pageHelpContent ? 'Update ' : 'Add new '}} class help text
<div class="uk-section-xsmall uk-margin-top uk-container">
<div class="uk-flex-middle uk-grid" uk-grid>
<div class="uk-width-expand">
<a routerLink="../" [queryParams]=" { 'pageId': pageId }" class="uk-flex uk-flex-middle uk-h5 uk-link-reset">
<span class="uk-margin-right">
<icon name="west" ratio="1.7" [flex]="true"></icon>
</span>
<h1 *ngIf="page" class="uk-h5 uk-margin-remove">
{{page.name}} - {{pageHelpContent ? 'Update ' : 'Add new '}} class help text
<span *ngIf="myForm.dirty" class="uk-text-large"> (unsaved changes)</span>
</h1>
</a>
</div>
<h1 *ngIf="page" class="uk-h6 uk-margin-remove">{{page.name}}<span *ngIf="myForm.dirty" class="uk-text-large"> (unsaved changes)</span></h1>
</div>
</div>
</div>
<div actions>
<div class="uk-section-xsmall uk-container">
<div class="uk-flex uk-flex-center uk-flex-right@m">
<button class="uk-button uk-button-default uk-margin-right"
(click)="resetCustom()" [class.uk-disabled]="!myForm.dirty"
[disabled]="!myForm.dirty || showLoading">Reset

View File

@ -1,20 +1,15 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<a routerLink="../pages" class="uk-button uk-button-link uk-margin-medium-right">
<icon name="west" ratio="2" [flex]="true"></icon>
</a>
<div>
<div class="uk-text-background uk-text-bold uk-text-small">
Admin Dashboard - Manage class help texts
<div class="uk-section-xsmall uk-margin-top">
<div class="uk-flex-middle uk-grid" uk-grid>
<div class="uk-width-expand">
<a routerLink="../pages" class="uk-flex uk-flex-middle uk-h5 uk-link-reset">
<span class="uk-margin-right">
<icon name="west" ratio="1.7" [flex]="true"></icon>
</span>
<h1 *ngIf="page" class="uk-h5 uk-margin-remove">{{page.name}}</h1>
</a>
</div>
<h1 *ngIf="page" class="uk-h6 uk-margin-remove">{{page.name}}</h1>
</div>
</div>
</div>
<div actions>
<div class="uk-section-xsmall">
<div class="uk-flex-right@m uk-flex-center uk-flex-middle uk-grid" uk-grid>
<div search-input [disabled]="showLoading" [expandable]="true" [searchControl]="filterForm" searchInputClass="outer" placeholder="Search helptext" class="uk-width-1-3@xl uk-width-2-5@l uk-width-1-2@m uk-width-1-1">
</div>
<div>

View File

@ -1,11 +1,5 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<div>
<div class="uk-text-background uk-text-bold uk-text-small">Manage Entities</div>
<h1 class="uk-h6 uk-margin-remove">{{name?name:'Super Admin'}}</h1>
</div>
</div>
<admin-tabs tab="entity" [portal]="portal" [type]="type"></admin-tabs>
<ul *ngIf="!isPortalAdministrator" class="uk-subnav uk-subnav-pill uk-margin-medium-top">
<li [class.uk-active]="filterForm.get('status').value === 'all'"><a

View File

@ -1,26 +1,24 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<a routerLink="../" [queryParams]=" { 'pageId': pageId }" class="uk-button uk-button-link uk-margin-right">
<icon name="west" ratio="2" [flex]="true"></icon>
</a>
<div>
<div class="uk-text-background uk-text-bold uk-text-small">
Admin Dashboard - {{pageHelpContent ? 'Update ' : 'Add new '}} page help text
<div class="uk-section-xsmall uk-margin-top uk-container">
<div class="uk-flex-middle uk-grid" uk-grid>
<div class="uk-width-expand">
<a routerLink="../" [queryParams]=" { 'pageId': pageId }" class="uk-flex uk-flex-middle uk-h5 uk-link-reset">
<span class="uk-margin-right">
<icon name="west" ratio="1.7" [flex]="true"></icon>
</span>
<h1 *ngIf="page" class="uk-h5 uk-margin-remove">
{{page.name}} - {{pageHelpContent ? 'Update ' : 'Add new '}} page help text
<span *ngIf="myForm.dirty" class="uk-text-large"> (unsaved changes)</span>
</h1>
</a>
</div>
<h1 *ngIf="page" class="uk-h6 uk-margin-remove">{{page.name}}<span *ngIf="myForm.dirty" class="uk-text-large"> (unsaved changes)</span></h1>
</div>
</div>
</div>
<div actions>
<div class="uk-section-xsmall uk-container">
<div class="uk-flex uk-flex-center uk-flex-right@m">
<button class="uk-button uk-button-default uk-margin-right"
(click)="resetCustom()" [class.uk-disabled]="!myForm.dirty"
[disabled]="!myForm.dirty || showLoading">Reset
</button>
<button class="uk-button uk-button-primary" [class.uk-disabled]="myForm.invalid || !myForm.dirty || myForm.disabled"
(click)="saveCustom()" [disabled]="myForm.invalid || !myForm.dirty || myForm.disabled || showLoading">Save
(click)="saveCustom()" [disabled]="myForm.invalid ||!myForm.dirty || myForm.disabled || showLoading">Save
</button>
</div>
</div>

View File

@ -1,20 +1,15 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<a routerLink="../pages" class="uk-button uk-button-link uk-margin-medium-right">
<icon name="west" ratio="2" [flex]="true"></icon>
</a>
<div>
<div class="uk-text-background uk-text-bold uk-text-small">
Admin Dashboard - Manage page help texts
<div class="uk-section-xsmall uk-margin-top">
<div class="uk-flex-middle uk-grid" uk-grid>
<div class="uk-width-expand">
<a routerLink="../pages" class="uk-flex uk-flex-middle uk-h5 uk-link-reset">
<span class="uk-margin-right">
<icon name="west" ratio="1.7" [flex]="true"></icon>
</span>
<h1 *ngIf="page" class="uk-h5 uk-margin-remove">{{page.name}}</h1>
</a>
</div>
<h1 *ngIf="page" class="uk-h6 uk-margin-remove">{{page.name}}</h1>
</div>
</div>
</div>
<div actions>
<div class="uk-section-xsmall">
<div class="uk-flex-right@m uk-flex-center uk-flex-middle uk-grid" uk-grid>
<div search-input [disabled]="showLoading" [expandable]="true" [searchControl]="filterForm" searchInputClass="outer" placeholder="Search helptext" class="uk-width-1-3@xl uk-width-2-5@l uk-width-1-2@m uk-width-1-1">
</div>
<div>

View File

@ -1,14 +1,5 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<ng-container *ngIf="showLogo">
<img [src]="entity | logoUrl" class="uk-margin-right uk-blend-multiply">
</ng-container>
<div>
<div class="uk-text-background uk-text-bold uk-text-small">Admin Dashboard - Manage Menus</div>
<h1 class="uk-h6 uk-margin-remove">{{name ? name : 'Super Admin'}}</h1>
</div>
</div>
<admin-tabs tab="menu" [portal]="portal" [type]="type"></admin-tabs>
</div>
<div actions>

View File

@ -1,11 +1,5 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<div>
<div class="uk-text-background uk-text-bold uk-text-small">Manage Pages</div>
<h1 class="uk-h6 uk-margin-remove">{{name ? name : 'Super Admin'}}</h1>
</div>
</div>
<admin-tabs tab="page" [portal]="portal" [type]="type"></admin-tabs>
<ul class="uk-subnav uk-subnav-pill uk-margin-medium-top">
<li [class.uk-active]="filterForm.get('type').value === 'all'"><a

View File

@ -1,11 +1,5 @@
<div page-content>
<div header>
<div class="uk-flex uk-flex-middle uk-margin-medium-top info">
<div>
<div class="uk-text-background uk-text-bold uk-text-small">Manage Portals</div>
<h1 class="uk-h6 uk-margin-remove">Super Admin</h1>
</div>
</div>
<admin-tabs tab="portal"></admin-tabs>
<ul class="uk-subnav uk-subnav-pill uk-margin-medium-top">
<li [class.uk-active]="filterForm.get('type').value === 'all'" class="uk-margin-small-bottom"><a

View File

@ -32,7 +32,7 @@
<ul #nav class="uk-list uk-nav uk-nav-parent-icon" [class.uk-list-large]="mobile"
[class.uk-nav-default]="!mobile" [class.uk-nav-primary]="mobile" uk-nav="duration: 400">
<ng-template ngFor [ngForOf]="items" let-item>
<li [class.uk-active]="item.isActive"
<li [class.uk-active]="item.isActive" [ngClass]="item.customClass"
[class.uk-parent]="item.items.length > 0">
<a [routerLink]="getItemRoute(item)" [title]="item.title" (click)="item.items.length === 0?closeOffcanvas():null"
[queryParams]="item.route?item.params:null" [queryParamsHandling]="item.route?queryParamsHandling:null" class="uk-flex uk-flex-middle">
@ -42,7 +42,7 @@
<span [class.hide-on-close]="item.icon" class="uk-width-expand@l uk-text-truncate uk-margin-small-left">{{item.title}}</span>
</a>
<ul *ngIf="item.items?.length > 0 && (isBrowser || item.isActive)" class="uk-nav-sub">
<li *ngFor="let subItem of item.items"
<li *ngFor="let subItem of item.items" [ngClass]="subItem.customClass"
[class.uk-active]="subItem.isActive">
<a [routerLink]="subItem.route?subItem.route:null" [title]="subItem.title" (click)="closeOffcanvas()"
[queryParams]="subItem.route?subItem.params:null" [queryParamsHandling]="subItem.route?queryParamsHandling:null">

View File

@ -31,6 +31,7 @@ declare var UIkit;
<ul class="uk-nav uk-navbar-dropdown-nav">
<ng-container *ngFor="let item of userMenuItems ">
<li *ngIf="item.needsAuthorization && isAuthorized || !item.needsAuthorization"
[ngClass]="item.customClass"
[class.uk-active]="isTheActiveSubMenu(item)">
<a *ngIf="item.route" [routerLink]="item.route"
[queryParams]="item.params">{{item.title}}</a>
@ -84,7 +85,7 @@ declare var UIkit;
</div>
<ul class="uk-nav uk-nav-primary uk-list uk-margin-top uk-nav-parent-icon" uk-nav>
<ng-container *ngFor="let item of userMenuItems ">
<li *ngIf="item.needsAuthorization && isAuthorized || !item.needsAuthorization">
<li *ngIf="item.needsAuthorization && isAuthorized || !item.needsAuthorization" [ngClass]="item.customClass">
<a *ngIf="item.route" [routerLink]="item.route" (click)="closeCanvas(account)">{{item.title}}</a>
<a *ngIf="!item.route && item.url" (click)="closeCanvas(account)" [href]="item.url" [class.custom-external]="item.target != '_self'"
[target]="item.target">{{item.title}}</a>

View File

@ -206,6 +206,7 @@ export class SliderTabsComponent implements AfterViewInit, OnDestroy {
public showActive(index) {
this.activeIndex = index;
this.activeEmitter.emit(this.tabs.get(this.activeIndex).id);
if(this.slider) {
this.slider.show(this.activeIndex);
}