@smartbit4all/ng-client 1.1.34 → 1.1.36

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.
@@ -5,6 +5,7 @@ import { SmarttreeGenericService } from '@smartbit4all/tree';
5
5
  import { Subject } from 'rxjs';
6
6
  import { ComponentModel, SmartViewContextService, UiAction, UiActionAdditionalParams, UiActionDescriptorService, UiActionModel, UiActionRequest, UiActionService, UiActionSpecificDemandResponse, UseUiAction } from '../view-context/projects';
7
7
  import { SmartAuthenticationServiceInterface } from './smart-authentication.service';
8
+ import { SmartComponentLayoutDefinition } from './smart-component-layout/smart-component-layout.model';
8
9
  export declare abstract class SmartComponentApiClient<T> implements UseUiAction {
9
10
  protected inject: Injector;
10
11
  protected auth: SmartAuthenticationServiceInterface;
@@ -25,6 +26,7 @@ export declare abstract class SmartComponentApiClient<T> implements UseUiAction
25
26
  dataChanged: Subject<void>;
26
27
  submit: Subject<void>;
27
28
  reSubscribeToChange: Subject<void>;
29
+ smartComponentLayoutDefinition?: SmartComponentLayoutDefinition;
28
30
  smartGrid?: SmartGrid;
29
31
  protected viewContext: SmartViewContextService;
30
32
  protected uiActionService: UiActionService;
@@ -46,6 +48,8 @@ export declare abstract class SmartComponentApiClient<T> implements UseUiAction
46
48
  getModel(): T | undefined;
47
49
  performUiActionRequest(uiActionRequest: UiActionRequest, widgetId?: string, nodeId?: string): Promise<any>;
48
50
  handleSpecificDemandsAsynchronously(uiAction: UiAction, uiActionRequest: UiActionRequest): Promise<UiActionSpecificDemandResponse>;
51
+ addSmartLayout(layout: SmartComponentLayoutDefinition): void;
52
+ private setParentComponent;
49
53
  addGrid(smartGrid: SmartGrid, options: GridOptions, useAsDefaultGrid?: boolean, componentReference?: SmartGridComponent): SmartGrid;
50
54
  addForm(smartFormId: string, smartForm: SmartForm, componentReference?: SmartformComponent): SmartForm;
51
55
  setUpDefaultTree(treeId: string): void;
@@ -0,0 +1,21 @@
1
+ import { OnChanges, SimpleChanges } from '@angular/core';
2
+ import { ComponentType, SmartComponentLayoutDefinition } from './smart-component-layout.model';
3
+ import { SmartForm, SmartformComponent, SmartformLayoutDefinitionService } from '@smartbit4all/form';
4
+ import { SmartGrid, SmartGridComponent } from '@smartbit4all/grid';
5
+ import * as i0 from "@angular/core";
6
+ export declare class SmartComponentLayoutComponent implements OnChanges {
7
+ private layoutService;
8
+ smartComponentLayout?: SmartComponentLayoutDefinition;
9
+ formChild?: SmartformComponent;
10
+ smartForm?: SmartForm;
11
+ gridChild?: SmartGridComponent;
12
+ smartGrid?: SmartGrid;
13
+ constructor(layoutService: SmartformLayoutDefinitionService);
14
+ ngOnChanges(changes: SimpleChanges): void;
15
+ type(): typeof ComponentType;
16
+ constructForm(): void;
17
+ makeid(length: number): string;
18
+ constructGrid(): void;
19
+ static ɵfac: i0.ɵɵFactoryDeclaration<SmartComponentLayoutComponent, never>;
20
+ static ɵcmp: i0.ɵɵComponentDeclaration<SmartComponentLayoutComponent, "smart-component-layout", never, { "smartComponentLayout": "smartComponentLayout"; }, {}, never, never>;
21
+ }
@@ -0,0 +1,30 @@
1
+ import { SmartWidgetDefinition } from '@smartbit4all/form';
2
+ import { SmartComponentApiClient } from '../smart-component-api-client';
3
+ export interface SmartComponentLayoutDefinition {
4
+ type: ComponentType;
5
+ expandable?: boolean;
6
+ direction?: LayoutDirection;
7
+ parentComponent: SmartComponentApiClient<any>;
8
+ components?: SmartComponentLayoutDefinition[];
9
+ widget?: SmartComponentWidgetDefinition;
10
+ form?: SmartWidgetDefinition[];
11
+ }
12
+ export interface SmartComponentWidgetDefinition {
13
+ type: ComponentWidgetType;
14
+ gridIdentifier?: string;
15
+ }
16
+ export declare type LayoutDirection = 'horizontal' | 'vertical';
17
+ export declare const LayoutDirection: {
18
+ Horizontal: LayoutDirection;
19
+ Vertical: LayoutDirection;
20
+ };
21
+ export declare type ComponentType = 'container' | 'form' | 'widget';
22
+ export declare const ComponentType: {
23
+ Container: ComponentType;
24
+ Form: ComponentType;
25
+ Widget: ComponentType;
26
+ };
27
+ export declare type ComponentWidgetType = 'grid';
28
+ export declare const ComponentWidgetType: {
29
+ Grid: "grid";
30
+ };
@@ -1,12 +1,14 @@
1
1
  import * as i0 from "@angular/core";
2
2
  import * as i1 from "./smart-client/smart-file-uploader/smart-file-uploader.component";
3
- import * as i2 from "@angular/platform-browser";
4
- import * as i3 from "@angular/material/core";
5
- import * as i4 from "./session/smart-session.module";
6
- import * as i5 from "./view-context/smart-view-context.module";
7
- import * as i6 from "@smartbit4all/form";
3
+ import * as i2 from "./smart-client/smart-component-layout/smart-component-layout.component";
4
+ import * as i3 from "@angular/platform-browser";
5
+ import * as i4 from "@angular/material/core";
6
+ import * as i5 from "./session/smart-session.module";
7
+ import * as i6 from "./view-context/smart-view-context.module";
8
+ import * as i7 from "@smartbit4all/form";
9
+ import * as i8 from "@smartbit4all/grid";
8
10
  export declare class SmartNgClientModule {
9
11
  static ɵfac: i0.ɵɵFactoryDeclaration<SmartNgClientModule, never>;
10
- static ɵmod: i0.ɵɵNgModuleDeclaration<SmartNgClientModule, [typeof i1.SmartFileUploaderComponent], [typeof i2.BrowserModule, typeof i3.MatCommonModule, typeof i4.SmartSessionModule, typeof i5.SmartViewContextModule, typeof i6.SmartformModule], [typeof i4.SmartSessionModule, typeof i5.SmartViewContextModule, typeof i1.SmartFileUploaderComponent]>;
12
+ static ɵmod: i0.ɵɵNgModuleDeclaration<SmartNgClientModule, [typeof i1.SmartFileUploaderComponent, typeof i2.SmartComponentLayoutComponent], [typeof i3.BrowserModule, typeof i4.MatCommonModule, typeof i5.SmartSessionModule, typeof i6.SmartViewContextModule, typeof i7.SmartformModule, typeof i8.SmartGridModule], [typeof i5.SmartSessionModule, typeof i6.SmartViewContextModule, typeof i1.SmartFileUploaderComponent, typeof i2.SmartComponentLayoutComponent]>;
11
13
  static ɵinj: i0.ɵɵInjectorDeclaration<SmartNgClientModule>;
12
14
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smartbit4all/ng-client",
3
- "version": "1.1.34",
3
+ "version": "1.1.36",
4
4
  "schematics": "./schematics/collection.json",
5
5
  "peerDependencies": {
6
6
  "@angular/common": "^13.2.0",
package/projects.d.ts CHANGED
@@ -1,6 +1,8 @@
1
1
  export * from './lib/smart-ng-client.service';
2
2
  export * from './lib/smart-ng-client.module';
3
3
  export * from './lib/smart-client/smart-file-uploader/smart-file-uploader.component';
4
+ export * from './lib/smart-client/smart-component-layout/smart-component-layout.component';
5
+ export * from './lib/smart-client/smart-component-layout/smart-component-layout.model';
4
6
  export * from './lib/view-context/projects';
5
7
  export * from './lib/session/projects';
6
8
  export * from './lib/smart-client/projects';
Binary file