ngx-sp-auth 4.1.2 → 4.1.3
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-sp-auth.mjs
CHANGED
|
@@ -3807,26 +3807,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
|
|
|
3807
3807
|
}] } });
|
|
3808
3808
|
|
|
3809
3809
|
class ListComponent {
|
|
3810
|
-
/**
|
|
3811
|
-
*
|
|
3812
|
-
*/
|
|
3813
3810
|
constructor() {
|
|
3814
3811
|
this.telasItem = [];
|
|
3815
|
-
this.hostName =
|
|
3816
|
-
|
|
3817
|
-
|
|
3818
|
-
return `${this.hostName}/${url}`;
|
|
3812
|
+
this.hostName = '';
|
|
3813
|
+
this.onTelaSelecionada = new EventEmitter();
|
|
3814
|
+
this.getExternalUrl = (url) => { return `${this.hostName}/${url}`; };
|
|
3819
3815
|
}
|
|
3820
3816
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3821
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: ListComponent, isStandalone: true, selector: "app-list", inputs: { telasItem: "telasItem", hostName: "hostName" }, ngImport: i0, template: "<ul class=\"nav flex-column mt-3\">\n @if(telasItem.length) {\n @for(clickLink of telasItem; track $index) {\n <li class=\"nav-item\">\n <a class=\"nav-link\" [target]=\"clickLink.IsExternal ? '_blank' : '_self'\"\n
|
|
3817
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: ListComponent, isStandalone: true, selector: "app-list", inputs: { telasItem: "telasItem", hostName: "hostName" }, outputs: { onTelaSelecionada: "onTelaSelecionada" }, ngImport: i0, template: "<ul class=\"nav flex-column mt-3\">\n @if(telasItem.length) {\n @for(clickLink of telasItem; track $index) {\n <li class=\"nav-item\">\n <a class=\"nav-link\" [target]=\"clickLink.IsExternal ? '_blank' : '_self'\" (click)=\"onTelaSelecionada.emit(clickLink.titulo)\"\n [href]=\"clickLink.IsExternal\n ? getExternalUrl(clickLink.urlPath)\n : '/SisproErpCloud/' + clickLink.urlPath\" >\n {{ clickLink.titulo }}\n </a>\n </li>\n }\n }\n</ul>\n", styles: ["a{color:#3e5154}\n"] }); }
|
|
3822
3818
|
}
|
|
3823
3819
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ListComponent, decorators: [{
|
|
3824
3820
|
type: Component,
|
|
3825
|
-
args: [{ selector: 'app-list', imports: [], standalone: true, template: "<ul class=\"nav flex-column mt-3\">\n @if(telasItem.length) {\n @for(clickLink of telasItem; track $index) {\n <li class=\"nav-item\">\n <a class=\"nav-link\" [target]=\"clickLink.IsExternal ? '_blank' : '_self'\"\n
|
|
3826
|
-
}],
|
|
3821
|
+
args: [{ selector: 'app-list', imports: [], standalone: true, template: "<ul class=\"nav flex-column mt-3\">\n @if(telasItem.length) {\n @for(clickLink of telasItem; track $index) {\n <li class=\"nav-item\">\n <a class=\"nav-link\" [target]=\"clickLink.IsExternal ? '_blank' : '_self'\" (click)=\"onTelaSelecionada.emit(clickLink.titulo)\"\n [href]=\"clickLink.IsExternal\n ? getExternalUrl(clickLink.urlPath)\n : '/SisproErpCloud/' + clickLink.urlPath\" >\n {{ clickLink.titulo }}\n </a>\n </li>\n }\n }\n</ul>\n", styles: ["a{color:#3e5154}\n"] }]
|
|
3822
|
+
}], propDecorators: { telasItem: [{
|
|
3827
3823
|
type: Input
|
|
3828
3824
|
}], hostName: [{
|
|
3829
3825
|
type: Input
|
|
3826
|
+
}], onTelaSelecionada: [{
|
|
3827
|
+
type: Output
|
|
3830
3828
|
}] } });
|
|
3831
3829
|
|
|
3832
3830
|
class NavTabsComponent {
|
|
@@ -3836,38 +3834,51 @@ class NavTabsComponent {
|
|
|
3836
3834
|
// #region ==========> PROPERTIES <==========
|
|
3837
3835
|
// #region PUBLIC
|
|
3838
3836
|
this.subMenus = [];
|
|
3839
|
-
this.hostName =
|
|
3837
|
+
this.hostName = '';
|
|
3838
|
+
this.onTituloSelecionado = new EventEmitter();
|
|
3839
|
+
this.onTelaSelecionada = new EventEmitter();
|
|
3840
3840
|
this.telasItem = [];
|
|
3841
3841
|
this.listaAtiva = '';
|
|
3842
3842
|
}
|
|
3843
3843
|
ngOnInit() {
|
|
3844
3844
|
if (this.subMenus.length != 0) {
|
|
3845
|
-
this.telasItem = this.subMenus[0].telasItem;
|
|
3845
|
+
this.telasItem = this.subMenus.filter(e => e.titulo.includes(this.activeItem ?? ''))[0].telasItem;
|
|
3846
3846
|
this.listaAtiva = this.activeItem ?? this.subMenus[0].titulo;
|
|
3847
|
+
if (this.activeItem && this.activeItem !== '')
|
|
3848
|
+
this.setAbaAtiva(this.activeItem);
|
|
3849
|
+
}
|
|
3850
|
+
}
|
|
3851
|
+
ngOnChanges(changes) {
|
|
3852
|
+
if (changes['activeItem'].currentValue && changes['activeItem'].currentValue !== "") {
|
|
3853
|
+
this.setAbaAtiva(changes['activeItem'].currentValue);
|
|
3854
|
+
}
|
|
3855
|
+
if ((changes['subMenus'].currentValue && changes['subMenus'].currentValue !== "") && this.activeItem !== '') {
|
|
3856
|
+
this.setAbaAtiva(this.activeItem);
|
|
3847
3857
|
}
|
|
3848
3858
|
}
|
|
3849
3859
|
// #region ==========> UTILS <==========
|
|
3850
|
-
|
|
3851
|
-
const index = this.subMenus.findIndex(submenu =>
|
|
3852
|
-
return submenu.titulo == b;
|
|
3853
|
-
});
|
|
3860
|
+
setAbaAtiva(titulo) {
|
|
3861
|
+
const index = this.subMenus.findIndex(submenu => submenu.titulo == titulo);
|
|
3854
3862
|
this.telasItem = this.subMenus[index].telasItem;
|
|
3855
3863
|
this.listaAtiva = this.subMenus[index].titulo;
|
|
3864
|
+
this.onTituloSelecionado.emit(titulo);
|
|
3856
3865
|
}
|
|
3857
3866
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: NavTabsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3858
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: NavTabsComponent, isStandalone: true, selector: "app-nav-tabs", inputs: { subMenus: "subMenus", hostName: "hostName", activeItem: "activeItem" }, ngImport: i0, template: "<ul class=\"menu my-3\">\n @for(menu of subMenus; track $index) {\n <li class=\"menu-item\" (click)=\"
|
|
3867
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: NavTabsComponent, isStandalone: true, selector: "app-nav-tabs", inputs: { subMenus: "subMenus", hostName: "hostName", activeItem: "activeItem" }, outputs: { onTituloSelecionado: "onTituloSelecionado", onTelaSelecionada: "onTelaSelecionada" }, usesOnChanges: true, ngImport: i0, template: "<ul class=\"menu my-3\">\n @for(menu of subMenus; track $index) {\n <li class=\"menu-item\" (click)=\"setAbaAtiva(menu.titulo)\" [class.active]=\"menu.titulo === listaAtiva\">\n <a class=\"glb-cursor-pointer\" (click)=\"setAbaAtiva(menu.titulo)\" [tabindex]=\"$index\" >\n {{ menu.titulo }}\n </a>\n </li>\n }\n</ul>\n\n@if (telasItem) {\n <app-list [telasItem]=\"telasItem\" [hostName]=\"hostName\" (onTelaSelecionada)=\"onTelaSelecionada.emit($event)\" />\n}\n", styles: ["@charset \"UTF-8\";.menu{list-style:none;padding:0;margin:0;display:flex;gap:20px}.menu-item a{text-align:center;position:relative;display:inline-block;padding-bottom:5px;color:#6c757d;text-decoration:none;transition:color .3s ease,border-bottom-color .3s ease;border-bottom:2px solid #fff;width:calc(100% + 15px)}.menu-item a:hover{color:#213b70;border-bottom:2px solid #213B70}.menu-item.active a:after{content:\"\";position:absolute;bottom:-2px;left:50%;transform:translate(-50%);width:calc(100% + 5px);height:2px;background-color:#213b70}.menu-item.active a{color:#213b70}.menu-item.active a:before{content:\"\";position:absolute;bottom:0;left:50%;transform:translate(-50%);width:0;height:0;opacity:1;transition:all .2s ease-in-out}\n"], dependencies: [{ kind: "component", type: ListComponent, selector: "app-list", inputs: ["telasItem", "hostName"], outputs: ["onTelaSelecionada"] }] }); }
|
|
3859
3868
|
}
|
|
3860
3869
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: NavTabsComponent, decorators: [{
|
|
3861
3870
|
type: Component,
|
|
3862
|
-
args: [{ selector: 'app-nav-tabs', imports: [
|
|
3863
|
-
ListComponent
|
|
3864
|
-
], template: "<ul class=\"menu my-3\">\n @for(menu of subMenus; track $index) {\n <li class=\"menu-item\" (click)=\"abaActive(menu.titulo)\" [class.active]=\"menu.titulo === listaAtiva\">\n <a class=\"glb-cursor-pointer\" (click)=\"abaActive(menu.titulo)\" [tabindex]=\"$index\">\n {{ menu.titulo }}\n </a>\n </li>\n }\n</ul>\n\n@if (telasItem) {\n <app-list [telasItem]=\"telasItem\" [hostName]=\"hostName\" />\n}\n", styles: ["@charset \"UTF-8\";.menu{list-style:none;padding:0;margin:0;display:flex;gap:20px}.menu-item a{text-align:center;position:relative;display:inline-block;padding-bottom:5px;color:#6c757d;text-decoration:none;transition:color .3s ease,border-bottom-color .3s ease;border-bottom:2px solid #fff;width:calc(100% + 15px)}.menu-item a:hover{color:#213b70;border-bottom:2px solid #213B70}.menu-item.active a:after{content:\"\";position:absolute;bottom:-2px;left:50%;transform:translate(-50%);width:calc(100% + 5px);height:2px;background-color:#213b70}.menu-item.active a{color:#213b70}.menu-item.active a:before{content:\"\";position:absolute;bottom:0;left:50%;transform:translate(-50%);width:0;height:0;opacity:1;transition:all .2s ease-in-out}\n"] }]
|
|
3871
|
+
args: [{ selector: 'app-nav-tabs', imports: [ListComponent], template: "<ul class=\"menu my-3\">\n @for(menu of subMenus; track $index) {\n <li class=\"menu-item\" (click)=\"setAbaAtiva(menu.titulo)\" [class.active]=\"menu.titulo === listaAtiva\">\n <a class=\"glb-cursor-pointer\" (click)=\"setAbaAtiva(menu.titulo)\" [tabindex]=\"$index\" >\n {{ menu.titulo }}\n </a>\n </li>\n }\n</ul>\n\n@if (telasItem) {\n <app-list [telasItem]=\"telasItem\" [hostName]=\"hostName\" (onTelaSelecionada)=\"onTelaSelecionada.emit($event)\" />\n}\n", styles: ["@charset \"UTF-8\";.menu{list-style:none;padding:0;margin:0;display:flex;gap:20px}.menu-item a{text-align:center;position:relative;display:inline-block;padding-bottom:5px;color:#6c757d;text-decoration:none;transition:color .3s ease,border-bottom-color .3s ease;border-bottom:2px solid #fff;width:calc(100% + 15px)}.menu-item a:hover{color:#213b70;border-bottom:2px solid #213B70}.menu-item.active a:after{content:\"\";position:absolute;bottom:-2px;left:50%;transform:translate(-50%);width:calc(100% + 5px);height:2px;background-color:#213b70}.menu-item.active a{color:#213b70}.menu-item.active a:before{content:\"\";position:absolute;bottom:0;left:50%;transform:translate(-50%);width:0;height:0;opacity:1;transition:all .2s ease-in-out}\n"] }]
|
|
3865
3872
|
}], ctorParameters: () => [], propDecorators: { subMenus: [{
|
|
3866
3873
|
type: Input
|
|
3867
3874
|
}], hostName: [{
|
|
3868
3875
|
type: Input
|
|
3869
3876
|
}], activeItem: [{
|
|
3870
3877
|
type: Input
|
|
3878
|
+
}], onTituloSelecionado: [{
|
|
3879
|
+
type: Output
|
|
3880
|
+
}], onTelaSelecionada: [{
|
|
3881
|
+
type: Output
|
|
3871
3882
|
}] } });
|
|
3872
3883
|
|
|
3873
3884
|
class NavSubMenus {
|
|
@@ -3901,11 +3912,13 @@ class SubMenuComponent {
|
|
|
3901
3912
|
this.navSubmenus = [];
|
|
3902
3913
|
this.isProduction = true;
|
|
3903
3914
|
this.hostname = "https://siscandesv6.sispro.com.br";
|
|
3915
|
+
this.onTituloSelecionado = new EventEmitter();
|
|
3916
|
+
this.onTelaSelecionada = new EventEmitter();
|
|
3904
3917
|
this.hostNameOutSystems = "";
|
|
3905
3918
|
this.listaSubMenus = [];
|
|
3906
3919
|
}
|
|
3907
3920
|
ngOnInit() {
|
|
3908
|
-
this.
|
|
3921
|
+
this.getHostName();
|
|
3909
3922
|
if (this.navSubmenus.length > 0 &&
|
|
3910
3923
|
this.navSubmenus[0].subMenuItem &&
|
|
3911
3924
|
this.navSubmenus[0].subMenuItem.length > 0) {
|
|
@@ -3919,14 +3932,14 @@ class SubMenuComponent {
|
|
|
3919
3932
|
this.listaSubMenus.push(...this.navSubmenus[i].subMenuItem);
|
|
3920
3933
|
}
|
|
3921
3934
|
}
|
|
3922
|
-
|
|
3935
|
+
getHostName() {
|
|
3923
3936
|
this._menuService.GetHostServerOutSystems().subscribe({
|
|
3924
3937
|
next: response => this.hostNameOutSystems = response.String,
|
|
3925
3938
|
error: error => this._projectUtil.showHttpError(error)
|
|
3926
3939
|
});
|
|
3927
3940
|
}
|
|
3928
3941
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: SubMenuComponent, deps: [{ token: MenuServicesService }, { token: ProjectUtilservice }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3929
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: SubMenuComponent, isStandalone: true, selector: "app-nav-sub-menu", inputs: { navSubmenus: "navSubmenus", isProduction: "isProduction", hostname: "hostname", activeItem: "activeItem" }, ngImport: i0, template: "<lib-container>\n <div class=\"px-5\" innerContent1>\n @for(subMenu of navSubmenus; track $index) {\n <div [class]=\"$first && subMenu.titulo == '' && subMenu.icon == '' ? ' mb-2' : 'mt-4 mb-2'\">\n @if (subMenu.icon != '') {\n <lib-icon class=\"bold engrenagem-ajustada\" iconName=\"{{ subMenu.icon }}\" />\n }\n @if (subMenu.titulo != ''){\n <span class=\"fw-bold fs-4 ms-1\">{{ subMenu.titulo }}</span>\n }\n\n <app-nav-tabs [activeItem]=\"activeItem\" [subMenus]=\"navSubmenus[$index].subMenuItem\" [hostName]=\"hostNameOutSystems\" />\n </div>\n\n @if(!$last){ <hr /> }\n }\n </div>\n</lib-container>\n", styles: [".engrenagem-ajustada{position:relative;top:-4px}\n"], dependencies: [{ kind: "component", type: NavTabsComponent, selector: "app-nav-tabs", inputs: ["subMenus", "hostName", "activeItem"] }, { kind: "component", type: LibIconsComponent, selector: "lib-icon", inputs: ["iconName", "iconColor", "iconSize", "iconFill"] }, { kind: "component", type: ContentContainerComponent, selector: "lib-container", inputs: ["documentation", "tabs", "advancedTabs", "containerTitle", "useBorder", "currentTab"], outputs: ["onChangeTab"] }] }); }
|
|
3942
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: SubMenuComponent, isStandalone: true, selector: "app-nav-sub-menu", inputs: { navSubmenus: "navSubmenus", isProduction: "isProduction", hostname: "hostname", activeItem: "activeItem" }, outputs: { onTituloSelecionado: "onTituloSelecionado", onTelaSelecionada: "onTelaSelecionada" }, ngImport: i0, template: "<lib-container>\n <div class=\"px-5\" innerContent1>\n @for(subMenu of navSubmenus; track $index) {\n <div [class]=\"$first && subMenu.titulo == '' && subMenu.icon == '' ? ' mb-2' : 'mt-4 mb-2'\">\n @if (subMenu.icon != '') {\n <lib-icon class=\"bold engrenagem-ajustada\" iconName=\"{{ subMenu.icon }}\" />\n }\n @if (subMenu.titulo != ''){\n <span class=\"fw-bold fs-4 ms-1\">{{ subMenu.titulo }}</span>\n }\n\n <app-nav-tabs [activeItem]=\"activeItem\" [subMenus]=\"navSubmenus[$index].subMenuItem\" [hostName]=\"hostNameOutSystems\"\n (onTelaSelecionada)=\"onTelaSelecionada.emit($event)\" (onTituloSelecionado)=\"onTituloSelecionado.emit($event)\" />\n </div>\n\n @if(!$last){ <hr /> }\n }\n </div>\n</lib-container>\n", styles: [".engrenagem-ajustada{position:relative;top:-4px}\n"], dependencies: [{ kind: "component", type: NavTabsComponent, selector: "app-nav-tabs", inputs: ["subMenus", "hostName", "activeItem"], outputs: ["onTituloSelecionado", "onTelaSelecionada"] }, { kind: "component", type: LibIconsComponent, selector: "lib-icon", inputs: ["iconName", "iconColor", "iconSize", "iconFill"] }, { kind: "component", type: ContentContainerComponent, selector: "lib-container", inputs: ["documentation", "tabs", "advancedTabs", "containerTitle", "useBorder", "currentTab"], outputs: ["onChangeTab"] }] }); }
|
|
3930
3943
|
}
|
|
3931
3944
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: SubMenuComponent, decorators: [{
|
|
3932
3945
|
type: Component,
|
|
@@ -3934,7 +3947,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
|
|
|
3934
3947
|
NavTabsComponent,
|
|
3935
3948
|
LibIconsComponent,
|
|
3936
3949
|
ContentContainerComponent
|
|
3937
|
-
], standalone: true, template: "<lib-container>\n <div class=\"px-5\" innerContent1>\n @for(subMenu of navSubmenus; track $index) {\n <div [class]=\"$first && subMenu.titulo == '' && subMenu.icon == '' ? ' mb-2' : 'mt-4 mb-2'\">\n @if (subMenu.icon != '') {\n <lib-icon class=\"bold engrenagem-ajustada\" iconName=\"{{ subMenu.icon }}\" />\n }\n @if (subMenu.titulo != ''){\n <span class=\"fw-bold fs-4 ms-1\">{{ subMenu.titulo }}</span>\n }\n\n <app-nav-tabs [activeItem]=\"activeItem\" [subMenus]=\"navSubmenus[$index].subMenuItem\" [hostName]=\"hostNameOutSystems\" />\n </div>\n\n @if(!$last){ <hr /> }\n }\n </div>\n</lib-container>\n", styles: [".engrenagem-ajustada{position:relative;top:-4px}\n"] }]
|
|
3950
|
+
], standalone: true, template: "<lib-container>\n <div class=\"px-5\" innerContent1>\n @for(subMenu of navSubmenus; track $index) {\n <div [class]=\"$first && subMenu.titulo == '' && subMenu.icon == '' ? ' mb-2' : 'mt-4 mb-2'\">\n @if (subMenu.icon != '') {\n <lib-icon class=\"bold engrenagem-ajustada\" iconName=\"{{ subMenu.icon }}\" />\n }\n @if (subMenu.titulo != ''){\n <span class=\"fw-bold fs-4 ms-1\">{{ subMenu.titulo }}</span>\n }\n\n <app-nav-tabs [activeItem]=\"activeItem\" [subMenus]=\"navSubmenus[$index].subMenuItem\" [hostName]=\"hostNameOutSystems\"\n (onTelaSelecionada)=\"onTelaSelecionada.emit($event)\" (onTituloSelecionado)=\"onTituloSelecionado.emit($event)\" />\n </div>\n\n @if(!$last){ <hr /> }\n }\n </div>\n</lib-container>\n", styles: [".engrenagem-ajustada{position:relative;top:-4px}\n"] }]
|
|
3938
3951
|
}], ctorParameters: () => [{ type: MenuServicesService }, { type: ProjectUtilservice }], propDecorators: { navSubmenus: [{
|
|
3939
3952
|
type: Input
|
|
3940
3953
|
}], isProduction: [{
|
|
@@ -3943,6 +3956,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
|
|
|
3943
3956
|
type: Input
|
|
3944
3957
|
}], activeItem: [{
|
|
3945
3958
|
type: Input
|
|
3959
|
+
}], onTituloSelecionado: [{
|
|
3960
|
+
type: Output
|
|
3961
|
+
}], onTelaSelecionada: [{
|
|
3962
|
+
type: Output
|
|
3946
3963
|
}] } });
|
|
3947
3964
|
|
|
3948
3965
|
/** Modules */
|