@abp/ng.theme.shared 7.0.0-rc.5 → 7.0.0
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/esm2020/extensions/lib/components/extensible-form/extensible-form-prop.component.mjs +12 -6
- package/esm2020/extensions/lib/enums/components.mjs +2 -0
- package/esm2020/extensions/lib/enums/props.enum.mjs +1 -1
- package/esm2020/extensions/public-api.mjs +2 -1
- package/esm2020/lib/components/index.mjs +2 -1
- package/esm2020/lib/components/password/password.component.mjs +38 -0
- package/esm2020/lib/handlers/error.handler.mjs +3 -2
- package/esm2020/lib/theme-shared.module.mjs +9 -5
- package/extensions/lib/components/extensible-form/extensible-form-prop.component.d.ts +2 -0
- package/extensions/lib/enums/components.d.ts +3 -0
- package/extensions/lib/enums/props.enum.d.ts +1 -0
- package/extensions/public-api.d.ts +1 -0
- package/fesm2015/abp-ng.theme.shared-extensions.mjs +9 -4
- package/fesm2015/abp-ng.theme.shared-extensions.mjs.map +1 -1
- package/fesm2015/abp-ng.theme.shared.mjs +46 -9
- package/fesm2015/abp-ng.theme.shared.mjs.map +1 -1
- package/fesm2020/abp-ng.theme.shared-extensions.mjs +8 -3
- package/fesm2020/abp-ng.theme.shared-extensions.mjs.map +1 -1
- package/fesm2020/abp-ng.theme.shared.mjs +46 -9
- package/fesm2020/abp-ng.theme.shared.mjs.map +1 -1
- package/lib/components/index.d.ts +1 -0
- package/lib/components/password/password.component.d.ts +12 -0
- package/lib/handlers/error.handler.d.ts +1 -0
- package/lib/theme-shared.module.d.ts +12 -11
- package/package.json +7 -4
|
@@ -1,21 +1,23 @@
|
|
|
1
1
|
import { animation, style, animate, keyframes, trigger, state, transition, useAnimation, query } from '@angular/animations';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { Component, Input, ChangeDetectionStrategy, EventEmitter, Output, ViewChild, InjectionToken, Inject, ViewEncapsulation, Injectable, Optional, ContentChild, Directive, HostListener, HostBinding, NgModule, ComponentFactoryResolver, RendererFactory2, ApplicationRef, APP_INITIALIZER, inject, LOCALE_ID } from '@angular/core';
|
|
3
|
+
import { Component, Input, ChangeDetectionStrategy, EventEmitter, Output, ViewChild, InjectionToken, Inject, ViewEncapsulation, Injectable, Optional, ContentChild, Directive, HostListener, forwardRef, HostBinding, NgModule, ComponentFactoryResolver, RendererFactory2, ApplicationRef, APP_INITIALIZER, inject, LOCALE_ID } from '@angular/core';
|
|
4
4
|
import * as i1 from '@angular/common';
|
|
5
5
|
import { DOCUMENT, formatDate, DatePipe } from '@angular/common';
|
|
6
6
|
import * as i1$1 from '@angular/router';
|
|
7
7
|
import { ResolveEnd } from '@angular/router';
|
|
8
8
|
import * as i2 from '@abp/ng.core';
|
|
9
|
-
import { getRoutePath, SubscriptionService, PROJECTION_STRATEGY, uuid, LocalizationService, getLocaleDirection, HttpErrorReporterService, RouterEvents, AuthService, RoutesService, InternalStore, DomInsertionService, CONTENT_STRATEGY, CoreModule, noop, ConfigStateService } from '@abp/ng.core';
|
|
9
|
+
import { getRoutePath, SubscriptionService, PROJECTION_STRATEGY, uuid, AbstractNgModelComponent, LocalizationService, getLocaleDirection, HttpErrorReporterService, RouterEvents, AuthService, RoutesService, InternalStore, DomInsertionService, CONTENT_STRATEGY, CoreModule, noop, ConfigStateService } from '@abp/ng.core';
|
|
10
10
|
import { startWith, map, debounceTime, filter, takeUntil, distinctUntilChanged, take, catchError, switchMap } from 'rxjs/operators';
|
|
11
11
|
import { fromEvent, Subscription, combineLatest, timer, ReplaySubject, Subject, BehaviorSubject, throwError, Observable, of } from 'rxjs';
|
|
12
12
|
import * as i3 from '@ng-bootstrap/ng-bootstrap';
|
|
13
13
|
import { NgbInputDatepickerConfig, NgbTypeaheadConfig, NgbDateParserFormatter, NgbPaginationModule } from '@ng-bootstrap/ng-bootstrap';
|
|
14
|
+
import * as i2$1 from '@angular/forms';
|
|
15
|
+
import { NG_VALUE_ACCESSOR, Validators } from '@angular/forms';
|
|
16
|
+
import * as i3$1 from '@ngx-validate/core';
|
|
17
|
+
import { NgxValidateCoreModule, VALIDATION_BLUEPRINTS, VALIDATION_MAP_ERRORS_FN, defaultMapErrorsFn, VALIDATION_VALIDATE_ON_SUBMIT, normalizeDiacritics } from '@ngx-validate/core';
|
|
14
18
|
import * as i1$2 from '@swimlane/ngx-datatable';
|
|
15
19
|
import { ColumnMode, NgxDatatableModule } from '@swimlane/ngx-datatable';
|
|
16
20
|
import { HttpErrorResponse } from '@angular/common/http';
|
|
17
|
-
import { NgxValidateCoreModule, VALIDATION_BLUEPRINTS, VALIDATION_MAP_ERRORS_FN, defaultMapErrorsFn, VALIDATION_VALIDATE_ON_SUBMIT, normalizeDiacritics } from '@ngx-validate/core';
|
|
18
|
-
import { Validators } from '@angular/forms';
|
|
19
21
|
|
|
20
22
|
const bounceIn = animation([
|
|
21
23
|
style({ opacity: '0', display: '{{ display }}' }),
|
|
@@ -901,6 +903,37 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
901
903
|
type: Input
|
|
902
904
|
}] } });
|
|
903
905
|
|
|
906
|
+
class PasswordComponent extends AbstractNgModelComponent {
|
|
907
|
+
constructor(injector) {
|
|
908
|
+
super(injector);
|
|
909
|
+
}
|
|
910
|
+
toggleFieldTextType() {
|
|
911
|
+
this.fieldTextType = !this.fieldTextType;
|
|
912
|
+
}
|
|
913
|
+
}
|
|
914
|
+
PasswordComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: PasswordComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
915
|
+
PasswordComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: PasswordComponent, selector: "abp-password", inputs: { inputId: "inputId", formControlName: "formControlName" }, providers: [
|
|
916
|
+
{
|
|
917
|
+
provide: NG_VALUE_ACCESSOR,
|
|
918
|
+
useExisting: forwardRef(() => PasswordComponent),
|
|
919
|
+
multi: true,
|
|
920
|
+
},
|
|
921
|
+
], usesInheritance: true, ngImport: i0, template: "<div class=\"input-group\" validationTarget>\r\n <input\r\n [type]=\"fieldTextType ? 'text' : 'password'\"\r\n class=\"form-control\"\r\n [id]=\"inputId\"\r\n [(ngModel)]=\"value\"\r\n />\r\n\r\n <button class=\"btn btn-secondary\" type=\"button\" (click)=\"toggleFieldTextType()\">\r\n <i\r\n class=\"fa\"\r\n [ngClass]=\"{\r\n 'fa-eye-slash': !fieldTextType,\r\n 'fa-eye': fieldTextType\r\n }\"\r\n ></i>\r\n </button>\r\n</div>\r\n", dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i3$1.ValidationTargetDirective, selector: "[validationTarget]", exportAs: ["validationTarget"] }] });
|
|
922
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: PasswordComponent, decorators: [{
|
|
923
|
+
type: Component,
|
|
924
|
+
args: [{ selector: 'abp-password', providers: [
|
|
925
|
+
{
|
|
926
|
+
provide: NG_VALUE_ACCESSOR,
|
|
927
|
+
useExisting: forwardRef(() => PasswordComponent),
|
|
928
|
+
multi: true,
|
|
929
|
+
},
|
|
930
|
+
], template: "<div class=\"input-group\" validationTarget>\r\n <input\r\n [type]=\"fieldTextType ? 'text' : 'password'\"\r\n class=\"form-control\"\r\n [id]=\"inputId\"\r\n [(ngModel)]=\"value\"\r\n />\r\n\r\n <button class=\"btn btn-secondary\" type=\"button\" (click)=\"toggleFieldTextType()\">\r\n <i\r\n class=\"fa\"\r\n [ngClass]=\"{\r\n 'fa-eye-slash': !fieldTextType,\r\n 'fa-eye': fieldTextType\r\n }\"\r\n ></i>\r\n </button>\r\n</div>\r\n" }]
|
|
931
|
+
}], ctorParameters: function () { return [{ type: i0.Injector }]; }, propDecorators: { inputId: [{
|
|
932
|
+
type: Input
|
|
933
|
+
}], formControlName: [{
|
|
934
|
+
type: Input
|
|
935
|
+
}] } });
|
|
936
|
+
|
|
904
937
|
const DEFAULT_VALIDATION_BLUEPRINTS = {
|
|
905
938
|
creditCard: 'AbpValidation::ThisFieldIsNotAValidCreditCardNumber.',
|
|
906
939
|
email: 'AbpValidation::ThisFieldIsNotAValidEmailAddress.',
|
|
@@ -1339,6 +1372,7 @@ class ErrorHandler {
|
|
|
1339
1372
|
this.cfRes = injector.get(ComponentFactoryResolver);
|
|
1340
1373
|
this.rendererFactory = injector.get(RendererFactory2);
|
|
1341
1374
|
this.httpErrorConfig = injector.get('HTTP_ERROR_CONFIG');
|
|
1375
|
+
this.authService = this.injector.get(AuthService);
|
|
1342
1376
|
this.listenToRestError();
|
|
1343
1377
|
this.listenToRouterError();
|
|
1344
1378
|
this.listenToRouterDataResolved();
|
|
@@ -1498,7 +1532,7 @@ class ErrorHandler {
|
|
|
1498
1532
|
});
|
|
1499
1533
|
}
|
|
1500
1534
|
navigateToLogin() {
|
|
1501
|
-
this.
|
|
1535
|
+
this.authService.navigateToLogin();
|
|
1502
1536
|
}
|
|
1503
1537
|
createErrorComponent(instance) {
|
|
1504
1538
|
const renderer = this.rendererFactory.createRenderer(null, null);
|
|
@@ -2037,6 +2071,7 @@ const declarationsWithExports = [
|
|
|
2037
2071
|
ModalComponent,
|
|
2038
2072
|
ToastComponent,
|
|
2039
2073
|
ToastContainerComponent,
|
|
2074
|
+
PasswordComponent,
|
|
2040
2075
|
NgxDatatableDefaultDirective,
|
|
2041
2076
|
NgxDatatableListDirective,
|
|
2042
2077
|
LoadingDirective,
|
|
@@ -2054,6 +2089,7 @@ BaseThemeSharedModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", v
|
|
|
2054
2089
|
ModalComponent,
|
|
2055
2090
|
ToastComponent,
|
|
2056
2091
|
ToastContainerComponent,
|
|
2092
|
+
PasswordComponent,
|
|
2057
2093
|
NgxDatatableDefaultDirective,
|
|
2058
2094
|
NgxDatatableListDirective,
|
|
2059
2095
|
LoadingDirective,
|
|
@@ -2061,7 +2097,7 @@ BaseThemeSharedModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", v
|
|
|
2061
2097
|
NgxDatatableModule,
|
|
2062
2098
|
NgxValidateCoreModule,
|
|
2063
2099
|
NgbPaginationModule,
|
|
2064
|
-
EllipsisModule], exports: [NgxDatatableModule, EllipsisModule, BreadcrumbComponent,
|
|
2100
|
+
EllipsisModule], exports: [NgxDatatableModule, EllipsisModule, NgxValidateCoreModule, BreadcrumbComponent,
|
|
2065
2101
|
BreadcrumbItemsComponent,
|
|
2066
2102
|
ButtonComponent,
|
|
2067
2103
|
ConfirmationComponent,
|
|
@@ -2070,6 +2106,7 @@ BaseThemeSharedModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", v
|
|
|
2070
2106
|
ModalComponent,
|
|
2071
2107
|
ToastComponent,
|
|
2072
2108
|
ToastContainerComponent,
|
|
2109
|
+
PasswordComponent,
|
|
2073
2110
|
NgxDatatableDefaultDirective,
|
|
2074
2111
|
NgxDatatableListDirective,
|
|
2075
2112
|
LoadingDirective,
|
|
@@ -2078,7 +2115,7 @@ BaseThemeSharedModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", v
|
|
|
2078
2115
|
NgxDatatableModule,
|
|
2079
2116
|
NgxValidateCoreModule,
|
|
2080
2117
|
NgbPaginationModule,
|
|
2081
|
-
EllipsisModule, NgxDatatableModule, EllipsisModule] });
|
|
2118
|
+
EllipsisModule, NgxDatatableModule, EllipsisModule, NgxValidateCoreModule] });
|
|
2082
2119
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: BaseThemeSharedModule, decorators: [{
|
|
2083
2120
|
type: NgModule,
|
|
2084
2121
|
args: [{
|
|
@@ -2090,7 +2127,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
2090
2127
|
EllipsisModule,
|
|
2091
2128
|
],
|
|
2092
2129
|
declarations: [...declarationsWithExports, HttpErrorWrapperComponent],
|
|
2093
|
-
exports: [NgxDatatableModule, EllipsisModule, ...declarationsWithExports],
|
|
2130
|
+
exports: [NgxDatatableModule, EllipsisModule, NgxValidateCoreModule, ...declarationsWithExports],
|
|
2094
2131
|
providers: [DatePipe],
|
|
2095
2132
|
}]
|
|
2096
2133
|
}] });
|
|
@@ -2231,5 +2268,5 @@ function validatePassword(shouldContain) {
|
|
|
2231
2268
|
* Generated bundle index. Do not edit.
|
|
2232
2269
|
*/
|
|
2233
2270
|
|
|
2234
|
-
export { BaseThemeSharedModule, BreadcrumbComponent, BreadcrumbItemsComponent, ButtonComponent, Confirmation, ConfirmationComponent, ConfirmationService, DEFAULT_ERROR_LOCALIZATIONS, DEFAULT_ERROR_MESSAGES, DEFAULT_VALIDATION_BLUEPRINTS, DateParserFormatter, DocumentDirHandlerService, EllipsisDirective, EllipsisModule, ErrorHandler, HTTP_ERROR_CONFIG, HTTP_ERROR_HANDLER, HttpErrorWrapperComponent, LoaderBarComponent, LoadingComponent, LoadingDirective, ModalCloseDirective, ModalComponent, ModalRefService, NGX_DATATABLE_MESSAGES, NG_BOOTSTRAP_CONFIG_PROVIDERS, NavItem, NavItemsService, NgxDatatableDefaultDirective, NgxDatatableListDirective, PageAlertService, SUPPRESS_UNSAVED_CHANGES_WARNING, THEME_SHARED_APPEND_CONTENT, THEME_SHARED_ROUTE_PROVIDERS, ThemeSharedModule, ToastComponent, ToastContainerComponent, ToasterService, UserMenu, UserMenuService, bounceIn, collapse, collapseLinearWithMargin, collapseWithMargin, collapseX, collapseY, collapseYWithMargin, configureNgBootstrap, configureRoutes, defaultNgxDatatableMessages, dialogAnimation, expandX, expandY, expandYWithMargin, fadeAnimation, fadeIn, fadeInDown, fadeInLeft, fadeInRight, fadeInUp, fadeOut, fadeOutDown, fadeOutLeft, fadeOutRight, fadeOutUp, getPasswordValidators, httpErrorConfigFactory, slideFromBottom, toastInOut, validatePassword };
|
|
2271
|
+
export { BaseThemeSharedModule, BreadcrumbComponent, BreadcrumbItemsComponent, ButtonComponent, Confirmation, ConfirmationComponent, ConfirmationService, DEFAULT_ERROR_LOCALIZATIONS, DEFAULT_ERROR_MESSAGES, DEFAULT_VALIDATION_BLUEPRINTS, DateParserFormatter, DocumentDirHandlerService, EllipsisDirective, EllipsisModule, ErrorHandler, HTTP_ERROR_CONFIG, HTTP_ERROR_HANDLER, HttpErrorWrapperComponent, LoaderBarComponent, LoadingComponent, LoadingDirective, ModalCloseDirective, ModalComponent, ModalRefService, NGX_DATATABLE_MESSAGES, NG_BOOTSTRAP_CONFIG_PROVIDERS, NavItem, NavItemsService, NgxDatatableDefaultDirective, NgxDatatableListDirective, PageAlertService, PasswordComponent, SUPPRESS_UNSAVED_CHANGES_WARNING, THEME_SHARED_APPEND_CONTENT, THEME_SHARED_ROUTE_PROVIDERS, ThemeSharedModule, ToastComponent, ToastContainerComponent, ToasterService, UserMenu, UserMenuService, bounceIn, collapse, collapseLinearWithMargin, collapseWithMargin, collapseX, collapseY, collapseYWithMargin, configureNgBootstrap, configureRoutes, defaultNgxDatatableMessages, dialogAnimation, expandX, expandY, expandYWithMargin, fadeAnimation, fadeIn, fadeInDown, fadeInLeft, fadeInRight, fadeInUp, fadeOut, fadeOutDown, fadeOutLeft, fadeOutRight, fadeOutUp, getPasswordValidators, httpErrorConfigFactory, slideFromBottom, toastInOut, validatePassword };
|
|
2235
2272
|
//# sourceMappingURL=abp-ng.theme.shared.mjs.map
|