ichec-angular-core 0.3.1 → 0.3.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/ichec-angular-core.mjs +305 -146
- package/fesm2022/ichec-angular-core.mjs.map +1 -1
- package/package.json +1 -1
- package/styles/styles.scss +25 -22
- package/types/ichec-angular-core.d.ts +62 -22
package/package.json
CHANGED
package/styles/styles.scss
CHANGED
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
|
|
4
4
|
.content-container {
|
|
5
5
|
display: flex;
|
|
6
|
-
padding:
|
|
6
|
+
padding-left: 5px;
|
|
7
|
+
padding-right: 5px;
|
|
7
8
|
flex-direction: column;
|
|
8
9
|
justify-content: center;
|
|
9
10
|
align-items: center;
|
|
@@ -23,31 +24,24 @@
|
|
|
23
24
|
align-items: center;
|
|
24
25
|
flex-direction: column;
|
|
25
26
|
padding: 5px;
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
.item-detail-heading {
|
|
29
|
-
width:100%;
|
|
30
|
-
max-width:500px
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
.item-detail-header{
|
|
34
|
-
display: inline;
|
|
35
|
-
width: 100%;
|
|
36
|
-
max-width: 100px;
|
|
27
|
+
width: 100%;
|
|
37
28
|
}
|
|
38
29
|
|
|
39
30
|
.item-edit-container {
|
|
40
31
|
display: flex;
|
|
41
|
-
justify-content: left;
|
|
42
|
-
align-items: left;
|
|
43
32
|
flex-direction: column;
|
|
44
33
|
width:100%;
|
|
45
34
|
max-width:800px;
|
|
35
|
+
justify-content: left;
|
|
36
|
+
align-items: center;
|
|
37
|
+
text-align: center;
|
|
46
38
|
}
|
|
47
39
|
|
|
48
40
|
.item-edit-header {
|
|
49
41
|
display: inline;
|
|
50
42
|
width: 100%;
|
|
43
|
+
margin-top: 5px;
|
|
44
|
+
margin-bottom: 5px;
|
|
51
45
|
}
|
|
52
46
|
|
|
53
47
|
.item-field{
|
|
@@ -68,6 +62,7 @@
|
|
|
68
62
|
|
|
69
63
|
.image-holder {
|
|
70
64
|
display: flex;
|
|
65
|
+
flex-direction: column;
|
|
71
66
|
justify-content: center;
|
|
72
67
|
align-items: center;
|
|
73
68
|
overflow: hidden;
|
|
@@ -75,7 +70,13 @@
|
|
|
75
70
|
}
|
|
76
71
|
|
|
77
72
|
.button-container{
|
|
78
|
-
|
|
73
|
+
margin: 5px;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.button-group{
|
|
77
|
+
margin:5px;
|
|
78
|
+
display: flex;
|
|
79
|
+
flex-direction: row;
|
|
79
80
|
}
|
|
80
81
|
|
|
81
82
|
.form-card{
|
|
@@ -83,6 +84,15 @@
|
|
|
83
84
|
align-items: center;
|
|
84
85
|
flex-direction: column;
|
|
85
86
|
display: flex;
|
|
87
|
+
width: 100%;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.form-card-left{
|
|
91
|
+
justify-content:center;
|
|
92
|
+
align-items: left;
|
|
93
|
+
flex-direction: column;
|
|
94
|
+
display: flex;
|
|
95
|
+
width: 100%;
|
|
86
96
|
}
|
|
87
97
|
|
|
88
98
|
.form-field{
|
|
@@ -98,13 +108,6 @@
|
|
|
98
108
|
margin: 5px;
|
|
99
109
|
}
|
|
100
110
|
|
|
101
|
-
.button-group{
|
|
102
|
-
margin:10px;
|
|
103
|
-
display: flex;
|
|
104
|
-
flex-direction: row;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
|
|
108
111
|
|
|
109
112
|
|
|
110
113
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FormGroup, FormControl, FormArray, FormBuilder, AbstractControl } from '@angular/forms';
|
|
2
|
-
import {
|
|
2
|
+
import { BehaviorSubject, Observable } from 'rxjs';
|
|
3
3
|
import { HttpClient, HttpParams, HttpHeaders, HttpErrorResponse } from '@angular/common/http';
|
|
4
4
|
import * as _angular_core from '@angular/core';
|
|
5
5
|
import { InjectionToken, OnInit, TemplateRef, AfterViewInit } from '@angular/core';
|
|
@@ -318,13 +318,14 @@ interface IServerManifest {
|
|
|
318
318
|
}
|
|
319
319
|
declare const REST_SERVICE_CONFIG: InjectionToken<RestServiceConfig>;
|
|
320
320
|
declare class RestService<D extends Identifiable, L extends Identifiable = D, C = D, U extends Identifiable = D> {
|
|
321
|
-
manifest: IServerManifest
|
|
321
|
+
manifest: BehaviorSubject<IServerManifest | null>;
|
|
322
322
|
readonly _url: string;
|
|
323
323
|
config: RestServiceConfig;
|
|
324
324
|
protected _http: HttpClient;
|
|
325
325
|
protected cookieService: CookieService;
|
|
326
326
|
deleteItem(id: number): Observable<void>;
|
|
327
327
|
getForUser(user: IPortalMemberDetail, query?: IItemQuery): Observable<IPaginated<L>>;
|
|
328
|
+
protected _getServiceManifest(): Observable<IServerManifest>;
|
|
328
329
|
get(query?: IItemQuery): Observable<IPaginated<L>>;
|
|
329
330
|
getItem(id: number): Observable<D>;
|
|
330
331
|
getUrl(url: string): Observable<D>;
|
|
@@ -374,7 +375,6 @@ declare class UserService extends ItemService<IPortalMemberDetail, IPortalMember
|
|
|
374
375
|
getSelf(): Observable<IPortalMemberDetail | null>;
|
|
375
376
|
private _getSelf;
|
|
376
377
|
private _selfFetchFailed;
|
|
377
|
-
private _getServiceManifest;
|
|
378
378
|
private _do_login;
|
|
379
379
|
hasAddPermission(feature: string): boolean;
|
|
380
380
|
hasDeletePermission(feature: string): boolean;
|
|
@@ -424,20 +424,27 @@ declare class FormService {
|
|
|
424
424
|
interface NavOption {
|
|
425
425
|
name: string;
|
|
426
426
|
route: string;
|
|
427
|
+
icon: string;
|
|
427
428
|
}
|
|
428
|
-
interface
|
|
429
|
+
interface NavGrouping {
|
|
429
430
|
name: string;
|
|
430
431
|
options: NavOption[];
|
|
431
432
|
}
|
|
433
|
+
interface NavGroup {
|
|
434
|
+
name: string;
|
|
435
|
+
groupings: NavGrouping[];
|
|
436
|
+
}
|
|
432
437
|
declare class LeftNavService {
|
|
433
|
-
|
|
438
|
+
activeGroupings: _angular_core.WritableSignal<Set<NavGrouping>>;
|
|
439
|
+
wide: _angular_core.WritableSignal<boolean>;
|
|
440
|
+
private _defaultGroupings;
|
|
434
441
|
private _groups;
|
|
435
|
-
private _defaultOptions;
|
|
436
442
|
private _groupService;
|
|
437
443
|
constructor();
|
|
438
444
|
onGroupsUpdated(groups: IGroupList[]): void;
|
|
439
|
-
|
|
445
|
+
setDefaultGroupings(groupings: NavGrouping[]): void;
|
|
440
446
|
setGroups(groups: NavGroup[]): void;
|
|
447
|
+
toggle(): void;
|
|
441
448
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LeftNavService, never>;
|
|
442
449
|
static ɵprov: _angular_core.ɵɵInjectableDeclaration<LeftNavService>;
|
|
443
450
|
}
|
|
@@ -565,6 +572,7 @@ declare class SelectTableComponent<T extends Identifiable> implements OnInit {
|
|
|
565
572
|
|
|
566
573
|
declare abstract class SelectionManager<D extends Identifiable, L extends Identifiable = D, C = D, U extends Identifiable = D> {
|
|
567
574
|
candidates: _angular_core.WritableSignal<Selectable<L>[]>;
|
|
575
|
+
dirty: _angular_core.WritableSignal<boolean>;
|
|
568
576
|
selected: _angular_core.WritableSignal<L[]>;
|
|
569
577
|
columns: TableColumn[];
|
|
570
578
|
itemService: ItemService<D, L, C, U>;
|
|
@@ -653,16 +661,21 @@ interface IFormFieldForm {
|
|
|
653
661
|
declare class FormFieldEditComponent {
|
|
654
662
|
availableTypes: ichec_angular_core.TypeChoice[];
|
|
655
663
|
readonly FieldType: typeof FieldType;
|
|
664
|
+
readonly deleteDialog: MatDialog;
|
|
656
665
|
form: _angular_core.InputSignal<FormGroup<IFormFieldForm>>;
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
666
|
+
canOrderUp: _angular_core.InputSignal<boolean>;
|
|
667
|
+
canOrderDown: _angular_core.InputSignal<boolean>;
|
|
668
|
+
orderUp: _angular_core.OutputEmitterRef<void>;
|
|
669
|
+
orderDown: _angular_core.OutputEmitterRef<void>;
|
|
670
|
+
deleted: _angular_core.OutputEmitterRef<void>;
|
|
660
671
|
get templateControl(): FormControl<IFileRecord>;
|
|
661
672
|
get fieldType(): FieldType;
|
|
662
|
-
|
|
663
|
-
|
|
673
|
+
onOrderUp(): void;
|
|
674
|
+
onOrderDown(): void;
|
|
675
|
+
onDelete(): void;
|
|
676
|
+
onDeleteClicked(): void;
|
|
664
677
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<FormFieldEditComponent, never>;
|
|
665
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<FormFieldEditComponent, "lib-form-field-edit", never, { "form": { "alias": "form"; "required": true; "isSignal": true; }; "
|
|
678
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<FormFieldEditComponent, "lib-form-field-edit", never, { "form": { "alias": "form"; "required": true; "isSignal": true; }; "canOrderUp": { "alias": "canOrderUp"; "required": false; "isSignal": true; }; "canOrderDown": { "alias": "canOrderDown"; "required": false; "isSignal": true; }; }, { "orderUp": "orderUp"; "orderDown": "orderDown"; "deleted": "deleted"; }, never, never, true, never>;
|
|
666
679
|
}
|
|
667
680
|
|
|
668
681
|
interface IFormGroupForm {
|
|
@@ -681,6 +694,7 @@ declare class DynamicFormForm {
|
|
|
681
694
|
form: FormGroup<IDynamicFormForm>;
|
|
682
695
|
constructor();
|
|
683
696
|
get groups(): FormArray<FormGroup<IFormGroupForm>>;
|
|
697
|
+
groupSize(id: number): number;
|
|
684
698
|
getFileFields(form: IFormDetail): IFileField[];
|
|
685
699
|
orderUp(id: number): void;
|
|
686
700
|
orderDown(id: number): void;
|
|
@@ -736,21 +750,44 @@ declare class DynamicFormComponent {
|
|
|
736
750
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<DynamicFormComponent, "lib-dynamic-form", never, { "inputForm": { "alias": "inputForm"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
737
751
|
}
|
|
738
752
|
|
|
753
|
+
interface IActiveGroup {
|
|
754
|
+
index: number;
|
|
755
|
+
group: FormGroup<IFormGroupForm>;
|
|
756
|
+
}
|
|
757
|
+
interface IActiveField {
|
|
758
|
+
index: number;
|
|
759
|
+
group_index: number;
|
|
760
|
+
field: FormGroup<IFormFieldForm>;
|
|
761
|
+
}
|
|
739
762
|
declare class DynamicFormBuilderComponent {
|
|
740
763
|
form: _angular_core.InputSignal<DynamicFormForm>;
|
|
741
764
|
handleSubmit: _angular_core.InputSignal<boolean>;
|
|
742
765
|
submitted: _angular_core.OutputEmitterRef<void>;
|
|
743
766
|
dirty: _angular_core.WritableSignal<boolean>;
|
|
767
|
+
activeGroup: _angular_core.WritableSignal<IActiveGroup | null>;
|
|
768
|
+
activeField: _angular_core.WritableSignal<IActiveField | null>;
|
|
744
769
|
fb: FormBuilder;
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
770
|
+
onGroupClick(index: number, group: FormGroup<IFormGroupForm>): void;
|
|
771
|
+
onFieldClick(index: number, group_index: number, field: FormGroup<IFormFieldForm>): void;
|
|
772
|
+
protected getFields(group: FormGroup<IFormGroupForm>): FormArray<FormGroup<IFormFieldForm>>;
|
|
773
|
+
isGroupSelected(id: number): boolean;
|
|
774
|
+
isFieldSelected(group_id: number, id: number): boolean;
|
|
775
|
+
getGroupLabel(control: AbstractControl): string;
|
|
776
|
+
getFieldLabel(control: AbstractControl): string;
|
|
777
|
+
allowOrderUp(): boolean;
|
|
778
|
+
allowOrderDown(): boolean;
|
|
779
|
+
allowGroupOrderUp(): boolean;
|
|
780
|
+
allowGroupOrderDown(): boolean;
|
|
751
781
|
onOrderUp(id: number): void;
|
|
752
782
|
onOrderDown(id: number): void;
|
|
753
|
-
|
|
783
|
+
addGroup(): void;
|
|
784
|
+
addField(group: FormGroup<IFormGroupForm>): void;
|
|
785
|
+
deleteGroup(id: number): void;
|
|
786
|
+
deleteField(): void;
|
|
787
|
+
onFieldOrderUp(): void;
|
|
788
|
+
onFieldOrderDown(): void;
|
|
789
|
+
onGroupOrderUp(): void;
|
|
790
|
+
onGroupOrderDown(): void;
|
|
754
791
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<DynamicFormBuilderComponent, never>;
|
|
755
792
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<DynamicFormBuilderComponent, "lib-dynamic-form-builder", never, { "form": { "alias": "form"; "required": true; "isSignal": true; }; "handleSubmit": { "alias": "handleSubmit"; "required": false; "isSignal": true; }; }, { "submitted": "submitted"; }, never, never, true, never>;
|
|
756
793
|
}
|
|
@@ -854,6 +891,7 @@ declare class TopBarComponent {
|
|
|
854
891
|
readonly user: _angular_core.WritableSignal<ichec_angular_core.IPortalMemberList | null>;
|
|
855
892
|
readonly loginRoute: _angular_core.InputSignal<string>;
|
|
856
893
|
private userService;
|
|
894
|
+
protected leftNavService: LeftNavService;
|
|
857
895
|
constructor();
|
|
858
896
|
onLogout(): void;
|
|
859
897
|
onLogin(): void;
|
|
@@ -866,11 +904,12 @@ declare class TopBarComponent {
|
|
|
866
904
|
declare class LeftNavComponent {
|
|
867
905
|
readonly background: _angular_core.InputSignal<string | undefined>;
|
|
868
906
|
user: _angular_core.WritableSignal<ichec_angular_core.IPortalMemberList | null>;
|
|
907
|
+
width: _angular_core.Signal<"200px" | "100px">;
|
|
869
908
|
protected userService: UserService;
|
|
870
909
|
protected leftNavService: LeftNavService;
|
|
871
910
|
sideNavContent: _angular_core.Signal<MatSidenavContent | undefined>;
|
|
872
911
|
constructor();
|
|
873
|
-
|
|
912
|
+
getGroupings(): _angular_core.WritableSignal<Set<ichec_angular_core.NavGrouping>>;
|
|
874
913
|
get backgroundStyle(): string;
|
|
875
914
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LeftNavComponent, never>;
|
|
876
915
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LeftNavComponent, "lib-left-nav", never, { "background": { "alias": "background"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
@@ -982,6 +1021,7 @@ declare class OrganizationEditComponent extends EditView<IOrganizationDetail, IO
|
|
|
982
1021
|
constructor();
|
|
983
1022
|
ngOnInit(): void;
|
|
984
1023
|
addressForm(): FormGroup<IAddressForm>;
|
|
1024
|
+
get showSubmit(): boolean;
|
|
985
1025
|
createItem(): IOrganizationCreate;
|
|
986
1026
|
protected updateItem(item: IOrganizationDetail): IOrganizationDetail;
|
|
987
1027
|
onItemAndUserAvailable(item: IOrganizationDetail, _: IPortalMemberDetail): void;
|
|
@@ -990,4 +1030,4 @@ declare class OrganizationEditComponent extends EditView<IOrganizationDetail, IO
|
|
|
990
1030
|
}
|
|
991
1031
|
|
|
992
1032
|
export { Address, AddressDetailComponent, AddressEditComponent, AddressForm, AddressService, ApiError, AvatarComponent, BackButtonComponent, DetailHeaderComponent, DetailView, DynamicFormBuilderComponent, DynamicFormComponent, DynamicFormForm, EditView, ErrorCode, FORM_FIELD_CHOICES, FeedbackComponent, FieldType, FileRecord, FileUploadComponent, FormFieldDetailComponent, FormFieldEditComponent, FormFieldValueForm, FormService, Group, GroupComponent, GroupDetailComponent, GroupService, ItemQuery, ItemService, ItemWithUserService, LeftNavComponent, LeftNavService, ListTableViewComponent, ListViewComponent, MemberSelectionManager, MockItemService, Organization, OrganizationComponent, OrganizationDetailComponent, OrganizationEditComponent, OrganizationService, Paginated, Permission, PopulatedFormComponent, PopulatedFormForm, PortalMember, REST_SERVICE_CONFIG, ResolvedPermission, RestService, SearchBarComponent, SelectTableComponent, SelectionManager, TopBarComponent, UserComponent, UserDetailComponent, UserEditComponent, UserService, getFieldTypeFromKey, getFileFieldIds };
|
|
993
|
-
export type { IAddressBase, IAddressCreate, IAddressDetail, IAddressForm, IAddressList, ICountry, IDynamicFormForm, IFieldFile, IFileField, IFileRecord, IForm, IFormCreate, IFormDetail, IFormFieldBase, IFormFieldCreate, IFormFieldDetail, IFormFieldValueBase, IFormFieldValueCreate, IFormFieldValueDetail, IFormFieldValueForm, IFormFieldValueUpdate, IFormGroupBase, IFormGroupCreate, IFormGroupDetail, IFormGroupUpdate, IFormUpdate, IGroupBase, IGroupCreate, IGroupDetail, IGroupList, IItemQuery, IMemberIdentifierBase, IMemberIdentifierCreate, IMemberIdentifierDetail, IOrganizationBase, IOrganizationCreate, IOrganizationDetail, IOrganizationList, IPaginated, IPermission, IPopulatedFormCreate, IPopulatedFormDetail, IPopulatedFormForm, IPopulatedFormUpdate, IPortalMemberBase, IPortalMemberCreate, IPortalMemberDetail, IPortalMemberList, IRestOptions, IServerManifest, Identifiable, LeftNavCategory, LeftNavOption, NavGroup, NavOption, OptionAction, OptionActionChoice, RestServiceConfig, Selectable, TableColumn, TypeChoice };
|
|
1033
|
+
export type { IAddressBase, IAddressCreate, IAddressDetail, IAddressForm, IAddressList, ICountry, IDynamicFormForm, IFieldFile, IFileField, IFileRecord, IForm, IFormCreate, IFormDetail, IFormFieldBase, IFormFieldCreate, IFormFieldDetail, IFormFieldValueBase, IFormFieldValueCreate, IFormFieldValueDetail, IFormFieldValueForm, IFormFieldValueUpdate, IFormGroupBase, IFormGroupCreate, IFormGroupDetail, IFormGroupUpdate, IFormUpdate, IGroupBase, IGroupCreate, IGroupDetail, IGroupList, IItemQuery, IMemberIdentifierBase, IMemberIdentifierCreate, IMemberIdentifierDetail, IOrganizationBase, IOrganizationCreate, IOrganizationDetail, IOrganizationList, IPaginated, IPermission, IPopulatedFormCreate, IPopulatedFormDetail, IPopulatedFormForm, IPopulatedFormUpdate, IPortalMemberBase, IPortalMemberCreate, IPortalMemberDetail, IPortalMemberList, IRestOptions, IServerManifest, Identifiable, LeftNavCategory, LeftNavOption, NavGroup, NavGrouping, NavOption, OptionAction, OptionActionChoice, RestServiceConfig, Selectable, TableColumn, TypeChoice };
|