@ngx-smz/layout 19.6.0 → 21.0.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/ngx-smz-layout.mjs +491 -489
- package/fesm2022/ngx-smz-layout.mjs.map +1 -1
- package/package.json +4 -10
- package/types/ngx-smz-layout.d.ts +350 -0
- package/index.d.ts +0 -5
- package/lib/config/config.d.ts +0 -25
- package/lib/config/index.d.ts +0 -2
- package/lib/config/provide.d.ts +0 -4
- package/lib/errors/access.d.ts +0 -6
- package/lib/errors/error.d.ts +0 -6
- package/lib/errors/errors-pages-service.d.ts +0 -41
- package/lib/errors/errors.routes.d.ts +0 -2
- package/lib/errors/notfound.d.ts +0 -6
- package/lib/layout/component/app.configurator.d.ts +0 -97
- package/lib/layout/component/app.floatingconfigurator.d.ts +0 -9
- package/lib/layout/component/app.footer.d.ts +0 -21
- package/lib/layout/component/app.layout.d.ts +0 -31
- package/lib/layout/component/app.menu.d.ts +0 -9
- package/lib/layout/component/app.menuitem.d.ts +0 -27
- package/lib/layout/component/app.sidebar.d.ts +0 -8
- package/lib/layout/component/app.topbar.d.ts +0 -46
- package/lib/layout/service/layout.service.d.ts +0 -54
- package/lib/layout/service/navigation.service.d.ts +0 -17
- package/lib/layout/service/page-title.service.d.ts +0 -16
- package/lib/logging/config/config.d.ts +0 -12
- package/lib/logging/config/index.d.ts +0 -2
- package/lib/logging/config/provide.d.ts +0 -4
- package/lib/logging/logging-config.d.ts +0 -7
- package/lib/logging/logging-scope.d.ts +0 -4
- package/lib/logging/logging.service.d.ts +0 -33
- package/lib/shared/component-injector/directives/component-injector.directive.d.ts +0 -20
- package/lib/shared/component-injector/interfaces/inject-content.d.ts +0 -8
- package/lib/shared/component-injector/interfaces/injectable.d.ts +0 -35
- package/lib/shared/component-injector/services/inject-component.service.d.ts +0 -12
- package/public-api.d.ts +0 -17
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { Router } from '@angular/router';
|
|
2
|
-
import { Subscription } from 'rxjs';
|
|
3
|
-
import { MenuItem } from 'primeng/api';
|
|
4
|
-
import { LayoutService } from '../service/layout.service';
|
|
5
|
-
import * as i0 from "@angular/core";
|
|
6
|
-
export declare class AppMenuitem {
|
|
7
|
-
router: Router;
|
|
8
|
-
private layoutService;
|
|
9
|
-
item: MenuItem;
|
|
10
|
-
index: number;
|
|
11
|
-
root: boolean;
|
|
12
|
-
parentKey: string;
|
|
13
|
-
hasClaim: (claims: string[]) => boolean;
|
|
14
|
-
active: boolean;
|
|
15
|
-
menuSourceSubscription: Subscription;
|
|
16
|
-
menuResetSubscription: Subscription;
|
|
17
|
-
key: string;
|
|
18
|
-
constructor(router: Router, layoutService: LayoutService);
|
|
19
|
-
ngOnInit(): void;
|
|
20
|
-
updateActiveStateFromRoute(): void;
|
|
21
|
-
itemClick(event: Event): void;
|
|
22
|
-
get submenuAnimation(): "collapsed" | "expanded";
|
|
23
|
-
get activeClass(): boolean;
|
|
24
|
-
ngOnDestroy(): void;
|
|
25
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AppMenuitem, never>;
|
|
26
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AppMenuitem, "[app-menuitem]", never, { "item": { "alias": "item"; "required": false; }; "index": { "alias": "index"; "required": false; }; "root": { "alias": "root"; "required": false; }; "parentKey": { "alias": "parentKey"; "required": false; }; }, {}, never, never, true, never>;
|
|
27
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { ElementRef } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export declare class AppSidebar {
|
|
4
|
-
el: ElementRef;
|
|
5
|
-
constructor(el: ElementRef);
|
|
6
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AppSidebar, never>;
|
|
7
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AppSidebar, "app-sidebar", never, {}, {}, never, never, true, never>;
|
|
8
|
-
}
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import { Signal } from '@angular/core';
|
|
2
|
-
import { LayoutService } from '../service/layout.service';
|
|
3
|
-
import { InjectableComponent } from '../../shared/component-injector/interfaces/injectable';
|
|
4
|
-
import { PrimeNG } from 'primeng/config';
|
|
5
|
-
import { MenuItem } from 'primeng/api';
|
|
6
|
-
import { NavigationService } from '../service/navigation.service';
|
|
7
|
-
import { PageTitleService } from '../service/page-title.service';
|
|
8
|
-
import * as i0 from "@angular/core";
|
|
9
|
-
export declare class AppTopbar {
|
|
10
|
-
primeNG: PrimeNG;
|
|
11
|
-
data: Signal<Topbar>;
|
|
12
|
-
layoutService: LayoutService;
|
|
13
|
-
navigationService: NavigationService;
|
|
14
|
-
pageTitleService: PageTitleService;
|
|
15
|
-
toggleDarkMode(): void;
|
|
16
|
-
handleMissingImage(event: Event, placeholder: string): void;
|
|
17
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AppTopbar, never>;
|
|
18
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AppTopbar, "app-topbar", never, {}, {}, never, never, true, never>;
|
|
19
|
-
}
|
|
20
|
-
export interface Topbar {
|
|
21
|
-
showMenuToggle?: boolean;
|
|
22
|
-
showBackButton?: boolean;
|
|
23
|
-
showConfigurator?: boolean;
|
|
24
|
-
showDarkModeToggle?: boolean;
|
|
25
|
-
logoPath?: {
|
|
26
|
-
light?: string;
|
|
27
|
-
dark?: string;
|
|
28
|
-
};
|
|
29
|
-
appName?: string;
|
|
30
|
-
features?: {
|
|
31
|
-
icon?: Signal<string>;
|
|
32
|
-
avatar?: Signal<string>;
|
|
33
|
-
placeholder?: string;
|
|
34
|
-
label?: string;
|
|
35
|
-
tooltip?: string;
|
|
36
|
-
menuItems?: MenuItem[];
|
|
37
|
-
}[];
|
|
38
|
-
menuItems?: {
|
|
39
|
-
icon?: string;
|
|
40
|
-
label?: string;
|
|
41
|
-
tooltip?: string;
|
|
42
|
-
routerLink?: string;
|
|
43
|
-
callback?: () => void;
|
|
44
|
-
component?: InjectableComponent<unknown>;
|
|
45
|
-
}[];
|
|
46
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
export interface LayoutConfig {
|
|
3
|
-
preset?: string;
|
|
4
|
-
primary?: string;
|
|
5
|
-
surface?: string | undefined | null;
|
|
6
|
-
darkTheme?: boolean;
|
|
7
|
-
menuMode?: string;
|
|
8
|
-
}
|
|
9
|
-
export interface LayoutState {
|
|
10
|
-
staticMenuDesktopInactive?: boolean;
|
|
11
|
-
overlayMenuActive?: boolean;
|
|
12
|
-
configSidebarVisible?: boolean;
|
|
13
|
-
staticMenuMobileActive?: boolean;
|
|
14
|
-
menuHoverActive?: boolean;
|
|
15
|
-
}
|
|
16
|
-
interface MenuChangeEvent {
|
|
17
|
-
key: string;
|
|
18
|
-
routeEvent?: boolean;
|
|
19
|
-
}
|
|
20
|
-
export declare class LayoutService {
|
|
21
|
-
private readonly config;
|
|
22
|
-
layoutConfig: import("@angular/core").WritableSignal<LayoutConfig>;
|
|
23
|
-
layoutState: import("@angular/core").WritableSignal<LayoutState>;
|
|
24
|
-
private configUpdate;
|
|
25
|
-
private overlayOpen;
|
|
26
|
-
private menuSource;
|
|
27
|
-
private resetSource;
|
|
28
|
-
menuSource$: import("rxjs").Observable<MenuChangeEvent>;
|
|
29
|
-
resetSource$: import("rxjs").Observable<unknown>;
|
|
30
|
-
configUpdate$: import("rxjs").Observable<LayoutConfig>;
|
|
31
|
-
overlayOpen$: import("rxjs").Observable<any>;
|
|
32
|
-
theme: import("@angular/core").Signal<"light" | "dark">;
|
|
33
|
-
isSidebarActive: import("@angular/core").Signal<boolean>;
|
|
34
|
-
isDarkTheme: import("@angular/core").Signal<boolean>;
|
|
35
|
-
getPrimary: import("@angular/core").Signal<string>;
|
|
36
|
-
getSurface: import("@angular/core").Signal<string>;
|
|
37
|
-
isOverlay: import("@angular/core").Signal<boolean>;
|
|
38
|
-
transitionComplete: import("@angular/core").WritableSignal<boolean>;
|
|
39
|
-
private initialized;
|
|
40
|
-
constructor();
|
|
41
|
-
private handleDarkModeTransition;
|
|
42
|
-
private startViewTransition;
|
|
43
|
-
toggleDarkMode(config?: LayoutConfig): void;
|
|
44
|
-
private onTransitionEnd;
|
|
45
|
-
onMenuToggle(): void;
|
|
46
|
-
isDesktop(): boolean;
|
|
47
|
-
isMobile(): boolean;
|
|
48
|
-
onConfigUpdate(): void;
|
|
49
|
-
onMenuStateChange(event: MenuChangeEvent): void;
|
|
50
|
-
reset(): void;
|
|
51
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutService, never>;
|
|
52
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<LayoutService>;
|
|
53
|
-
}
|
|
54
|
-
export {};
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
export declare class NavigationService {
|
|
3
|
-
private router;
|
|
4
|
-
private location;
|
|
5
|
-
private history;
|
|
6
|
-
private isPopping;
|
|
7
|
-
readonly canGoBack: import("@angular/core").Signal<boolean>;
|
|
8
|
-
private loggingService;
|
|
9
|
-
private logger;
|
|
10
|
-
constructor();
|
|
11
|
-
/** Para template: [disabled]="!navigationService.canGoBackSignal()" */
|
|
12
|
-
canGoBackSignal(): boolean;
|
|
13
|
-
/** Volta um passo: remove do history e chama Location.back() */
|
|
14
|
-
goBack(): void;
|
|
15
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<NavigationService, never>;
|
|
16
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<NavigationService>;
|
|
17
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
export declare class PageTitleService {
|
|
3
|
-
private router;
|
|
4
|
-
private loggingService;
|
|
5
|
-
private logger;
|
|
6
|
-
private titleSignal;
|
|
7
|
-
readonly title: import("@angular/core").Signal<string>;
|
|
8
|
-
readonly hasTitle: import("@angular/core").Signal<boolean>;
|
|
9
|
-
constructor();
|
|
10
|
-
/** Percorre recursivamente o snapshot até a rota mais interna */
|
|
11
|
-
private getDeepestSnapshot;
|
|
12
|
-
/** Lê o title do data da rota mais interna */
|
|
13
|
-
private updateTitle;
|
|
14
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<PageTitleService, never>;
|
|
15
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<PageTitleService>;
|
|
16
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { WritableSignal } from '@angular/core';
|
|
2
|
-
import { LoggingConfig } from '../logging-config';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
export type SmzLayoutLoggingConfigType = {
|
|
5
|
-
logging: WritableSignal<LoggingConfig>;
|
|
6
|
-
};
|
|
7
|
-
export declare class SmzLayoutLogging {
|
|
8
|
-
logging: WritableSignal<LoggingConfig>;
|
|
9
|
-
setConfig(config: SmzLayoutLoggingConfigType): void;
|
|
10
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<SmzLayoutLogging, never>;
|
|
11
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<SmzLayoutLogging>;
|
|
12
|
-
}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { EnvironmentProviders, InjectionToken } from '@angular/core';
|
|
2
|
-
import { SmzLayoutLoggingConfigType } from './config';
|
|
3
|
-
export declare const SMZ_LAYOUT_LOGGING_CONFIG: InjectionToken<SmzLayoutLoggingConfigType>;
|
|
4
|
-
export declare function provideSmzLayoutLogging(initializers: (() => SmzLayoutLoggingConfigType[])): EnvironmentProviders;
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { LoggingScope } from './logging-scope';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export interface ScopedLogger {
|
|
4
|
-
log(message?: any, ...optionalParams: any[]): void;
|
|
5
|
-
warn(message?: any, ...optionalParams: any[]): void;
|
|
6
|
-
error(message?: any, ...optionalParams: any[]): void;
|
|
7
|
-
debug(message?: any, ...optionalParams: any[]): void;
|
|
8
|
-
}
|
|
9
|
-
export declare class LoggingService {
|
|
10
|
-
private configFn;
|
|
11
|
-
private enabled;
|
|
12
|
-
private levelRank;
|
|
13
|
-
/** expose current settings */
|
|
14
|
-
readonly isEnabled: import("@angular/core").Signal<boolean>;
|
|
15
|
-
readonly currentLevel: import("@angular/core").Signal<"error" | "debug" | "info" | "warn">;
|
|
16
|
-
readonly activeScopes: import("@angular/core").Signal<string[]>;
|
|
17
|
-
/** toggle logging global */
|
|
18
|
-
enable(): void;
|
|
19
|
-
disable(): void;
|
|
20
|
-
toggle(): void;
|
|
21
|
-
private shouldLog;
|
|
22
|
-
log(message?: any, ...optionalParams: any[]): void;
|
|
23
|
-
warn(message?: any, ...optionalParams: any[]): void;
|
|
24
|
-
error(message?: any, ...optionalParams: any[]): void;
|
|
25
|
-
debug(message?: any, ...optionalParams: any[]): void;
|
|
26
|
-
/**
|
|
27
|
-
* Retorna um logger com prefixo [owner] e restringe pelos scopes do config
|
|
28
|
-
* owner agora é um LoggingScope ou string
|
|
29
|
-
*/
|
|
30
|
-
scoped(owner: LoggingScope | string): ScopedLogger;
|
|
31
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<LoggingService, never>;
|
|
32
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<LoggingService>;
|
|
33
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { ViewContainerRef, AfterContentInit, OnDestroy, EventEmitter, ComponentRef } from '@angular/core';
|
|
2
|
-
import { InjectableComponent } from '../interfaces/injectable';
|
|
3
|
-
import { InjectComponentService } from '../services/inject-component.service';
|
|
4
|
-
import { ComponentType } from '@angular/cdk/overlay';
|
|
5
|
-
import * as i0 from "@angular/core";
|
|
6
|
-
export declare class ComponentInjectorDirective implements AfterContentInit, OnDestroy {
|
|
7
|
-
viewContainerRef: ViewContainerRef;
|
|
8
|
-
private service;
|
|
9
|
-
componentInjector: InjectableComponent<unknown>;
|
|
10
|
-
context: unknown;
|
|
11
|
-
componentCreated: EventEmitter<ComponentRef<ComponentType<unknown>>>;
|
|
12
|
-
isActive: boolean;
|
|
13
|
-
constructor(viewContainerRef: ViewContainerRef, service: InjectComponentService);
|
|
14
|
-
ngAfterContentInit(): void;
|
|
15
|
-
addComp(): void;
|
|
16
|
-
removeComp(): void;
|
|
17
|
-
ngOnDestroy(): void;
|
|
18
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<ComponentInjectorDirective, never>;
|
|
19
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<ComponentInjectorDirective, "ng-template[componentInjector]", never, { "componentInjector": { "alias": "componentInjector"; "required": false; }; "context": { "alias": "context"; "required": false; }; }, { "componentCreated": "componentCreated"; }, never, never, true, never>;
|
|
20
|
-
}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { BehaviorSubject } from 'rxjs';
|
|
2
|
-
import { InjectableContentEntity, InjectableOutput } from './inject-content';
|
|
3
|
-
import { ComponentRef, WritableSignal } from '@angular/core';
|
|
4
|
-
import { ComponentType } from '@angular/cdk/overlay';
|
|
5
|
-
export interface ComponentData {
|
|
6
|
-
component: ComponentDataBase | null;
|
|
7
|
-
inputs: InjectableContentEntity[];
|
|
8
|
-
outputs?: InjectableOutput[];
|
|
9
|
-
ref?: {
|
|
10
|
-
componentRef: ComponentRef<unknown> | null;
|
|
11
|
-
};
|
|
12
|
-
visibilityDependsOn?: {
|
|
13
|
-
propertyName: string;
|
|
14
|
-
formId: string;
|
|
15
|
-
reversed: boolean;
|
|
16
|
-
condition?: unknown;
|
|
17
|
-
conditions?: unknown[];
|
|
18
|
-
};
|
|
19
|
-
componentId?: string;
|
|
20
|
-
}
|
|
21
|
-
export interface ComponentDataBase {
|
|
22
|
-
isValid: WritableSignal<boolean>;
|
|
23
|
-
onValidationError$?: BehaviorSubject<boolean>;
|
|
24
|
-
getData: () => unknown;
|
|
25
|
-
}
|
|
26
|
-
export interface InjectableComponent<TComponent> {
|
|
27
|
-
component: ComponentType<TComponent> | null;
|
|
28
|
-
inputs: InjectableContentEntity[];
|
|
29
|
-
outputs: InjectableOutput[];
|
|
30
|
-
ref?: {
|
|
31
|
-
componentRef: ComponentRef<unknown> | null;
|
|
32
|
-
};
|
|
33
|
-
styleClass?: string;
|
|
34
|
-
componentId?: string;
|
|
35
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { ComponentRef } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export type DynamicComponent = Record<string, unknown>;
|
|
4
|
-
export declare class InjectComponentService {
|
|
5
|
-
componentRefs: Map<string, ComponentRef<DynamicComponent>>;
|
|
6
|
-
setComponent(key: string, ref: ComponentRef<DynamicComponent>): void;
|
|
7
|
-
updateComponent(key: string, input: string, value: unknown): void;
|
|
8
|
-
deleteComponent(key: string): void;
|
|
9
|
-
getComponent(key: string): ComponentRef<DynamicComponent> | undefined;
|
|
10
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<InjectComponentService, never>;
|
|
11
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<InjectComponentService>;
|
|
12
|
-
}
|
package/public-api.d.ts
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
export * from './lib/layout/component/app.layout';
|
|
2
|
-
export * from './lib/config';
|
|
3
|
-
export type { Footer } from './lib/layout/component/app.footer';
|
|
4
|
-
export type { Topbar } from './lib/layout/component/app.topbar';
|
|
5
|
-
export { AppFloatingConfigurator } from './lib/layout/component/app.floatingconfigurator';
|
|
6
|
-
export { AccessPageComponent } from './lib/errors/access';
|
|
7
|
-
export { ErrorPageComponent } from './lib/errors/error';
|
|
8
|
-
export { NotfoundPageComponent } from './lib/errors/notfound';
|
|
9
|
-
export { ErrorsRoutes } from './lib/errors/errors.routes';
|
|
10
|
-
export { ErrorPagesConfigService } from './lib/errors/errors-pages-service';
|
|
11
|
-
export { LayoutService } from './lib/layout/service/layout.service';
|
|
12
|
-
export type { LayoutConfig, LayoutState } from './lib/layout/service/layout.service';
|
|
13
|
-
export * from './lib/logging/config';
|
|
14
|
-
export type { ScopedLogger } from './lib/logging/logging.service';
|
|
15
|
-
export { LoggingService } from './lib/logging/logging.service';
|
|
16
|
-
export { LoggingScope } from './lib/logging/logging-scope';
|
|
17
|
-
export type { LoggingConfig } from './lib/logging/logging-config';
|