ichec-angular-core 0.3.5 → 0.3.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ichec-angular-core",
3
- "version": "0.3.5",
3
+ "version": "0.3.7",
4
4
  "exports": {
5
5
  "./styles/": "./styles",
6
6
  "./package.json": {
@@ -1,5 +1,6 @@
1
1
  import * as _angular_forms from '@angular/forms';
2
2
  import { FormGroup, FormControl, FormArray, FormBuilder, AbstractControl } from '@angular/forms';
3
+ import * as ichec_angular_core from 'ichec-angular-core';
3
4
  import { BehaviorSubject, Observable } from 'rxjs';
4
5
  import { HttpClient, HttpParams, HttpHeaders, HttpErrorResponse } from '@angular/common/http';
5
6
  import * as _angular_core from '@angular/core';
@@ -9,7 +10,6 @@ import { Location } from '@angular/common';
9
10
  import { ActivatedRoute } from '@angular/router';
10
11
  import { MatDialog } from '@angular/material/dialog';
11
12
  import { MatTable } from '@angular/material/table';
12
- import * as ichec_angular_core from 'ichec-angular-core';
13
13
  import { MatSort } from '@angular/material/sort';
14
14
  import { MatButtonToggleChange } from '@angular/material/button-toggle';
15
15
  import { DataSource, CollectionViewer, ListRange } from '@angular/cdk/collections';
@@ -240,10 +240,7 @@ interface IFormFieldBase {
240
240
  field_type: string;
241
241
  description: string;
242
242
  default: string;
243
- options: {
244
- key: string;
245
- value: string;
246
- }[] | null;
243
+ options: string | null;
247
244
  }
248
245
  type IFormFieldCreate = IFormFieldBase;
249
246
  interface IFormFieldDetail extends IFormFieldBase {
@@ -351,9 +348,11 @@ interface IServerManifest {
351
348
  declare const REST_SERVICE_CONFIG: InjectionToken<RestServiceConfig>;
352
349
  declare class RestService<D extends Identifiable, L extends Identifiable = D, C = D, U extends Identifiable = D> {
353
350
  manifest: BehaviorSubject<IServerManifest | null>;
351
+ loggedInUser: BehaviorSubject<ichec_angular_core.IPortalMemberList | null>;
354
352
  readonly _url: string;
355
353
  readonly userQuery = "user";
356
354
  config: RestServiceConfig;
355
+ protected document: Document;
357
356
  protected _http: HttpClient;
358
357
  protected cookieService: CookieService;
359
358
  deleteItem(id: number): Observable<void>;
@@ -374,7 +373,7 @@ declare class RestService<D extends Identifiable, L extends Identifiable = D, C
374
373
  private getHeaders;
375
374
  protected get baseUrl(): string;
376
375
  private get mediaUrl();
377
- protected getRequestBase(content_type?: string, params?: HttpParams, file?: string): IRequestBase;
376
+ protected getRequestBase(content_type?: string, params?: HttpParams, file?: string, xhr?: boolean): IRequestBase;
378
377
  handleError(error: HttpErrorResponse): Observable<never>;
379
378
  }
380
379
 
@@ -394,18 +393,20 @@ declare class ResolvedPermission {
394
393
  canView: boolean;
395
394
  canDelete: boolean;
396
395
  }
396
+ interface ILogoutManifest {
397
+ url: string;
398
+ }
397
399
  declare class UserService extends ItemService<IPortalMemberDetail, IPortalMemberList, IPortalMemberCreate> {
398
400
  /**
399
401
  Service to handle IPortalMember via REST and also handle logins.
400
402
  */
401
- loggedInUser: BehaviorSubject<IPortalMemberList | null>;
402
403
  canInvite: _angular_core.WritableSignal<boolean>;
403
- private document;
404
404
  readonly _url: string;
405
405
  typename: string;
406
406
  private permissions;
407
407
  login(next?: string): void;
408
408
  logout(next?: string): void;
409
+ _logout_redirect(manifest: ILogoutManifest): void;
409
410
  canCreate(): boolean;
410
411
  getSelf(): Observable<IPortalMemberDetail | null>;
411
412
  inviteMember(invite: IMemberInvitation): Observable<IMemberInvitation>;
@@ -679,15 +680,6 @@ declare class FileUploadComponent {
679
680
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<FileUploadComponent, "lib-file-upload", never, { "control": { "alias": "control"; "required": true; "isSignal": true; }; "uploadCategory": { "alias": "uploadCategory"; "required": false; "isSignal": true; }; "allowedSizeMb": { "alias": "allowedSizeMb"; "required": false; "isSignal": true; }; "showHeading": { "alias": "showHeading"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
680
681
  }
681
682
 
682
- declare class FormFieldDetailComponent {
683
- readonly field: _angular_core.InputSignal<IFormFieldDetail>;
684
- form: _angular_core.InputSignal<FormGroup<any>>;
685
- get key(): string;
686
- get control(): FormControl<IFileRecord>;
687
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<FormFieldDetailComponent, never>;
688
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<FormFieldDetailComponent, "lib-form-field-detail", never, { "field": { "alias": "field"; "required": true; "isSignal": true; }; "form": { "alias": "form"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
689
- }
690
-
691
683
  interface IOption {
692
684
  key: string;
693
685
  value: string;
@@ -705,6 +697,16 @@ interface IFormFieldForm {
705
697
  id: FormControl<number | null>;
706
698
  }
707
699
 
700
+ declare class FormFieldDetailComponent {
701
+ readonly field: _angular_core.InputSignal<IFormFieldDetail>;
702
+ form: _angular_core.InputSignal<FormGroup<any>>;
703
+ resolveOptions(options: string | null): IOption[];
704
+ get key(): string;
705
+ get control(): FormControl<IFileRecord>;
706
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<FormFieldDetailComponent, never>;
707
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<FormFieldDetailComponent, "lib-form-field-detail", never, { "field": { "alias": "field"; "required": true; "isSignal": true; }; "form": { "alias": "form"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
708
+ }
709
+
708
710
  declare class FormFieldEditComponent {
709
711
  availableTypes: ichec_angular_core.TypeChoice[];
710
712
  readonly FieldType: typeof FieldType;